aboutsummaryrefslogtreecommitdiff
path: root/examples/c/CMakeLists.txt
blob: ea5e7747efd75c66e2417b30a61b3803ea59df6e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
if(CMAKE_HOST_WIN32)
    set(libname "libconfig")
else()
    set(libname "config")
endif()

add_executable(c_example1 example1.c )
add_executable(c_example2 example2.c )
add_executable(c_example3 example3.c )

target_include_directories(c_example1 PRIVATE ${CMAKE_SOURCE_DIR}/lib)
target_include_directories(c_example2 PRIVATE ${CMAKE_SOURCE_DIR}/lib)
target_include_directories(c_example3 PRIVATE ${CMAKE_SOURCE_DIR}/lib)

target_link_libraries(c_example1 ${libname} )
target_link_libraries(c_example2 ${libname} )
target_link_libraries(c_example3 ${libname} )