Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 344613 - dev-libs/gmp-5.0.1: build failure in configure stage
Summary: dev-libs/gmp-5.0.1: build failure in configure stage
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: HPPA Linux
: High normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-08 01:15 UTC by Christian Franke
Modified: 2010-11-17 18:13 UTC (History)
1 user (show)

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


Attachments
config.log from gmp build (config.log,185.99 KB, text/plain)
2010-11-08 01:18 UTC, Christian Franke
Details
build.log from gmp build (build.log,17.57 KB, text/plain)
2010-11-08 01:22 UTC, Christian Franke
Details
Without the workaround in the ebuild... (20101110-181152.log.gz,74.43 KB, application/x-gzip)
2010-11-11 07:35 UTC, Jeroen Roovers (RETIRED)
Details
dev-libs:mpfr-3.0.0_p3:20101112-151718.log (20101112-151718.log,689.50 KB, text/plain)
2010-11-12 15:30 UTC, Jeroen Roovers (RETIRED)
Details
sys-apps:coreutils-8.5:20101112-152846.log (20101112-152846.log,548.19 KB, text/plain)
2010-11-12 16:10 UTC, Jeroen Roovers (RETIRED)
Details
dev-perl:Math-BigInt-GMP-1.24:20101112-174023.log [killed after ~20 hours] (20101112-174023.log,9.10 KB, text/plain)
2010-11-13 16:13 UTC, Jeroen Roovers (RETIRED)
Details
dev-python:pycrypto-2.3:20101113-161032.log [killed after 15 minutes CPU use] (20101113-161032.log,63.01 KB, text/plain)
2010-11-13 16:27 UTC, Jeroen Roovers (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Franke 2010-11-08 01:15:52 UTC
dev-libs/gmp-5.0.1 fails to build, at least on hppa.

Reproducible: Always




# emerge --info
Portage 2.2.0_alpha4 (default/linux/hppa/10.0/server, gcc-4.4.4, glibc-2.11.2-r3, 2.6.34-livecd64 parisc64)
=================================================================
System uname: Linux-2.6.34-livecd64-parisc64-PA8800_-Mako-with-gentoo-1.12.13
Timestamp of tree: Sun, 07 Nov 2010 14:15:01 +0000
app-shells/bash:     4.1_p7
dev-lang/python:     2.6.5-r3, 3.1.2-r4
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    2.3-r1
sys-devel/autoconf:  2.65-r1
sys-devel/automake:  1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.4.4-r2
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.10
sys-devel/make:      3.81-r2
virtual/os-headers:  2.6.30-r1 (sys-kernel/linux-headers)
Repositories: gentoo
ACCEPT_KEYWORDS="hppa ~hppa"
ACCEPT_LICENSE="@FSF-APPROVED"
CBUILD="hppa2.0-unknown-linux-gnu"
CFLAGS="-O2 -pipe -march=2.0 -fgcse-sm -fgcse-las -g2 -ggdb"
CHOST="hppa2.0-unknown-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-O2 -pipe -march=2.0 -fgcse-sm -fgcse-las -g2 -ggdb"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs buildpkg candy collision-protect distlocks fixlafiles fixpackages metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox"
GENTOO_MIRRORS="http://gentoo.mneisen.org/ http://de-mirror.org/distro/gentoo/ http://gentoo.tiscali.nl/ http://gentoo.mirror.pw.edu.pl/"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
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=""
SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"
USE="apache2 berkdb bzip2 caps cli cracklib crypt cscope cups cxx firefox foomaticdb fortran gdbm gpm hppa iconv idn imlib ipv6 ithreads kerberos ldap libwww modules mudflap mysql ncurses nls nptl nptlonly openmp pam pcre perl pppd python readline sasl session snmp spell sqlite ssl sysfs syslog tcpd truetype unicode vim-syntax xattr xml xml2 xorg xulrunner zlib zsh-completion" 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 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" 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="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-2" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="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, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Christian Franke 2010-11-08 01:18:09 UTC
Created attachment 253581 [details]
config.log from gmp build
Comment 2 Christian Franke 2010-11-08 01:22:04 UTC
Created attachment 253583 [details]
build.log from gmp build

If someone needs an environment for testing, drop me a mail at nobody@nowhere.ws and I'll create you an account on that box.
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-10 16:54:03 UTC
This may have to do with the special econf stuff we do in src_compile():

    # GMP believes hppa2.0 is 64bit
    local is_hppa_2_0
    if [[ ${CHOST} == hppa2.0-* ]] ; then
        is_hppa_2_0=1
        export CHOST=${CHOST/2.0/1.1}
    fi

I actually have a similar build log from July this year.
Comment 4 SpanKY gentoo-dev 2010-11-10 21:46:57 UTC
i vaguely recall seeing some info that upstream had tweaked hppa2.0 stuff yet again.  so yes, i wouldnt be surprised if that little bit of magic with the stupid gmp configure script isnt quite working anymore.
Comment 5 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-11 07:35:21 UTC
Created attachment 253959 [details]
Without the workaround in the ebuild...
Comment 6 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-11 17:43:58 UTC
That's fixed. It fails 20 out of 30 tests so obviously something else is still wrong. I would advise not to use it at this stage.

In fact I've just package.masked it in profiles/arc/hppa. We need to preserve the old libgmp.so or we can't use expr from coreutils, and we can't even rebuild coreutils because that runs expr itself:

expr: error while loading shared libraries: libgmp.so.3: cannot open shared object file: No such file or directory
expr: error while loading shared libraries: libgmp.so.3: cannot open shared object file: No such file or directory
[..]

I don't think this is specific to HPPA, but it sure kills your system.
Comment 7 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-11 17:57:36 UTC
Oh wait, that's a portage bug. eutils checks for FEATURES=preserve-libs, and emerge warns thusly:

"FEATURES variable contains unknown value(s): preserve-libs"

So eutils does not preserve the old library and neither does emerge. :-\

I don't actually know what the above quotation means. It's a known value and it's dangerous to use with that version of sys-apps/portage. But that's bug #345131 now.
Comment 8 Christian Franke 2010-11-12 09:40:01 UTC
Building dev-libs/gmp-5.0.1 on hppa2.0 without the "cross-compilation-hack" which builts for a hppa1.1-unknown-linux-gnu host, the configure script uses the directory parisc64 which is probably not what we want, if I am not mistaken.

There is an easy way to built the original ebuild on hppa2.0: It is sufficient to have small shell scripts in place for hppa1.1-unknown-linux-gnu-foo which execute hppa2.0-unknown-linux-gnu-foo with $@ as arguments, though this is obviously a very dirty hack.
However, a dev-libs/gmp-5.0.1 built this way passes all the tests.

So it seems to me as if autoconf of dev-libs/gmp being unable do determine the correct linker command which makes it use "link" where it should use "ld" was the exact problem and not a side effect.
Comment 9 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-12 15:30:36 UTC
Created attachment 254097 [details]
dev-libs:mpfr-3.0.0_p3:20101112-151718.log

mpfr: 69 of 156 tests failed
Comment 10 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-12 16:10:17 UTC
Created attachment 254103 [details]
sys-apps:coreutils-8.5:20101112-152846.log

The expr tests fail.
Comment 11 SpanKY gentoo-dev 2010-11-13 01:22:00 UTC
gmp-5 already has calls to preserve_old_lib.  so masking it for not preserving the library is wrong -- it clearly does and works for people.
Comment 12 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-13 16:13:23 UTC
Created attachment 254217 [details]
dev-perl:Math-BigInt-GMP-1.24:20101112-174023.log [killed after ~20 hours]
Comment 13 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-13 16:27:52 UTC
Created attachment 254223 [details]
dev-python:pycrypto-2.3:20101113-161032.log [killed after 15 minutes CPU use]
Comment 14 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-16 17:40:39 UTC
According to [1] we simply need to export [GMP]ABI="1.0" and do nothing else in the ebuild, because everything hppa2.0 or hppa64 assumes a 64-bit userland, which only HPUX supports.

Incidentally, with my last change to the ebuild I broke more than I fixed, so I will address that too shortly, before I remove the mask.


[1] http://gmplib.org/manual/ABI-and-ISA.html#ABI-and-ISA
Comment 15 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-16 21:09:36 UTC
(In reply to comment #14)
> According to [1] we simply need to export [GMP]ABI="1.0" and do nothing else in
> the ebuild, because everything hppa2.0 or hppa64 assumes a 64-bit userland,
> which only HPUX supports.

Simply setting that in the ebuild fixes the gmp and mpfr test suite failures entirely. Committed then. Also removed the package.mask entry again.
Comment 16 SpanKY gentoo-dev 2010-11-17 11:08:06 UTC
thanks ... that code is a lot less ugly in the ebuild

could you commit a similar fix to the gmp-4.3.2 ebuild ?  that'll be sticking around for a while due to the SLOT for old SONAME
Comment 17 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-17 15:42:13 UTC
(In reply to comment #16)
> thanks ... that code is a lot less ugly in the ebuild
> 
> could you commit a similar fix to the gmp-4.3.2 ebuild ?  that'll be sticking
> around for a while due to the SLOT for old SONAME

dev-libs/gmp isn't SLOTted right now!?
Comment 18 Jeroen Roovers (RETIRED) gentoo-dev 2010-11-17 16:28:27 UTC
(In reply to comment #17)
> > could you commit a similar fix to the gmp-4.3.2 ebuild ?

Fixed that for 4.3.2 too. Same change.

> dev-libs/gmp isn't SLOTted right now!?

I guess that's for the future (and won't affect HPPA at all).

Anyway, all fixed.
Comment 19 SpanKY gentoo-dev 2010-11-17 18:13:27 UTC
i dont back-SLOT until the latest version goes stable.  causes much less confusion for users.