www-client/chromium: pax-mark v8_context_snapshot_generator
authorMike Gilbert <floppym@gentoo.org>
Sun, 10 Dec 2017 17:44:02 +0000 (12:44 -0500)
committerMike Gilbert <floppym@gentoo.org>
Sun, 10 Dec 2017 17:47:37 +0000 (12:47 -0500)
Bug: https://bugs.gentoo.org/640480
Package-Manager: Portage-2.3.17, Repoman-2.3.6_p24

www-client/chromium/chromium-63.0.3239.84.ebuild
www-client/chromium/chromium-64.0.3282.14.ebuild

index c228cfc0c39d7432ea09e278480f7a8b5f5d2908..71a061010b7a4bf63d7631565dbd2dcde535a507 100644 (file)
@@ -537,24 +537,31 @@ src_configure() {
        "$@" || die
 }
 
-src_compile() {
-       local ninja_targets="chrome chromedriver"
-       if use suid; then
-               ninja_targets+=" chrome_sandbox"
-       fi
+host_binary() {
+       local x
+       for x; do
+               if tc-is-cross-compiler; then
+                       eninja -C out/Release "host/${x}"
+                       pax-mark m "out/Release/host/${x}"
+               else
+                       eninja -C out/Release "${x}"
+                       pax-mark m "out/Release/${x}"
+               fi
+       done
+}
 
+src_compile() {
        # Build mksnapshot and pax-mark it.
-       if tc-is-cross-compiler; then
-               eninja -C out/Release host/mksnapshot || die
-               pax-mark m out/Release/host/mksnapshot
-       else
-               eninja -C out/Release mksnapshot || die
-               pax-mark m out/Release/mksnapshot
-       fi
+       host_binary mksnapshot v8_context_snapshot_generator
+
+       # Work around circular dep issue
+       # https://chromium-review.googlesource.com/c/chromium/src/+/617768
+       eninja -C out/Release gen/ui/accessibility/ax_enums.h
 
        # Even though ninja autodetects number of CPUs, we respect
        # user's options, for debugging with -j 1 or any other reason.
-       eninja -C out/Release ${ninja_targets} || die
+       eninja -C out/Release chrome chromedriver
+       use suid && eninja -C out/Release chrome_sandbox
 
        pax-mark m out/Release/chrome
 }
index a03199f2130818664250a01107b15ec000097963..e436cbd1b5995c28b37e2d9095d958a313d425ef 100644 (file)
@@ -539,27 +539,34 @@ src_configure() {
        "$@" || die
 }
 
+host_binary() {
+       local x
+       for x; do
+               if tc-is-cross-compiler; then
+                       eninja -C out/Release "host/${x}"
+                       pax-mark m "out/Release/host/${x}"
+               else
+                       eninja -C out/Release "${x}"
+                       pax-mark m "out/Release/${x}"
+               fi
+       done
+}
+
 src_compile() {
        # Calling this here supports resumption via FEATURES=keepwork
        python_setup
 
-       local ninja_targets="chrome chromedriver"
-       if use suid; then
-               ninja_targets+=" chrome_sandbox"
-       fi
-
        # Build mksnapshot and pax-mark it.
-       if tc-is-cross-compiler; then
-               eninja -C out/Release host/mksnapshot || die
-               pax-mark m out/Release/host/mksnapshot
-       else
-               eninja -C out/Release mksnapshot || die
-               pax-mark m out/Release/mksnapshot
-       fi
+       host_binary mksnapshot v8_context_snapshot_generator
+
+       # Work around circular dep issue
+       # https://chromium-review.googlesource.com/c/chromium/src/+/617768
+       eninja -C out/Release gen/ui/accessibility/ax_enums.h
 
        # Even though ninja autodetects number of CPUs, we respect
        # user's options, for debugging with -j 1 or any other reason.
-       eninja -C out/Release ${ninja_targets} || die
+       eninja -C out/Release chrome chromedriver
+       use suid && eninja -C out/Release chrome_sandbox
 
        pax-mark m out/Release/chrome
 }