Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 214669 - app-arch/bzip2-1.0.5-r00.1 links to /usr/lib/libbz2.1.dylib but library is found in /usr/lib/libz2.dylib, rendering bzip2 unusable
Summary: app-arch/bzip2-1.0.5-r00.1 links to /usr/lib/libbz2.1.dylib but library is fo...
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: x86 OS X
: High normal
Assignee: Gentoo non-Linux Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-25 10:39 UTC by Martin Hauser
Modified: 2009-10-19 20:59 UTC (History)
0 users

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


Attachments
The bzip2 emerge.log (bzip2_emerge.log,18.17 KB, text/plain)
2008-04-01 08:24 UTC, Martin Hauser
Details
emerge --info (emerge_info.log,2.64 KB, text/plain)
2008-04-01 09:31 UTC, Martin Hauser
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Hauser 2008-03-25 10:39:34 UTC
the bug manifests as follows:

[20153:0][11:35][mh@SnowFlake:~/]% bzip2
dyld: Library not loaded: /Users/mh/Library/Gentoo/usr/lib/libbz2.1.dylib
  Referenced from: /Users/mh/Library/Gentoo/bin/bzip2
  Reason: image not found
zsh: trace trap  bzip2

if you look around then there is no libbz2.1.dylib only a libbz2.dylib ... 

which breaks portage and bzip2 of course (no unpacking of .bz2 files anymore).

Symlinking /usr/lib/libbz2.dylib to libbz2.1.dylib fixes the problem though.
Comment 1 Fabian Groffen gentoo-dev 2008-03-25 10:49:57 UTC
do you have the build-log by chance?

My bzip2-1.0.5 provides:
% qlist bzip2 | grep dylib | sed -e "s:${EPREFIX}::"
/lib/libbz2.1.0.5.dylib
/lib/libbz2.1.0.dylib
/lib/libbz2.1.dylib
/lib/libbz2.dylib
/usr/lib/libbz2.dylib

no applications should link against /usr/lib with bzip2, only the /lib versions.  Please provide an `otool -L $EPREFIX/bin/bzip2`
Comment 2 Fabian Groffen gentoo-dev 2008-03-25 10:52:12 UTC
(please file further bug-reports under Gentoo/Alt -> Prefix Support instead)
Comment 3 Martin Hauser 2008-03-25 10:57:42 UTC
As bzip2 does not crash on being emerged (emerge runs through just fine), there is no build.log ... sorry.

otool -L provides the following:

/Users/mh/Library/Gentoo/bin/bzip2:
	/Users/mh/Library/Gentoo/usr/lib/libbz2.1.dylib (compatibility version 1.0.0, current version 1.0.5)
	/Users/mh/Library/Gentoo/usr/lib/gcc/i686-apple-darwin9/4.0.1/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.0.0)

Comment 4 Fabian Groffen gentoo-dev 2008-03-25 11:21:29 UTC
something is very wrong with prefix in your case:

a) looks like gen_usr_ldscript didn't run
b) portage's broken-install-names check didn't catch this problem, whereas it should have

Disturbing, my Leopard install had no problems emerging bzip2 and it is correctly linked...
Comment 5 Martin Hauser 2008-03-25 11:24:16 UTC
I'll reemerge bzip2 and have a closer look on what's actually happening + creating a manual build.log using tee and will get back to you with that.
Comment 6 Martin Hauser 2008-04-01 08:24:36 UTC
Created attachment 147946 [details]
The bzip2 emerge.log

Sorry for the delay, here is the bzip2 emerge log, created from the terminal. bzip2 still links to those files in usr/lib in the prefix tree... 

I've wondered if the error could occur as my prefix tree root directory is currently a symlink ? It never made any problems in the past half year on any other emerge though.
Comment 7 Fabian Groffen gentoo-dev 2008-04-01 08:28:47 UTC
please post your emerge --info, you have a very weird problem; Portage doesn't correct any objects for you, whereas it should have, hence your problems.
Comment 8 Martin Hauser 2008-04-01 09:31:32 UTC
Created attachment 147949 [details]
emerge --info

There you go. Sounds not good if portage doesn't correct this things...
Comment 9 Fabian Groffen gentoo-dev 2008-04-03 13:40:07 UTC
ok, this is confusing.  Does your tree snapshot have gen_usr_ldscript in the bzip2 ebuild (at the end)?

Can you put some einfo calls around that call to check that code is reached at all for you?
Comment 10 Martin Hauser 2008-04-04 07:58:12 UTC
Hi,

I guess it's there:

# tail -n 5 /Volumes/fourtytwo/Gentoo/usr/portage/app-arch/bzip2/bzip2-1.0.5-r00.1.ebuild
		[[ libbz2$(get_libname ${PV}) != ${v} ]] &&
		dosym libbz2$(get_libname ${PV}) /$(get_libdir)/${v}
	done
	gen_usr_ldscript libbz2$(get_libname)
}

as for the einfo calls, how would I do that without breaking the checksums and how would they look all? Sorry I haven't gotten around getting myself into how the ebuilds really work yet.
Comment 11 Fabian Groffen gentoo-dev 2008-04-12 09:05:01 UTC
(In reply to comment #10)
> as for the einfo calls, how would I do that without breaking the checksums and
> how would they look all? Sorry I haven't gotten around getting myself into how
> the ebuilds really work yet.

Just run `ebuild <the ebuild> digest` and it will recalculate the checksums.