Created
February 23, 2015 15:22
-
-
Save manuelm/f71c1d33a57e5bcca758 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/project/cmake/kodi-config.cmake.in b/project/cmake/kodi-config.cmake.in | |
index 0e3b158..5dcf42c 100644 | |
--- a/project/cmake/kodi-config.cmake.in | |
+++ b/project/cmake/kodi-config.cmake.in | |
@@ -3,7 +3,7 @@ SET(APP_NAME @APP_NAME@) | |
SET(APP_VERSION_MAJOR @APP_VERSION_MAJOR@) | |
SET(APP_VERSION_MINOR @APP_VERSION_MINOR@) | |
IF(NOT WIN32) | |
- SET(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} @CXX11_SWITCH@") | |
+ SET(CMAKE_CXX_FLAGS "$ENV{CXXFLAGS} ${CMAKE_CXX_FLAGS} @CXX11_SWITCH@") | |
ENDIF() | |
LIST(APPEND CMAKE_MODULE_PATH @prefix@/lib/kodi) | |
ADD_DEFINITIONS(@ARCH_DEFINES@) | |
diff --git a/project/cmake/scripts/common/handle-depends.cmake b/project/cmake/scripts/common/handle-depends.cmake | |
index f0ae25f..eb0aae7 100644 | |
--- a/project/cmake/scripts/common/handle-depends.cmake | |
+++ b/project/cmake/scripts/common/handle-depends.cmake | |
@@ -63,8 +63,11 @@ function(add_addon_depends addon searchpath) | |
# TODO: figure out if we should use -DCMAKE_C_FLAGS="${CMAKE_C_FLAGS} ${ARCH_DEFINES}" and why it doesn't work | |
# TODO: figure out why this doesn't work for OSX32 and IOS/ATV2 | |
if(NOT CMAKE_USER_MAKE_RULES_OVERRIDE AND NOT CMAKE_USER_MAKE_RULES_OVERRIDE_CXX AND NOT APPLE) | |
- list(APPEND BUILD_ARGS -DCMAKE_C_FLAGS=${ARCH_DEFINES} | |
- -DCMAKE_CXX_FLAGS=${ARCH_DEFINES}) | |
+ # make sure we create strings, not lists | |
+ set(TMP_C_FLAGS "${CMAKE_C_FLAGS} ${ARCH_DEFINES}") | |
+ set(TMP_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${ARCH_DEFINES}") | |
+ list(APPEND BUILD_ARGS -DCMAKE_C_FLAGS=${TMP_C_FLAGS} | |
+ -DCMAKE_CXX_FLAGS=${TMP_CXX_FLAGS}) | |
endif() | |
if(CMAKE_TOOLCHAIN_FILE) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment