'emerge oprofile' fails with: ... make[3]: Entering directory `/var/tmp/portage/dev-util/oprofile-0.9.6/work/oprofile-0.9.6/libop' if i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I. -I.. -I../libutil -W -Wall -fno-common -Wdeclaration-after-statement -O2 -march=athlon -fomit-frame-pointer -MT op_events.o -MD -MP -MF ".deps/op_events.Tpo" -c -o op_events.o op_events.c; \ then mv -f ".deps/op_events.Tpo" ".deps/op_events.Po"; else rm -f ".deps/op_events.Tpo"; exit 1; fi op_hw_specific.h: In function 'read_events': op_hw_specific.h:80: error: PIC register 'ebx' clobbered in 'asm' op_hw_specific.h: In function 'arch_filter_events': op_hw_specific.h:49: error: PIC register 'ebx' clobbered in 'asm' make[3]: *** [op_events.o] Error 1 make[3]: Leaving directory `/var/tmp/portage/dev-util/oprofile-0.9.6/work/oprofile-0.9.6/libop' make[2]: *** [all-recursive] Error 1 Reproducible: Always tarantel linux # emerge --info =dev-util/oprofile-0.9.6 Portage 2.1.7.16 (hardened/linux/x86/10.0, gcc-4.3.4, glibc-2.11-r1, 2.6.31-gentoo-r6 i686) ================================================================= System Settings ================================================================= System uname: Linux-2.6.31-gentoo-r6-i686-AMD_Athlon-tm-_Processor-with-gentoo-2.0.1 Timestamp of tree: Tue, 12 Jan 2010 12:00:16 +0000 distcc 3.1 i686-pc-linux-gnu [disabled] app-shells/bash: 4.0_p35 dev-java/java-config: 2.1.10 dev-lang/python: 2.6.4, 3.1.1-r1 dev-python/pycrypto: 2.1.0 dev-util/cmake: 2.8.0 sys-apps/baselayout: 2.0.1 sys-apps/openrc: 0.6.0 sys-apps/sandbox: 2.1 sys-devel/autoconf: 2.13, 2.65 sys-devel/automake: 1.4_p6-r1, 1.5, 1.6.3, 1.7.9-r2, 1.8.5-r4, 1.9.6-r2, 1.10.3, 1.11.1 sys-devel/binutils: 2.20 sys-devel/gcc-config: 1.4.1 sys-devel/libtool: 2.2.6b virtual/os-headers: 2.6.30-r1 ACCEPT_KEYWORDS="x86 ~x86" ACCEPT_LICENSE="* -@EULA PUEL dlj-1.1 skype-eula" CBUILD="i686-pc-linux-gnu" CFLAGS="-O2 -march=athlon -fomit-frame-pointer" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config /var/lib/hsqldb" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/eselect/postgresql /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/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 -march=athlon -fomit-frame-pointer" DISTDIR="/usr/portage/distfiles" FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch" FFLAGS="-O2 -march=athlon -fomit-frame-pointer" GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror http://ftp-stud.fht-esslingen.de/pub/Mirrors/gentoo/ rsync://ftp.fi.muni.cz/pub/linux/gentoo ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo rsync://gd.tuwien.ac.at/opsys/linux/gentoo ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo ftp://ftp.tu-clausthal.de/pub/linux/gentoo http://gentoo.oregonstate.edu http://212.219.247.17/sites/www.ibiblio.org/gentoo/ ftp://ftp6.uni-erlangen.de/pub/mirrors/gentoo http://ftp6.uni-erlangen.de/pub/mirrors/gentoo ftp://vlaai.snt.ipv6.utwente.nl/pub/os/linux/gentoo/ http://www.gigaload.org/gentoo.org/" LDFLAGS="-Wl,-O1" LINGUAS="de fr" MAKEOPTS="-j1" 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/layman/java-overlay /usr/local/portage/layman/science /usr/local/portage/layman/dotnet /usr/local/portage" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="3dnow 3dnowext X Xaw3d a52 aac acl acpi administrator afs alsa amrr ao aotuv apache2 asf aspell audacious audiofile automount bash-completion beagle berkdb bjam blas bluetooth boo boost bzip2 c++ cairo cdda cddb cdf cdio cdparanoia cdr cgi chm cli consolekit corba cracklib crypt cups curl cxx daap dbus device-mapper dga dia djvu doc dri ds2490 dv dvb dvd dvdr dvi dxr3 eds elf emacs emboss encode epiphany esd evo examples exif expat extra extras fam fame ffmpeg fftw firefox fits flac fltk foomaticdb fortran fpx fts3 fuse galago gd gdal gdbm geolocation geos gif gimp ginac git glade glib glitz gml gmp gnokii gnome gnome-keyring gnuplot gnutls gphoto2 gpm graphics graphtft graphviz gs gsl gsm gstreamer gtk guile hal hardened harness hddtemp hdf hdf5 hlapi http httpd iconv icq icu id3 ide imagemagick imap innodb ipod ipv6 irda ithreads jabber jadetex java java5 java6 jbig john jpeg jpeg2k kde kerberos kexi kpathsea ladspa lame lapack latex lcms ldap libffi libgda libsamplerate lirc lm_sensors lua lzo mad mail maildir mailwrapper math matroska mmx mmxext mng modules mono motif mozdevelop mozilla mp3 mp4 mpeg mplayer mtp mudflap musicbrainz mysql mysqli nautilus ncurses neXt netcdf netpbm network networking networkmanager nfs nls nntp nptl nptlonly nsplugin ntfs ntp numarray numeric obex objc ocaml octave odbc ogdi ogg ole openexr opengl openmp pam pcre pda pdf perl pic plotutils plugins png podcast policykit posix postgres postscript pppd preview-latex proj projectx pstricks pulseaudio pymol python qhull qt3support quicktime readline reflection reiserfs rle rpc rrdcgi rrdtool samba sasl science sdl server session slang slp smbclient sndfile snmp soup sox speex spell spl sql sqlite ssl stlport subtitles subversion suexec svg swig sysfs szip t1lib tcl tcpd tex tex4ht texmacs theora threads thunderbird tidy tiff tk tntc tools truetype udev unicode urandom usb userlocales utempter v4l2 virtualbox vorbis wav webdav webdav-serf webkit win32codecs wmf wxwidgets x264 x86 xattr xcb xemacs xext xine xml xmlreader xmlrpc xorg xpm xulrunner xv xvid xvmc zlib zvbi" ALSA_CARDS="via82xx" 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 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" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev " KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de fr" NETBEANS_MODULES="ide websvccommon nb harness apisupport groovy gsf j2ee java xml" QEMU_SOFTMMU_TARGETS="i386 ppc ppc64 x86_64" QEMU_USER_TARGETS="arm i386 x86_64" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="ati vesa" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS ================================================================= Package Settings ================================================================= dev-util/oprofile-0.9.6 was built with the following: USE="-qt3" tarantel linux # emerge -pqv =dev-util/oprofile-0.9.6 [ebuild R ] dev-util/oprofile-0.9.6 USE="-qt3"
Created attachment 217018 [details] /var/tmp/portage/dev-util/oprofile-0.9.6/temp/build.log
Please, try with oprofile-0.9.7_rc1.
For me, it doesn't work: make[2]: Entering directory `/var/tmp/portage/dev-util/oprofile-0.9.7_rc1/work/oprofile-0.9.7-rc1/libop' Making all in . make[3]: Entering directory `/var/tmp/portage/dev-util/oprofile-0.9.7_rc1/work/oprofile-0.9.7-rc1/libop' i686-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I.. -I../libutil -W -Wall -fno-common -Wdeclaration-after-statement -O2 -march=native -mfpmath=sse -pipe -fprefetch-loop-arrays -fpeel-loops -fgraphite-identity -floop-interchange -floop-block -floop-strip-mine -fira-loop-pressure -fpredictive-commoning -freorder-blocks-and-partition -ftracer -ftree-loop-distribution -ftree-vectorize --param l2-cache-size=1024 --param l1-cache-size=16 --param l1-cache-line-size=16 -ggdb -MT op_events.o -MD -MP -MF .deps/op_events.Tpo -c -o op_events.o op_events.c In file included from op_events.c:19:0: op_hw_specific.h: In function 'read_events': op_hw_specific.h:94:2: error: PIC register clobbered by 'ebx' in 'asm' op_hw_specific.h: In function 'arch_filter_events': op_hw_specific.h:30:2: error: PIC register clobbered by 'ebx' in 'asm' make[3]: *** [op_events.o] Error 1 make[3]: Leaving directory `/var/tmp/portage/dev-util/oprofile-0.9.7_rc1/work/oprofile-0.9.7-rc1/libop' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/var/tmp/portage/dev-util/oprofile-0.9.7_rc1/work/oprofile-0.9.7-rc1/libop' make[1]: *** [all-recursive] Error 1 # gcc -v Using built-in specs. COLLECT_GCC=/usr/i686-pc-linux-gnu/gcc-bin/4.5.2/gcc COLLECT_LTO_WRAPPER=/usr/libexec/gcc/i686-pc-linux-gnu/4.5.2/lto-wrapper Target: i686-pc-linux-gnu Configured with: /dane/domeny/PORT/portage/sys-devel/gcc-4.5.2/work/gcc-4.5.2/configure --prefix=/usr --bindir=/usr/i686-pc-linux-gnu/gcc-bin/4.5.2 --includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.5.2/include --datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.5.2 --mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.5.2/man --infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.5.2/info --with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.5.2/include/g++-v4 --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --disable-altivec --disable-fixed-point --with-ppl --with-cloog --disable-ppl-version-check --with-cloog-include=/usr/include/cloog --enable-lto --enable-nls --without-included-gettext --with-system-zlib --disable-werror --enable-secureplt --disable-multilib --enable-libmudflap --disable-libssp --enable-esp --enable-libgomp --enable-cld --with-python-dir=/share/gcc-data/i686-pc-linux-gnu/4.5.2/python --enable-checking=release --disable-libgcj --with-arch=i686 --enable-languages=c,c++ --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl=http://bugs.gentoo.org/ --with-pkgversion='Gentoo Hardened 4.5.2 p1.1, pie-0.4.5' Thread model: posix gcc version 4.5.2 (Gentoo Hardened 4.5.2 p1.1, pie-0.4.5)
Thank you. Could then raise this problem at upstream mailing list, please? https://lists.sourceforge.net/lists/listinfo/oprofile-list I've subscribed there and I'll follow thread there.
Thank you Marcin! Here is the reference on thread with suggested fix: http://thread.gmane.org/gmane.linux.oprofile/9684 Please, try it out and report upstream!
It's fixed in 0.7.7-rc2 . I'm wondering could we backport patch to 0.9.6? If we can't, i think oprofile-0.9.6 should be masked at hardened profile.
oprofile-0.9.7_rc3 is in the tree and backport to 0.9.6 is not trivial so I'd better avoided that. I'll keep this bug open until release happens. As for masking, I'm not opposed to this but that's something hardened team to consider :)
Fixed in 0.9.7. Thank you, guys, again!