#3681: hsc2hs wrapper script throws away $HSC2HS_EXTRA's value when specified C
compiler to use
---------------------------+------------------------------------------------
  Reporter:  nwn           |          Owner:            
      Type:  bug           |         Status:  new       
  Priority:  normal        |      Milestone:            
 Component:  hsc2hs        |        Version:  6.12.1 RC1
Resolution:                |       Keywords:            
Difficulty:                |             Os:  MacOS X   
  Testcase:                |   Architecture:  x86       
   Failure:  None/Unknown  |  
---------------------------+------------------------------------------------
Comment (by duncan):

 Ah yes ok. So the hsc2hs wrapper script is wrong because it drops the CC
 flags when the caller specifies where gcc is. Only if the caller does not
 specify the location of gcc will hsc2hs get called with the correct cc
 flags.

 There are probably several places this could be fixed. Longer term it's
 probably not reasonable for hsc2hs to be hard-coded to a particular
 target. In principle it should be possible to call it for either 32 or
 64bit modes on hosts that support it (or possibly to use a cross-
 compiler).

 This suggests that perhaps it is the build managers (eg cabal) that should
 know which target is in use and then pass flags to tools as appropriate.

 In the mean time, ghc only supports 32bit on OSX, so it's probably ok to
 have the `HSC2HS_EXTRA` flags be unconditional.

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3681#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to