Merge pull request #144 from bithug/master
Allow disabling embedded Bitcode
This commit is contained in:
commit
173110e9b4
|
@ -50,6 +50,7 @@ echo_help()
|
||||||
echo " --ios-sdk=SDKVERSION Override iOS SDK version"
|
echo " --ios-sdk=SDKVERSION Override iOS SDK version"
|
||||||
echo " --noparallel Disable running make with parallel jobs (make -j)"
|
echo " --noparallel Disable running make with parallel jobs (make -j)"
|
||||||
echo " --tvos-sdk=SDKVERSION Override tvOS SDK version"
|
echo " --tvos-sdk=SDKVERSION Override tvOS SDK version"
|
||||||
|
echo " --disable-bitcode Disable embedding Bitcode"
|
||||||
echo " -v, --verbose Enable verbose logging"
|
echo " -v, --verbose Enable verbose logging"
|
||||||
echo " --verbose-on-error Dump last 500 lines from log file if an error occurs (for Travis builds)"
|
echo " --verbose-on-error Dump last 500 lines from log file if an error occurs (for Travis builds)"
|
||||||
echo " --version=VERSION OpenSSL version to build (defaults to ${DEFAULTVERSION})"
|
echo " --version=VERSION OpenSSL version to build (defaults to ${DEFAULTVERSION})"
|
||||||
|
@ -189,6 +190,7 @@ ARCHS=""
|
||||||
BRANCH=""
|
BRANCH=""
|
||||||
CLEANUP=""
|
CLEANUP=""
|
||||||
CONFIG_ENABLE_EC_NISTP_64_GCC_128=""
|
CONFIG_ENABLE_EC_NISTP_64_GCC_128=""
|
||||||
|
CONFIG_DISABLE_BITCODE=""
|
||||||
CONFIG_NO_DEPRECATED=""
|
CONFIG_NO_DEPRECATED=""
|
||||||
IOS_SDKVERSION=""
|
IOS_SDKVERSION=""
|
||||||
LOG_VERBOSE=""
|
LOG_VERBOSE=""
|
||||||
|
@ -218,6 +220,9 @@ case $i in
|
||||||
--ec-nistp-64-gcc-128)
|
--ec-nistp-64-gcc-128)
|
||||||
CONFIG_ENABLE_EC_NISTP_64_GCC_128="true"
|
CONFIG_ENABLE_EC_NISTP_64_GCC_128="true"
|
||||||
;;
|
;;
|
||||||
|
--disable-bitcode)
|
||||||
|
CONFIG_DISABLE_BITCODE="true"
|
||||||
|
;;
|
||||||
-h|--help)
|
-h|--help)
|
||||||
echo_help
|
echo_help
|
||||||
exit
|
exit
|
||||||
|
@ -377,6 +382,9 @@ else
|
||||||
fi
|
fi
|
||||||
echo " iOS SDK: ${IOS_SDKVERSION}"
|
echo " iOS SDK: ${IOS_SDKVERSION}"
|
||||||
echo " tvOS SDK: ${TVOS_SDKVERSION}"
|
echo " tvOS SDK: ${TVOS_SDKVERSION}"
|
||||||
|
if [ "${CONFIG_DISABLE_BITCODE}" == "true" ]; then
|
||||||
|
echo " Bitcode embedding disabled"
|
||||||
|
fi
|
||||||
echo " Number of make threads: ${BUILD_THREADS}"
|
echo " Number of make threads: ${BUILD_THREADS}"
|
||||||
if [ -n "${CONFIG_OPTIONS}" ]; then
|
if [ -n "${CONFIG_OPTIONS}" ]; then
|
||||||
echo " Configure options: ${CONFIG_OPTIONS}"
|
echo " Configure options: ${CONFIG_OPTIONS}"
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
"ios-tvos-cross-base" => {
|
"ios-tvos-cross-base" => {
|
||||||
template => 1,
|
template => 1,
|
||||||
cflags => combine('-isysroot $(CROSS_TOP)/SDKs/$(CROSS_SDK) -fno-common',
|
cflags => combine('-isysroot $(CROSS_TOP)/SDKs/$(CROSS_SDK) -fno-common',
|
||||||
sub { (defined($ENV{'SDKVERSION'}) && $ENV{'SDKVERSION'} =~ /^(9|[1-9][0-9]+)\./ && $disabled{shared})
|
sub { ((!defined($ENV{'CONFIG_DISABLE_BITCODE'}) || $ENV{'CONFIG_DISABLE_BITCODE'} ne 'true') && defined($ENV{'SDKVERSION'}) && $ENV{'SDKVERSION'} =~ /^(9|[1-9][0-9]+)\./ && $disabled{shared})
|
||||||
? '-fembed-bitcode' : (); },
|
? '-fembed-bitcode' : (); },
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
|
|
|
@ -61,8 +61,10 @@ do
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Embed bitcode for SDK >= 9
|
# Embed bitcode for SDK >= 9
|
||||||
if [[ "${SDKVERSION}" == 9.* || "${SDKVERSION}" == [0-9][0-9].* ]]; then
|
if [ "${CONFIG_DISABLE_BITCODE}" != "true" ]; then
|
||||||
LOCAL_CONFIG_OPTIONS="${LOCAL_CONFIG_OPTIONS} -fembed-bitcode"
|
if [[ "${SDKVERSION}" == 9.* || "${SDKVERSION}" == [0-9][0-9].* ]]; then
|
||||||
|
LOCAL_CONFIG_OPTIONS="${LOCAL_CONFIG_OPTIONS} -fembed-bitcode"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Add platform specific config options
|
# Add platform specific config options
|
||||||
|
|
|
@ -32,6 +32,7 @@ do
|
||||||
export SDKVERSION
|
export SDKVERSION
|
||||||
export IOS_MIN_SDK_VERSION
|
export IOS_MIN_SDK_VERSION
|
||||||
export TVOS_MIN_SDK_VERSION
|
export TVOS_MIN_SDK_VERSION
|
||||||
|
export CONFIG_DISABLE_BITCODE
|
||||||
|
|
||||||
# Determine platform
|
# Determine platform
|
||||||
if [[ "${TARGET}" == "ios-sim-cross-"* ]]; then
|
if [[ "${TARGET}" == "ios-sim-cross-"* ]]; then
|
||||||
|
|
Loading…
Reference in New Issue