Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 291715 - dev-lang/tk-8.5.x require patch for prefix usage
Summary: dev-lang/tk-8.5.x require patch for prefix usage
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All IRIX
: High normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-03 14:57 UTC by Stuart Shelton
Modified: 2010-12-07 09:04 UTC (History)
0 users

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


Attachments
Patch for tk-8.5.7 to place XFT_LIBS before X11_LIBS, so that the X11 library search path is correct (tk-8.5.7-prefix.patch,496 bytes, patch)
2009-11-03 15:21 UTC, Stuart Shelton
Details | Diff
tk-8.5.8.ebuild.patch (tk-8.5.8.ebuild.patch,2.63 KB, patch)
2010-07-02 16:33 UTC, Stuart Shelton
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stuart Shelton 2009-11-03 14:57:02 UTC
tk-8.5.7 doesn't include a library path option for '-lX11 -lXss -lXext', which results in the system libraries rather than the prefix libraries being used.

On one system this passed unnoticed, as the (now ancient) system versions of these libraries were used.

On another machine which doesn't have system XScreenSaver installed (although does have the libXScrnSaver package installed) the build fails because the linker can't find a library for -lXss.

I have a simple fix, but I'm not sure of its correctness: $(XFT_LIBS) includes the correct -L path for portage, and so placing this first fixes the problem.  A better solution would be t prepend this path onto X11_LIB_SWITCHES - but I'm not sure how this should best be done.
Comment 1 Stuart Shelton 2009-11-03 15:21:49 UTC
Created attachment 209132 [details, diff]
Patch for tk-8.5.7 to place XFT_LIBS before X11_LIBS, so that the X11 library search path is correct


The only other values in Makefile.in which contain the library search path but not libraries is $(LDFLAGS), so swapping the -lX* directives and $(XFT_LIBS) seemed the most sensible option...
Comment 2 Fabian Groffen gentoo-dev 2009-11-11 14:47:05 UTC
That's a fix that actually relies on some little coincidence.  Can't we just somehow inject the -L${EPREFIX}/usr/$(get_libdir) path somewhere so we know it's proper?
Comment 3 Stuart Shelton 2009-11-12 19:57:47 UTC
That'd certainly make sense - but CFLAGS et al. are only included after these libraries, and so wouldn't affect the outcome.

I'm not aware of another good method (other than patching the Makefile in some other way, which may well be the best solution - the above patch was just the minimal set of changes to get the thing working) to inject the library path...
Comment 4 Stuart Shelton 2010-07-02 15:26:11 UTC
Still a problem with tk-8.5.8 :(
Comment 5 Stuart Shelton 2010-07-02 16:33:45 UTC
Created attachment 237289 [details, diff]
tk-8.5.8.ebuild.patch


Having said that, it does look as if the tk ebuild could do with a bit of eprefix-ifying.  How's this?
Comment 6 Stuart Shelton 2010-07-02 16:46:58 UTC
Actually, ignore that last one - tk-8.5.8-r1.ebuild (which I'd somehow missed) includes all of these changes :o
Comment 7 Justin Lecher (RETIRED) gentoo-dev 2010-12-07 09:04:21 UTC
Wotks for me.