Enable ObjC build by default and reenable 64-bit mac libjingle build
BUG=2124 TESTED=trybots & building for mac, mac64, ios-sim, and ios-device on my MBP all build everything in out/Debug. R=niklas.enbom@webrtc.org, wu@webrtc.org Review URL: https://webrtc-codereview.appspot.com/2080004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@4620 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
4498d013f6
commit
e3de6b1e90
8
all.gyp
8
all.gyp
@ -14,18 +14,10 @@
|
||||
'type': 'none',
|
||||
'dependencies': [
|
||||
'webrtc/webrtc.gyp:*',
|
||||
],
|
||||
# TODO(henrike): fix build errors on 64 bit Mac for libjingle. See issue
|
||||
# 2124. Once done the entire conditional below can be removed.
|
||||
'conditions': [
|
||||
['OS!="mac" or target_arch!="x64" or libjingle_objc==1', {
|
||||
'dependencies': [
|
||||
'talk/libjingle.gyp:*',
|
||||
'talk/libjingle_examples.gyp:*',
|
||||
'talk/libjingle_tests.gyp:*',
|
||||
],
|
||||
}],
|
||||
],
|
||||
},
|
||||
],
|
||||
}
|
||||
|
@ -36,8 +36,6 @@
|
||||
# flood of chromium-style warnings.
|
||||
'clang_use_chrome_plugins%': 0,
|
||||
'libpeer_target_type%': 'static_library',
|
||||
# Whether or not to build the ObjectiveC PeerConnection API & tests.
|
||||
'libjingle_objc%': 0,
|
||||
'conditions': [
|
||||
['OS=="android" or OS=="linux"', {
|
||||
# TODO(henrike): make sure waterfall bots have $JAVA_HOME configured
|
||||
@ -110,7 +108,7 @@
|
||||
'HAVE_OPENSSL_SSL_H=1',
|
||||
],
|
||||
}],
|
||||
['libjingle_objc==1', {
|
||||
['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
|
||||
'defines': [
|
||||
'CARBON_DEPRECATED=YES',
|
||||
],
|
||||
|
@ -42,7 +42,6 @@
|
||||
}],
|
||||
],
|
||||
}],
|
||||
|
||||
['OS=="linux" or OS=="android"', {
|
||||
'targets': [
|
||||
{
|
||||
@ -150,7 +149,7 @@
|
||||
},
|
||||
],
|
||||
}],
|
||||
['libjingle_objc == 1', {
|
||||
['OS=="ios" or (OS=="mac" and target_arch!="ia32")', {
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'libjingle_peerconnection_objc',
|
||||
@ -234,8 +233,8 @@
|
||||
'xcode_settings': {
|
||||
'CLANG_ENABLE_OBJC_ARC': 'YES',
|
||||
},
|
||||
}
|
||||
]
|
||||
}, # target libjingle_peerconnection_objc
|
||||
],
|
||||
}],
|
||||
],
|
||||
|
||||
@ -591,17 +590,6 @@
|
||||
],
|
||||
}],
|
||||
['OS=="mac"', {
|
||||
'conditions': [
|
||||
['libjingle_objc != 1', {
|
||||
'link_settings' :{
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-framework Carbon',
|
||||
],
|
||||
},
|
||||
},
|
||||
}],
|
||||
],
|
||||
'sources': [
|
||||
'base/macasyncsocket.cc',
|
||||
'base/macasyncsocket.h',
|
||||
@ -622,15 +610,33 @@
|
||||
'$(SDKROOT)/usr/lib/libcrypto.dylib',
|
||||
'$(SDKROOT)/usr/lib/libssl.dylib',
|
||||
],
|
||||
},
|
||||
'all_dependent_settings': {
|
||||
'link_settings': {
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-framework Cocoa',
|
||||
'-framework Foundation',
|
||||
'-framework IOKit',
|
||||
'-framework Security',
|
||||
'-framework SystemConfiguration',
|
||||
],
|
||||
},
|
||||
},
|
||||
},
|
||||
'conditions': [
|
||||
['target_arch=="ia32"', {
|
||||
'all_dependent_settings': {
|
||||
'link_settings': {
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-framework Carbon',
|
||||
],
|
||||
},
|
||||
},
|
||||
},
|
||||
}],
|
||||
],
|
||||
}],
|
||||
['OS=="ios"', {
|
||||
'sources': [
|
||||
@ -639,14 +645,17 @@
|
||||
'dependencies': [
|
||||
'../net/third_party/nss/ssl.gyp:libssl',
|
||||
],
|
||||
'all_dependent_settings': {
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-framework Foundation',
|
||||
'-framework IOKit',
|
||||
'-framework Security',
|
||||
'-framework SystemConfiguration',
|
||||
'-framework UIKit',
|
||||
],
|
||||
},
|
||||
},
|
||||
}],
|
||||
['OS=="win"', {
|
||||
'sources': [
|
||||
@ -903,12 +912,18 @@
|
||||
'media/devices/macdevicemanagermm.mm',
|
||||
],
|
||||
'conditions': [
|
||||
# TODO(hughv): Investigate if this is needed.
|
||||
[ 'libjingle_objc != 1', {
|
||||
['target_arch=="ia32"', {
|
||||
'sources': [
|
||||
'media/devices/carbonvideorenderer.cc',
|
||||
'media/devices/carbonvideorenderer.h',
|
||||
],
|
||||
'link_settings': {
|
||||
'xcode_settings': {
|
||||
'OTHER_LDFLAGS': [
|
||||
'-framework Carbon',
|
||||
],
|
||||
},
|
||||
},
|
||||
}],
|
||||
],
|
||||
'xcode_settings': {
|
||||
|
@ -218,7 +218,7 @@
|
||||
], # targets
|
||||
}], # OS=="linux" or OS=="win"
|
||||
|
||||
['libjingle_objc==1 and OS=="ios"', {
|
||||
['OS=="ios"', {
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'AppRTCDemo',
|
||||
@ -276,17 +276,23 @@
|
||||
# we could pick more intelligently among the keys, but as a
|
||||
# first cut just tell the developer to specify a key identity
|
||||
# explicitly.
|
||||
'ensure_single_key': '<!(python -c "assert len(\'\'\'<(key_id)\'\'\') > 0 and \'\\n\' not in \'\'\'<(key_id)\'\'\', \'key_id gyp variable needs to be set explicitly because there are multiple codesigning keys, or none!\'")',
|
||||
'ensure_single_key': '<!(python -c "assert \'\\n\' not in \'\'\'<(key_id)\'\'\', \'key_id gyp variable needs to be set explicitly because there are multiple codesigning keys!\'")',
|
||||
},
|
||||
'conditions': [
|
||||
['key_id==""', {
|
||||
'action': [ 'echo', 'Skipping signing' ],
|
||||
}, {
|
||||
'action': [
|
||||
'/usr/bin/codesign', '-v', '--force', '--sign', '<(key_id)',
|
||||
'${BUILT_PRODUCTS_DIR}/AppRTCDemo.app',
|
||||
],
|
||||
}],
|
||||
],
|
||||
},
|
||||
],
|
||||
}, # target AppRTCDemo
|
||||
], # targets
|
||||
}], # libjingle_objc==1
|
||||
}], # OS=="ios"
|
||||
|
||||
['OS=="android"', {
|
||||
'targets': [
|
||||
|
@ -464,13 +464,16 @@
|
||||
},
|
||||
],
|
||||
}],
|
||||
['libjingle_objc == 1', {
|
||||
['OS=="ios" or (OS=="mac" and target_arch!="ia32" and mac_sdk>="10.7")', {
|
||||
# The >=10.7 above is required to make ARC link cleanly (e.g. as
|
||||
# opposed to _compile_ cleanly, which the library under test
|
||||
# does just fine on 10.6 too).
|
||||
'targets': [
|
||||
{
|
||||
'target_name': 'libjingle_peerconnection_objc_test',
|
||||
'variables': {
|
||||
'infoplist_file': './app/webrtc/objctests/Info.plist',
|
||||
},
|
||||
'target_name': 'libjingle_peerconnection_objc_test',
|
||||
'type': 'executable',
|
||||
'mac_bundle': 1,
|
||||
'mac_bundle_resources': [
|
||||
@ -510,7 +513,7 @@
|
||||
],
|
||||
}],
|
||||
],
|
||||
},
|
||||
}, # target libjingle_peerconnection_objc_test
|
||||
],
|
||||
}],
|
||||
],
|
||||
|
@ -1,4 +1,4 @@
|
||||
#!/bin/bash
|
||||
#!/bin/bash -e
|
||||
|
||||
# Copyright (c) 2013 The WebRTC project authors. All Rights Reserved.
|
||||
#
|
||||
@ -8,66 +8,18 @@
|
||||
# in the file PATENTS. All contributing project authors may
|
||||
# be found in the AUTHORS file in the root of the source tree.
|
||||
|
||||
function build_project() {
|
||||
# make the target string
|
||||
if [[ -z "$2" ]]; then
|
||||
target_string=""
|
||||
else
|
||||
declare -a arg_target=("${!2}")
|
||||
# Work in trunk/.
|
||||
cd "$(dirname $0)/../.."
|
||||
|
||||
for item in ${arg_target[*]}
|
||||
do
|
||||
temp_string="-target $item "
|
||||
target_string=$target_string$temp_string
|
||||
done
|
||||
fi
|
||||
export GYP_DEFINES="build_with_libjingle=1 build_with_chromium=0"
|
||||
GYP_DEFINES="$GYP_DEFINES OS=ios target_arch=armv7 key_id=\"\""
|
||||
export GYP_GENERATORS="ninja"
|
||||
export GYP_CROSSCOMPILE=1
|
||||
|
||||
# xcodebuild
|
||||
xcodebuild -project "$1" -sdk iphoneos \
|
||||
-configuration ${CONFIGURATION} \
|
||||
-CONFIGURATION_BUILD_DIR=${CONFIGURATION_BUILD_DIR} $target_string
|
||||
|
||||
if [ "$?" != "0" ]; then
|
||||
echo "[Error] build $1 failed!" 1>&2
|
||||
echo "@@@STEP_FAILURE@@@"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
# change the working directory to trunk
|
||||
cd "$( dirname "${BASH_SOURCE[0]}" )/../.."
|
||||
|
||||
# build setting
|
||||
CONFIGURATION_BUILD_DIR=./xcodebuild
|
||||
CONFIGURATION=Debug
|
||||
GYPDEF="OS=ios target_arch=arm armv7=1 arm_neon=1 enable_video=0 include_opus=1"
|
||||
|
||||
export GYP_DEFINES=$GYPDEF
|
||||
echo "[Running gclient runhooks...]"
|
||||
echo "@@@BUILD_STEP runhooks@@@"
|
||||
gclient runhooks
|
||||
if [ "$?" != "0" ]; then
|
||||
echo "[Error] gclient runhooks failed!" 1>&2
|
||||
echo "@@@STEP_FAILURE@@@"
|
||||
exit 2
|
||||
fi
|
||||
echo "[Projects updated]\n"
|
||||
gclient runhooks || { echo "@@@STEP_FAILURE@@@"; exit 2; }
|
||||
|
||||
echo "@@@BUILD_STEP compile@@@"
|
||||
echo "[Building XCode projects...]"
|
||||
array_target_module=(
|
||||
"bitrate_controller" "media_file" "paced_sender" "remote_bitrate_estimator"
|
||||
"webrtc_utility" "rtp_rtcp" "CNG" "G711" "G722" "iLBC" "iSACFix" "PCM16B"
|
||||
"audio_coding_module" "NetEq" "audio_conference_mixer" "audio_device"
|
||||
"audio_processing" "iSAC" "isac_neon" "audio_processing_neon" "webrtc_opus"
|
||||
)
|
||||
array_target_opus=("opus")
|
||||
|
||||
build_project "webrtc/common_audio/common_audio.xcodeproj"
|
||||
build_project "webrtc/modules/modules.xcodeproj" array_target_module[@]
|
||||
build_project "webrtc/system_wrappers/source/system_wrappers.xcodeproj"
|
||||
build_project "webrtc/voice_engine/voice_engine.xcodeproj"
|
||||
build_project "third_party/opus/opus.xcodeproj" array_target_opus[@]
|
||||
echo "[Building XCode projects is successful]\n"
|
||||
ninja -C out/Debug || { echo "@@@STEP_FAILURE@@@"; exit 2; }
|
||||
|
||||
exit 0
|
||||
|
@ -132,6 +132,7 @@
|
||||
'-framework AVFoundation',
|
||||
'-framework CoreMedia',
|
||||
'-framework CoreVideo',
|
||||
'-framework UIKit',
|
||||
],
|
||||
},
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user