Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 347167 - sys-libs/zlib fails to build with targets that omit the vendor field in the tuple
Summary: sys-libs/zlib fails to build with targets that omit the vendor field in the t...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-29 12:34 UTC by Diego Elio Pettenò (RETIRED)
Modified: 2012-08-18 23:27 UTC (History)
4 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Diego Elio Pettenò (RETIRED) gentoo-dev 2010-11-29 12:34:13 UTC
CHOST=arm-linux-gnu echo $(echo "${CHOST}" | sed -e 's/^[^-]*-\([^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([^-]*\)-.*$/\1/')
gnu

This causes soname not to be emitted, and thus the gen_usr_ldscript dies in the process


chmod 644 /usr/arm-linux-gnu/tmp/portage/sys-libs/zlib-1.2.5-r2/image//usr/include/zlib.h /usr/arm-linux-gnu/tmp/portage/sys-libs/zlib-1.2.5-r2/image//usr/include/zconf.h
 * ERROR: sys-libs/zlib-1.2.5-r2 failed:
 *   unable to read SONAME from libz.so
 * 
 * Call stack:
 *     ebuild.sh, line   54:  Called src_install
 *   environment, line 2320:  Called gen_usr_ldscript '-a' 'z'
 *   environment, line 1390:  Called die
 * The specific snippet of code:
 *                       [[ -z ${tlib} ]] && die "unable to read SONAME from ${lib}";
 * 
 * If you need support, post the output of 'emerge --info =sys-libs/zlib-1.2.5-r2',
 * the complete build log and the output of 'emerge -pqv =sys-libs/zlib-1.2.5-r2'.
 * The complete build log is located at '/usr/arm-linux-gnu/tmp/portage/sys-libs/zlib-1.2.5-r2/temp/build.log'.
 * The ebuild environment file is located at '/usr/arm-linux-gnu/tmp/portage/sys-libs/zlib-1.2.5-r2/temp/environment'.
 * S: '/usr/arm-linux-gnu/tmp/portage/sys-libs/zlib-1.2.5-r2/work/zlib-1.2.5'

>>> Failed to emerge sys-libs/zlib-1.2.5-r2 for /usr/arm-linux-gnu/, Log file:
Comment 1 Wolfram Kahl 2011-06-12 20:19:57 UTC
I see this error, too, when using cross-emerge.

I did, in my first attempt at cross compilation:

  crossdev -t mipsel-linux-uclibc
  mipsel-linux-uclibc-fix-root mipsel-linux-uclibc

Then, trying:

  mipsel-linux-uclibc-emerge -avuDN gcc

I get:

 * ERROR: sys-libs/zlib-1.2.5-r2 failed (install phase):
 *   unable to read SONAME from libz.so

``Azdo''s message in http://forums.gentoo.org/viewtopic-t-825260-start-0.html
mentions that libz.so is created without soname; the creating command in my
case is:

mipsel-linux-uclibc-gcc -shared -Os -pipe  -fomit-frame-pointer
-I/usr/mipsel-linux-uclibc/usr/include/ -I/usr/mipsel-linux-uclibc/include/
-fPIC -D_LARGEFILE64_SOURCE=1 -o libz.so.1.2.5 adler32.lo compress.lo crc32.lo
deflate.lo gzclose.lo gzlib.lo gzread.lo gzwrite.lo infback.lo inffast.lo
inflate.lo inftrees.lo trees.lo uncompr.lo zutil.lo  -lc
-L/usr/mipsel-linux-uclibc/lib -L/usr/mipsel-linux-uclibc/usr/lib


This is on x86_64 running 2.6.37-gentoo-r4.
Comment 2 Oleh 2011-11-08 18:25:05 UTC
Any updates on this bug? When doing cross build with i486 to i686 CHOST change with current zlib's configure script, getting soname failure

export CHOST=i486-pc-linux-gnu

echo "${CHOST}" | sed -e 's/^[^-]*-\([^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([    ^-]*\)$/\1/' -e 's/^[^-]*-[^-]*-\([^-]*\)-.*$/\1/'
linux 
looks correct but failure.
Comment 3 Oleh 2012-07-26 04:41:04 UTC
supposedly fixed with zlib-1.2.6 and above, at least i can do a cross-chost builds now
Comment 4 SpanKY gentoo-dev 2012-08-18 23:27:14 UTC
should be all set now in the tree; thanks for the report!

Commit message: Extract host os field via config.sub
http://sources.gentoo.org/sys-libs/zlib/zlib-1.2.7.ebuild?r1=1.3&r2=1.4