Closed Bug 922460 Opened 6 years ago Closed 6 years ago

Kill media/webrtc/shared_libs.mk

Categories

(Firefox Build System :: General, defect)

defect
Not set

Tracking

(Not tracked)

RESOLVED FIXED
mozilla27

People

(Reporter: glandium, Assigned: glandium)

References

Details

Attachments

(1 file, 1 obsolete file)

It is actually apparently useless, and even redundant with what expandlibs does.
Comment on attachment 812412 [details] [diff] [review]
Kill media/webrtc/shared_libs.mk

The fact is, either gkmedias is built as static or shared, it contains all the webrtc stuff referenced in media/webrtc/shared_libs.mk, which makes adding them again in SHARED_LIBRARY_LIBS in toolkit/library/Makefile.in redundant.
https://tbpl.mozilla.org/?tree=Try&rev=cd4e012aec05
Attachment #812412 - Flags: review?(ted)
Attachment #812412 - Flags: feedback?(rjesup)
Guess what, that failed on windows. Which means we already have a serious problem with webrtc code duplicated between gkmedias.dll and xul.dll
Looks like we need a serious update to layout/media/symbols.def.in.
$ dumpbin -exports gkmedias.dll | grep webrtc returns no symbol, so in fact, the symbol exporting from layout/media/symbols.def.in doesn't work. This means that in practice, webrtc is not in gkmedias.
ah... MOZ_WEBRTC_IN_LIBXUL... so why exactly is webrtc still in gkmedias?
Attachment #812412 - Attachment is obsolete: true
Attachment #812412 - Flags: review?(ted)
Attachment #812412 - Flags: feedback?(rjesup)
Attachment #812496 - Flags: review?(ted) → review+
https://hg.mozilla.org/mozilla-central/rev/e153730cc100
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
This breaks the build on Linux with --disable-webrtc:

make[5]: Entering directory `/var/tmp/moz-build-dir/layout/media/webrtc'
rm -f libwebrtc.a
mkdir -p ".deps/"
/var/tmp/moz-build-dir/_virtualenv/bin/python /home/markus/mozilla-central/config/expandlibs_gen.py --depend .deps/.//libwebrtc.a.desc.pp -o libwebrtc.a.desc  ../../../media/
webrtc/trunk/webrtc/common_video/common_video_common_video/libcommon_video.a ../../../media/webrtc/trunk/webrtc/common_audio/common_audio_common_audio/libcommon_audio.a ../..
/../media/webrtc/trunk/webrtc/modules/modules_video_capture_module/libvideo_capture_module.a ../../../media/webrtc/trunk/webrtc/modules/modules_webrtc_utility/libwebrtc_utili
ty.a ../../../media/webrtc/trunk/webrtc/modules/modules_audio_coding_module/libaudio_coding_module.a ../../../media/webrtc/trunk/webrtc/modules/modules_CNG/libCNG.a ../../../
media/webrtc/trunk/webrtc/modules/modules_G711/libG711.a ../../../media/webrtc/trunk/webrtc/modules/modules_PCM16B/libPCM16B.a ../../../media/webrtc/trunk/webrtc/modules/modu
les_NetEq/libNetEq.a ../../../media/webrtc/trunk/webrtc/system_wrappers/source/system_wrappers_system_wrappers/libsystem_wrappers.a ../../../media/webrtc/trunk/webrtc/modules
/modules_webrtc_video_coding/libwebrtc_video_coding.a ../../../media/webrtc/trunk/webrtc/modules/video_coding/utility/video_coding_utility_video_coding_utility/libvideo_codin
g_utility.a ../../../media/webrtc/trunk/webrtc/modules/modules_webrtc_i420/libwebrtc_i420.a ../../../media/webrtc/trunk/webrtc/modules/video_coding/codecs/vp8/vp8_webrtc_vp8/
libwebrtc_vp8.a ../../../media/webrtc/trunk/webrtc/modules/modules_webrtc_opus/libwebrtc_opus.a ../../../media/webrtc/trunk/webrtc/modules/modules_video_render_module/libvide
o_render_module.a ../../../media/webrtc/trunk/webrtc/video_engine/video_engine_video_engine_core/libvideo_engine_core.a ../../../media/webrtc/trunk/webrtc/voice_engine/voice_
engine_voice_engine/libvoice_engine.a ../../../media/webrtc/trunk/webrtc/modules/modules_media_file/libmedia_file.a ../../../media/webrtc/trunk/webrtc/modules/modules_rtp_rtc
p/librtp_rtcp.a ../../../media/webrtc/trunk/webrtc/modules/modules_bitrate_controller/libbitrate_controller.a ../../../media/webrtc/trunk/webrtc/modules/modules_remote_bitrat
e_estimator/libremote_bitrate_estimator.a ../../../media/webrtc/trunk/webrtc/modules/modules_paced_sender/libpaced_sender.a ../../../media/webrtc/trunk/webrtc/modules/modules
_video_processing/libvideo_processing.a ../../../media/webrtc/trunk/webrtc/modules/modules_audio_conference_mixer/libaudio_conference_mixer.a ../../../media/webrtc/trunk/webr
tc/modules/modules_audio_device/libaudio_device.a ../../../media/webrtc/trunk/webrtc/modules/modules_audio_processing/libaudio_processing.a ../../../media/webrtc/trunk/third_
party/libyuv/libyuv_libyuv/libyuv.a ../../../media/mtransport/third_party/nICEr/nicer_nicer/libnicer.a ../../../media/mtransport/third_party/nrappkit/nrappkit_nrappkit/libnra
ppkit.a  ../../../media/webrtc/trunk/webrtc/modules/modules_video_processing_sse2/libvideo_processing_sse2.a ../../../media/webrtc/trunk/webrtc/modules/modules_audio_processi
ng_sse2/libaudio_processing_sse2.a ../../../media/webrtc/trunk/webrtc/common_audio/common_audio_common_audio_sse2/libcommon_audio_sse2.a
Traceback (most recent call last):
  File "/home/markus/mozilla-central/config/expandlibs_gen.py", line 43, in <module>
    print >>outfile, generate(args)
  File "/home/markus/mozilla-central/config/expandlibs_gen.py", line 27, in generate
    raise Exception("File not found: %s" % arg)
Exception: File not found: ../../../media/webrtc/trunk/webrtc/common_video/common_video_common_video/libcommon_video.a
make[5]: *** [libwebrtc.a.desc] Error 1
make[5]: *** Deleting file `libwebrtc.a.desc'
Try this fixup:

diff --git a/layout/media/moz.build b/layout/media/moz.build
--- a/layout/media/moz.build
+++ b/layout/media/moz.build
@@ -3,9 +3,10 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 MODULE = 'layout'
 
 LIBRARY_NAME = 'gkmedias'
 
-DIRS += ['webrtc']
+if CONFIG['MOZ_WEBRTC']:
+    DIRS += ['webrtc']
Your fixup works. Thanks.
I landed comment 10 (with glandium as patch-author, and r=ted granted over IRC) to minimize the number of folks bitten by the current disable-webrtc build bustage:
 https://hg.mozilla.org/integration/mozilla-inbound/rev/7d0d6326133f
Depends on: 925860
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.