Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 25473 - dolib.{a,so} to read links and create them
Summary: dolib.{a,so} to read links and create them
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Unclassified (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
: 36094 36095 65730 67012 67790 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-07-28 19:03 UTC by SpanKY
Modified: 2011-10-30 22:22 UTC (History)
5 users (show)

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


Attachments
dolib.so.patch (dolib.so,773 bytes, patch)
2003-07-28 19:03 UTC, SpanKY
Details | Diff
dolib.so.patch (liblinks,880 bytes, patch)
2003-07-28 19:05 UTC, SpanKY
Details | Diff
dolib.patch (dolib.patch,3.07 KB, patch)
2004-10-04 06:49 UTC, SpanKY
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description SpanKY gentoo-dev 2003-07-28 19:03:00 UTC
currently if you have this setup:
root@vapier 0 work # pwd
/var/tmp/portage/testing-0/work
root@vapier 0 work # ls -al
total 12
drwx------    2 root     root         4096 Jul 28 21:54 .
drwxr-xr-x    6 portage  portage      4096 Jul 28 21:54 ..
-rw-r--r--    1 root     root            2 Jul 28 21:54 blah.so
lrwxr-xr-x    1 root     root            7 Jul 28 21:54 blah.so.1 -> blah.so
lrwxr-xr-x    1 root     root            7 Jul 28 21:54 blah.so.2 -> blah.so

and you run `dolib.so blah.so*`, you'll get this
root@vapier 0 lib # pwd
/var/tmp/portage/testing-0/image/usr/lib
root@vapier 0 lib # ls -al
total 20
drwxr-xr-x    2 root     root         4096 Jul 28 21:56 .
drwxr-xr-x    3 root     root         4096 Jul 28 21:55 ..
-rwxr-xr-x    1 root     root            2 Jul 28 21:56 blah.so
-rwxr-xr-x    1 root     root            2 Jul 28 21:56 blah.so.1
-rwxr-xr-x    1 root     root            2 Jul 28 21:56 blah.so.2

so i made a patch so the 'proper' behavior will be:
root@vapier 0 lib # pwd
/var/tmp/portage/testing-0/image/usr/lib
root@vapier 0 lib # ls -al
total 12
drwxr-xr-x    2 root     root         4096 Jul 28 21:56 .
drwxr-xr-x    3 root     root         4096 Jul 28 21:55 ..
-rwxr-xr-x    1 root     root            2 Jul 28 21:56 blah.so
lrwxr-xr-x    1 root     root            7 Jul 28 21:56 blah.so.1 -> blah.so
lrwxr-xr-x    1 root     root            7 Jul 28 21:56 blah.so.2 -> blah.so

note !
if the lib is linked in some other manner than that (i.e. the file is trying to
do /usr/lib/libblah.so -> /lib/libblah.so.1, or /usr/lib/libblah.so ->
/usr/lib/blahblah/blahhh/liblbah.so.1, then this patch will still do
/usr/lib/libblah.so -> libblah.so.1).  i figured that ppl who do crazy linking
have a makefile ...
Comment 1 SpanKY gentoo-dev 2003-07-28 19:03:41 UTC
Created attachment 15165 [details, diff]
dolib.so.patch

was made against dolib.so but it is trivial to apply to dolib.a also
Comment 2 SpanKY gentoo-dev 2003-07-28 19:05:31 UTC
Created attachment 15166 [details, diff]
dolib.so.patch

err, wrong file :/
Comment 3 SpanKY gentoo-dev 2003-12-19 13:37:23 UTC
*** Bug 36094 has been marked as a duplicate of this bug. ***
Comment 4 SpanKY gentoo-dev 2003-12-19 13:37:36 UTC
*** Bug 36095 has been marked as a duplicate of this bug. ***
Comment 5 Carsten Lohrke (RETIRED) gentoo-dev 2003-12-21 15:24:47 UTC
This bug is a few month old and a patch exists, so why it is not included in portage yet?
Comment 6 Masatomo Nakano (RETIRED) gentoo-dev 2003-12-24 17:43:17 UTC
I think that 'readlink' command is better than "$(basename $(ls -al ${x} | awk '{print $NF}'))"

carpaski: Is there a reason not to include this patch? If not, I'll do...
Comment 7 SpanKY gentoo-dev 2003-12-24 17:51:10 UTC
the reason i didnt use readlink at the time was because readlink was part of debianutils ... i didnt want to make portage DEPEND on such a thing :)

now that it's part of coreutils i guess using readlink is cool
Comment 8 SpanKY gentoo-dev 2004-10-04 06:49:01 UTC
Created attachment 41067 [details, diff]
dolib.patch

nick: here's a much cooler patch ... lets get it into .51 !@

- have dolib create symlinks
- have dolib.a/dolib.so just call dolib with the appropriate $LIBOPTIONS

having the same code duplicated in dolib/dolib.a/dolib.so is just a waste ...
so now everything is just in dolib

also, having the strip in dolib.so was pointless since portage runs strip on
all the shared files in $D anyways
Comment 9 Nicholas Jones (RETIRED) gentoo-dev 2004-10-09 16:25:52 UTC
*** Bug 65730 has been marked as a duplicate of this bug. ***
Comment 10 SpanKY gentoo-dev 2004-10-10 18:09:56 UTC
*** Bug 67012 has been marked as a duplicate of this bug. ***
Comment 11 SpanKY gentoo-dev 2004-10-16 13:31:49 UTC
*** Bug 67790 has been marked as a duplicate of this bug. ***
Comment 12 Nicholas Jones (RETIRED) gentoo-dev 2004-10-22 08:48:03 UTC
Bug has been fixed and released in stable portages on or before 2.0.51-r2
Comment 13 Florian Evers 2004-11-03 05:33:12 UTC
@Nicholas Jones:
This bug has been fixed?

Look at comment #10:
http://bugs.gentoo.org/show_bug.cgi?id=67012
It's still there.
I'm using Portage 2.0.51-r2, "x86"

Reopen?
Comment 14 SpanKY gentoo-dev 2004-11-03 05:42:44 UTC
yes this bug is fixed

Bug 67012 was filed before 2.0.51 was released :p