Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 248645 - x11-plugins/wmmsg: fails with forced --as-needed
Summary: x11-plugins/wmmsg: fails with forced --as-needed
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Dockapp Team
URL: http://www.gentoo.org/proj/en/qa/asne...
Whiteboard:
Keywords:
Depends on:
Blocks: as-needed
  Show dependency tree
 
Reported: 2008-11-24 16:13 UTC by Diego Elio Pettenò (RETIRED)
Modified: 2009-04-28 14:25 UTC (History)
0 users

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


Attachments
Build log (wmmsg-1.0.1:20081124-131252.log,13.29 KB, text/plain)
2008-11-24 16:13 UTC, Diego Elio Pettenò (RETIRED)
Details
working build log (wmmsg-1.0.1-20090116.log,18.32 KB, text/plain)
2009-01-16 14:05 UTC, Michele Noberasco (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Diego Elio Pettenò (RETIRED) gentoo-dev 2008-11-24 16:13:32 UTC
I'm reporting this bug because the package in summary fails to build when forcing --as-needed on through spec files (check out http://blog.flameeyes.eu/2008/11/14/problems-and-mitigation-strategies-for-as-needed for details).

Check the attached build log.

Thanks,
Diego
Comment 1 Diego Elio Pettenò (RETIRED) gentoo-dev 2008-11-24 16:13:43 UTC
Created attachment 173235 [details]
Build log
Comment 2 Michele Noberasco (RETIRED) gentoo-dev 2008-12-02 10:32:03 UTC
Could you double check this one? It builds fine with --as-needed on my machine...
Comment 3 Michele Noberasco (RETIRED) gentoo-dev 2009-01-15 11:24:22 UTC
Closing.
Comment 4 Diego Elio Pettenò (RETIRED) gentoo-dev 2009-01-15 13:56:37 UTC
Please, have you _read_ the blog post I linked? Can you _please_ read it now?

I'm quite ready to bet you *didn't* read the blog post because otherwise you'd know _why_ it doesn't fail for you but _does_ fail for me and _is_ broken.
Comment 5 Michele Noberasco (RETIRED) gentoo-dev 2009-01-15 16:21:06 UTC
(In reply to comment #4)

[rant mode on]

Yes, I did read your blog post, altough I missed the 'rebuild your system' part (my fault), which I'm doing now. If I didn't your blog, I would have a hard time testing stuff without a --as-needed enabled gcc profile.

Btw, I could have done than sooner if you had bothered to reply to comment #2.

And finally, being gentle to people (instead of sarcastic), expecially when you are pointing out at their errors, would make it a pleasure to learn something new. Keep in mind that everyone here is devoting what precious little free time they can spare on Gentoo, not just you.

[rant mode off]
Comment 6 Diego Elio Pettenò (RETIRED) gentoo-dev 2009-01-15 19:54:04 UTC
Rebuild system? no that's not the part at all, please re-read again and feel free to ask. By the way I read comment #2 as "it does not fail with just LDFLAGS=--as-needed so it might be a problem with forced --as-needed only" (which is somewhat lower priority).

If a package fails forced --as-needed but not LDFLAGS=--as-needed it's because it's either ignoring LDFLAGS (bad) or fails because of an indirect link.

But there is a difference between NEEDINFO and WORKSFORME. WORKSFORME I read as "works for me and I don't care for others".
Comment 7 Michele Noberasco (RETIRED) gentoo-dev 2009-01-16 13:59:12 UTC
(In reply to comment #6)

Thanks for your polite reply.
I feel better now, really :-)

> Rebuild system? no that's not the part at all, please re-read again and feel
> free to ask.
I read it again (:-P) and stopped my complete rebuild :-)

By the way I read comment #2 as "it does not fail with just
> LDFLAGS=--as-needed so it might be a problem with forced --as-needed only"
> (which is somewhat lower priority).
Oh, I see. But actually, it builds fine here with forced --as-needed.
And I'm sure my gcc profile is correct, since I already reproduced and fixed a number of similar bugs.

> But there is a difference between NEEDINFO and WORKSFORME. WORKSFORME I read as
> "works for me and I don't care for others".
I didn't mean it to sound that way, I'm sorry for that.
Actually I wanted to say "it does work for me, can you help me with this?"

I analyzed the linking line that is failing for you and works for me: our setups must be a little different; the link lines are similar, but mine differs from yours by linking some different libraries, and in different order.

So I'm sorry, but I cannot reproduce your issue here, let alone fix it.
Comment 8 Michele Noberasco (RETIRED) gentoo-dev 2009-01-16 14:05:09 UTC
Created attachment 178694 [details]
working build log

Attaching my own build log for reference.
Comment 9 Diego Elio Pettenò (RETIRED) gentoo-dev 2009-01-16 14:14:25 UTC
Okay it might be the different libtool version to be the problem, I'm using 2.2 on the tinderbox. Can you tell me which version are you using? Because this is really interesting to know since I didn't know libtool ever expanded shell commands.

At any rate I checked out the Makefile.am in the source code and... it sincerely stinks.

AM_LDFLAGS = -lX11 -lXext -lXpm -L/usr/X11R6/lib -L/usr/lib -L/usr/local/lib `glib-config --libs` `gtk-config --libs` `imlib2-config --libs`

it's passing this thing though LDFLAGS, and the reason for it is that if you actually pass this through LDADD it will fail telling you that --libs is an ldflag. Funky crappy libtool checks, foobillard has something similar.

Since the package si actually patched to use GTK2, it should be changed so that instead of using pkg-config --libs gtk+-2.0 in Makefile.am it uses $(GTK_LIBS) (which is already calculated during configure). It could also use pkg-config to discover imlib2 and thus replace the imlib2-config call with IMLIB2_LIBS, at which point AM_LDFLAGS should be replaced with LDADD and work out fine.
Comment 10 Michele Noberasco (RETIRED) gentoo-dev 2009-01-16 14:22:14 UTC
Btw, I just noticed that the problem in bug #248639 is the same as in here (cannot link to imlib2). I don't know if this has some meaning for you.
Comment 11 Michele Noberasco (RETIRED) gentoo-dev 2009-01-16 14:24:35 UTC
I'm using libtool-1.5.26
Comment 12 Michele Noberasco (RETIRED) gentoo-dev 2009-01-16 14:57:31 UTC
Following your comment, I just committed to cvs a change where I clean up package Makefile.am via the patch we apply.

The package still compiles fine here with forces --as-needed.
Comment 13 Michele Noberasco (RETIRED) gentoo-dev 2009-04-28 14:25:03 UTC
Well, it seems this needs some testing from the bug reporter...