gelisam / hawk

Haskell text processor for the command-line
Apache License 2.0
361 stars 20 forks source link

Workaround: lookupSymbol failed in relocateSection (RELOC_GOT) ... HSinteger-gmp-1.0.2.0.o: unknown symbol `___gmp_rands' #228

Open bwagner opened 4 years ago

bwagner commented 4 years ago

When following the instructions in the README and then running hawk '[1..3]' I get the error:

hawk:
lookupSymbol failed in relocateSection (RELOC_GOT)
/Users/bwagner/.stack/programs/x86_64-osx/ghc-8.4.4/lib/ghc-8.4.4/integer-gmp-1.0.2.0/HSinteger-gmp-1.0.2.0.o: unknown symbol `___gmp_rands'
error: GhcException "unable to load package `integer-gmp-1.0.2.0'"

Jumping around a few github issues, the solution is a blatantly simple:

rm /Users/bwagner/.stack/programs/x86_64-osx/ghc-8.4.4/lib/ghc-8.4.4/integer-gmp-1.0.2.0/HSinteger-gmp-1.0.2.0.o of course you need to adjust the path in the above statement unless you're on a mac and your username and ghc versions happen to coincide with mine. See: https://gitlab.haskell.org/ghc/ghc/issues/15105#note_153699

gelisam commented 4 years ago

Thanks. Since this isn't a bug in hawk, but it is something which hawk users might encounter, I'll keep this ticket open but with the wontfix label, just like I did for #211, to make it easier for users to find.

osfameron commented 4 years ago

I just installed Stack on my Macbook for the purpose of installing Hawk, and stack install ran to completion.

Got the error as above, and deleted /Users/myusername/.stack/programs/x86_64-osx/ghc-8.4.4/lib/ghc-8.4.4/integer-gmp-1.0.2.0/HSinteger-gmp-1.0.2.0.o as suggested.

Now I get the new error:

$ hawk '[1..3]'
hawk: ghc: readCreateProcessWithExitCode: runInteractiveProcess: exec: does not exist (No such file or directory)
gelisam commented 4 years ago

Thanks. The two error messages are unrelated, so let's discuss your new error message in #235.