Enable cmake formatting (#53)
* enable cmake formatting * update style check workflow * update readme * update wording
This commit is contained in:
parent
4e87a9410a
commit
866ae707e5
8 changed files with 142 additions and 85 deletions
|
@ -1,8 +1,6 @@
|
|||
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
|
||||
|
||||
project(GreeterStandalone
|
||||
LANGUAGES CXX
|
||||
)
|
||||
project(GreeterStandalone LANGUAGES CXX)
|
||||
|
||||
# --- Import tools ----
|
||||
|
||||
|
@ -16,15 +14,10 @@ CPMAddPackage(
|
|||
NAME cxxopts
|
||||
GITHUB_REPOSITORY jarro2783/cxxopts
|
||||
VERSION 2.2.0
|
||||
OPTIONS
|
||||
"CXXOPTS_BUILD_EXAMPLES Off"
|
||||
"CXXOPTS_BUILD_TESTS Off"
|
||||
OPTIONS "CXXOPTS_BUILD_EXAMPLES Off" "CXXOPTS_BUILD_TESTS Off"
|
||||
)
|
||||
|
||||
CPMAddPackage(
|
||||
NAME Greeter
|
||||
SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/..
|
||||
)
|
||||
CPMAddPackage(NAME Greeter SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/..)
|
||||
|
||||
# ---- Create standalone executable ----
|
||||
|
||||
|
@ -32,9 +25,6 @@ file(GLOB sources CONFIGURE_DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/source/*.cpp)
|
|||
|
||||
add_executable(GreeterStandalone ${sources})
|
||||
|
||||
set_target_properties(GreeterStandalone PROPERTIES
|
||||
CXX_STANDARD 17
|
||||
OUTPUT_NAME "Greeter"
|
||||
)
|
||||
set_target_properties(GreeterStandalone PROPERTIES CXX_STANDARD 17 OUTPUT_NAME "Greeter")
|
||||
|
||||
target_link_libraries(GreeterStandalone Greeter cxxopts)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue