diff --git a/srcpkgs/chromium/patches/linker-no-keep-memory.patch b/srcpkgs/chromium/patches/linker-no-keep-memory.patch new file mode 100644 index 0000000000..7ef4f2d442 --- /dev/null +++ b/srcpkgs/chromium/patches/linker-no-keep-memory.patch @@ -0,0 +1,13 @@ +Building with -g on x86 can use more than 4G memory, so try to +lower the memory requirement by forcing ld(1) --no-keep-memory. + +--- build/common.gypi.orig 2014-09-26 11:50:55.381056525 +0200 ++++ build/common.gypi 2014-09-26 11:51:58.281560018 +0200 +@@ -3287,6 +3287,7 @@ + 'ldflags': [ + '-Wl,-z,now', + '-Wl,-z,relro', ++ '-Wl,--no-keep-memory', + ], + }, + }], diff --git a/srcpkgs/chromium/template b/srcpkgs/chromium/template index 9dc48aaeb6..2d1c9bd209 100644 --- a/srcpkgs/chromium/template +++ b/srcpkgs/chromium/template @@ -51,11 +51,6 @@ pre_configure() { do_configure() { local conf="" - if [ "$XBPS_TARGET_MACHINE" = "i686" ]; then - # Use linker flags to reduce memory consumption - LDFLAGS+=" -Wl,--no-keep-memory -Wl,--reduce-memory-overheads" - fi - unset CC CXX export -n CFLAGS CXXFLAGS LDFLAGS @@ -147,7 +142,6 @@ do_configure() { esac conf+=" -Dtarget_arch=${arch}" fi - # https://code.google.com/p/chromium/issues/detail?id=386097 third_party/libaddressinput/chromium/tools/update-strings.py @@ -157,10 +151,6 @@ do_configure() { do_build() { unset CC CXX - if [ "$XBPS_TARGET_MACHINE" = "i686" ]; then - # Use linker flags to reduce memory consumption - LDFLAGS+=" -Wl,--no-keep-memory -Wl,--reduce-memory-overheads" - fi export -n CFLAGS CXXFLAGS LDFLAGS ninja -C out/Release ${makejobs} chrome chrome_sandbox chromedriver }