-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathCMakeLists.txt
43 lines (40 loc) · 1.12 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Copyright (c) 2018-2019 Snowflake Computing, Inc. All rights reserved.
# include public headers and test utils
include_directories(
"../include"
"utils")
set(SOURCE_UTILS
utils/example_setup.c
utils/example_setup.h)
if (LINUX)
FOREACH(EX ${EXAMPLES})
add_executable(ex_${EX} ${SOURCE_UTILS} ${EX}.c)
target_link_libraries(
ex_${EX}
snowflakeclient
-Wl,--whole-archive curl ssl crypto -Wl,--no-whole-archive
)
ENDFOREACH ()
endif ()
if (APPLE)
FOREACH (EX ${EXAMPLES})
add_executable(ex_${EX} ${SOURCE_UTILS} ${EX}.c)
target_link_libraries(
ex_${EX}
z m
"-framework CoreFoundation"
snowflakeclient
-all_load curl ssl crypto
)
ENDFOREACH()
endif()
if (WIN32)
FOREACH (EX ${EXAMPLES})
add_executable(ex_${EX} ${SOURCE_UTILS} ${EX}.c)
target_link_libraries(
ex_${EX}
snowflakeclient
libcurl_a libssl_a libcrypto_a zlib_a
)
ENDFOREACH ()
endif ()