Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 508732 - app-text/pdftk-2.02 on hardened - gcj: internal compiler error: Killed (program ecj1)
Summary: app-text/pdftk-2.02 on hardened - gcj: internal compiler error: Killed (progr...
Status: RESOLVED DUPLICATE of bug 574808
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Printing Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-26 02:16 UTC by akarmn
Modified: 2017-02-02 22:59 UTC (History)
2 users (show)

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


Attachments
The build log (file_508732.txt,368.80 KB, text/plain)
2014-04-26 02:16 UTC, akarmn
Details

Note You need to log in before you can comment on or make changes to this bug.
Description akarmn 2014-04-26 02:16:46 UTC
Created attachment 375744 [details]
The build log

pl ~ # emerge --info '=app-text/pdftk-1.44::gentoo'
Portage 2.2.7 (hardened/linux/amd64, gcc-4.7.3, glibc-2.17, 3.10.1-hardened-r1 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.10.1-hardened-r1-x86_64-QEMU_Virtual_CPU_version_1.5.3-with-gentoo-2.2
KiB Mem:     6968792 total,   2078016 free
KiB Swap:          0 total,         0 free
Timestamp of tree: Fri, 25 Apr 2014 00:45:01 +0000
ld GNU ld (GNU Binutils) 2.23.2
app-shells/bash:          4.2_p45
dev-java/java-config:     2.1.12-r1
dev-lang/python:          2.7.5-r3, 3.2.5-r3, 3.3.3
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.69
sys-devel/automake:       1.13.4
sys-devel/binutils:       2.23.2
sys-devel/gcc:            4.7.3-r1
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.9 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo piratepack-testing
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=native -mtune=native"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe -march=native -mtune=native"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch preserve-libs protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync webrsync-gpg xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/piratepack-testing"
SYNC=""
USE="X acl alsa amd64 berkdb bindist bzip2 cli consolekit cracklib crypt cxx dbus dri gdbm gtk hardened iconv ipv6 jpeg justify livecd lock mmx modules multilib ncurses networkmanager nls nptl opengl openmp pam pax_kernel pcre policykit readline session sse sse2 ssl startup-notification tcpd thunar udev unicode urandom userlocales xtpax zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" 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 ublox ubx" INPUT_DEVICES="evdev synaptics mutouch mouse keyboard" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_3" RUBY_TARGETS="ruby19 ruby20" USERLAND="GNU" VIDEO_CARDS="intel vesa via nouveau nv radeon sisusb savage mach64 r128 dummy v4l modesetting cirrus fbdev" 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, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

pl ~ # emerge -pqv '=app-text/pdftk-1.44::gentoo'
[ebuild  N    ] app-text/pdftk-1.44 
pl ~ # 

Build log:
Comment 1 Martin Väth 2014-04-26 06:29:27 UTC
Probably not enough free mem. Try to add some swap.
Comment 2 akarmn 2014-04-26 06:49:12 UTC
ok I'll(In reply to Martin Väth from comment #1)
> Probably not enough free mem. Try to add some swap.

OK I'll try, but I started the VM with 7000 MB, and my RAM disk holding the filesystem has 1.8 GB left, so that like 3.8 GB for RAM.
Comment 3 akarmn 2014-04-26 06:52:35 UTC
pl ~ # df -haT
df: ‘/mnt/cdrom’: No such file or directory
Filesystem     Type         Size  Used Avail Use% Mounted on
rootfs         rootfs       5.0G  3.3G  1.8G  66% /
tmpfs          tmpfs        5.0G  3.3G  1.8G  66% /
none           proc            0     0     0    - /proc
tmpfs          tmpfs        681M  656K  680M   1% /run
udev           devtmpfs      10M     0   10M   0% /dev
mqueue         mqueue          0     0     0    - /dev/mqueue
devpts         devpts          0     0     0    - /dev/pts
none           tmpfs        3.4G     0  3.4G   0% /dev/shm
sysfs          sysfs           0     0     0    - /sys
debugfs        debugfs         0     0     0    - /sys/kernel/debug
cgroup_root    tmpfs         10M     0   10M   0% /sys/fs/cgroup
openrc         cgroup          0     0     0    - /sys/fs/cgroup/openrc
cpuset         cgroup          0     0     0    - /sys/fs/cgroup/cpuset
cpu            cgroup          0     0     0    - /sys/fs/cgroup/cpu
cpuacct        cgroup          0     0     0    - /sys/fs/cgroup/cpuacct
freezer        cgroup          0     0     0    - /sys/fs/cgroup/freezer
binfmt_misc    binfmt_misc     0     0     0    - /proc/sys/fs/binfmt_misc
pl ~ # free -m
             total       used       free     shared    buffers     cached
Mem:          6805       4814       1991          0          0       3857
-/+ buffers/cache:        956       5848
Swap:            0          0          0
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2014-04-26 16:22:26 UTC
(In reply to Martin Väth from comment #1)
> Probably not enough free mem. Try to add some swap.

It's most likely the hardened kernel/libc killing it. dmesg or syslog might tell.
Comment 5 akarmn 2014-04-26 18:20:41 UTC
(In reply to Jeroen Roovers from comment #4)
> (In reply to Martin Väth from comment #1)
> > Probably not enough free mem. Try to add some swap.
> 
> It's most likely the hardened kernel/libc killing it. dmesg or syslog might
> tell.

Yes you are right. I get many messages like this when I try to emerge it:
Apr 26 17:44:22 pl kernel: [73611.655817] PAX: execution attempt in: <anonymous mapping>, 3e0a422e000-3e0a42e4000 3e0a422e000
Apr 26 17:44:22 pl kernel: [73611.655822] PAX: terminating task: /usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.3/ecj1(ecj1):30759, uid/euid: 250/250, PC: 000003e0a422e3b0, SP: 000003edadbe58c8

paxctl -v /usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.3/ecj1
gives only RANDEXEC and MPROTECT disabled (-------x-e--).

So I just did (to disable MPROTECT)

paxctl -m /usr/libexec/gcc/x86_64-pc-linux-gnu/4.7.3/ecj1

and it can compile now.

So is this a bug that should be fixed by upstream or just the maintainer of the ebuild to set the flag, or is it up to the user of gentoo-hardened to manually set this?

Thanks
Comment 6 Manuel Rüger (RETIRED) gentoo-dev 2015-05-27 16:52:30 UTC
1.4.4 has been dropped from the tree, is this still an issue with 2.02?
Comment 7 Patrice Clement gentoo-dev 2015-06-12 07:39:15 UTC
Reopen if the problem still occurs with version 2.02.
Comment 8 Patrice Clement gentoo-dev 2015-07-07 12:56:48 UTC
Marking as FIXED.
Comment 9 Horst Prote 2017-01-31 21:50:03 UTC
(In reply to Patrice Clement from comment #7)
> Reopen if the problem still occurs with version 2.02.

Yes, it reoccured with version 2.02 on hardened for me.
My fix was disabling CONFIG_PAX_MPROTECT_COMPAT in kernel config.
Comment 10 James Le Cuirot gentoo-dev 2017-02-02 19:33:30 UTC
Why was this reopened? Disabling CONFIG_PAX_MPROTECT_COMPAT worked and I gather that feature can break a lot of things.
Comment 11 Magnus Granberg gentoo-dev 2017-02-02 22:59:34 UTC

*** This bug has been marked as a duplicate of bug 574808 ***