aboutsummaryrefslogtreecommitdiff
path: root/app/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'app/CMakeLists.txt')
-rw-r--r--app/CMakeLists.txt7
1 files changed, 5 insertions, 2 deletions
diff --git a/app/CMakeLists.txt b/app/CMakeLists.txt
index 3cba6fa..7f90c2c 100644
--- a/app/CMakeLists.txt
+++ b/app/CMakeLists.txt
@@ -1,6 +1,9 @@
1cmake_minimum_required(VERSION 3.4.1) 1cmake_minimum_required(VERSION 3.4.1)
2include(ExternalProject) 2include(ExternalProject)
3 3
4set(CC_OPTIMISATION_FLAGS "-ffunction-sections -fdata-sections")
5set(LD_OPTIMISATION_FLAGS "-Wl,--gc-sections")
6
4set(xCONFIG 7set(xCONFIG
5 "CC=${CMAKE_C_COMPILER} \ 8 "CC=${CMAKE_C_COMPILER} \
6 ${CMAKE_C_COMPILE_OPTIONS_EXTERNAL_TOOLCHAIN}${CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN} \ 9 ${CMAKE_C_COMPILE_OPTIONS_EXTERNAL_TOOLCHAIN}${CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN} \
@@ -9,8 +12,8 @@ set(xCONFIG
9 "LD=${CMAKE_LINKER}" 12 "LD=${CMAKE_LINKER}"
10 "AR=${CMAKE_AR}" 13 "AR=${CMAKE_AR}"
11 "RANLIB=${CMAKE_RANLIB}" 14 "RANLIB=${CMAKE_RANLIB}"
12 "CFLAGS=${CMAKE_C_FLAGS}" 15 "CFLAGS=${CMAKE_C_FLAGS} ${CC_OPTIMISATION_FLAGS}"
13 "LDFLAGS=${CMAKE_SHARED_LINKER_FLAGS}" 16 "LDFLAGS=${CMAKE_SHARED_LINKER_FLAGS} ${LD_OPTIMISATION_FLAGS}"
14 "--host=${CMAKE_C_COMPILER_TARGET}" 17 "--host=${CMAKE_C_COMPILER_TARGET}"
15) 18)
16 19