-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
77 lines (63 loc) · 1.94 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
CMAKE_MINIMUM_REQUIRED( VERSION 2.8)
project(updatedeployqt)
# Let cmake know that this is a release build.
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release)
endif()
set(CMAKE_C_FLAGS "-Wall -Wextra")
set(CMAKE_C_FLAGS_DEBUG "-g")
set(CMAKE_C_FLAGS_RELEASE "-O3")
# Include Directories.
include_directories(.)
include_directories(include)
add_definitions(-DJSON_TRACK_SOURCE) # tell json-parser to track the line from json files.
SET(source)
list(APPEND source src/logger.c
src/qt_version_info.c
src/json.c
src/utils.c
src/args_parser.c
src/config_manager.c
src/config_generator.c
src/deploy_info.c
src/bridge_deployer.c
src/library_deployer.c
src/injector.c
src/md5.c
src/main.c
src/json_builder.c
include/json_builder.h
include/logger.h
include/md5.h
include/utils.h
include/qt_version_info.h
include/deploy_info.h
include/injector.h
include/bridge_deployer.h
include/library_deployer.h
include/args_parser.h
include/config_manager.h
include/config_generator.h
include/json.h)
if(CACHE_DIR)
message("-- Will be static linking with libgcc.")
set(CMAKE_EXE_LINKER_FLAGS "--static -static-libgcc")
include_directories(${CACHE_DIR})
add_definitions(-DBINARIES_PACKAGED_HEADER_AVAL)
list(APPEND source ${CACHE_DIR}/libqxcb_5_6_0.h
${CACHE_DIR}/libqxcb_5_7_0.h
${CACHE_DIR}/libqxcb_5_8_0.h
${CACHE_DIR}/libqxcb_5_9_0.h
${CACHE_DIR}/libqxcb_5_10_0.h
${CACHE_DIR}/aiub.h)
endif()
if(GIT_COMMIT_STR)
add_definitions(-DGIT_COMMIT_STR="${GIT_COMMIT_STR}")
endif()
add_executable(updatedeployqt ${source})
target_link_libraries(updatedeployqt PUBLIC m)
target_include_directories(updatedeployqt PUBLIC . include)
install(
TARGETS updatedeployqt
RUNTIME DESTINATION bin
)