#1786: can't build ghc-6.8.0.20071017 under Solaris using a GNU linker
-------------------------+--------------------------------------------------
Reporter: guest | Owner:
Type: bug | Status: new
Priority: normal | Milestone: 6.8.1
Component: Compiler | Version: 6.8
Severity: normal | Resolution:
Keywords: | Difficulty: Unknown
Os: Solaris | Testcase:
Architecture: x86 |
-------------------------+--------------------------------------------------
Comment (by duncan):
This is a Cabal bug. See:
http://hackage.haskell.org/trac/hackage/ticket/98
Distribution/Simple/GHC.hs line 374:
{{{
ldArgs = ["-r"]
++ ["-x"] -- FIXME: only some systems's ld support the "-x" flag
++ ["-o", ghciLibName <.> "tmp"]
}}}
We could fix this with a test during the configure step, or we could hack
it and assume that if we're on Solaris then we never use -x. The latter is
easy, the former is better.
Probably the right thing to do is in the configure step (in the
Distribution.Simple.Configure.configure function) is after all the known
programs have been configured, to run ld and test if it supports -x. If it
does, use lookupProgram/updateProgram to update the ProgramConfiguration
with the configured ld program modified to have programArgs = ["-x"].
Any volunteers?
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1786#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
Glasgow-haskell-bugs@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs