Last Comment Bug 820559 - PeerConnection doesn't build on Android (GCC 4.4)
: PeerConnection doesn't build on Android (GCC 4.4)
Status: RESOLVED FIXED
[WebRTC] [blocking-webrtc-] [qa-]
:
Product: Core
Classification: Components
Component: WebRTC (show other bugs)
: Trunk
: ARM Android
: P2 normal (vote)
: mozilla20
Assigned To: Dan Mosedale (:dmose)
: Jason Smith [:jsmith]
:
Mentors:
: 821318 (view as bug list)
Depends on:
Blocks: 750869
  Show dependency treegraph
 
Reported: 2012-12-11 13:39 PST by Dan Mosedale (:dmose)
Modified: 2012-12-14 20:26 PST (History)
5 users (show)
dmose: in‑testsuite-
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch 1, workaround by casting template arg to int (2.54 KB, patch)
2012-12-11 13:40 PST, Dan Mosedale (:dmose)
ekr: review+
Details | Diff | Splinter Review

Description Dan Mosedale (:dmose) 2012-12-11 13:39:01 PST
The just-landed PeerConnection Dispatch patch uses a newer C++ idiom that the compiler in the Android NDK r5c doesn't support, as per <http://stackoverflow.com/questions/5720359/no-matching-function-call-to-anonymous-enum>.

Current Android compiles fail thusly:

PeerConnectionImpl.cpp
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp: In member function 'void sipcc::PeerConnectionImpl::ChangeReadyState(sipcc::PeerConnectionImpl::ReadyState)':
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1029: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1029: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp: In member function 'void sipcc::PeerConnectionImpl::IceGatheringCompleted_m(mozilla::NrIceCtx*)':
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1076: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1076: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp: In member function 'void sipcc::PeerConnectionImpl::IceCompleted_m(mozilla::NrIceCtx*)':
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1107: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'
/Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp:1107: error: no matching function for call to 'WrapRunnable(nsCOMPtr<IPeerConnectionObserver>&, nsresult (IPeerConnectionObserver::*)(uint32_t), IPeerConnectionObserver::<anonymous enum>)'

In the directory  /Users/dmose/r/inbound/objdir-droid/media/webrtc/signaling/signaling_ecc
The following command failed to execute properly:
/usr/local/bin/ccache /usr/local/android-ndk-r5c/toolchains/arm-linux-androideabi-4.4.3/prebuilt/darwin-x86/bin/arm-linux-androideabi-g++ -o src/peerconnection/PeerConnectionImpl.o -c -fvisibility=hidden -DNO_NSPR_10_SUPPORT -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 -DLOG4CXX_STATIC -D_NO_LOG4CXX -DUSE_SSLEAY -D_CPR_USE_EXTERNAL_LOGGER -DWEBRTC_RELATIVE_PATH -DHAVE_WEBRTC_VIDEO -DHAVE_WEBRTC_VOICE -DHAVE_STDLIB_H=1 -DINTEGER_TYPES_H="mozilla/StandardInteger.h" -DHAVE_UINT8_T=1 -DHAVE_UINT16_T=1 -DHAVE_UINT32_T=1 -DHAVE_UINT64_T=1 -DMOZILLA_INTERNAL_API -DSIP_OS_LINUX -D_GNU_SOURCE -DLINUX -DGIPS_VER=3510 -DSECLIB_OPENSSL -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 -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DWTF_USE_DYNAMIC_ANNOTATIONS=1 -D_DEBUG -I. -I/Users/dmose/r/inbound/src/media/webrtc/signaling//.. -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/callcontrol -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/common -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/common/browser_logging -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/media -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/media-conduit -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/mediapipeline -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/softphonewrapper -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/peerconnection -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/sipcc/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//./src/sipcc/cpr/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../ipc/chromium/src -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../ipc/chromium/src/base/third_party/nspr -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../xpcom/base -I../../../../dist/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../dom/base -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../media/mtransport -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../trunk/src -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../trunk/src/video_engine/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../trunk/src/voice_engine/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../trunk/src/modules/interface -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../trunk/src/peerconnection -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../netwerk/srtp/src/include -I/Users/dmose/r/inbound/src/media/webrtc/signaling//../../../netwerk/srtp/src/crypto/include -fPIC -isystem /usr/local/android-ndk-r5c/platforms/android-9/arch-arm/usr/include -Wall -Wpointer-arith -Woverloaded-virtual -Werror=return-type -Wtype-limits -Wempty-body -Wno-ctor-dtor-privacy -Wno-overlength-strings -Wno-invalid-offsetof -Wno-variadic-macros -Wno-long-long -mandroid -fno-short-enums -fno-exceptions -Wno-psabi -march=armv7-a -mthumb -mfpu=vfp -mfloat-abi=softfp -I/Users/dmose/r/inbound/objdir-droid/build/stlport -I/usr/local/android-ndk-r5c/sources/cxx-stl/stlport/stlport -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -std=gnu++0x -pipe -DDEBUG -D_DEBUG -DTRACING -g -fno-omit-frame-pointer -funwind-tables -I/Users/dmose/r/inbound/objdir-droid/dist/include/nspr -I/Users/dmose/r/inbound/objdir-droid/dist/include/nss -isystem /usr/local/android-ndk-r5c/platforms/android-9/arch-arm/usr/include -DMOZILLA_CLIENT -include ../../../../mozilla-config.h -MD -MF .deps/PeerConnectionImpl.o.pp /Users/dmose/r/inbound/src/media/webrtc/signaling/src/peerconnection/PeerConnectionImpl.cpp
Comment 1 Dan Mosedale (:dmose) 2012-12-11 13:40:06 PST
Created attachment 691045 [details] [diff] [review]
patch 1, workaround by casting template arg to int

This makes the file compile on Android.
Comment 2 Dan Mosedale (:dmose) 2012-12-11 13:47:16 PST
Try server build in progress: https://tbpl.mozilla.org/?tree=Try&rev=5319e143f39f
Comment 3 Eric Rescorla (:ekr) 2012-12-12 07:01:41 PST
Comment on attachment 691045 [details] [diff] [review]
patch 1, workaround by casting template arg to int

Review of attachment 691045 [details] [diff] [review]:
-----------------------------------------------------------------

Lightning
Comment 4 Dan Mosedale (:dmose) 2012-12-12 07:04:33 PST
Last try-server run had a bunch of oranges, likely due to the state of inbound at the time, rather than this patch.  Doing another:

https://tbpl.mozilla.org/?tree=Try&rev=02e321eaa40c
Comment 5 Dan Mosedale (:dmose) 2012-12-12 10:17:57 PST
Pushed to mozilla-inbound: 

https://hg.mozilla.org/integration/mozilla-inbound/rev/7ef53b8f1ff6
Comment 6 Dan Mosedale (:dmose) 2012-12-12 10:18:57 PST
Setting in-testsuite-; since this fixes build-bustage, the compiler acts as a test-suite here.
Comment 7 Ed Morley [:emorley] 2012-12-13 08:09:37 PST
https://hg.mozilla.org/mozilla-central/rev/7ef53b8f1ff6
Comment 8 Nathan Froyd [:froydnj] 2012-12-13 12:29:44 PST
*** Bug 821318 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.