Ticket #2383 (closed bug: invalid)

Opened 5 years ago

Last modified 5 years ago

hsc2hs puts -F on call to ghc

Reported by: povman Owned by:
Priority: normal Milestone: 6.10.1
Component: hsc2hs Version: 6.8.2
Keywords: Cc:
Operating System: MacOS X Architecture: Unknown/Multiple
Type of failure: Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

$ /usr/local/bin/hsc2hs --ld=/usr/local/bin/ghc --cflag=-package --cflag=base-3.0.1.0 --cflag=-package --cflag=bytestring-0.9.0.1 --lflag=-optl-lz -o dist/build/Codec/Compression/Zlib/Stream.hs Codec/Compression/Zlib/Stream.hsc
ghc-6.8.2: unrecognised flags: -F/Users/lukeworth/Library/Frameworks
Usage: For basic information, try the `--help' option.
compiling dist/build/Codec/Compression/Zlib/Stream_hsc_make.c failed
command was: ghc -c -package base-3.0.1.0 -package bytestring-0.9.0.1 -F/Users/lukeworth/Library/Frameworks dist/build/Codec/Compression/Zlib/Stream_hsc_make.c -o dist/build/Codec/Compression/Zlib/Stream_hsc_make.o

Change History

Changed 5 years ago by povman

  • version changed from 6.8.3 to 6.8.2

Changed 5 years ago by duncan

Note that there is no obvious workaround. hsc2hs invents this flag all on it's own and passes it direct to ghc which does not understand it.

It does it even without Cabal telling hsc2hs to use ghc as cc. ghc's version of hsc2hs does that anyway.

hsc2hs is almost certainly not the right place to be deciding whether or not to use the per-user frameworks by default. That should be done either by ghc or by Cabal.

Changed 5 years ago by judah

I cannot reproduce this behavior on OS X 10.5 (intel) with ghc-6.8.2.

I'm pretty sure that this problem only occurs with Christian Maeder's distribution of ghc-6.8.2, in which he modified hsc2hs to add the -F flag:  http://www.haskell.org/pipermail/glasgow-haskell-users/2007-December/013907.html

povman, can you confirm that your distribution of ghc was one of Christian's? This is probably the case if you have OS X 10.4; see http://www.haskell.org/ghc/download_ghc_682.html#macosxppc

Note that there was a discussion of handling framework paths in Cabal at the following ticket (hsc2hs is mentioned in the comments):  http://hackage.haskell.org/trac/hackage/ticket/189

Changed 5 years ago by povman

Indeed, I am using that distribution. Huh. I guess no-one's really inclined to update it either, seeing how 6.8.3 is out.

Changed 5 years ago by maeder

I think, that was an old bug in one of my Mac distributions. (Should have been fixed.)

Changed 5 years ago by maeder

Changed 5 years ago by povman

I've actually made it work by reverting to GHC 6.8.1, so I can't even test your fix - sorry. If I ever get 6.8.3 installed I'll check if it works there too.

Changed 5 years ago by igloo

  • difficulty set to Unknown
  • milestone set to 6.10.1

Changed 5 years ago by ross

  • status changed from new to closed
  • resolution set to invalid

As Christian has said, this was never in the mainline.

Changed 5 years ago by simonmar

  • architecture changed from Unknown to Unknown/Multiple
Note: See TracTickets for help on using tickets.