From 5ef50ff268fe724e61518fc72c0bdd4d988fffdd Mon Sep 17 00:00:00 2001 From: Gautier Pelloux-Prayer Date: Fri, 27 Feb 2015 15:10:10 +0100 Subject: [PATCH] Revert "iphone-config.site: use XXXFLAGS variables to set flags instead of using CC/CXX/OBJC compiler variables" This reverts commit d8fe77bd97bedec075a4577edc597ab2ce102545. Conflicts: submodules/build/builders.d/gsm.mk --- submodules/build/builders.d/gsm.mk | 5 +---- submodules/build/iphone-config.site | 31 ++++++++++++++--------------- 2 files changed, 16 insertions(+), 20 deletions(-) diff --git a/submodules/build/builders.d/gsm.mk b/submodules/build/builders.d/gsm.mk index ce686b064..c2f96fd2e 100644 --- a/submodules/build/builders.d/gsm.mk +++ b/submodules/build/builders.d/gsm.mk @@ -14,10 +14,7 @@ build-libgsm: cd $(BUILDER_BUILD_DIR)/$(gsm_dir)\ && mkdir -p $(prefix)/include/gsm \ && host_alias=$(host) . $(BUILDER_SRC_DIR)/build/$(config_site) \ - && make install \ - CC="$${CC} $${COMMON_FLAGS} -w" \ - INSTALL_ROOT=$(prefix) \ - GSM_INSTALL_INC=$(prefix)/include/gsm + && make -j1 CC="$${CC}" INSTALL_ROOT=$(prefix) GSM_INSTALL_INC=$(prefix)/include/gsm install clean-libgsm: cd $(BUILDER_BUILD_DIR)/$(gsm_dir)\ diff --git a/submodules/build/iphone-config.site b/submodules/build/iphone-config.site index 95812fc57..033e2bd0d 100644 --- a/submodules/build/iphone-config.site +++ b/submodules/build/iphone-config.site @@ -4,22 +4,22 @@ SDK_VERSION_MAJOR=5 SDK_VERSION=5.0 MCPU="" CLANG_TARGET_SPECIFIER=miphoneos-version-min -if test "${host_alias}" = "i386-apple-darwin" ; then +if test "${host_alias}" = "i386-apple-darwin" ; then PLATFORM=Simulator ARCH=i386 CMAKE_OPTS="-DCMAKE_SYSTEM_PROCESSOR=i386" MCPU="" CLANG_TARGET_SPECIFIER=mios-simulator-version-min -elif test "${host_alias}" = "armv7-apple-darwin" ; then +elif test "${host_alias}" = "armv7-apple-darwin" ; then ARCH=armv7 PLATFORM=OS CMAKE_OPTS="-DCMAKE_SYSTEM_PROCESSOR=arm" MCPU="-mcpu=cortex-a8" -elif test "${host_alias}" = "aarch64-apple-darwin" ; then +elif test "${host_alias}" = "aarch64-apple-darwin" ; then ARCH=arm64 PLATFORM=OS CMAKE_OPTS="-DCMAKE_SYSTEM_PROCESSOR=aarch64" -else +else echo "bad host ${host_alias} must be either i386-apple-darwin or arm[v7,64]-apple-darwin" exit fi @@ -28,12 +28,12 @@ XCODE_DEV_PATH=`xcode-select -print-path` #new path with Xcode 4.3: if test -d ${XCODE_DEV_PATH}/Platforms/iPhone${PLATFORM}.platform/Developer/SDKs ; then SDK_PATH_LIST=`ls -drt ${XCODE_DEV_PATH}/Platforms/iPhone${PLATFORM}.platform/Developer/SDKs/iPhone${PLATFORM}*` - SDK_BIN_PATH=${XCODE_DEV_PATH}/Platforms/iPhone${PLATFORM}.platform/Developer/usr/bin + SDK_BIN_PATH=${XCODE_DEV_PATH}/Platforms/iPhone${PLATFORM}.platform/Developer/usr/bin else SDK_PATH_LIST=`ls -drt /Developer/Platforms/iPhone${PLATFORM}.platform/Developer/SDKs/iPhone${PLATFORM}*` - SDK_BIN_PATH=/Developer/Platforms/iPhone${PLATFORM}.platform/Developer/usr/bin + SDK_BIN_PATH=/Developer/Platforms/iPhone${PLATFORM}.platform/Developer/usr/bin fi - + for SYSROOT_PATH in $SDK_PATH_LIST ; do echo $SYSROOT_PATH ; done ; echo "Selecting SDK path = ${SYSROOT_PATH}" @@ -47,24 +47,23 @@ COMMON_FLAGS="$COMMON_FLAGS -Dsha256=polarssl_sha256" COMMON_FLAGS="-Qunused-arguments -Wno-unknown-warning-option -Wno-unused-command-line-argument-hard-error-in-future $COMMON_FLAGS" # you can use ccache to speed up build, in which case just define LINPHONE_CCACHE to 'ccache' -if test "$LINPHONE_CCACHE" = "ccache" ; then + +if test "$LINPHONE_CCACHE" = "ccache" ; then # ccache doesn't like some options COMMON_FLAGS="$COMMON_FLAGS -Wno-variadic-macros -Wno-pointer-arith -Wno-return-type -Wno-tautological-compare -Wno-unused-function -Wno-error" fi -CC="xcrun $LINPHONE_CCACHE clang" -OBJC="xcrun $LINPHONE_CCACHE clang" -CXX="xcrun $LINPHONE_CCACHE clang++" -LD="xcrun ld" +CC="xcrun $LINPHONE_CCACHE clang -std=c99 $COMMON_FLAGS" +OBJC="xcrun $LINPHONE_CCACHE clang -std=c99 $COMMON_FLAGS" +CXX="xcrun $LINPHONE_CCACHE clang++ $COMMON_FLAGS" +LD="xcrun ld -arch ${ARCH}" AR="xcrun ar" RANLIB="xcrun ranlib" STRIP="xcrun strip" NM="xcrun nm" -LDFLAGS="-arch ${ARCH}" -CFLAGS="$COMMON_FLAGS -std=c99" -CPPFLAGS="$COMMON_FLAGS -Dasm=__asm" -OBJCFLAGS="$COMMON_FLAGS -std=c99 -x objective-c -fexceptions -gdwarf-2 -fobjc-abi-version=2 -fobjc-legacy-dispatch" +CPPFLAGS="-Dasm=__asm" +OBJCFLAGS="-x objective-c -fexceptions -gdwarf-2 -fobjc-abi-version=2 -fobjc-legacy-dispatch" #Force install script to use -C so that header files don't get re-written if not changed. INSTALL_DATA="ginstall -C"