Unverified Commit dac7649d authored by boklm's avatar boklm
Browse files

Bugs 22832: Only include objects under out/Release/obj in libwebrtc-magic.a.

Object files from elsewhere under out/ should never have been included,
because they are not part of webrtc itself, but rather side-effect build
artifacts like gn. Including those extraneous .o files was mostly
harmless (except for library size), because on linux they happened to be
the same architecture as the webrtc.o files. However it won't work for
the mac build (because libwebrtc-magic.a would include a mix of linux
ELF and mac Mach-O objects). Additionally, build_time.o, part of the gn
build, embeds a timestamp with month resolution, causing a failure of
reproducibility, as found at https://bugs.torproject.org/22832.

tor-browser-bundle.git author: David Fifield <david@bamsoftware.com>
tor-browser-bundle.git commit: 781da76f120f849416c772cef45a9a9a103b4eef
parent 8d3c245d
......@@ -70,9 +70,12 @@ GN_ARGS+=" rtc_include_opus=false rtc_include_ilbc=false rtc_include_internal_au
rm -rf out/Release
"$GN" gen out/Release --args="$GN_ARGS"
ninja -C out/Release webrtc field_trial metrics_default pc_test_utils
# https://github.com/keroserene/go-webrtc/issues/23#issuecomment-175312648
# libwebrtc-linux-386-magic.a(dump_syms_regtest.o): unsupported ELF file type 2
ar crs libwebrtc-magic.a $(find . -name '*.o' -not -name '*.main.o' -not -name 'dump_syms_regtest.o' | sort)
# .o files under out/Release/obj/ are the build outputs. Don't include .o
# files from elsewhere under out/ because they are build helpers and things
# like that, not necessarily of the target architecture, and anyway are not
# needed.
# https://bugs.torproject.org/22832
ar crs libwebrtc-magic.a $(find out/Release/obj -name '*.o' | sort)
mkdir -p $distdir
cd $distdir
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment