mirror of
https://github.com/30hours/blah2.git
synced 2024-11-08 12:25:42 +00:00
CMake add Werror Wall and tidy
This commit is contained in:
parent
fb839736cf
commit
ef0739a49b
1 changed files with 10 additions and 8 deletions
|
@ -7,6 +7,8 @@ project(blah2)
|
||||||
include(CMakePrintHelpers)
|
include(CMakePrintHelpers)
|
||||||
include(CTest)
|
include(CTest)
|
||||||
|
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror")
|
||||||
|
|
||||||
find_package(Threads REQUIRED)
|
find_package(Threads REQUIRED)
|
||||||
find_package(asio REQUIRED)
|
find_package(asio REQUIRED)
|
||||||
find_path(RAPIDJSON_INCLUDE_DIRS "rapidjson/allocators.h")
|
find_path(RAPIDJSON_INCLUDE_DIRS "rapidjson/allocators.h")
|
||||||
|
@ -18,15 +20,15 @@ find_package(Catch2 CONFIG REQUIRED)
|
||||||
set(CMAKE_PREFIX_PATH "/opt/uhd" ${CMAKE_PREFIX_PATH})
|
set(CMAKE_PREFIX_PATH "/opt/uhd" ${CMAKE_PREFIX_PATH})
|
||||||
find_package(UHD "4.6.0.0" CONFIG REQUIRED)
|
find_package(UHD "4.6.0.0" CONFIG REQUIRED)
|
||||||
|
|
||||||
SET (PROJECT_ROOT "${PROJECT_SOURCE_DIR}")
|
set(PROJECT_ROOT "${PROJECT_SOURCE_DIR}")
|
||||||
SET (CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_ROOT}/bin")
|
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PROJECT_ROOT}/bin")
|
||||||
SET (PROJECT_BINARY_TEST_DIR "${PROJECT_ROOT}/bin/test")
|
set(PROJECT_BINARY_TEST_DIR "${PROJECT_ROOT}/bin/test")
|
||||||
SET (PROJECT_BINARY_TEST_UNIT_DIR "${PROJECT_BINARY_TEST_DIR}/unit")
|
set(PROJECT_BINARY_TEST_UNIT_DIR "${PROJECT_BINARY_TEST_DIR}/unit")
|
||||||
SET (PROJECT_BINARY_TEST_FUNCTIONAL_DIR "${PROJECT_BINARY_TEST_DIR}/functional")
|
set(PROJECT_BINARY_TEST_FUNCTIONAL_DIR "${PROJECT_BINARY_TEST_DIR}/functional")
|
||||||
SET (PROJECT_BINARY_TEST_COMPARISON_DIR "${PROJECT_BINARY_TEST_DIR}/comparison")
|
set(PROJECT_BINARY_TEST_COMPARISON_DIR "${PROJECT_BINARY_TEST_DIR}/comparison")
|
||||||
|
|
||||||
MESSAGE ("Binary path: ${PROJECT_BINARY_DIR}")
|
message("Binary path: ${PROJECT_BINARY_DIR}")
|
||||||
MESSAGE ("Binary test path: ${PROJECT_BINARY_TEST_DIR}")
|
message("Binary test path: ${PROJECT_BINARY_TEST_DIR}")
|
||||||
|
|
||||||
# include from top-level src dir
|
# include from top-level src dir
|
||||||
include_directories(src ${UHD_INCLUDE_DIRS})
|
include_directories(src ${UHD_INCLUDE_DIRS})
|
||||||
|
|
Loading…
Reference in a new issue