Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 221961 - dev-libs/dietlibc 0.30-r2 > $current exhibits wrong path on HPPA
Summary: dev-libs/dietlibc 0.30-r2 > $current exhibits wrong path on HPPA
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: HPPA Linux
: High major (vote)
Assignee: Gentoo VPS Team (OBSOLETE)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 221951 227429
  Show dependency tree
 
Reported: 2008-05-13 16:08 UTC by Luca Lesinigo
Modified: 2011-04-04 08:52 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 Luca Lesinigo 2008-05-13 16:08:20 UTC
dev-libs/dietlibc-0.30-r2 will install its lib files in /usr/diet/lib-parisc.

Its 'diet' command is supposed to let gcc link against dietlibc instead of the system's default libc. From diet(1):
       diet  tries to be smart for cross compiling.  If the first argument is not gcc but
       sparc-linux-gcc, diet will guess that you want to cross compile for sparc and  use
       bin-sparc/dietlibc.a instead of the dietlibc.a for your default architecture.

on HPPA, with the default CHOST="hppa2.0-unknown-linux-gnu", this results in trying to use a wrong path (/usr/diet/lib-hppa2.0) in all crosscompile-aware ebuilds/Makefiles - see for example sys-cluster/util-vserver-0.30.215.

A simple symlink /usr/lib/lib-hppa2.0 -> lib-parisc works around the problem.

A good solution could be a renaming patch like the one used for the same problem on ppc, see bug #179408
Comment 1 Luca Lesinigo 2008-06-16 13:18:55 UTC
this bug also appears in version 0.31 of dietlibc, see bug #227429
Comment 2 Luca Lesinigo 2008-09-16 20:42:51 UTC
still present in dietlibc-0.32_pre20080829
Comment 3 Luca Lesinigo 2008-09-16 20:46:15 UTC
in my first report I say:
 "A simple symlink /usr/lib/lib-hppa2.0 -> lib-parisc works around the problem"

when it actually is /usr/diet/lib-hppa2.0 -> lib-parisc
sorry for the typo.
Comment 4 Benedikt Böhm (RETIRED) gentoo-dev 2008-11-16 14:17:54 UTC
ah, this is probably another victim of the uname voodoo in dietlibc ... i'm a bit short on time currently, and can also not test it on hppa, so maybe checkout my svn repo of dietlibc (http://svn.linux-vserver.org/svn/dietlibc/) and give it a try (and send me the patch afterwards)

thanks
Comment 5 Benedikt Böhm (RETIRED) gentoo-dev 2009-07-05 14:07:11 UTC
please try if this patch fixes the problem: http://git.xnull.de/gitweb/?p=dietlibc.git;a=commit;h=81a5c1497633853cb7d210e5b99028a78eea4981
Comment 6 Luca Lesinigo 2010-05-10 12:01:29 UTC
Trying to emerge the latest unstable ebuild fails, probably due to the same "uname voodoo" problem.

Failure is:
[....]
hppa2.0-unknown-linux-gnu-gcc: /var/tmp/portage/dev-libs/dietlibc-0.33_pre20090721/work/dietlibc-0.33_pre20090721/bin-hppa2.0/start.o: No such file or directory
hppa2.0-unknown-linux-gnu-gcc: /var/tmp/portage/dev-libs/dietlibc-0.33_pre20090721/work/dietlibc-0.33_pre20090721/bin-hppa2.0/dietlibc.a: No such file or directory

that's because the /bin/hppa2.0/ path doesn't exist and all the .o files are actually under /bin-parisc/

Comment 7 Luca Lesinigo 2010-06-29 18:37:59 UTC
(In reply to comment #5)
> please try if this patch fixes the problem:
> http://git.xnull.de/gitweb/?p=dietlibc.git;a=commit;h=81a5c1497633853cb7d210e5b99028a78eea4981
This URL gives HTTP 403.

Latest snapshot (dev-libs/dietlibc-0.33_pre20100626 doesn't compile due to this bug, but opposite of my last comment: looks for bin-parisc/diet when object files and binaries are in bin-hppa2.0
Maybe some stuff is in the right place and there's just something else here and there to fix?
Comment 8 Rolf Eike Beer archtester 2010-12-02 18:19:10 UTC
In my understanding the current ebuild on HPPA is changed much too invasive against upstream. I created a new ebuild in my private overlay:

http://opensource.sf-tec.de/repos/dakon-overlay/dev-libs/dietlibc/

-I reverted the "move parisc to hppa2.0" as it was wrong
 -one place used hppa.20 for example
 -hppa1.1 will not work anymore
-the first hunk of the use_correct_platform_on_hppa.diff will instead set the platform to "parisc" if the compiler name starts with "hppa1.1" or "hppa2.0"

Luca tested this and confirmed that it works for him on HPPA.
Comment 9 Benedikt Böhm (RETIRED) gentoo-dev 2011-04-04 08:52:24 UTC
i've added dietlibc-0.33_pre20110403 to the tree, which is a snapshot created from scratch, reverting both the ppc and hppa rename. i added your patch with the additional support for ppc/ppc64. please give it a try and reopen if it's still broken