Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 361461 - www-client/chromium-11.0.696.25: fails to build with gcc 4.6
Summary: www-client/chromium-11.0.696.25: fails to build with gcc 4.6
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Chromium Project
URL:
Whiteboard:
Keywords: InOverlay
: 362905 366657 382001 (view as bug list)
Depends on:
Blocks: gcc-4.6
  Show dependency tree
 
Reported: 2011-03-31 11:22 UTC by Vladimir Smirnov (RETIRED)
Modified: 2012-04-13 14:39 UTC (History)
14 users (show)

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


Attachments
chromium-gcc46.patch (chromium-gcc46.patch,3.12 KB, patch)
2011-03-31 11:23 UTC, Vladimir Smirnov (RETIRED)
Details | Diff
chromium-gcc46_p2.patch (chromium-gcc46_new.patch,499 bytes, patch)
2011-04-03 15:05 UTC, Vladimir Smirnov (RETIRED)
Details | Diff
chromium-gcc46-summ.patch (chromium-gcc46-summ.patch,5.29 KB, patch)
2011-04-20 17:36 UTC, Nilus
Details | Diff
chromium-12.0.733.0-r1.ebuild (chromium-12.0.733.0-r1.ebuild,10.75 KB, text/plain)
2011-04-20 17:38 UTC, Nilus
Details
build.log chromium-12.0.742.5 (build.log.tar.gz,116.92 KB, text/plain)
2011-04-24 18:56 UTC, Vasco Gervasi
Details
chromium-12.0.742.12-r1.ebuild (chromium-12.0.742.12-r1.ebuild,11.35 KB, text/plain)
2011-05-03 12:54 UTC, Nilus
Details
gcc-4.6 I'm successfully using with www-client/chromium-11.0.696.65 (chromium-gcc46.patch,3.39 KB, patch)
2011-05-10 07:29 UTC, Zeev Tarantov
Details | Diff
gcc-4.6 patch for www-client/chromium-12.0.742.21 (chromium-12-gcc46.patch,3.41 KB, patch)
2011-05-11 22:48 UTC, Zeev Tarantov
Details | Diff
chromium-13.0.772.0-gcc46.patch (chromium-13.0.772.0-gcc46.patch,3.04 KB, patch)
2011-05-26 16:50 UTC, Markus Peloquin
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vladimir Smirnov (RETIRED) gentoo-dev 2011-03-31 11:22:28 UTC
Lots of missing <cstddef> headers

Reproducible: Always

Steps to Reproduce:
1. emerge gcc 4.6
2. select gcc 4.6
3. emerge chromium
Actual Results:  
lot's of "size_t undefined", "NULL is undefined", etc.


emereg --info:

Portage 2.2.0_alpha29 (default/linux/amd64/10.0, gcc-4.6.0-pre9999, glibc-2.13-r2, 2.6.38-rc6-civil x86_64)
=================================================================
System uname: Linux-2.6.38-rc6-civil-x86_64-Intel-R-_Core-TM-_i7-2600K_CPU_@_3.40GHz-with-gentoo-2.0.2
Timestamp of tree: Thu, 31 Mar 2011 07:15:01 +0000
ccache version 3.1.4 [enabled]
app-shells/bash:     4.2_p8
dev-java/java-config: 2.1.11-r3
dev-lang/python:     2.6.6-r2, 2.7.1-r1, 3.1.3-r1
dev-util/ccache:     3.1.4
dev-util/cmake:      2.8.4
sys-apps/baselayout: 2.0.2
sys-apps/openrc:     0.8.0
sys-apps/sandbox:    2.5
sys-devel/autoconf:  2.13, 2.68
sys-devel/automake:  1.9.6-r3, 1.10.3, 1.11.1
sys-devel/binutils:  2.21
sys-devel/gcc:       4.4.5, 4.5.2, 4.6.0_pre9999::toolchain
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.4-r1
sys-devel/make:      3.82
virtual/os-headers:  2.6.38 (sys-kernel/linux-headers)
Repositories: gentoo my_overlay x11 yousei qting-edge kde mozilla vmware toolchain gcc-porting
Installed sets: 
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=corei7-avx -mtune=corei7-avx"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0 /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -pipe -march=corei7-avx -mtune=corei7-avx"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs ccache distlocks fixlafiles fixpackages news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="ftp://ftp.corbina.net/pub/Linux/gentoo/ http://trumpetti.atm.tut.fi/gentoo/ ftp://trumpetti.atm.tut.fi/gentoo/ http://distfiles.gentoo.org ftp://xeon.gentoo.ru"
LANG="ru_RU.utf8"
LC_ALL="C"
LDFLAGS="-Wl,-O1 -Wl,--sort-common,--as-needed"
LINGUAS="en ru"
MAKEOPTS="-j8"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage/my /var/lib/layman/x11 /usr/local/portage/yousei /var/lib/layman/qting-edge /usr/local/portage/kde /var/lib/layman/mozilla /var/lib/layman/vmware /var/lib/layman/toolchain /var/lib/layman/gcc-porting"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="16bit X a52 aac acl acpi alsa amd64 avahi berkdb branding bzip2 cddb chm cleartype cli consolekit cracklib crypt cups curl curlwrappers cxx cyrillic dbus device-mapper djvu dri dvdnav encode exif ffmpeg flac fontconfig freetype gdbm glibc-omitfp glitz gpm gstreamer iconv icq id3 ipv6 ithreads java6 jpeg kde kdehiddenvisibility lcms lirc lm_sensors lzma mmx mmxext mng modules mouse mp2 mp3 mp4 mpeg2 mudflap multilib musepack mysql ncurses nepomuk nls nptl nptlonly ogg openexr opengl openmp pam pch pcre pdf perl plasma png policykit pppd python qt-copy qt3-support qt3support qt4 raw readline sasl scanner sdl-image sdl-sound semantic-desktop session slang smp spell sqlite sqlite3 srt ssa sse sse2 sse3 ssl ssse3 svg sysfs tcpd theora threads tiff truetype unicode usb vaapi vdpau vorbis wavpack webkit wma wmf wmp wxwindows x264 xcb xforms xine xkb xorg xvid zlib" ALSA_CARDS="emu10k1 intel-hda" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file cgid cgi authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en ru" LIRC_DEVICES="livedrive_midi" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" SANE_BACKENDS="epson epson2" USERLAND="GNU" VIDEO_CARDS="nvidia nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Vladimir Smirnov (RETIRED) gentoo-dev 2011-03-31 11:23:31 UTC
Created attachment 267967 [details, diff]
chromium-gcc46.patch
Comment 2 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-03-31 12:31:56 UTC
Vladimir, could you please submit the patches upstream? See http://www.chromium.org/developers/contributing-code for more info.

I'd be glad to help you getting those patches upstream, feel free to contact me.
Comment 3 Ryan Hill (RETIRED) gentoo-dev 2011-04-03 05:53:25 UTC
Added to gcc-porting overlay.
Comment 4 Vladimir Smirnov (RETIRED) gentoo-dev 2011-04-03 15:05:59 UTC
Created attachment 268341 [details, diff]
chromium-gcc46_p2.patch

In overlay still 2 includes are missing, at least for chromium-11.0.696.28-r1
Comment 5 Emmanuel Andry 2011-04-07 09:19:35 UTC
Also true with chromium-11.0.696.34
Comment 6 Andrew John Hughes 2011-04-09 00:06:41 UTC
Confirmed here too.  The attached patch needs to be added to gcc4.6.patch in the overlay.
Comment 7 Rafał Mużyło 2011-04-10 17:35:08 UTC
*** Bug 362905 has been marked as a duplicate of this bug. ***
Comment 8 Nilus 2011-04-20 17:36:44 UTC
Created attachment 270693 [details, diff]
chromium-gcc46-summ.patch

Previous patch does not work. I'm attached my patch, working on a version www-client/chromium-12.0.733.0 and ebuild
Comment 9 Nilus 2011-04-20 17:38:31 UTC
Created attachment 270695 [details]
chromium-12.0.733.0-r1.ebuild

ebuild for chromium-gcc46-summ.patch
Comment 10 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-04-20 20:40:13 UTC
(In reply to comment #8)
> Previous patch does not work. I'm attached my patch, working on a version
> www-client/chromium-12.0.733.0 and ebuild

Please submit patches upstream and not here. It is not maintainable to apply them on the Gentoo side.
Comment 11 Vasco Gervasi 2011-04-24 13:36:28 UTC
Does it work against 12.0.742.5?

Thanks
Comment 12 Vasco Gervasi 2011-04-24 18:53:12 UTC
The patch seems to give me this error against 12.0.742.5:


media/filters/audio_file_reader.cc: In member function ‘bool media::AudioFileReader::Open()’:
media/filters/audio_file_reader.cc:74:26: error: ‘CODEC_TYPE_AUDIO’ was not declared in this scope
make: *** [out/Release/obj.target/media/media/filters/audio_file_reader.o] Errore 1
make: *** Attesa dei processi non terminati....
Comment 13 Vasco Gervasi 2011-04-24 18:56:23 UTC
Created attachment 271031 [details]
build.log chromium-12.0.742.5
Comment 14 Krzysztof Pawlik (RETIRED) gentoo-dev 2011-04-27 19:27:18 UTC
Same for www-client/chromium-11.0.696.57.
Comment 15 Nilus 2011-05-03 12:54:29 UTC
Created attachment 271975 [details]
chromium-12.0.742.12-r1.ebuild

Build good with patch chromium-gcc46-summ.patch
Comment 16 Vasco Gervasi 2011-05-03 18:59:12 UTC
Error with 12.0.742.16 and gcc46 patch


  i686-pc-linux-gnu-g++ '-DNO_HEAPCHECKER' '-DCHROMIUM_BUILD' '-DENABLE_REMOTING=1' '-DUSE_PROPRIETARY_CODECS' '-DENABLE_GPU=1' '-DENABLE_EGLIMAGE=1' '-DHAVE_XINPUT2' '-D__STDC_CONSTANT_MACROS' '-DUSE_SYSTEM_VPX' '-D__OMX_EXPORTS' '-D__STDC_FORMAT_MACROS' '-DNDEBUG' '-DNVALGRIND' '-DDYNAMIC_ANNOTATIONS_ENABLED=0' -I. -Iout/Release/obj/gen/ffmpeg -Ithird_party/openmax/il -Iout/Release/obj/gen/openmax -pthread -fno-exceptions -Wall -Wno-unused-parameter -Wno-missing-field-initializers -D_FILE_OFFSET_BITS=64 -fvisibility=hidden -pipe -m32 -mmmx -fno-strict-aliasing -pthread -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng14 -I/usr/include/libdrm -O2 -fno-ident -fdata-sections -ffunction-sections -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -MMD -MF out/Release/.deps/out/Release/obj.target/media/media/filters/audio_renderer_algorithm_base.o.d.raw -march=native -O2 -pipe -fomit-frame-pointer -c -o out/Release/obj.target/media/media/filters/audio_renderer_algorithm_base.o media/filters/audio_renderer_algorithm_base.cc
media/filters/audio_file_reader.cc: In member function ‘bool media::AudioFileReader::Open()’:
media/filters/audio_file_reader.cc:74:26: error: ‘CODEC_TYPE_AUDIO’ was not declared in this scope
make: *** [out/Release/obj.target/media/media/filters/audio_file_reader.o] Errore 1
make: *** Attesa dei processi non terminati....
emake failed
Comment 17 Chris Smith 2011-05-09 22:45:48 UTC
(In reply to comment #16)
> Error with 12.0.742.16 and gcc46 patch

Worked here (the patch) with 12.0.742.21.
Comment 18 Zeev Tarantov 2011-05-10 07:29:45 UTC
Created attachment 272711 [details, diff]
gcc-4.6 I'm successfully using with www-client/chromium-11.0.696.65
Comment 19 Zeev Tarantov 2011-05-11 22:48:12 UTC
Created attachment 272905 [details, diff]
gcc-4.6 patch for www-client/chromium-12.0.742.21
Comment 20 Vasco Gervasi 2011-05-12 17:48:20 UTC
Using this patch chromium-12-gcc46.patch against www-client/chromium-12.0.742.21 , I get this error:


_FORMAT_MACROS' '-DNDEBUG' '-DNVALGRIND' '-DDYNAMIC_ANNOTATIONS_ENABLED=0' -I. -Iout/Release/obj/gen/ffmpeg -Ithird_party/openmax/il -Iout/Release/obj/gen/openmax -pthread -fno-exceptions -Wall -Wno-unused-parameter -Wno-missing-field-initializers -D_FILE_OFFSET_BITS=64 -fvisibility=hidden -pipe -m32 -mmmx -fno-strict-aliasing -pthread -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng14 -I/usr/include/libdrm -O2 -fno-ident -fdata-sections -ffunction-sections -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -MMD -MF out/Release/.deps/out/Release/obj.target/media/media/filters/audio_renderer_algorithm_default.o.d.raw -march=native -O2 -pipe -fomit-frame-pointer -c -o out/Release/obj.target/media/media/filters/audio_renderer_algorithm_default.o media/filters/audio_renderer_algorithm_default.cc
media/filters/audio_file_reader.cc: In member function ‘bool media::AudioFileReader::Open()’:
media/filters/audio_file_reader.cc:74:26: error: ‘CODEC_TYPE_AUDIO’ was not declared in this scope
make: *** [out/Release/obj.target/media/media/filters/audio_file_reader.o] Errore 1
make: *** Attesa dei processi non terminati....
emake failed
Comment 21 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-05-13 06:13:56 UTC
*** Bug 366657 has been marked as a duplicate of this bug. ***
Comment 22 Vasco Gervasi 2011-05-13 12:53:01 UTC
Same error with www-client/chromium-13.0.761.0 and chromium-12-gcc46.patch. Ideas? Can be a libav-9999 related error?


media/filters/audio_file_reader.cc: In member function ‘bool media::AudioFileReader::Open()’:
media/filters/audio_file_reader.cc:74:26: error: ‘CODEC_TYPE_AUDIO’ was not declared in this scope
make: *** [out/Release/obj.target/media/media/filters/audio_file_reader.o] Errore 1
make: *** Attesa dei processi non terminati....
emake failed
Comment 23 Vasco Gervasi 2011-05-13 17:38:50 UTC
Has someone emerged successful chromium 12 or 13 series against gcc-4.6?
Is someone using libav-9999?

Thanks
Comment 24 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-05-13 17:52:44 UTC
(In reply to comment #23)
> Has someone emerged successful chromium 12 or 13 series against gcc-4.6?
> Is someone using libav-9999?

Could you rather use forums.gentoo.org for discussions?

This bug is super-clear: chromium does not compile with gcc-4.6, there are patches but nobody has submitted them to the right place, which is upstream. Please read http://www.chromium.org/developers/contributing-code . Just in case: attaching patches to upstream bug reports won't work either. Please read the doc, the right site is http://codereview.chromium.org
Comment 25 Vasco Gervasi 2011-05-14 10:07:22 UTC
As I suspected chromium will not compile against libav-9999, downgrading to 0.7_pre20110327 worked. I can confirm that patch for gcc-4.6 works for chromium-13.0.761.0.

Thanks to all
Comment 26 Vasco Gervasi 2011-05-18 18:45:33 UTC
Error applying patch with chromium-13.0.767.1
Comment 27 Markus Peloquin 2011-05-26 16:50:34 UTC
Created attachment 274707 [details, diff]
chromium-13.0.772.0-gcc46.patch

Not much to explain here. Chromium-13 builds now. I'm not going to bother figuring out why there are ebuilds attached to this bug; I just ignored them.
Comment 28 Tolga Dalman 2011-05-30 10:50:34 UTC
Chromium 12.0.742.68 now builds with GCC-4.6
Comment 29 Ulenrich 2011-06-07 21:33:43 UTC
No for chromium-12.0.742.91, the long known missing standard include case: "size_t"
----------
In file included from chrome/browser/search_engines/template_url_prepopulate_data.cc:5:0:
./chrome/browser/search_engines/template_url_prepopulate_data.h:30:29: Fehler: »size_t« wurde nicht deklariert
make: *** [out/Release/obj.target/browser/chrome/browser/search_engines/template_url_prepopulate_data.o] Fehler 1
emake failed
 * ERROR: www-client/chromium-12.0.742.91 failed
Comment 30 Ulenrich 2011-06-08 00:09:40 UTC
But using this patch
http://bugs.gentoo.org/attachment.cgi?id=272905
then chromium-12.0.742.91 compiles through without error.

This patch exists always a month now. Nobody cares about including it into the official gentoo ebuild?
Comment 31 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-06-08 06:55:08 UTC
(In reply to comment #30)
> This patch exists always a month now. Nobody cares about including it into the
> official gentoo ebuild?

Please read http://bugs.gentoo.org/show_bug.cgi?id=361461#c2 and http://bugs.gentoo.org/show_bug.cgi?id=361461#c10 . Again, _no_ patch attached to _this_ bug will be applied on the Gentoo side. The right course of action is to submit patches upstream - recently a few patches by another Gentoo developer, Christoph Mende (angelos) have landed, and I've helped him with the upstreaming.

If anyone else thinks some more patches are needed, please read http://www.chromium.org/developers/contributing-code .

Thank you for your interest in getting the package to build with gcc-4.6.
Comment 32 Alexandre Rostovtsev (RETIRED) gentoo-dev 2011-06-10 05:01:49 UTC
(In reply to comment #31)
> Please read http://bugs.gentoo.org/show_bug.cgi?id=361461#c2 and
> http://bugs.gentoo.org/show_bug.cgi?id=361461#c10 . Again, _no_ patch attached
> to _this_ bug will be applied on the Gentoo side. The right course of action is
> to submit patches upstream - recently a few patches by another Gentoo
> developer, Christoph Mende (angelos) have landed, and I've helped him with the
> upstreaming.
> 
> If anyone else thinks some more patches are needed, please read
> http://www.chromium.org/developers/contributing-code .

Paweł, IMHO your response is unreasonable. Firs of all, you are asking Gentoo bugzilla users to go through a complicated process involving signing a contributor agreement and learning how to use Chromium's strange scm and code review setup (that is not used by any other project) just to get a trivial patch adding some #include statements committed.

Second, *you are upstream*. You are listed in Chromium's AUTHORS file, you are experienced with Chromium's tools and code review procedures, you have already signed all agreements, and (if I understand it right) you have commit rights. Why are you asking Gentoo users to learn how to become a Chromium developer when you, already a Chromium developer, could simply commit the patch?
Comment 33 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-06-10 06:24:07 UTC
(In reply to comment #32)
> Second, *you are upstream*. You are listed in Chromium's AUTHORS file, you are
> experienced with Chromium's tools and code review procedures, you have already
> signed all agreements, and (if I understand it right) you have commit rights.
> Why are you asking Gentoo users to learn how to become a Chromium developer
> when you, already a Chromium developer, could simply commit the patch?

First thing to note is that I just don't have resources to test with gcc-4.6 right now. A committer should test the patch he's submitting for review, and the reviewers may request changes that would have to be tested again with gcc-4.6.

And then, to make tcmalloc compile with gcc-4.6, we don't just apply the two-line patch submitted here. Instead, the entire tcmalloc directory has to be updated to the upstream (google-perftools) release, and local patches have to be merged: http://codereview.chromium.org/7050034/ .
Comment 34 Kevin Bowling 2011-06-11 05:10:24 UTC
I wonder what the lacking resource is.  It isn't time if you let the compiles run in the background.  I'd guess you run gentoo so it's a simple emerge and gcc-config away, and it's not like you need to rebuild your entire system with 4.6.  If you are indeed upstream, these patches are fairly critical for the likes of Fedora 15 and soon other distros, so why drag your feet just because gcc 4.6 is masked for now in gentoo?
Comment 35 Gen2 2011-06-19 19:53:09 UTC
I wonder why the complete tcmalloc-subproject needs to be updated, if the short-term solution would be just a two-liner? I bet that noone here doubts that the new version needs to be integrated sooner or later, but for the sake of getting this thing finally through, it should be enough to use the patch we are proposing here...

(In reply to comment #33)
> (In reply to comment #32)
> > Second, *you are upstream*. You are listed in Chromium's AUTHORS file, you are
> > experienced with Chromium's tools and code review procedures, you have already
> > signed all agreements, and (if I understand it right) you have commit rights.
> > Why are you asking Gentoo users to learn how to become a Chromium developer
> > when you, already a Chromium developer, could simply commit the patch?
> 
> First thing to note is that I just don't have resources to test with gcc-4.6
> right now. A committer should test the patch he's submitting for review, and
> the reviewers may request changes that would have to be tested again with
> gcc-4.6.
> 
> And then, to make tcmalloc compile with gcc-4.6, we don't just apply the
> two-line patch submitted here. Instead, the entire tcmalloc directory has to be
> updated to the upstream (google-perftools) release, and local patches have to
> be merged: http://codereview.chromium.org/7050034/ .
Comment 36 Vladimir Smirnov (RETIRED) gentoo-dev 2011-06-20 10:35:03 UTC
Patches here are hard to maintain, they'll almost certainly break in next version bump. I don't have enough time to commit fix to chromium repo in a near future.
Comment 37 Chris Smith 2011-06-21 16:40:28 UTC
Don't want to beat a dead horse, but besides failing to build the latest chromium-14.0.794.0 I can no longer build the patched version I'm currently running and previously built, all fail with:
==========================================================
  x86_64-pc-linux-gnu-g++ '-DNO_HEAPCHECKER' '-DCHROMIUM_BUILD' '-DENABLE_REMOTING=1' '-DENABLE_P2P_APIS=1' '-DENABLE_GPU=1' '-DENABLE_EGLIMAGE=1' '-DNDEBUG' '-DNVALGRIND' '-DDYNAMIC_ANNOTATIONS_ENABLED=0' -Ibase/allocator -Ithird_party/tcmalloc/chromium/src/base -Ithird_party/tcmalloc/chromium/src -I. -pthread -fno-exceptions -Wno-unused-parameter -Wno-missing-field-initializers -D_FILE_OFFSET_BITS=64 -pipe -fPIC -fno-strict-aliasing -DNO_HEAP_CHECK -Wno-deprecated -Wno-format -O2 -fno-ident -fdata-sections -ffunction-sections -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -MMD -MF out/Release/.deps/out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/tcmalloc.o.d.raw -O2 -march=native -fomit-frame-pointer -pipe -floop-interchange -floop-strip-mine -floop-block -c -o out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/tcmalloc.o third_party/tcmalloc/chromium/src/tcmalloc.cc
third_party/tcmalloc/chromium/src/tcmalloc.cc:379:36: error: conflicting declaration ‘void* (* __malloc_hook)(size_t, const void*)’
/usr/include/malloc.h:176:39: error: ‘__malloc_hook’ has a previous declaration as ‘void* (* volatile __malloc_hook)(size_t, const void*)’
third_party/tcmalloc/chromium/src/tcmalloc.cc:387:47: error: conflicting declaration ‘void* (* __realloc_hook)(void*, size_t, const void*)’
/usr/include/malloc.h:179:39: error: ‘__realloc_hook’ has a previous declaration as ‘void* (* volatile __realloc_hook)(void*, size_t, const void*)’
third_party/tcmalloc/chromium/src/tcmalloc.cc:393:50: error: conflicting declaration ‘void (* __free_hook)(void*, const void*)’
/usr/include/malloc.h:173:38: error: ‘__free_hook’ has a previous declaration as ‘void (* volatile __free_hook)(void*, const void*)’
third_party/tcmalloc/chromium/src/tcmalloc.cc:1587:54: error: conflicting declaration ‘void* (* __memalign_hook)(size_t, size_t, const void*)’
/usr/include/malloc.h:183:39: error: ‘__memalign_hook’ has a previous declaration as ‘void* (* volatile __memalign_hook)(size_t, size_t, const void*)’
third_party/tcmalloc/chromium/src/tcmalloc.cc: In function ‘void PrintStats(int)’:
third_party/tcmalloc/chromium/src/tcmalloc.cc:541:47: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’, declared with attribute warn_unused_result [-Wunused-result]
third_party/tcmalloc/chromium/src/tcmalloc.cc: In function ‘void ReportLargeAlloc(Length, void*)’:
third_party/tcmalloc/chromium/src/tcmalloc.cc:919:47: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’, declared with attribute warn_unused_result [-Wunused-result]
make: *** [out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/tcmalloc.o] Error 1
emake failed
==========================================================
Comment 38 Chris Smith 2011-06-21 17:14:19 UTC
Oops, comment 37 was the error for chromium-14.0.794.0 and may be a different bug. The following is for chromium-13.0.772.0-r1 with the gcc46.patch the previously built (I'm running it), but it no longer builds:
==============================
  x86_64-pc-linux-gnu-g++ '-DNO_HEAPCHECKER' '-DDISABLE_NACL' '-DCHROMIUM_BUILD' '-DENABLE_REMOTING=1' '-DENABLE_P2P_APIS=1' '-DUSE_PROPRIETARY_CODECS' '-DENABLE_GPU=1' '-DENABLE_EGLIMAGE=1' '-DNDEBUG' '-DNVALGRIND' '-DDYNAMIC_ANNOTATIONS_ENABLED=0' -Ibase/allocator -Ithird_party/tcmalloc/chromium/src/base -Ithird_party/tcmalloc/chromium/src -I. -pthread -fno-exceptions -Wno-unused-parameter -Wno-missing-field-initializers -D_FILE_OFFSET_BITS=64 -pipe -fPIC -fno-strict-aliasing -DNO_HEAP_CHECK -Wno-deprecated -Wno-format -O2 -fno-ident -fdata-sections -ffunction-sections -fno-rtti -fno-threadsafe-statics -fvisibility-inlines-hidden -MMD -MF out/Release/.deps/out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/base/vdso_support.o.d.raw -O2 -march=native -fomit-frame-pointer -pipe -floop-interchange -floop-strip-mine -floop-block -c -o out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/base/vdso_support.o third_party/tcmalloc/chromium/src/base/vdso_support.cc
third_party/tcmalloc/chromium/src/base/vdso_support.cc: In member function ‘void base::VDSOSupport::ElfMemImage::Init(const void*)’:
third_party/tcmalloc/chromium/src/base/vdso_support.cc:264:3: error: ‘ptrdiff_t’ was not declared in this scope
third_party/tcmalloc/chromium/src/base/vdso_support.cc:264:3: note: suggested alternatives:
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.0/include/g++-v4/x86_64-pc-linux-gnu/bits/c++config.h:156:28: note:   ‘std::ptrdiff_t’
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.0/include/g++-v4/x86_64-pc-linux-gnu/bits/c++config.h:156:28: note:   ‘std::ptrdiff_t’
third_party/tcmalloc/chromium/src/base/vdso_support.cc:264:13: error: expected ‘;’ before ‘relocation’
third_party/tcmalloc/chromium/src/base/vdso_support.cc:268:37: error: ‘relocation’ was not declared in this scope
make: *** [out/Release/obj.target/allocator/third_party/tcmalloc/chromium/src/base/vdso_support.o] Error 1
emake failed
==============================
Not sure what has changed that causes it to no longer build.
Comment 39 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-06-21 17:15:19 UTC
(In reply to comment #37)
> Don't want to beat a dead horse, but besides failing to build the latest
> chromium-14.0.794.0 I can no longer build the patched version I'm currently
> running and previously built, all fail with:
> ==========================================================
> third_party/tcmalloc/chromium/src/tcmalloc.cc:379:36: error: conflicting
> declaration ‘void* (* __malloc_hook)(size_t, const void*)’
> /usr/include/malloc.h:176:39: error: ‘__malloc_hook’ has a previous declaration
> as ‘void* (* volatile __malloc_hook)(size_t, const void*)’

This seems to be a different error. Please file a separate bug, and make sure to include emerge --info. /usr/include/malloc.h is provided by glibc.
Comment 40 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-06-29 10:42:42 UTC
We have a report (https://bugs.gentoo.org/show_bug.cgi?id=355181#c7) that chromium-14.0.803.0 compiles fine with gcc-4.6. I'll keep this bug open until 14.x moves into ~arch (which should happen within a few weeks). If you hit problems with that version, please make sure to report them here.
Comment 41 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-08-09 17:45:11 UTC
Just tested here:

www-client/chromium-13.0.782.109 fails with gcc-4.6
www-client/chromium-14.0.835.18 is fine with gcc-4.6

So waiting for 14.x to hit ~arch.
Comment 42 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2011-08-11 23:56:09 UTC
chromium-14.x is now in ~arch, closing
Comment 43 Paweł Hajdan, Jr. (RETIRED) gentoo-dev 2012-04-13 14:39:40 UTC
*** Bug 382001 has been marked as a duplicate of this bug. ***