[GHC] #8666: integer-gmp fails to compile on Debian Squeeze

GHC ghc-devs at haskell.org
Wed Apr 30 20:13:00 UTC 2014


#8666: integer-gmp fails to compile on Debian Squeeze
---------------------------------------+----------------------------------
        Reporter:  jstolarek           |            Owner:
            Type:  bug                 |           Status:  new
        Priority:  normal              |        Milestone:
       Component:  libraries (other)   |          Version:  7.7
      Resolution:                      |         Keywords:
Operating System:  Linux               |     Architecture:  x86_64 (amd64)
 Type of failure:  Compile-time crash  |       Difficulty:  Unknown
       Test Case:                      |       Blocked By:
        Blocking:                      |  Related Tickets:
---------------------------------------+----------------------------------

Comment (by ocharles):

 I believe I am running into this bug:


 {{{
 ollie at nixos ~/w/ghc> nix-shell --pure -I /home/ollie -p
 haskellPackages_ghc782.ghc haskellPackages.cabalInstall -p
 haskellPackages_ghc782.happy haskellPackages_ghc782.alex -p ncurses -p
 gnum4

 [nix-shell:~/work/ghc/libraries/base]$ make
 make -C ../.. all_libraries/base
 make[1]: Entering directory `/home/ollie/work/ghc'
 ===--- building phase 0
 make -r --no-print-directory -f ghc.mk phase=0 phase_0_builds
 make[2]: Nothing to be done for `phase_0_builds'.
 ===--- building phase 1
 make -r --no-print-directory -f ghc.mk phase=1 phase_1_builds
 make[2]: Nothing to be done for `phase_1_builds'.
 ===--- building final phase
 make -r --no-print-directory -f ghc.mk phase=final all_libraries/base
 "inplace/bin/ghc-stage1" -hisuf dyn_hi -osuf  dyn_o -hcsuf dyn_hc -fPIC
 -dynamic  -H64m -O0 -fasm    -package-name integer-gmp-0.5.1.0 -hide-all-
 packages -i -ilibraries/integer-gmp/. -ilibraries/integer-gmp/dist-
 install/build -ilibraries/integer-gmp/dist-install/build/autogen
 -Ilibraries/integer-gmp/dist-install/build -Ilibraries/integer-gmp/dist-
 install/build/autogen -Ilibraries/integer-gmp/include    -optP-include
 -optPlibraries/integer-gmp/dist-install/build/autogen/cabal_macros.h
 -package ghc-prim-0.3.1.0 -Wall -package-name integer-gmp -XHaskell2010 -O
 -fasm  -no-user-package-db -rtsopts -Ilibraries/integer-
 gmp/mkGmpDerivedConstants/dist     -odir libraries/integer-gmp/dist-
 install/build -hidir libraries/integer-gmp/dist-install/build -stubdir
 libraries/integer-gmp/dist-install/build
 -optl-L'/home/ollie/work/ghc/libraries/ghc-prim/dist-install/build'
 -optl-L'/home/ollie/work/ghc/rts/dist/build' -optl-lm -optl-lrt -optl-ldl
 -fPIC -dynamic  -H64m -O0 -fasm    -package-name integer-gmp-0.5.1.0
 -hide-all-packages -i -ilibraries/integer-gmp/. -ilibraries/integer-gmp
 /dist-install/build -ilibraries/integer-gmp/dist-install/build/autogen
 -Ilibraries/integer-gmp/dist-install/build -Ilibraries/integer-gmp/dist-
 install/build/autogen -Ilibraries/integer-gmp/include    -optP-include
 -optPlibraries/integer-gmp/dist-install/build/autogen/cabal_macros.h
 -package ghc-prim-0.3.1.0 -Wall -package-name integer-gmp -XHaskell2010 -O
 -fasm  -no-user-package-db -rtsopts -Ilibraries/integer-
 gmp/mkGmpDerivedConstants/dist     -fno-use-rpaths -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../ghc-prim-0.3.1.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../rts-1.0' -optl-Wl,-zorigin libraries/integer-gmp/dist-
 install/build/GHC/Integer.dyn_o libraries/integer-gmp/dist-
 install/build/GHC/Integer/GMP/Internals.dyn_o libraries/integer-gmp/dist-
 install/build/GHC/Integer/GMP/Prim.dyn_o libraries/integer-gmp/dist-
 install/build/GHC/Integer/Logarithms.dyn_o libraries/integer-gmp/dist-
 install/build/GHC/Integer/Logarithms/Internals.dyn_o libraries/integer-gmp
 /dist-install/build/GHC/Integer/Type.dyn_o libraries/integer-gmp/dist-
 install/build/cbits/gmp-wrappers.dyn_o  libraries/integer-gmp/dist-
 install/build/cbits/cbits.dyn_o   libraries/integer-gmp/gmp/objs/*.o
 -shared -dynamic -dynload deploy   -no-auto-link-packages -o libraries
 /integer-gmp/dist-install/build/libHSinteger-
 gmp-0.5.1.0-ghc7.9.20140430.so
 Warning: -rtsopts and -with-rtsopts have no effect with -shared.
     Call hs_init_ghc() from your main() function to set these options.
 /nix/store/xjvdpqgn2kd4rg0k30z020kxylvlbpx0-binutils-2.23.1/bin/ld:
 libraries/integer-gmp/gmp/objs/aors.o: relocation R_X86_64_32 against
 `__gmpz_add' can not be used when making a shared object; recompile with
 -fPIC
 libraries/integer-gmp/gmp/objs/aors.o: could not read symbols: Bad value
 collect2: error: ld returned 1 exit status
 make[2]: *** [libraries/integer-gmp/dist-install/build/libHSinteger-
 gmp-0.5.1.0-ghc7.9.20140430.so] Error 1
 make[1]: *** [all_libraries/base] Error 2
 make[1]: Leaving directory `/home/ollie/work/ghc'
 make: *** [all] Error 2

 }}}

 If anyone has anything they'd like me to try - suggest away!

 I'm at revision 34db5ccf52ec2a1b5e953c282d0c52a7fc82c02a (at least in the
 root of the source tree), and my nixpkgs is
 e001ac6a9ee3e3f1d755c16d1a27e5ce75a76902

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/8666#comment:9>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list