logo       

[ ghc-Bugs-1364820 ] LDFLAGS not used by generated ghc: msg#00060

lang.haskell.glasgow.bugs

Subject: [ ghc-Bugs-1364820 ] LDFLAGS not used by generated ghc

Bugs item #1364820, was opened at 2005-11-23 11:42
Message generated for change (Comment added) made by jgoerzen
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1364820&group_id=8032

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Compiler
Group: None
Status: Closed
Resolution: Wont Fix
Priority: 5
Submitted By: John Goerzen (jgoerzen)
Assigned to: Nobody/Anonymous (nobody)
Summary: LDFLAGS not used by generated ghc

Initial Comment:
Hello,

I specified LDFLAGS=-Wl,-bbigtoc which is needed to
link programs of any size on AIX, including ghc.

The stage1/ghc-inplace compiler, however, is not
passing this along to gcc.

I can manually run the commands that make is running,
add -optl -Wl,-bbigtoc and get the correct result, but
GHC should do this itself.

This is GHC 6.4.1.

----------------------------------------------------------------------

>Comment By: John Goerzen (jgoerzen)
Date: 2005-11-28 08:17

Message:
Logged In: YES
user_id=491567

All of the above, really. I want LDFLAGS to be used when
building ghc, any other tools in the tree, and when GHC does
linking itself.

I'll take a look at the config options you mentioned. Did I
miss them in the docs somewhere? If not, could this bug be
considered a request to document this?

----------------------------------------------------------------------

Comment By: Simon Marlow (simonmar)
Date: 2005-11-28 06:19

Message:
Logged In: YES
user_id=48280

Where do you want LDFLAGS to be used? Just when building
GHC, or do you want them to be added for every link in the
tree? And when the GHC you're building does any linking itself?

We don't tend to use LDFLAGS/CFLAGS because they're a bit
global, it's not usually what you want. Instead, you should
modify build.mk, something like this:

GhcStage1HcOpts += -optl-Wl,-bbigtoc

and if you want GHC to always add this option for you, then
the best place to put it is the ld-options field of the rts
package (see ghc/rts/package.conf.in). (also there's
machdepCCOptions in ghc/compiler/main/DynFlags, but that
applies to all C compilations and it's wired into the
compiler, so that's perhaps not as suitable).


----------------------------------------------------------------------

Comment By: John Goerzen (jgoerzen)
Date: 2005-11-23 11:57

Message:
Logged In: YES
user_id=491567

The final (stage2) compiler also does not honor these flags
automatically.

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=108032&aid=1364820&group_id=8032


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise