Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 70367 - LDFLAGS="-Wl,-O1" breaks mol
Summary: LDFLAGS="-Wl,-O1" breaks mol
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: PPC64 All
: High normal (vote)
Assignee: PPC Porters
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 65002
  Show dependency tree
 
Reported: 2004-11-07 11:33 UTC by Stefan Bruda
Modified: 2005-02-26 02:45 UTC (History)
2 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 Stefan Bruda 2004-11-07 11:33:57 UTC
Yet aanother MOL build problem, this one probably unrelated to the kernel version.  If LDFLAGS are set to "-Wl,-O1" the build fails and we get:

+ Entering Linux
  AS [x]   /var/tmp/portage/mol-0.9.70/work/mol-0.9.70/src/kmod/Linux/../build/_traps.o
  AS [x]   /var/tmp/portage/mol-0.9.70/work/mol-0.9.70/src/kmod/Linux/../build/_actions.o
ld: unrecognized option '-Wl,-O1'
ld: use the --help option for usage information
make[5]: *** [/var/tmp/portage/mol-0.9.70/work/mol-0.9.70/src/kmod/Linux/../build/mol.o] Error 1
make[4]: *** [_module_/var/tmp/portage/mol-0.9.70/work/mol-0.9.70/src/kmod/Linux/../build] Error 2
nm: '../build/mol.ko': No such file
nm: '../build/mol.ko': No such file
checker.pl failed
rm: cannot remove `../build/mol.ko': No such file or directory

Of course the LDFLAGS are not pertinent to kernel modules (as noted), but they would be nice in the application itself and should be in any case suppressed when building the modules.
Comment 1 Michael Hanselmann (hansmi) (RETIRED) gentoo-dev 2004-11-13 10:12:34 UTC
I looked into this one and I'll try to fix it as soon as I talked with vapier about a possible bug in flag-o-matic.eclass.
Comment 2 SpanKY gentoo-dev 2004-11-15 11:31:55 UTC
CFLAGS="-Wl,-O1"
LDFLAGS="-O1"

these are correct forms

LDFLAGS="-Wl,-O1"

this is not correct
Comment 3 Stefan Bruda 2004-11-15 16:04:02 UTC
Sorry, but I will have to reopen this.  Reference for the way I use LDFLAGS: http://forums.gentoo.org/viewtopic.php?t=67777 (subsequent posts do explain various differences in syntax).  Also see: http://forums.gentoo.org/viewtopic.php?t=231170 and http://forums.gentoo.org/viewtopic.php?t=226909 (plus references therein).
Comment 4 SpanKY gentoo-dev 2004-11-15 18:21:52 UTC
it doesnt matter how many forums you read, it's still wrong
Comment 5 Luca Barbato gentoo-dev 2004-11-16 02:18:02 UTC
Taviso could you update your guide at the forum with the correct syntax?
Comment 6 Alexander Skwar 2004-12-07 01:30:40 UTC
Hm, I'm a little confused. In this bug, it's written that

CFLAGS="-Wl,-O1"
LDFLAGS="-O1"

should be correct syntax. 

But when I set this, I cannot compile courier-authlib, which uses mysql_config.
I can only do so, when I don't add -Wl,-O1 to CFLAGS