Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

malformed mach-o #1978

Closed
LiamGoodacre opened this issue Oct 11, 2016 · 2 comments
Closed

malformed mach-o #1978

LiamGoodacre opened this issue Oct 11, 2016 · 2 comments

Comments

@LiamGoodacre
Copy link

Stack version: 1.1.2 x86_64 hpack-0.14.0

This is my first time trying to build after upgrading to macOS Sierra, but I don't know if that is related in any way to what's happening.
After first trying to build purescript I see the following:

...
[2 of 2] Compiling Main             ( psc-ide-server/Main.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/psc-ide-server/psc-ide-server-tmp/Main.o ) [Network.Socket changed]
<command line>: can't load .so/.DLL for: ~/git/purescript/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/libHSpurescript-0.10.1-DuUlgyFgUgfCeepCOmAPc5-ghc7.10.3.dylib (dlopen(~/git/purescript/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/libHSpurescript-0.10.1-DuUlgyFgUgfCeepCOmAPc5-ghc7.10.3.dylib, 5): no suitable image found.  Did find:
        ~/git/purescript/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/libHSpurescript-0.10.1-DuUlgyFgUgfCeepCOmAPc5-ghc7.10.3.dylib: malformed mach-o: load commands size (35048) > 32768)
Progress: 9/10
--  While building package purescript-0.10.1 using:
      ~/.stack/setup-exe-cache/x86_64-osx/setup-Simple-Cabal-1.22.5.0-ghc-7.10.3 --builddir=.stack-work/dist/x86_64-osx/Cabal-1.22.5.0 build lib:purescript exe:psc exe:psc-bundle exe:psc-docs exe:psc-hierarchy exe:psc-ide-client exe:psc-ide-server exe:psc-publish exe:psci test:tests --ghc-options " -ddump-hi -ddump-to-file"
    Process exited with code: ExitFailure 1

Didn't know what to do with that, so I tried a stack upgrade to see if that would help:

...
stack-1.2.0: configure
[1 of 1] Compiling Main             ( /private/var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/stack-upgrade17450/stack-1.2.0/Setup.hs, /private/var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/stack-upgrade17450/stack-1.2.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup/Main.o )
Linking /private/var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/stack-upgrade17450/stack-1.2.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup/setup ...
Configuring stack-1.2.0...
stack-1.2.0: build
Preprocessing library stack-1.2.0...
[ 1 of 96] Compiling Text.PrettyPrint.Leijen.Extended ( src/Text/PrettyPrint/Leijen/Extended.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Text/PrettyPrint/Leijen/Extended.o )
[ 2 of 96] Compiling Stack.Ghci.Script ( src/Stack/Ghci/Script.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Stack/Ghci/Script.o )
[ 3 of 96] Compiling Stack.FileWatch  ( src/Stack/FileWatch.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Stack/FileWatch.o )
[ 4 of 96] Compiling System.Process.PagerEditor ( src/System/Process/PagerEditor.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/System/Process/PagerEditor.o )
[ 5 of 96] Compiling System.Process.Log ( src/System/Process/Log.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/System/Process/Log.o )
[ 6 of 96] Compiling Paths_stack      ( .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/autogen/Paths_stack.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Paths_stack.o )
[ 7 of 96] Compiling Path.Find        ( src/Path/Find.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Path/Find.o )
[ 8 of 96] Compiling Path.Extra       ( src/Path/Extra.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Path/Extra.o )
[ 9 of 96] Compiling System.Process.Read ( src/System/Process/Read.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/System/Process/Read.o )
ghc: panic! (the 'impossible' happened)
  (GHC version 7.10.3 for x86_64-apple-darwin):
        Loading temp shared object failed: dlopen(/var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/ghc22600_0/libghc_55.dylib, 5): no suitable image found.  Did find:
        /var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/ghc22600_0/libghc_55.dylib: malformed mach-o: load commands size (47960) > 32768

Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug

Completed 178 action(s).

--  While building package stack-1.2.0 using:
      /private/var/folders/z7/z51s4jss7mx610k7r2wgrj2r0000gn/T/stack-upgrade17450/stack-1.2.0/.stack-work/dist/x86_64-osx/Cabal-1.22.5.0/setup/setup --builddir=.stack-work/dist/x86_64-osx/Cabal-1.22.5.0 build lib:stack exe:stack --ghc-options " -ddump-hi -ddump-to-file"
    Process exited with code: ExitFailure 1

Any help would be much appreciated.

@snoyberg
Copy link
Contributor

I think you're looking for the Stack issue tracker at:

http://github.com/commercialhaskell/stack/issues

This issue looks like:

commercialhaskell/stack#2577

@LiamGoodacre
Copy link
Author

oops! thanks a lot :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants