The installation of dev-lang/erlang-12.2.5 fails with a warning about executable stack in /usr/lib64/erlang/erts-5.6.5/bin/beam and /usr/lib64/erlang/erts-5.6.5/bin/beam.smp. The following mask fixes the issue: QA_EXECSTACK="usr/lib*/erlang/erts-*/bin/beam usr/lib*/erlang/erts-*/bin/beam.smp" $ emerge --info Portage 2.1.6_rc2 (default/linux/amd64/2008.0/developer, gcc-4.3.1, glibc-2.7-r2, 2.6.28-rc5-mactel x86_64) ================================================================= System uname: Linux-2.6.28-rc5-mactel-x86_64-Intel-R-_Core-TM-2_Duo_CPU_T7500_@_2.20GHz-with-glibc2.2.5 Timestamp of tree: Sat, 29 Nov 2008 12:30:08 +0000 app-shells/bash: 3.2_p48 dev-java/java-config: 1.3.7, 2.1.6-r1 dev-lang/python: 2.5.2-r8 dev-util/cmake: 2.6.2 sys-apps/baselayout: 2.0.0 sys-apps/openrc: 0.3.0-r1 sys-apps/sandbox: 1.2.18.1-r3 sys-devel/autoconf: 2.13, 2.63 sys-devel/automake: 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2 sys-devel/binutils: 2.19 sys-devel/gcc-config: 1.4.0-r4 sys-devel/libtool: 1.5.26 virtual/os-headers: 2.6.27-r2 ACCEPT_KEYWORDS="amd64 ~amd64" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe -march=nocona -fomit-frame-pointer -mno-tls-direct-seg-refs" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config /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/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/splash /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d" CXXFLAGS="-O2 -pipe -march=nocona -fomit-frame-pointer -mno-tls-direct-seg-refs" DISTDIR="/usr/portage/distfiles" FEATURES="collision-protect cvs digest distlocks metadata-transfer multilib-strict parallel-fetch protect-owned sandbox sfperms sign splitdebug strict stricter unmerge-orphans userfetch userpriv usersandbox" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" LANG="de_DE.UTF-8" LC_ALL="de_DE.UTF-8" LDFLAGS="-Wl,--as-needed" LINGUAS="de en" MAKEOPTS="-j3" PKGDIR="/usr/portage/packages" 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/gentopia /usr/local/portage/layman/mozilla /usr/local/portage/layman/x11 /usr/local/portage/layman/sunrise /usr/local/overlays/lars /usr/local/overlays/party-ebuilds /usr/local/overlays/php-overlay /usr/local/overlays/couchdb-overlay" SYNC="rsync://rsync.gentoo.org/gentoo-portage" USE="X a52 aac aalib acl acpi admin aiglx alsa amd64 apache2 applet asyncns audioscrobbler autoipd automount avahi bash-completion beagle berkdb binfilter bluetooth bonjour bookmarks bzip2 cairo cdda cddb cdparanoia cdr chm consolekit cpudetection cracklib crypt cscope cups curl cvs daap dbus dell device-mapper dga dia dirac disk-partition djvu dmi dpms dri dri2 dts dv dvb dvd dvdnav dvdr dvdread dvi eds enca encode eog esd evo exif extraengine extras fam fbsplash ffmpeg firefox flac fontconfig ftp fuse gajim galago gdbm gedit gif gimp gimp-print gimpprint git glade glitz gnet gnome gnome-keyring gnome-print gphoto2 gpm gsf gsm gstreamer gstreamer010 gtk gtkhtml guile gzip hal howl hvm iconv idle idn ieee1394 ilbc inkjar ipod ipv6 jabber jack java5 jingle jpeg jrtplib kdeenablefinal keyring laptop lcms ldap libcaca libgda libnotify libsexy live logrotate lua lzo mactel mad matroska mhash midi mmx mng mono mozdevelop mp2 mp3 mpeg mpm-worker msn multilib multiuser musepack musicbrainz mysql nautilus ncurses networkmanager newspr nfs njb nls nntp no-old-linux nptl nptlonly nsplugin ntp ntplonly office ogg opengl ortp pam pango pcf pcre pdf php png portaudio ppds prediction print printer pygrub python quicktime rar readline ruby samba schroedinger slp smp soap sockets speex spell sqlite sqlite3 srt srv srvdir sse sse2 ssh ssl ssse3 startup-notification subversion svg t1lib tagwriting theora threads tiff tracker trayicon truetype tslib unicode usb v4l v4l2 vim-pager vim-syntax vorbis vorbis-psy webdav wma wmf x264 xanim xattr xcb xcomposite xforms xft xhtml xinerama xml xml2 xorg xprint xulrunner xv xvid yahoo zeroconf zlib" ALSA_CARDS="hda-intel als4000" ALSA_PCM_PLUGINS="adpcm alaw copy dshare dsnoop extplug file hooks ladspa lfloat linear meter mulaw multi null rate route share shm asym dmix empty iec958 ioplug plug 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" APACHE2_MPMS="prefork" ELIBC="glibc" INPUT_DEVICES="keyboard mouse synaptics evdev tslib" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de en" LIRC_DEVICES="macmini" USERLAND="GNU" VIDEO_CARDS="intel i810" Unset: CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
The mask is making the warning go away...but is it actually a fix?
This should be reported upstream. Would you be so kind to do that. If not, please at least add your scanelf log file so I can do the report.
Created attachment 174492 [details] /var/tmp/portage/dev-lang/erlang-12.2.5/temp/scanelf-execstack.log Scanelf log. I tried reporting the bug myself but I was told that OTP only has a private bugtracker. So maybe one should send a mail to erlang-bugs, but I'm not sure how upstream handles bug reports.
(In reply to comment #3) > Created an attachment (id=174492) [edit] > /var/tmp/portage/dev-lang/erlang-12.2.5/temp/scanelf-execstack.log > > Scanelf log. I tried reporting the bug myself but I was told that OTP only has > a > private bugtracker. So maybe one should send a mail to erlang-bugs, but I'm not > sure how upstream handles bug reports. When I had a more reliable internet connection, I used to report all our patches to erlang-bugs mailing list...they reacted fast and in a friendly manner. Just try it. :)
Mail sent.
(In reply to comment #5) > Mail sent. Unluckily upstream does not react...we will wait until after the holidays.
This issue is caused by hand-written assembly code without a .note.GNU-stack section.
Created attachment 178130 [details, diff] Fixes the executable stacks on amd64 This patch can be easily extended to fix the other arches (arm, ppc, sparc, x86), too.
(In reply to comment #7) > This issue is caused by hand-written assembly code without a .note.GNU-stack > section. Is this taken from upstream? Or do they at least know about this fix?
(In reply to comment #9) > (In reply to comment #7) > > This issue is caused by hand-written assembly code without a .note.GNU-stack > > section. > > Is this taken from upstream? Or do they at least know about this fix? > No, the patch is mine. I haven't sent it upstream yet...
(In reply to comment #10) > (In reply to comment #9) > > (In reply to comment #7) > > > This issue is caused by hand-written assembly code without a .note.GNU-stack > > > section. > > > > Is this taken from upstream? Or do they at least know about this fix? > > > > No, the patch is mine. I haven't sent it upstream yet... Could you please do so? If you are afraid of it or don't have the time, I can do it, of course.
Done. http://www.erlang.org/pipermail/erlang-patches/2009-January/000362.html
And we got an answer: http://www.erlang.org/pipermail/erlang-patches/2009-January/000363.html Perfect. So we will wait for R13.
(In reply to comment #13) > And we got an answer: > http://www.erlang.org/pipermail/erlang-patches/2009-January/000363.html > > Perfect. So we will wait for R13. > Could you do a revbump with upstream patch for exec stack issues? http://www.erlang.org/pipermail/erlang-patches/2009-February/000370.html And while at it, could you also include the following patch which fixes a segfault on amd64 with hipe? (suggested by upstream) http://www.erlang.org/pipermail/erlang-bugs/2009-January/001173.html Thanks.
Both fixes added. Closing. Please test and report back.
(In reply to comment #15) > Both fixes added. Closing. Please test and report back. > Exec stacks are gone and the segfault is fixed. Thank you very much!