Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 593434 - www-client/chromium/chromium-54.0.2840.16 build failure with USE=-gn
Summary: www-client/chromium/chromium-54.0.2840.16 build failure with USE=-gn
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Chromium Project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-09-10 12:24 UTC by Albert W. Hopkins
Modified: 2016-09-23 14:38 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Albert W. Hopkins 2016-09-10 12:24:21 UTC
When attempting to build chromium with USE=-gn I always get a failure:

"gyp: /var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16/services/user/user.gyp not found (cwd: /var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16)"

The reason that I want "-gn" is that it pulls in a bunch of GNOME stuff that I don't use/need.

Build log:
[...]
 * Configuring Chromium...
build/gyp_chromium --depth=. -Ddisable_sse2=1 -Ddisable_nacl=1
-Dflapper_version_h_file=/var/tmp/portage/www-client/chromium-54.0.2840.16/temp/flapper_version.h
-Duse_system_bzip2=1 -Duse_system_ffmpeg=0 -Duse_system_flac=1
-Duse_system_harfbuzz=1 -Duse_system_jsoncpp=1 -Duse_system_libevent=1
-Duse_system_libpng=1 -Duse_system_libvpx=1 -Duse_system_libwebp=1
-Duse_system_libxml=1 -Duse_system_libxslt=1 -Duse_system_minizip=1
-Duse_system_nspr=1 -Duse_system_snappy=1 -Duse_system_speex=1
-Duse_system_xdg_utils=1 -Duse_system_zlib=1 -Duse_system_yasm=1
-Duse_cups=1 -Duse_gconf=0 -Duse_gnome_keyring=0
-Dlinux_link_gnome_keyring=0 -Duse_gtk3=0
-Denable_hangout_services_extension=0 -Duse_kerberos=0
-Duse_pulseaudio=0 -Duse_allocator=tcmalloc -Denable_widevine=0
-Dlinux_link_gsettings=1 -Dlinux_link_libpci=1
-Dlinux_link_libspeechd=1 -Dlibspeechd_h_prefix=speech-dispatcher/
-Dusb_ids_path=/usr/share/misc/usb.ids
-Dfieldtrial_testing_like_official_build=1 -Dclang=0
-Dclang_use_chrome_plugins=0 -Dhost_clang=0
-Dlinux_use_bundled_binutils=0 -Dlinux_use_bundled_gold=0
-Dlinux_use_gold_flags=0 -Dsysroot= -Dproprietary_codecs=1
-Dffmpeg_branding=Chromium
-Dgoogle_api_key=AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc
-Dgoogle_default_client_id=329227923882.apps.googleusercontent.com
-Dgoogle_default_client_secret=vgKG0NNv7GoDpbtoFNLxCUXu
-Dtarget_arch=x64 -Dwerror= -Ddisable_fatal_linker_warnings=1
Updating projects from gyp files...
gyp: /var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16/services/user/user.gyp not found (cwd: /var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16)
 * ERROR: www-client/chromium-54.0.2840.16::gentoo failed (configure phase):
 *   (no error message)
 * 
 * Call stack:
 *     ebuild.sh, line 115:  Called src_configure
 *   environment, line 5427:  Called die
 * The specific snippet of code:
 *           egyp_chromium ${myconf_gyp} || die;
 * 
 * If you need support, post the output of `emerge --info '=www-client/chromium-54.0.2840.16::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=www-client/chromium-54.0.2840.16::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/www-client/chromium-54.0.2840.16/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/www-client/chromium-54.0.2840.16/temp/environment'.
 * Working directory: '/var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16'
 * S: '/var/tmp/portage/www-client/chromium-54.0.2840.16/work/chromium-54.0.2840.16'
Comment 1 Alexander Sergeyev 2016-09-10 15:50:42 UTC
I've just discovered the same issue -- (with no countermeasures applied) portage refuses to build chromium without gn useflag, which pulls whole gnome metapackage or gnome-keyring. The gn useflag is enforced in portage's profiles/base/package.use.force:

# Pawel Hajdan jr <phajdan.jr@gentoo.org> (20 Aug 2016)
# Chromium GYP build is no longer supported - always use GN.
>=www-client/chromium-54 gn

I would be very happy to avoid dragging the pile of gnome packages into my system too.
Comment 2 Mike Gilbert gentoo-dev 2016-09-10 16:01:43 UTC
(In reply to Alexander E. Sergeev from comment #1)
> I've just discovered the same issue -- (with no countermeasures applied)
> portage refuses to build chromium without gn useflag, which pulls whole
> gnome metapackage or gnome-keyring.

No, it does not depend on any gnome metapackage. Stop making things up.
Comment 3 Alexander Sergeyev 2016-09-10 16:07:20 UTC
> No, it does not depend on any gnome metapackage
Sorry. Indeed, it does not. I misinterpret "gn? ( gnome gnome-keyring )" assumming that on right side there are packages (like gnome-base/gnome and gnome-base/gnome-keyring) and not other useflags.
Comment 4 Mike Gilbert gentoo-dev 2016-09-10 16:16:40 UTC
I plan to drop the gn USE flag with the next beta channel bump.

I am also testing to see if gconf and gnome-keyring can be made optional in chromium 54/55.
Comment 5 Albert W. Hopkins 2016-09-10 18:45:50 UTC
(In reply to Mike Gilbert from comment #4)
> I plan to drop the gn USE flag with the next beta channel bump.
> 
> I am also testing to see if gconf and gnome-keyring can be made optional in
> chromium 54/55.

Oh so it's upstream that is upstream that is enforcing all the GNOME requirements?  I didn't think they even cared about GNOME.  I use GNOME, but never required the integration with Chromium (as I don't use Chromium much, just as a fallback).

Is it Chromium + GNOME now the recommended way of running the browser?  I looked at the USE flag description for "gn" and didn't think it had much to do with GNOME, but it was pulling in GNOME stuff so I disabled it.  But it seems to me what you're saying is Chromium+GNOME is the way now going forward.

thanks,
-a
Comment 6 Albert W. Hopkins 2016-09-10 18:48:09 UTC
I should clarify that on my main machine I use GNOME, but on my VM I basically don't run any desktop environment and occasionally via ssh run Firefox and/or GNOME.
Comment 7 Mike Gilbert gentoo-dev 2016-09-10 19:07:13 UTC
The Chromium developers recently swapped out the "GYP" build system with a new one called "GN". The gn USE flag switches between the two.

When they were migrating the GYP build files to GN, some mistakes were made and some conditional code related to gconf and gnome-keyring was broken. This is what prompted the REQUIRED_USE constraint in the ebuild.

These issues have since been fixed upstream, but I am not certain exactly when.

There is no advantage/disadvantage to using the GNOME desktop environment with the Chromium web browser.
Comment 8 Albert W. Hopkins 2016-09-10 21:07:31 UTC
(In reply to Mike Gilbert from comment #7)

The explanation makes sense.  Thanks.
Comment 9 Dominik Strehlke 2016-09-10 22:40:15 UTC
(In reply to Mike Gilbert from comment #7)
> The Chromium developers recently swapped out the "GYP" build system with a
> new one called "GN". The gn USE flag switches between the two.
> 
> When they were migrating the GYP build files to GN, some mistakes were made
> and some conditional code related to gconf and gnome-keyring was broken.
> This is what prompted the REQUIRED_USE constraint in the ebuild.
> 
> These issues have since been fixed upstream, but I am not certain exactly
> when.

Mike, I manually removed the gnome/gnome-keyring constraints from the 54.0.2840.16 ebuild and it is building fine. No more assertions failing like in the last one.

The build will (hopefully) finish overnight and tomorrow I'll comment once more on the resulting binary's quality ;-)
Comment 10 Mike Gilbert gentoo-dev 2016-09-11 00:56:13 UTC
commit fb618f2412feae4a1c18a1ab2afe188a31663242
Author: Mike Gilbert <floppym@gentoo.org>
Date:   Sat Sep 10 16:01:54 2016 -0400

    www-client/chromium: make gnome and gnome-keyring optional for M54
    
    Package-Manager: portage-2.3.0_p24
Comment 11 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2016-09-22 01:22:13 UTC
Can we close this bug now?
Comment 12 Albert W. Hopkins 2016-09-23 10:54:50 UTC
(In reply to Paweł Hajdan, Jr. from comment #11)
> Can we close this bug now?

Probably.  I've had chromium 54 masked since so I haven't been able to check to see if it builds w/o pulling in the gnome stuff, but I can try it out now and let you know in a bit.

thanks,
-a
Comment 13 Albert W. Hopkins 2016-09-23 12:18:07 UTC
Seems perhaps that "gn" now causes problems if you have USE=system-ffmpeg:

Building gn using itself to out/Release...
DEBUG:root:Running: /var/tmp/portage/www-client/chromium-54.0.2840.27/work/temp/tmpdCj1Pi/gn gen /var/tmp/portage/www-client/chromium-54.0.2840.27/work/chromium-54.0.2840.27/out/Release --args= is_debug=false enable_nacl=false enable_hangout_services_extension=true enable_widevine=false use_cups=true use_gconf=true use_gnome_keyring=false use_gtk3=false use_kerberos=false use_pulseaudio=true fieldtrial_testing_like_official_build=true is_clang=false use_gold=false use_sysroot=false proprietary_codecs=true ffmpeg_branding="Chromium" google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc" google_default_client_id="329227923882.apps.googleusercontent.com" google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu" treat_warnings_as_errors=false fatal_linker_warnings=false use_allocator="none" is_debug=false
ERROR at //media/BUILD.gn:27:3: Assertion failed.
  assert(
  ^-----
proprietary codecs and ffmpeg_branding set to Chromium are incompatible
See //media/BUILD.gn:28:7: 
      ffmpeg_branding != "Chromium",
      ^----------------------------
This is where it was set.
See //BUILD.gn:279:7: which caused the file to be included.
      "//media:media_unittests",
      ^------------------------
Command '['/var/tmp/portage/www-client/chromium-54.0.2840.27/work/temp/tmpdCj1Pi/gn', 'gen', '/var/tmp/portage/www-client/chromium-54.0.2840.27/work/chromium-54.0.2840.27/out/Release', '--args= is_debug=false enable_nacl=false enable_hangout_services_extension=true enable_widevine=false use_cups=true use_gconf=true use_gnome_keyring=false use_gtk3=false use_kerberos=false use_pulseaudio=true fieldtrial_testing_like_official_build=true is_clang=false use_gold=false use_sysroot=false proprietary_codecs=true ffmpeg_branding="Chromium" google_api_key="AIzaSyDEAOvatFo0eTgsV_ZlEzx0ObmepsMzfAc" google_default_client_id="329227923882.apps.googleusercontent.com" google_default_client_secret="vgKG0NNv7GoDpbtoFNLxCUXu" treat_warnings_as_errors=false fatal_linker_warnings=false use_allocator="none" is_debug=false']' returned non-zero exit status 1


$ emerge -vp chromium

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U  ] www-client/chromium-54.0.2840.27::gentoo [53.0.2785.116::gentoo] USE="cups (gn*) gnome hangouts (pic) pulseaudio system-ffmpeg tcmalloc -custom-cflags -gnome-keyring -gtk3 -kerberos (-neon) -proprietary-codecs (-selinux) -suid% {-test} -widevine" L10N="-am -ar -bg -bn -ca -cs -da -de -el -en-GB -es -es-419 -et -fa -fi -fil -fr -gu -he -hi -hr -hu -id -it -ja -kn -ko -lt -lv -ml -mr -ms -nb -nl -pl -pt-BR -pt-PT -ro -ru -sk -sl -sr -sv -sw -ta -te -th -tr -uk -vi -zh-CN -zh-TW" 0 KiB
Comment 14 Albert W. Hopkins 2016-09-23 12:26:34 UTC
Actually I still get the error even with USE-system-ffmpeg, so I don't know what I'm doing wrong here.
Comment 15 Mike Gilbert gentoo-dev 2016-09-23 14:38:28 UTC
The ffmpeg issue is separate from the issue initially reported. I'll fix it shortly.