Bump to EAPI-4; use pkg_pretend and make missing sandbox support in kernel fatal...
authorPaweł Hajdan <phajdan.jr@gentoo.org>
Tue, 18 Oct 2011 08:10:30 +0000 (08:10 +0000)
committerPaweł Hajdan <phajdan.jr@gentoo.org>
Tue, 18 Oct 2011 08:10:30 +0000 (08:10 +0000)
Package-Manager: portage-2.1.10.11/cvs/Linux i686

www-client/chromium/ChangeLog
www-client/chromium/Manifest
www-client/chromium/chromium-16.0.904.0-r2.ebuild
www-client/chromium/chromium-9999-r1.ebuild

index cae727f31d764813844d4b9bb70c62421968bc2f..f5c416b341387bcf818f3f89dccf8a6d4a6382d0 100644 (file)
@@ -1,6 +1,12 @@
 # ChangeLog for www-client/chromium
 # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.469 2011/10/17 18:29:58 nativemad Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/ChangeLog,v 1.470 2011/10/18 08:10:30 phajdan.jr Exp $
+
+  18 Oct 2011; Pawel Hajdan jr <phajdan.jr@gentoo.org>
+  chromium-16.0.904.0-r2.ebuild, chromium-9999-r1.ebuild:
+  Bump to EAPI-4; use pkg_pretend and make missing sandbox support in kernel
+  fatal if installing the package; add a die hook for better diagnostics and
+  more precise error messages.
 
   17 Oct 2011; Andreas Schuerch <nativemad@gentoo.org>
   chromium-14.0.835.202.ebuild:
index 4563ef98e2270d5aa0a15a06448c54a9691313cf..20590f378fbf87d5069f6b0f676aa82d1725481b 100644 (file)
@@ -1,5 +1,5 @@
 -----BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
+Hash: SHA512
 
 AUX chromium-browser.xml 407 RMD160 457374ff72561648d9777ffb3270ad10d864a6be SHA1 65543bfff7d0350d40ba258e61061b0c5579e1f2 SHA256 bc039012f8677468e9ce5df825f9d8096be6deb5813031c86a087c88105096ff
 AUX chromium-icu-compatibility-r0.patch 1659 RMD160 5d1fcc18d27b96f0c1b4f14b24dd8ab40ce917ca SHA1 517155769d0f421a4a81bffbcac39d17fa099956 SHA256 f70d99472d56e0aa7398b5638412d440d22943eb2c5962957f973e90992fdc99
@@ -22,14 +22,15 @@ EBUILD chromium-15.0.874.83.ebuild 14224 RMD160 df78a96ac7bd075a4a8f21fd24a1fc3b
 EBUILD chromium-15.0.874.92.ebuild 14224 RMD160 0188245d09b5d7eb8152c5d6247fc54a36dafc59 SHA1 960f6920c927393948fca81dd93c26aef09d976f SHA256 47e9062d9f357861abc7592cf48a596003961d59a88b4ec2ac8bca4233b46093
 EBUILD chromium-16.0.899.0.ebuild 13949 RMD160 5a5333ade34f2aacc504f70e16faf4b2ad4144b7 SHA1 06bb027a26c5517240ae9c2e4aef2a8eee7e5e70 SHA256 cd314d18256783329639ab69f9e088daad5c6fe5344a6c0e4a6c0c848c5a8cf4
 EBUILD chromium-16.0.904.0-r1.ebuild 14033 RMD160 10e2b2168b0b28fd5b0917a1f07da74403a0a51e SHA1 3e6312696579f3b30f4a71ba66b08649c80b8d79 SHA256 695c873b84ac7712f307de2c0d4a9cfee7b00d4e99b92a8375d57e6fba521682
-EBUILD chromium-16.0.904.0-r2.ebuild 14749 RMD160 c56f6e5ee4d4ee9201c108e51fb29469b6a01120 SHA1 71d006f584b236d3777e8a0fc5cecf3a498c3ac3 SHA256 39822699972fe1b6eadbd3eb55d62902fee06ed495979dabba30dc306a01ad60
-EBUILD chromium-9999-r1.ebuild 17326 RMD160 cf66e7261e9d5a890b4c06cd915d1bcf183b7faf SHA1 0e86aaf64abe72a3cba204060672631cfa480cef SHA256 5d6593c55705dbd7af2dbfd50abe042bda4d1f8f6bab4ed2b3a667357e1ddde9
-MISC ChangeLog 103340 RMD160 db92d04f8971c65fbbc2a5bed9edd831f8c34a3b SHA1 8a43a04680f371baa4f22acf0870fb17347f9251 SHA256 d99dea22c481a7c143ade07e4f915124e0fb9564b3e384b7a0eeb46d0b52a09e
+EBUILD chromium-16.0.904.0-r2.ebuild 15515 RMD160 8784fe6b72e0785f5b4ff07e3cbf8f3846a49878 SHA1 5560da05ac544408b9bdcf13a0f85fd969b06f69 SHA256 af9b4c3336c973a682e474451362ed23aca979912ff70c37e742fe56bf435d08
+EBUILD chromium-9999-r1.ebuild 18092 RMD160 7e73a3728f150beb46d74ef0a5f280d4b7d6a672 SHA1 9b1a6dd1e04620c71056e739da4ccd5d88bd4cfd SHA256 e98d25d71ff987a136ecb53d25880444c302c36011984e48faabb9e21fd8e8ff
+MISC ChangeLog 103640 RMD160 f0688d31e1581685cc9f65e782807c14aa20eeb1 SHA1 b704f2e1e438959d9aee7593c5d0c2667ccb75f4 SHA256 6205f6af2a65fb75d164914ca30e11245ab648074e2faa2c2f9742943bec1022
+MISC chromium-9999-r1.ebuild.orig 17326 RMD160 cf66e7261e9d5a890b4c06cd915d1bcf183b7faf SHA1 0e86aaf64abe72a3cba204060672631cfa480cef SHA256 5d6593c55705dbd7af2dbfd50abe042bda4d1f8f6bab4ed2b3a667357e1ddde9
 MISC metadata.xml 495 RMD160 91f2c4344cde85374523c8c16f5987ad0320b607 SHA1 5e97c7979fac0de374958532e38fcbca1191963b SHA256 375fb24d5d647728a58b3a7d0d552bf7d8eb5f26eef3c249dcf9a2dcb9e5bb37
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.17 (GNU/Linux)
 
-iEYEARECAAYFAk6cdB8ACgkQB6aLYPQCwODqfACggeVUNnSJXHI3Pn+MQdw+vGpJ
-0+sAn02dU4o8I0EOY4UEFYAWHP4U97sz
-=3jzs
+iEYEAREKAAYFAk6dNH0ACgkQuUQtlDBCeQKuzgCfXQ69ZS2m0gxUpVsNy+k2Umhx
+cwsAnRrRe6TTU0/vzy9KcpJjNcO6hYiN
+=pdpQ
 -----END PGP SIGNATURE-----
index 23e6103810e9a889320d866398b5271911ab90cf..0a61e3bd9e3190f3c914a2d441217a3f643d455f 100644 (file)
@@ -1,8 +1,8 @@
 # Copyright 1999-2011 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-16.0.904.0-r2.ebuild,v 1.3 2011/10/15 03:12:32 phajdan.jr Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-16.0.904.0-r2.ebuild,v 1.4 2011/10/18 08:10:30 phajdan.jr Exp $
 
-EAPI="3"
+EAPI="4"
 PYTHON_DEPEND="2:2.6"
 
 inherit eutils fdo-mime flag-o-matic gnome2-utils linux-info multilib \
@@ -98,29 +98,62 @@ get_installed_v8_version() {
        best_version dev-lang/v8 | sed -e 's@dev-lang/v8-@@g'
 }
 
-pkg_setup() {
-       CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser"
+pkg_pretend() {
+       if [[ "${MERGE_TYPE}" == "source" || "${MERGE_TYPE}" == "binary" ]]; then
+               # Fail if the kernel doesn't support features needed for sandboxing,
+               # bug #363907.
+               ERROR_PID_NS="PID_NS is required for sandbox to work"
+               ERROR_NET_NS="NET_NS is required for sandbox to work"
+               CONFIG_CHECK="PID_NS NET_NS"
+               check_extra_config
+       fi
+}
 
-       # Make sure the build system will use the right tools, bug #340795.
-       tc-export AR CC CXX RANLIB
+if ! has chromium-pkg_die ${EBUILD_DEATH_HOOKS}; then
+       EBUILD_DEATH_HOOKS+=" chromium-pkg_die";
+fi
 
-       # Make sure the build system will use the right python, bug #344367.
-       python_set_active_version 2
-       python_pkg_setup
+chromium-pkg_die() {
+       if [[ "${EBUILD_PHASE}" != "compile" ]]; then
+               return
+       fi
 
        # Prevent user problems like bug #348235.
        eshopts_push -s extglob
        if is-flagq '-g?(gdb)?([1-9])'; then
-               ewarn "You have enabled debug info (probably have -g or -ggdb in your \$C{,XX}FLAGS)."
-               ewarn "You may experience really long compilation times and/or increased memory usage."
-               ewarn "If compilation fails, please try removing -g{,gdb} before reporting a bug."
+               ewarn
+               ewarn "You have enabled debug info (i.e. -g or -ggdb in your CFLAGS/CXXFLAGS)."
+               ewarn "Please try removing -g{,gdb} before reporting a bug."
+               ewarn
        fi
        eshopts_pop
 
-       # Warn if the kernel doesn't support features useful for sandboxing,
-       # bug #363907.
-       CONFIG_CHECK="~PID_NS ~NET_NS"
-       check_extra_config
+       # ccache often causes bogus compile failures, especially when the cache gets
+       # corrupted.
+       if has ccache ${FEATURES}; then
+               ewarn
+               ewarn "You have enabled ccache. Please try disabling ccache"
+               ewarn "before reporting a bug."
+               ewarn
+       fi
+
+       # If the system doesn't have enough memory, the compilation is known to
+       # fail. Print info about memory to recognize this condition.
+       einfo
+       einfo "$(grep MemTotal /proc/meminfo)"
+       einfo "$(grep SwapTotal /proc/meminfo)"
+       einfo
+}
+
+pkg_setup() {
+       CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser"
+
+       # Make sure the build system will use the right tools, bug #340795.
+       tc-export AR CC CXX RANLIB
+
+       # Make sure the build system will use the right python, bug #344367.
+       python_set_active_version 2
+       python_pkg_setup
 
        if use bindist; then
                elog "bindist enabled: H.264 video support will be disabled."
index aa225c55bc68f70a8ce2365c44f73e64af42183a..b1109ddb012df3a5cd2e397c33f60aead04c2aba 100644 (file)
@@ -1,8 +1,8 @@
 # Copyright 1999-2011 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-9999-r1.ebuild,v 1.60 2011/10/15 03:12:32 phajdan.jr Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-client/chromium/chromium-9999-r1.ebuild,v 1.61 2011/10/18 08:10:30 phajdan.jr Exp $
 
-EAPI="3"
+EAPI="4"
 PYTHON_DEPEND="2:2.6"
 
 inherit eutils fdo-mime flag-o-matic gnome2-utils linux-info multilib \
@@ -150,6 +150,53 @@ get_installed_v8_version() {
        best_version dev-lang/v8 | sed -e 's@dev-lang/v8-@@g'
 }
 
+pkg_pretend() {
+       if [[ "${MERGE_TYPE}" == "source" || "${MERGE_TYPE}" == "binary" ]]; then
+               # Fail if the kernel doesn't support features needed for sandboxing,
+               # bug #363907.
+               ERROR_PID_NS="PID_NS is required for sandbox to work"
+               ERROR_NET_NS="NET_NS is required for sandbox to work"
+               CONFIG_CHECK="PID_NS NET_NS"
+               check_extra_config
+       fi
+}
+
+if ! has chromium-pkg_die ${EBUILD_DEATH_HOOKS}; then
+       EBUILD_DEATH_HOOKS+=" chromium-pkg_die";
+fi
+
+chromium-pkg_die() {
+       if [[ "${EBUILD_PHASE}" != "compile" ]]; then
+               return
+       fi
+
+       # Prevent user problems like bug #348235.
+       eshopts_push -s extglob
+       if is-flagq '-g?(gdb)?([1-9])'; then
+               ewarn
+               ewarn "You have enabled debug info (i.e. -g or -ggdb in your CFLAGS/CXXFLAGS)."
+               ewarn "Please try removing -g{,gdb} before reporting a bug."
+               ewarn
+       fi
+       eshopts_pop
+
+       # ccache often causes bogus compile failures, especially when the cache gets
+       # corrupted.
+       if has ccache ${FEATURES}; then
+               ewarn
+               ewarn "You have enabled ccache. Please try disabling ccache"
+               ewarn "before reporting a bug."
+               ewarn
+       fi
+
+       # If the system doesn't have enough memory, the compilation is known to
+       # fail. Print info about memory to recognize this condition.
+       einfo
+       einfo "$(grep MemTotal /proc/meminfo)"
+       einfo "$(grep SwapTotal /proc/meminfo)"
+       einfo
+}
+
 pkg_setup() {
        SUFFIX="-${SLOT}"
        CHROMIUM_HOME="/usr/$(get_libdir)/chromium-browser${SUFFIX}"
@@ -161,20 +208,6 @@ pkg_setup() {
        python_set_active_version 2
        python_pkg_setup
 
-       # Prevent user problems like bug #348235.
-       eshopts_push -s extglob
-       if is-flagq '-g?(gdb)?([1-9])'; then
-               ewarn "You have enabled debug info (probably have -g or -ggdb in your \$C{,XX}FLAGS)."
-               ewarn "You may experience really long compilation times and/or increased memory usage."
-               ewarn "If compilation fails, please try removing -g{,gdb} before reporting a bug."
-       fi
-       eshopts_pop
-
-       # Warn if the kernel doesn't support features useful for sandboxing,
-       # bug #363907.
-       CONFIG_CHECK="~PID_NS ~NET_NS"
-       check_extra_config
-
        if use bindist; then
                elog "bindist enabled: H.264 video support will be disabled."
        else