|
|
Created:
8 years, 5 months ago by luke.weber Modified:
7 years, 6 months ago Reviewers:
Torne CC:
chromium-reviews Visibility:
Public. |
Description* Removed changes to envsetup.sh
* Moved pyauto check into it's own conditional
* Cleaned up code on the ar/ranlib/ld binary section for mac.
Patch Set 1 #Patch Set 2 : #Patch Set 3 : #Patch Set 4 : #Patch Set 5 : #
Total comments: 4
Patch Set 6 : #Patch Set 7 : #Patch Set 8 : #Messages
Total messages: 3 (0 generated)
I've only tested this on a webrtc build, so not sure if host_os is used in chromium extensively outside of common.gypi. It isn't used outside of this in webrtc, and I've removed the variable in favor of a new global HOST_OS. Haven't tested ninja.py, but tried to apply the same logic.
To make this useful/testable it really needs to work for all of Chromium, not just the part you are interested in. https://chromiumcodereview.appspot.com/10807048/diff/2003/android/envsetup.sh File android/envsetup.sh (left): https://chromiumcodereview.appspot.com/10807048/diff/2003/android/envsetup.sh... android/envsetup.sh:142: DEFINES+=" host_os=${host_os}" You need to update the references to host_os in every gyp file: there are still references in skia/skia.gyp, base/base.gyp, v8/tools/gyp/v8.gyp, v8/build/common.gypi Yes, this means you need to also submit a CL to V8 (once the change to gyp is in and has been rolled into V8). https://chromiumcodereview.appspot.com/10807048/diff/2003/common.gypi File common.gypi (right): https://chromiumcodereview.appspot.com/10807048/diff/2003/common.gypi#newcode817 common.gypi:817: 'conditions': [ Break this out into a separate conditions section instead of nesting it. I don't think pyauto is built for android currently, so it may be fine to just do os_posix==1 and OS!="mac" and OS!="android" https://chromiumcodereview.appspot.com/10807048/diff/2003/common.gypi#newcode... common.gypi:3130: ['CXX.host', '<!(which g++)'], Don't duplicate setting these to the same thing. Why is it necessary to set AR/LD/RANLIB here when it's not set for linux?
Incorporated feedback from Torne. Added some comments about specific reasons for the patch and the errors I'm having. https://chromiumcodereview.appspot.com/10807048/diff/2003/common.gypi File common.gypi (right): https://chromiumcodereview.appspot.com/10807048/diff/2003/common.gypi#newcode... common.gypi:3130: ['CXX.host', '<!(which g++)'], On 2012/08/01 11:28:51, Torne wrote: > Don't duplicate setting these to the same thing. Why is it necessary to set > AR/LD/RANLIB here when it's not set for linux? Disclaimer here, I'm building webrtc and libjingle. A lot of similar code, but there is a small chance you don't get this error on linux with the same codebase. I get this error on quite a few places for RANLIB: /Users/luke/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/darwin-x86/bin/arm-linux-androideabi-g++ '-DWEBRTC_SVNREVISION="n/a"' '-D_FILE_OFFSET_BITS=64' '-DNO_TCMALLOC' '-DDISABLE_NACL' '-DCHROMIUM_BUILD' '-DUSE_PROPRIETARY_CODECS' '-DENABLE_GPU=1' '-DUSE_OPENSSL=1' '-DENABLE_EGLIMAGE=1' '-DUSE_SKIA=1' '-DWEBRTC_LINUX' '-DWEBRTC_ANDROID' '-DWEBRTC_ARCH_ARM' '-DWEBRTC_CLOCK_TYPE_REALTIME' '-DWEBRTC_THREAD_RR' '-DWEBRTC_ANDROID_OPENSLES' '-DWEBRTC_NS_FIXED' '-DWEBRTC_AUDIOPROC_DEBUG_DUMP' '-DGOOGLE_PROTOBUF_NO_RTTI' '-DGOOGLE_PROTOBUF_NO_STATIC_INITIALIZER' '-D__STDC_FORMAT_MACROS' '-D__ARM_ARCH_5__' '-D__ARM_ARCH_5T__' '-D__ARM_ARCH_5E__' '-D__ARM_ARCH_5TE__' '-DANDROID' '-D__GNU_SOURCE=1' '-DUSE_STLPORT=1' '-D_STLP_USE_PTR_SPECIALIZATIONS=1' '-DHAVE_SYS_UIO_H' '-DANDROID_BINSIZE_HACK' '-DHAVE_OFF64_T' '-DDYNAMIC_ANNOTATIONS_ENABLED=1' '-DWTF_USE_DYNAMIC_ANNOTATIONS=1' '-D_DEBUG' -Ithird_party/webrtc -Ithird_party -Ithird_party/webrtc/modules/audio_processing/include -Ithird_party/webrtc/modules/interface -Ithird_party/webrtc/modules/audio_processing/aec/include -Ithird_party/webrtc/modules/audio_processing/aecm/include -Ithird_party/webrtc/modules/audio_processing/agc/include -Ithird_party/webrtc/common_audio/signal_processing/include -Ithird_party/webrtc/common_audio/vad/include -Ithird_party/webrtc/system_wrappers/interface -Ithird_party/webrtc/modules/audio_processing/ns/include -Iout/Debug/obj/gen/protoc_out -Ithird_party/protobuf -Ithird_party/protobuf/src -Werror -fno-exceptions -fno-strict-aliasing -Wall -Wno-unused-parameter -Wno-missing-field-initializers -fvisibility=hidden -pipe -fPIC -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -mthumb -fno-tree-sra -Wno-psabi -mthumb-interwork -march=armv5te -mtune=xscale -msoft-float -U__linux__ -ffunction-sections -funwind-tables -g -fstack-protector -fno-short-enums -finline-limit=64 -Wa,--noexecstack -Wno-error=non-virtual-dtor -I/Users/luke/android/android-ndk-r8b/platforms/android-9/arch-arm/usr/include -I/Users/luke/android/android-ndk-r8b/sources/cxx-stl/stlport/stlport -O0 -g -fno-omit-frame-pointer -mlong-calls -marm -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -Wsign-compare -Woverloaded-virtual -Wno-abi -MMD -MF out/Debug/.deps/out/Debug/obj.target/audio_processing/third_party/webrtc/modules/audio_processing/voice_detection_impl.o.d.raw -c -o out/Debug/obj.target/audio_processing/third_party/webrtc/modules/audio_processing/voice_detection_impl.o third_party/webrtc/modules/audio_processing/voice_detection_impl.cc rm -f out/Debug/obj.target/third_party/webrtc/modules/librtp_rtcp.a && ar crsT out/Debug/obj.target/third_party/webrtc/modules/librtp_rtcp.a out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/bitrate.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_rtcp_impl.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtcp_receiver.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtcp_receiver_help.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtcp_sender.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtcp_utility.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_header_extension.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_receiver.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_sender.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_utility.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/ssrc_database.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/tmmbr_help.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/dtmf_queue.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_receiver_audio.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_sender_audio.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/forward_error_correction.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/forward_error_correction_internal.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/producer_fec.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_packet_history.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_receiver_video.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_sender_video.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/receiver_fec.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/rtp_format_vp8.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/transmission_bucket.o out/Debug/obj.target/rtp_rtcp/third_party/webrtc/modules/rtp_rtcp/source/vp8_partition_aggregator.o ar: warning: rtcp_receiver_help.o truncated to rtcp_receiver_h ar: warning: rtp_header_extension.o truncated to rtp_header_exte ar: warning: rtp_receiver_audio.o truncated to rtp_receiver_au ar: warning: rtp_sender_audio.o truncated to rtp_sender_audi ar: warning: forward_error_correction.o truncated to forward_error_c ar: warning: forward_error_correction_internal.o truncated to forward_error_c ar: warning: rtp_packet_history.o truncated to rtp_packet_hist ar: warning: rtp_receiver_video.o truncated to rtp_receiver_vi ar: warning: rtp_sender_video.o truncated to rtp_sender_vide ar: warning: rtp_format_vp8.o truncated to rtp_format_vp8. ar: warning: transmission_bucket.o truncated to transmission_bu ar: warning: vp8_partition_aggregator.o truncated to vp8_partition_a /usr/bin/ranlib: warning for library: out/Debug/obj.target/third_party/webrtc/modules/librtp_rtcp.a the table of contents is empty (no object file members in the library define global symbols) Followed by this error for my system ld: ./gyp-mac-tool flock out/Debug/linker.lock /Users/luke/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/darwin-x86/bin/arm-linux-androideabi-gcc -shared -Wl,-z,noexecstack -fPIC -Wl,-z,relro -Wl,-z,now -nostdlib -Wl,--no-undefined -Wl,--exclude-libs=ALL --sysroot=/Users/luke/android/android-ndk-r8b/platforms/android-9/arch-arm -Wl,--icf=safe -L/Users/luke/android/android-ndk-r8b/sources/cxx-stl/stlport/libs/armeabi -Wl,-shared,-Bsymbolic /Users/luke/android/android-ndk-r8b/platforms/android-9/arch-arm/usr/lib/crtbegin_so.o -Wl,-soname=libvoiceclient.so -o out/Debug/obj.target/libvoiceclient.so -Wl,--whole-archive out/Debug/obj.target/voiceclient/src/jni/voiceclient_main.o out/Debug/obj.target/voiceclient/src/jni/tuenti/presenceouttask.o out/Debug/obj.target/voiceclient/src/jni/tuenti/presencepushtask.o out/Debug/obj.target/voiceclient/src/jni/tuenti/clientsignalingthread.o out/Debug/obj.target/voiceclient/src/jni/tuenti/voiceclient.o out/Debug/obj.target/voiceclient/src/jni/tuenti/txmppauth.o out/Debug/obj.target/voiceclient/src/jni/tuenti/txmpppump.o out/Debug/obj.target/voiceclient/src/jni/tuenti/txmppsocket.o out/Debug/obj.target/third_party/libjingle/libjingle_audio_only.a out/Debug/obj.target/third_party/expat/libexpat.a out/Debug/obj.target/third_party/openssl/libopenssl.a out/Debug/obj.target/third_party/libsrtp/libsrtp.a out/Debug/obj.target/third_party/webrtc/voice_engine/libvoice_engine_core.a out/Debug/obj.target/third_party/webrtc/common_audio/libresampler.a out/Debug/obj.target/third_party/webrtc/common_audio/libsignal_processing.a out/Debug/obj.target/third_party/webrtc/modules/libaudio_coding_module.a out/Debug/obj.target/third_party/webrtc/modules/libCNG.a out/Debug/obj.target/third_party/webrtc/modules/libG711.a out/Debug/obj.target/third_party/webrtc/modules/libG722.a out/Debug/obj.target/third_party/webrtc/modules/libiLBC.a out/Debug/obj.target/third_party/webrtc/modules/libiSAC.a out/Debug/obj.target/third_party/webrtc/modules/libiSACFix.a out/Debug/obj.target/third_party/webrtc/modules/libPCM16B.a out/Debug/obj.target/third_party/webrtc/modules/libNetEq.a out/Debug/obj.target/third_party/webrtc/common_audio/libvad.a out/Debug/obj.target/third_party/webrtc/system_wrappers/source/libsystem_wrappers.a out/Debug/obj.target/third_party/webrtc/system_wrappers/source/libcpu_features_android.a out/Debug/obj.target/third_party/webrtc/modules/libaudio_conference_mixer.a out/Debug/obj.target/third_party/webrtc/modules/libaudio_processing.a out/Debug/obj.target/third_party/webrtc/modules/libaec.a out/Debug/obj.target/third_party/webrtc/modules/libapm_util.a out/Debug/obj.target/third_party/webrtc/modules/libaecm.a out/Debug/obj.target/third_party/webrtc/modules/libagc.a out/Debug/obj.target/third_party/webrtc/modules/libns_fix.a out/Debug/obj.target/third_party/webrtc/modules/libaudioproc_debug_proto.a out/Debug/obj.target/third_party/protobuf/libprotobuf_lite.a out/Debug/obj.target/third_party/webrtc/modules/libwebrtc_utility.a out/Debug/obj.target/third_party/webrtc/modules/libaudio_device.a out/Debug/obj.target/third_party/webrtc/modules/libmedia_file.a out/Debug/obj.target/third_party/webrtc/modules/librtp_rtcp.a out/Debug/obj.target/third_party/webrtc/modules/libremote_bitrate_estimator.a out/Debug/obj.target/third_party/webrtc/modules/libudp_transport.a out/Debug/obj.target/third_party/libjingle/libjingle.a out/Debug/obj.target/third_party/libjingle/libjingle_p2p.a -Wl,--no-whole-archive -ldl -llog -lOpenSLES -lstlport_static /Users/luke/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt//darwin-x86/bin//../lib/gcc/arm-linux-androideabi/4.4.3/libgcc.a -lc -lstdc++ -lm /Users/luke/android/android-ndk-r8b/platforms/android-9/arch-arm/usr/lib/crtend_so.o out/Debug/obj.target/third_party/libjingle/libjingle_audio_only.a: member out/Debug/obj.target/third_party/libjingle/libjingle_audio_only.a(__.SYMDEF SORTED) in archive is not an object collect2: ld returned 1 exit status make: *** [out/Debug/obj.target/libvoiceclient.so] Error 1 Maybe there is a different variable to set that resolves both of these issues, or maybe linux is just equivalent or close enough to the toolchain versions that there is no issue. |