~allanlesage/libcolumbus/enable-coverage-option

« back to all changes in this revision

Viewing changes to CMakeLists.txt

  • Committer: Jussi Pakkanen
  • Date: 2013-04-03 13:50:54 UTC
  • mto: This revision was merged to the branch mainline in revision 443.
  • Revision ID: jussi.pakkanen@canonical.com-20130403135054-gzmxj4hsb1ts7s03
Enable -Wextra and fix unused warnings it produces.

Show diffs side-by-side

added added

removed removed

Lines of Context:
7
7
 
8
8
option(enable_tests "Enable tests." ON)
9
9
option(enable_scalability_tests "Additional scalability tests that are potentially very slow to run." OFF)
10
 
option(full_warnings "Full compiler warnings." ON)
 
10
option(full_warnings "All possible compiler warnings." OFF)
11
11
option(debug_messages "Print debug messages.")
12
12
option(full_unicode "Enable full Unicode support (takes lots of memory).")
13
13
option(use_python2 "Build Python bindings against Python 2 (UNSUPPORTED)." OFF)
21
21
include(cmake/python.cmake)
22
22
include(cmake/coverage.cmake)
23
23
 
 
24
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -pedantic -Wextra")
 
25
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra")
24
26
if(${full_warnings})
25
 
  set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -pedantic")
26
 
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic")
 
27
# C does not have any more warning flags.
 
28
  set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Weffc++")
27
29
endif()
28
30
 
29
31
if(${debug_messages})