Opened 9 years ago

Closed 9 years ago

#5010 closed bug (fixed)

ghc-asm has a poor shebang

Reported by: mcandre Owned by: igloo
Priority: highest Milestone: 7.2.1
Component: Compiler Version: 6.12.3
Keywords: Cc:
Operating System: MacOS X Architecture: Unknown/Multiple
Type of failure: Runtime crash Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


During a cabal install of Snap and its dependency bytestring-mmap, ghc-asm complained that it couldn't run.

$ cabal install bytestring-mmap-0.2.1
Resolving dependencies...
Configuring bytestring-mmap-0.2.1...
Preprocessing library bytestring-mmap-0.2.1...
Building bytestring-mmap-0.2.1...
[1 of 3] Compiling System.IO.Posix.MMap.Internal ( System/IO/Posix/MMap/Internal.hs, dist/build/System/IO/Posix/MMap/Internal.o )
ghc: could not execute: /Library/Frameworks/GHC.framework/Versions/612/usr/lib/ghc-6.12.3/ghc-asm
cabal: Error: some packages failed to install:
bytestring-mmap-0.2.1 failed during the building phase. The exception was:
ExitFailure 1

Upon further investigation, it was determined that ghc-asm wouldn't run due to its shebang.

$ less /Library/Frameworks/GHC.framework/Versions/612/usr/lib/ghc-6.12.3/ghc-asm

$TARGETPLATFORM  = "i386-apple-darwin";

I installed MacPorts in ~/macports, not /opt/local. When GHC was installed, it should have used the shebang

#!/usr/bin/env perl

which does not depend on MacPorts being installed in /opt/local, or for that matter MacPorts being installed at all.


  • GHC 6.12.3
  • Haskell Platform 2010.2.0.0
  • Mac OS X 10.6.6
  • MacBook Pro 5,1

Change History (2)

comment:1 Changed 9 years ago by igloo

Milestone: 7.2.1
Owner: set to igloo
Priority: normalhighest

Thanks for the report.

comment:2 Changed 9 years ago by igloo

Resolution: fixed
Status: newclosed

Ah, I missed that this was in version 6.12.3. It's since been fixed (the OS X installers now use /usr/bin/perl).

Note: See TracTickets for help on using tickets.