[GHC] #15837: Hadrian should build dynamically linked ghc binary

GHC ghc-devs at haskell.org
Thu Dec 6 09:59:06 UTC 2018


#15837: Hadrian should build dynamically linked ghc binary
-------------------------------------+-------------------------------------
        Reporter:  davide            |                Owner:  davide
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Build System      |              Version:  8.6.1
  (Hadrian)                          |
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
                                     |  Unknown/Multiple
 Type of failure:  None/Unknown      |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):  Phab:D5385
       Wiki Page:                    |  Phab:D5327
-------------------------------------+-------------------------------------

Comment (by davide):

 Note that the make build system succeeds and can be used as a reference
 here. Here is the verbose (-v3) output of the make build command that
 builds/links the ghc binary:

 {{{
 # Model ghc build (make default)

 "inplace/bin/ghc-stage1" -o ghc/stage2/build/tmp/ghc-stage2 -hisuf dyn_hi
 -osuf  dyn_o -hcsuf dyn_hc -fPIC -dynamic  -H32m -O -Wall      -hide-all-
 packages -i -ighc/. -ighc/stage2/build -Ighc/stage2/build
 -ighc/stage2/build/ghc/autogen -Ighc/stage2/build/ghc/autogen    -optP-
 DGHCI -optP-include -optPghc/stage2/build/ghc/autogen/cabal_macros.h
 -package-id array-0.5.2.0 -package-id base-4.12.0.0 -package-id
 bytestring-0.10.9.0 -package-id containers-0.6.0.1 -package-id
 deepseq-1.4.4.0 -package-id directory-1.3.3.1 -package-id filepath-1.4.2.1
 -package-id ghc-8.7 -package-id ghc-boot-8.7 -package-id ghc-prim-0.5.3
 -package-id ghci-8.7 -package-id haskeline-0.7.4.3 -package-id
 process-1.6.3.0 -package-id time-1.9.2 -package-id transformers-0.5.5.0
 -package-id unix-2.7.2.2 -Wall -Wnoncanonical-monad-instances
 -Wnoncanonical-monadfail-instances -Wnoncanonical-monoid-instances -fno-
 warn-name-shadowing -threaded -XHaskell2010 -XNoImplicitPrelude  -O2
 -haddock -Wcpp-undef -no-hs-main -threaded -no-user-package-db -rtsopts
 -Wnoncanonical-monad-instances  -odir ghc/stage2/build -hidir
 ghc/stage2/build -stubdir ghc/stage2/build     -fPIC -dynamic  -H32m -O
 -Wall      -hide-all-packages -i -ighc/. -ighc/stage2/build
 -Ighc/stage2/build -ighc/stage2/build/ghc/autogen
 -Ighc/stage2/build/ghc/autogen    -optP-DGHCI -optP-include
 -optPghc/stage2/build/ghc/autogen/cabal_macros.h -package-id array-0.5.2.0
 -package-id base-4.12.0.0 -package-id bytestring-0.10.9.0 -package-id
 containers-0.6.0.1 -package-id deepseq-1.4.4.0 -package-id
 directory-1.3.3.1 -package-id filepath-1.4.2.1 -package-id ghc-8.7
 -package-id ghc-boot-8.7 -package-id ghc-prim-0.5.3 -package-id ghci-8.7
 -package-id haskeline-0.7.4.3 -package-id process-1.6.3.0 -package-id
 time-1.9.2 -package-id transformers-0.5.5.0 -package-id unix-2.7.2.2 -Wall
 -Wnoncanonical-monad-instances -Wnoncanonical-monadfail-instances
 -Wnoncanonical-monoid-instances -fno-warn-name-shadowing -threaded
 -XHaskell2010 -XNoImplicitPrelude  -O2 -haddock -Wcpp-undef -no-hs-main
 -threaded -no-user-package-db -rtsopts       -Wnoncanonical-monad-
 instances  -fno-use-rpaths -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../haskeline-0.7.4.3' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../stm-2.5.0.0' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../ghc-8.7'
 -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../terminfo-0.4.1.2' -optl-Wl,-rpath
 -optl-Wl,'$ORIGIN/../process-1.6.3.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../hpc-0.6.0.3' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../ghci-8.7'
 -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../transformers-0.5.5.0' -optl-Wl,-rpath
 -optl-Wl,'$ORIGIN/../template-haskell-2.15.0.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../pretty-1.1.3.6' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../ghc-
 heap-8.7' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../ghc-boot-8.7' -optl-
 Wl,-rpath -optl-Wl,'$ORIGIN/../ghc-boot-th-8.7' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../directory-1.3.3.1' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../unix-2.7.2.2' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../time-1.9.2' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../filepath-1.4.2.1' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../binary-0.8.6.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../containers-0.6.0.1' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../bytestring-0.10.9.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../deepseq-1.4.4.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../array-0.5.2.0' -optl-Wl,-rpath -optl-
 Wl,'$ORIGIN/../base-4.12.0.0' -optl-Wl,-rpath -optl-Wl,'$ORIGIN
 /../integer-gmp-1.0.2.0' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../ghc-
 prim-0.5.3' -optl-Wl,-rpath -optl-Wl,'$ORIGIN/../rts' -optl-Wl,-zorigin
 ghc/stage2/build/Main.dyn_o ghc/stage2/build/GHCi/Leak.dyn_o
 ghc/stage2/build/GHCi/UI.dyn_o ghc/stage2/build/GHCi/UI/Info.dyn_o
 ghc/stage2/build/GHCi/UI/Monad.dyn_o ghc/stage2/build/GHCi/UI/Tags.dyn_o
 ghc/stage2/build/hschooks.dyn_o

 Glasgow Haskell Compiler, Version 8.7.20181205, stage 1 booted by GHC
 version 8.4.4
 Using binary package database: /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/inplace/lib/package.conf.d/package.cache
 package flags [-package-id array-0.5.2.0{unit array-0.5.2.0 True ([])},
                -package-id base-4.12.0.0{unit base-4.12.0.0 True ([])},
                -package-id bytestring-0.10.9.0{unit bytestring-0.10.9.0
 True ([])},
                -package-id containers-0.6.0.1{unit containers-0.6.0.1 True
 ([])},
                -package-id deepseq-1.4.4.0{unit deepseq-1.4.4.0 True
 ([])},
                -package-id directory-1.3.3.1{unit directory-1.3.3.1 True
 ([])},
                -package-id filepath-1.4.2.1{unit filepath-1.4.2.1 True
 ([])},
                -package-id ghc-8.7{unit ghc-8.7 True ([])},
                -package-id ghc-boot-8.7{unit ghc-boot-8.7 True ([])},
                -package-id ghc-prim-0.5.3{unit ghc-prim-0.5.3 True ([])},
                -package-id ghci-8.7{unit ghci-8.7 True ([])},
                -package-id haskeline-0.7.4.3{unit haskeline-0.7.4.3 True
 ([])},
                -package-id process-1.6.3.0{unit process-1.6.3.0 True
 ([])},
                -package-id time-1.9.2{unit time-1.9.2 True ([])},
                -package-id transformers-0.5.5.0{unit transformers-0.5.5.0
 True ([])},
                -package-id unix-2.7.2.2{unit unix-2.7.2.2 True ([])},
                -package-id array-0.5.2.0{unit array-0.5.2.0 True ([])},
                -package-id base-4.12.0.0{unit base-4.12.0.0 True ([])},
                -package-id bytestring-0.10.9.0{unit bytestring-0.10.9.0
 True ([])},
                -package-id containers-0.6.0.1{unit containers-0.6.0.1 True
 ([])},
                -package-id deepseq-1.4.4.0{unit deepseq-1.4.4.0 True
 ([])},
                -package-id directory-1.3.3.1{unit directory-1.3.3.1 True
 ([])},
                -package-id filepath-1.4.2.1{unit filepath-1.4.2.1 True
 ([])},
                -package-id ghc-8.7{unit ghc-8.7 True ([])},
                -package-id ghc-boot-8.7{unit ghc-boot-8.7 True ([])},
                -package-id ghc-prim-0.5.3{unit ghc-prim-0.5.3 True ([])},
                -package-id ghci-8.7{unit ghci-8.7 True ([])},
                -package-id haskeline-0.7.4.3{unit haskeline-0.7.4.3 True
 ([])},
                -package-id process-1.6.3.0{unit process-1.6.3.0 True
 ([])},
                -package-id time-1.9.2{unit time-1.9.2 True ([])},
                -package-id transformers-0.5.5.0{unit transformers-0.5.5.0
 True ([])},
                -package-id unix-2.7.2.2{unit unix-2.7.2.2 True ([])}]
 loading package database /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/inplace/lib/package.conf.d
 wired-in package ghc-prim mapped to ghc-prim-0.5.3
 wired-in package integer-wired-in mapped to integer-gmp-1.0.2.0
 wired-in package base mapped to base-4.12.0.0
 wired-in package rts mapped to rts
 wired-in package template-haskell mapped to template-haskell-2.15.0.0
 wired-in package ghc mapped to ghc-8.7
 ("getPreloadPackagesAnd pkgids:",[])
 ("getPreloadPackagesAnd
 preload:",["haskeline-0.7.4.3","stm-2.5.0.0","ghc","terminfo-0.4.1.2","process-1.6.3.0","hpc-0.6.0.3","ghci-8.7","transformers-0.5.5.0
 ","template-haskell","pretty-1.1.3.6","ghc-heap-8.7","ghc-boot-8.7","ghc-
 boot-
 th-8.7","binary-0.8.6.0","directory-1.3.3.1","unix-2.7.2.2","time-1.9.2","filepath-1.4.2.1","containers-0.6.0.1","bytestring-0.10.9.0","deepseq-1.4.4.0","array-0.5.2.0","base
 ","integer-wired-in","ghc-prim","rts"])
 Warning: -rtsopts and -with-rtsopts have no effect with -no-hs-main.
     Call hs_init_ghc() from your main() function to set these options.
 Created temporary directory: /run/user/1000/ghc13514_0
 *** C Compiler:
 /nix/store/qanjz18apdwi0vl98sdrvyf4z4hv65df-gcc-wrapper-7.3.0/bin/cc -fno-
 stack-protector -DTABLES_NEXT_TO_CODE -c /run/user/1000/ghc13514_0/ghc_1.c
 -o /run/user/1000/ghc13514_0/ghc_2.o -no-pie -fPIC -U__PIC__ -D__PIC__
 -I/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/rts/dist/build
 -I/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/includes
 -I/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/includes/dist-
 derivedconstants/header
 ("getPreloadPackagesAnd pkgids:",[])
 ("getPreloadPackagesAnd
 preload:",["haskeline-0.7.4.3","stm-2.5.0.0","ghc","terminfo-0.4.1.2","process-1.6.3.0","hpc-0.6.0.3","ghci-8.7","transformers-0.5.5.0
 ","template-haskell","pretty-1.1.3.6","ghc-heap-8.7","ghc-boot-8.7","ghc-
 boot-
 th-8.7","binary-0.8.6.0","directory-1.3.3.1","unix-2.7.2.2","time-1.9.2","filepath-1.4.2.1","containers-0.6.0.1","bytestring-0.10.9.0","deepseq-1.4.4.0","array-0.5.2.0","base
 ","integer-wired-in","ghc-prim","rts"])
 @@@ Stripping prefix for "Cffi" to "ffi" for package "rts"
 ("collectLinkOpts",(["-lHShaskeline-0.7.4.3-ghc8.7.20181205","-lHSstm-2.5.0.0-ghc8.7.20181205","-lHSghc-8.7-ghc8.7.20181205","-lHSterminfo-0.4.1.2-ghc8.7.20181205","-lHSprocess-1.6.3.0-ghc8.7.20181205","-lHShpc-0.6.0.3-ghc8.7.20181205","-lHSghci-8.7-ghc8.7.20181205","-lHStransformers-0.5.5.0-ghc8.7.20181205
 ","-lHStemplate-
 haskell-2.15.0.0-ghc8.7.20181205","-lHSpretty-1.1.3.6-ghc8.7.20181205
 ","-lHSghc-heap-8.7-ghc8.7.20181205","-lHSghc-boot-8.7-ghc8.7.20181205
 ","-lHSghc-boot-
 th-8.7-ghc8.7.20181205","-lHSbinary-0.8.6.0-ghc8.7.20181205","-lHSdirectory-1.3.3.1-ghc8.7.20181205","-lHSunix-2.7.2.2-ghc8.7.20181205","-lHStime-1.9.2-ghc8.7.20181205","-lHSfilepath-1.4.2.1-ghc8.7.20181205","-lHScontainers-0.6.0.1-ghc8.7.20181205","-lHSbytestring-0.10.9.0-ghc8.7.20181205","-lHSdeepseq-1.4.4.0-ghc8.7.20181205","-lHSarray-0.5.2.0-ghc8.7.20181205","-lHSbase-4.12.0.0-ghc8.7.20181205
 ","-lHSinteger-gmp-1.0.2.0-ghc8.7.20181205","-lHSghc-
 prim-0.5.3-ghc8.7.20181205","-lHSrts_thr-
 ghc8.7.20181205","-lffi"],["-ltinfo","-lrt","-lutil","-ldl","-lgmp","-lm","-lrt","-ldl","-lnuma"],["-Wl,-u,base_GHCziTopHandler_runIO_closure","-Wl,-u,base_GHCziTopHandler_runNonIO_closure","-Wl,-u,ghczmprim_GHCziTuple_Z0T_closure","-Wl,-u,ghczmprim_GHCziTypes_True_closure","-Wl,-u,ghczmprim_GHCziTypes_False_closure","-Wl,-u,base_GHCziPack_unpackCString_closure","-Wl,-u,base_GHCziWeak_runFinalizzerBatch_closure","-Wl,-u,base_GHCziIOziException_stackOverflow_closure","-Wl,-u,base_GHCziIOziException_heapOverflow_closure","-Wl,-u,base_GHCziIOziException_allocationLimitExceeded_closure","-Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnMVar_closure","-Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnSTM_closure","-Wl,-u,base_GHCziIOziException_cannotCompactFunction_closure","-Wl,-u,base_GHCziIOziException_cannotCompactPinned_closure","-Wl,-u,base_GHCziIOziException_cannotCompactMutable_closure","-Wl,-u,base_ControlziExceptionziBase_absentSumFieldError_closure","-Wl,-u,base_Controlz
 iExceptionziBase_nonTermination_closure","-Wl,-u,base_ControlziExceptionziBase_nestedAtomically_closure","-Wl,-u,base_GHCziEventziThread_blockedOnBadFD_closure","-Wl,-u,base_GHCziConcziSync_runSparks_closure","-Wl,-u,base_GHCziConcziIO_ensureIOManagerIsRunning_closure","-Wl,-u,base_GHCziConcziIO_ioManagerCapabilitiesChanged_closure","-Wl,-u,base_GHCziConcziSignal_runHandlersPtr_closure","-Wl,-u,base_GHCziTopHandler_flushStdHandles_closure","-Wl,-u,base_GHCziTopHandler_runMainIO_closure","-Wl,-u,ghczmprim_GHCziTypes_Czh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Izh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Fzh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Dzh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Wzh_con_info","-Wl,-u,base_GHCziPtr_Ptr_con_info","-Wl,-u,base_GHCziPtr_FunPtr_con_info","-Wl,-u,base_GHCziInt_I8zh_con_info","-Wl,-u,base_GHCziInt_I16zh_con_info","-Wl,-u,base_GHCziInt_I32zh_con_info","-Wl,-u,base_GHCziInt_I64zh_con_info","-Wl,-u,base_GHCziWord_W8zh_con_info","-Wl,-u,base_GHCziWord_W16
 zh_con_info","-Wl,-u,base_GHCziWord_W32zh_con_info","-Wl,-u,base_GHCziWord_W64zh_con_info","-Wl,-u,base_GHCziStable_StablePtr_con_info","-Wl,-u,hs_atomic_add8","-Wl,-u,hs_atomic_add16","-Wl,-u,hs_atomic_add32","-Wl,-u,hs_atomic_add64","-Wl,-u,hs_atomic_sub8","-Wl,-u,hs_atomic_sub16","-Wl,-u,hs_atomic_sub32","-Wl,-u,hs_atomic_sub64","-Wl,-u,hs_atomic_and8","-Wl,-u,hs_atomic_and16","-Wl,-u,hs_atomic_and32","-Wl,-u,hs_atomic_and64","-Wl,-u,hs_atomic_nand8","-Wl,-u,hs_atomic_nand16","-Wl,-u,hs_atomic_nand32","-Wl,-u,hs_atomic_nand64","-Wl,-u,hs_atomic_or8","-Wl,-u,hs_atomic_or16","-Wl,-u,hs_atomic_or32","-Wl,-u,hs_atomic_or64","-Wl,-u,hs_atomic_xor8","-Wl,-u,hs_atomic_xor16","-Wl,-u,hs_atomic_xor32","-Wl,-u,hs_atomic_xor64","-Wl,-u,hs_cmpxchg8","-Wl,-u,hs_cmpxchg16","-Wl,-u,hs_cmpxchg32","-Wl,-u,hs_cmpxchg64","-Wl,-u,hs_atomicread8","-Wl,-u,hs_atomicread16","-Wl,-u,hs_atomicread32","-Wl,-u,hs_atomicread64","-Wl,-u,hs_atomicwrite8","-Wl,-u,hs_atomicwrite16","-Wl,-u,hs_atomicwrite32","-Wl
 ,-u,hs_atomicwrite64"]))
 *** C Compiler:
 /nix/store/qanjz18apdwi0vl98sdrvyf4z4hv65df-gcc-wrapper-7.3.0/bin/cc -fno-
 stack-protector -DTABLES_NEXT_TO_CODE -c /run/user/1000/ghc13514_0/ghc_4.s
 -o /run/user/1000/ghc13514_0/ghc_5.o
 ("getPreloadPackagesAnd pkgids:",[])
 ("getPreloadPackagesAnd
 preload:",["haskeline-0.7.4.3","stm-2.5.0.0","ghc","terminfo-0.4.1.2","process-1.6.3.0","hpc-0.6.0.3","ghci-8.7","transformers-0.5.5.0
 ","template-haskell","pretty-1.1.3.6","ghc-heap-8.7","ghc-boot-8.7","ghc-
 boot-
 th-8.7","binary-0.8.6.0","directory-1.3.3.1","unix-2.7.2.2","time-1.9.2","filepath-1.4.2.1","containers-0.6.0.1","bytestring-0.10.9.0","deepseq-1.4.4.0","array-0.5.2.0","base
 ","integer-wired-in","ghc-prim","rts"])
 @@@ Stripping prefix for "Cffi" to "ffi" for package "rts"
 ("collectLinkOpts",(["-lHShaskeline-0.7.4.3-ghc8.7.20181205","-lHSstm-2.5.0.0-ghc8.7.20181205","-lHSghc-8.7-ghc8.7.20181205","-lHSterminfo-0.4.1.2-ghc8.7.20181205","-lHSprocess-1.6.3.0-ghc8.7.20181205","-lHShpc-0.6.0.3-ghc8.7.20181205","-lHSghci-8.7-ghc8.7.20181205","-lHStransformers-0.5.5.0-ghc8.7.20181205
 ","-lHStemplate-
 haskell-2.15.0.0-ghc8.7.20181205","-lHSpretty-1.1.3.6-ghc8.7.20181205
 ","-lHSghc-heap-8.7-ghc8.7.20181205","-lHSghc-boot-8.7-ghc8.7.20181205
 ","-lHSghc-boot-
 th-8.7-ghc8.7.20181205","-lHSbinary-0.8.6.0-ghc8.7.20181205","-lHSdirectory-1.3.3.1-ghc8.7.20181205","-lHSunix-2.7.2.2-ghc8.7.20181205","-lHStime-1.9.2-ghc8.7.20181205","-lHSfilepath-1.4.2.1-ghc8.7.20181205","-lHScontainers-0.6.0.1-ghc8.7.20181205","-lHSbytestring-0.10.9.0-ghc8.7.20181205","-lHSdeepseq-1.4.4.0-ghc8.7.20181205","-lHSarray-0.5.2.0-ghc8.7.20181205","-lHSbase-4.12.0.0-ghc8.7.20181205
 ","-lHSinteger-gmp-1.0.2.0-ghc8.7.20181205","-lHSghc-
 prim-0.5.3-ghc8.7.20181205","-lHSrts_thr-
 ghc8.7.20181205","-lffi"],["-ltinfo","-lrt","-lutil","-ldl","-lgmp","-lm","-lrt","-ldl","-lnuma"],["-Wl,-u,base_GHCziTopHandler_runIO_closure","-Wl,-u,base_GHCziTopHandler_runNonIO_closure","-Wl,-u,ghczmprim_GHCziTuple_Z0T_closure","-Wl,-u,ghczmprim_GHCziTypes_True_closure","-Wl,-u,ghczmprim_GHCziTypes_False_closure","-Wl,-u,base_GHCziPack_unpackCString_closure","-Wl,-u,base_GHCziWeak_runFinalizzerBatch_closure","-Wl,-u,base_GHCziIOziException_stackOverflow_closure","-Wl,-u,base_GHCziIOziException_heapOverflow_closure","-Wl,-u,base_GHCziIOziException_allocationLimitExceeded_closure","-Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnMVar_closure","-Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnSTM_closure","-Wl,-u,base_GHCziIOziException_cannotCompactFunction_closure","-Wl,-u,base_GHCziIOziException_cannotCompactPinned_closure","-Wl,-u,base_GHCziIOziException_cannotCompactMutable_closure","-Wl,-u,base_ControlziExceptionziBase_absentSumFieldError_closure","-Wl,-u,base_Controlz
 iExceptionziBase_nonTermination_closure","-Wl,-u,base_ControlziExceptionziBase_nestedAtomically_closure","-Wl,-u,base_GHCziEventziThread_blockedOnBadFD_closure","-Wl,-u,base_GHCziConcziSync_runSparks_closure","-Wl,-u,base_GHCziConcziIO_ensureIOManagerIsRunning_closure","-Wl,-u,base_GHCziConcziIO_ioManagerCapabilitiesChanged_closure","-Wl,-u,base_GHCziConcziSignal_runHandlersPtr_closure","-Wl,-u,base_GHCziTopHandler_flushStdHandles_closure","-Wl,-u,base_GHCziTopHandler_runMainIO_closure","-Wl,-u,ghczmprim_GHCziTypes_Czh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Izh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Fzh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Dzh_con_info","-Wl,-u,ghczmprim_GHCziTypes_Wzh_con_info","-Wl,-u,base_GHCziPtr_Ptr_con_info","-Wl,-u,base_GHCziPtr_FunPtr_con_info","-Wl,-u,base_GHCziInt_I8zh_con_info","-Wl,-u,base_GHCziInt_I16zh_con_info","-Wl,-u,base_GHCziInt_I32zh_con_info","-Wl,-u,base_GHCziInt_I64zh_con_info","-Wl,-u,base_GHCziWord_W8zh_con_info","-Wl,-u,base_GHCziWord_W16
 zh_con_info","-Wl,-u,base_GHCziWord_W32zh_con_info","-Wl,-u,base_GHCziWord_W64zh_con_info","-Wl,-u,base_GHCziStable_StablePtr_con_info","-Wl,-u,hs_atomic_add8","-Wl,-u,hs_atomic_add16","-Wl,-u,hs_atomic_add32","-Wl,-u,hs_atomic_add64","-Wl,-u,hs_atomic_sub8","-Wl,-u,hs_atomic_sub16","-Wl,-u,hs_atomic_sub32","-Wl,-u,hs_atomic_sub64","-Wl,-u,hs_atomic_and8","-Wl,-u,hs_atomic_and16","-Wl,-u,hs_atomic_and32","-Wl,-u,hs_atomic_and64","-Wl,-u,hs_atomic_nand8","-Wl,-u,hs_atomic_nand16","-Wl,-u,hs_atomic_nand32","-Wl,-u,hs_atomic_nand64","-Wl,-u,hs_atomic_or8","-Wl,-u,hs_atomic_or16","-Wl,-u,hs_atomic_or32","-Wl,-u,hs_atomic_or64","-Wl,-u,hs_atomic_xor8","-Wl,-u,hs_atomic_xor16","-Wl,-u,hs_atomic_xor32","-Wl,-u,hs_atomic_xor64","-Wl,-u,hs_cmpxchg8","-Wl,-u,hs_cmpxchg16","-Wl,-u,hs_cmpxchg32","-Wl,-u,hs_cmpxchg64","-Wl,-u,hs_atomicread8","-Wl,-u,hs_atomicread16","-Wl,-u,hs_atomicread32","-Wl,-u,hs_atomicread64","-Wl,-u,hs_atomicwrite8","-Wl,-u,hs_atomicwrite16","-Wl,-u,hs_atomicwrite32","-Wl
 ,-u,hs_atomicwrite64"]))
 *** Linker:
 /nix/store/qanjz18apdwi0vl98sdrvyf4z4hv65df-gcc-wrapper-7.3.0/bin/cc -fno-
 stack-protector -DTABLES_NEXT_TO_CODE '-Wl,--hash-size=31' -Wl,--reduce-
 memory-overheads -Wl,--no-as-needed -Wl,-rpath
 '-Wl,$ORIGIN/../haskeline-0.7.4.3' -Wl,-rpath '-Wl,$ORIGIN/../stm-2.5.0.0'
 -Wl,-rpath '-Wl,$ORIGIN/../ghc-8.7' -Wl,-rpath
 '-Wl,$ORIGIN/../terminfo-0.4.1.2' -Wl,-rpath
 '-Wl,$ORIGIN/../process-1.6.3.0' -Wl,-rpath '-Wl,$ORIGIN/../hpc-0.6.0.3'
 -Wl,-rpath '-Wl,$ORIGIN/../ghci-8.7' -Wl,-rpath
 '-Wl,$ORIGIN/../transformers-0.5.5.0' -Wl,-rpath '-Wl,$ORIGIN/../template-
 haskell-2.15.0.0' -Wl,-rpath '-Wl,$ORIGIN/../pretty-1.1.3.6' -Wl,-rpath
 '-Wl,$ORIGIN/../ghc-heap-8.7' -Wl,-rpath '-Wl,$ORIGIN/../ghc-boot-8.7'
 -Wl,-rpath '-Wl,$ORIGIN/../ghc-boot-th-8.7' -Wl,-rpath
 '-Wl,$ORIGIN/../directory-1.3.3.1' -Wl,-rpath
 '-Wl,$ORIGIN/../unix-2.7.2.2' -Wl,-rpath '-Wl,$ORIGIN/../time-1.9.2'
 -Wl,-rpath '-Wl,$ORIGIN/../filepath-1.4.2.1' -Wl,-rpath
 '-Wl,$ORIGIN/../binary-0.8.6.0' -Wl,-rpath
 '-Wl,$ORIGIN/../containers-0.6.0.1' -Wl,-rpath
 '-Wl,$ORIGIN/../bytestring-0.10.9.0' -Wl,-rpath
 '-Wl,$ORIGIN/../deepseq-1.4.4.0' -Wl,-rpath '-Wl,$ORIGIN/../array-0.5.2.0'
 -Wl,-rpath '-Wl,$ORIGIN/../base-4.12.0.0' -Wl,-rpath '-Wl,$ORIGIN
 /../integer-gmp-1.0.2.0' -Wl,-rpath '-Wl,$ORIGIN/../ghc-prim-0.5.3'
 -Wl,-rpath '-Wl,$ORIGIN/../rts' -Wl,-zorigin -o ghc/stage2/build/tmp/ghc-
 stage2 -lm -no-pie -fPIC -U__PIC__ -D__PIC__ -Wl,--gc-sections
 ghc/stage2/build/Main.dyn_o ghc/stage2/build/GHCi/Leak.dyn_o
 ghc/stage2/build/GHCi/UI.dyn_o ghc/stage2/build/GHCi/UI/Info.dyn_o
 ghc/stage2/build/GHCi/UI/Monad.dyn_o ghc/stage2/build/GHCi/UI/Tags.dyn_o
 ghc/stage2/build/hschooks.dyn_o -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/haskeline/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/haskeline/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/stm
 /dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/stm
 /dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/compiler/stage2/build -Xlinker -rpath-link
 -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/compiler/stage2/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/terminfo/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/terminfo/dist-install/build
 -L/nix/store/x5ms5m9ga6v7vy3akc58yx279ggfnbnl-ghc-build-environment/lib
 -Xlinker -rpath-link -Xlinker /nix/store/x5ms5m9ga6v7vy3akc58yx279ggfnbnl-
 ghc-build-environment/lib -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/process/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/process/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/hpc
 /dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/hpc
 /dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/ghci/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/ghci/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/transformers/dist-install/build
 -Xlinker -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/transformers/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries
 /template-haskell/dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries
 /template-haskell/dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/pretty/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/pretty/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 heap/dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 heap/dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/ghc-boot/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/ghc-boot/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 boot-th/dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 boot-th/dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/binary/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/binary/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/directory/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/directory/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/unix
 /dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/unix
 /dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/time/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/time/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/filepath/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/filepath/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/containers/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/containers/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/bytestring/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/bytestring/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/deepseq/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/deepseq/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/array/dist-install/build -Xlinker
 -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/array/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/base
 /dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/base
 /dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/integer-gmp/dist-install/build
 -Xlinker -rpath-link -Xlinker /home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/libraries/integer-gmp/dist-install/build
 -L/home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 prim/dist-install/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/libraries/ghc-
 prim/dist-install/build -L/home/david/MEGA/File_Dump/Well-
 Typed/GHC/_nosync_git/ghc/rts/dist/build -Xlinker -rpath-link -Xlinker
 /home/david/MEGA/File_Dump/Well-Typed/GHC/_nosync_git/ghc/rts/dist/build
 /run/user/1000/ghc13514_0/ghc_2.o /run/user/1000/ghc13514_0/ghc_5.o
 -Wl,-u,base_GHCziTopHandler_runIO_closure
 -Wl,-u,base_GHCziTopHandler_runNonIO_closure
 -Wl,-u,ghczmprim_GHCziTuple_Z0T_closure
 -Wl,-u,ghczmprim_GHCziTypes_True_closure
 -Wl,-u,ghczmprim_GHCziTypes_False_closure
 -Wl,-u,base_GHCziPack_unpackCString_closure
 -Wl,-u,base_GHCziWeak_runFinalizzerBatch_closure
 -Wl,-u,base_GHCziIOziException_stackOverflow_closure
 -Wl,-u,base_GHCziIOziException_heapOverflow_closure
 -Wl,-u,base_GHCziIOziException_allocationLimitExceeded_closure
 -Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnMVar_closure
 -Wl,-u,base_GHCziIOziException_blockedIndefinitelyOnSTM_closure
 -Wl,-u,base_GHCziIOziException_cannotCompactFunction_closure
 -Wl,-u,base_GHCziIOziException_cannotCompactPinned_closure
 -Wl,-u,base_GHCziIOziException_cannotCompactMutable_closure
 -Wl,-u,base_ControlziExceptionziBase_absentSumFieldError_closure
 -Wl,-u,base_ControlziExceptionziBase_nonTermination_closure
 -Wl,-u,base_ControlziExceptionziBase_nestedAtomically_closure
 -Wl,-u,base_GHCziEventziThread_blockedOnBadFD_closure
 -Wl,-u,base_GHCziConcziSync_runSparks_closure
 -Wl,-u,base_GHCziConcziIO_ensureIOManagerIsRunning_closure
 -Wl,-u,base_GHCziConcziIO_ioManagerCapabilitiesChanged_closure
 -Wl,-u,base_GHCziConcziSignal_runHandlersPtr_closure
 -Wl,-u,base_GHCziTopHandler_flushStdHandles_closure
 -Wl,-u,base_GHCziTopHandler_runMainIO_closure
 -Wl,-u,ghczmprim_GHCziTypes_Czh_con_info
 -Wl,-u,ghczmprim_GHCziTypes_Izh_con_info
 -Wl,-u,ghczmprim_GHCziTypes_Fzh_con_info
 -Wl,-u,ghczmprim_GHCziTypes_Dzh_con_info
 -Wl,-u,ghczmprim_GHCziTypes_Wzh_con_info -Wl,-u,base_GHCziPtr_Ptr_con_info
 -Wl,-u,base_GHCziPtr_FunPtr_con_info -Wl,-u,base_GHCziInt_I8zh_con_info
 -Wl,-u,base_GHCziInt_I16zh_con_info -Wl,-u,base_GHCziInt_I32zh_con_info
 -Wl,-u,base_GHCziInt_I64zh_con_info -Wl,-u,base_GHCziWord_W8zh_con_info
 -Wl,-u,base_GHCziWord_W16zh_con_info -Wl,-u,base_GHCziWord_W32zh_con_info
 -Wl,-u,base_GHCziWord_W64zh_con_info
 -Wl,-u,base_GHCziStable_StablePtr_con_info -Wl,-u,hs_atomic_add8
 -Wl,-u,hs_atomic_add16 -Wl,-u,hs_atomic_add32 -Wl,-u,hs_atomic_add64
 -Wl,-u,hs_atomic_sub8 -Wl,-u,hs_atomic_sub16 -Wl,-u,hs_atomic_sub32
 -Wl,-u,hs_atomic_sub64 -Wl,-u,hs_atomic_and8 -Wl,-u,hs_atomic_and16
 -Wl,-u,hs_atomic_and32 -Wl,-u,hs_atomic_and64 -Wl,-u,hs_atomic_nand8
 -Wl,-u,hs_atomic_nand16 -Wl,-u,hs_atomic_nand32 -Wl,-u,hs_atomic_nand64
 -Wl,-u,hs_atomic_or8 -Wl,-u,hs_atomic_or16 -Wl,-u,hs_atomic_or32
 -Wl,-u,hs_atomic_or64 -Wl,-u,hs_atomic_xor8 -Wl,-u,hs_atomic_xor16
 -Wl,-u,hs_atomic_xor32 -Wl,-u,hs_atomic_xor64 -Wl,-u,hs_cmpxchg8
 -Wl,-u,hs_cmpxchg16 -Wl,-u,hs_cmpxchg32 -Wl,-u,hs_cmpxchg64
 -Wl,-u,hs_atomicread8 -Wl,-u,hs_atomicread16 -Wl,-u,hs_atomicread32
 -Wl,-u,hs_atomicread64 -Wl,-u,hs_atomicwrite8 -Wl,-u,hs_atomicwrite16
 -Wl,-u,hs_atomicwrite32 -Wl,-u,hs_atomicwrite64
 -lHShaskeline-0.7.4.3-ghc8.7.20181205 -lHSstm-2.5.0.0-ghc8.7.20181205
 -lHSghc-8.7-ghc8.7.20181205 -lHSterminfo-0.4.1.2-ghc8.7.20181205
 -lHSprocess-1.6.3.0-ghc8.7.20181205 -lHShpc-0.6.0.3-ghc8.7.20181205
 -lHSghci-8.7-ghc8.7.20181205 -lHStransformers-0.5.5.0-ghc8.7.20181205
 -lHStemplate-haskell-2.15.0.0-ghc8.7.20181205
 -lHSpretty-1.1.3.6-ghc8.7.20181205 -lHSghc-heap-8.7-ghc8.7.20181205
 -lHSghc-boot-8.7-ghc8.7.20181205 -lHSghc-boot-th-8.7-ghc8.7.20181205
 -lHSbinary-0.8.6.0-ghc8.7.20181205 -lHSdirectory-1.3.3.1-ghc8.7.20181205
 -lHSunix-2.7.2.2-ghc8.7.20181205 -lHStime-1.9.2-ghc8.7.20181205
 -lHSfilepath-1.4.2.1-ghc8.7.20181205
 -lHScontainers-0.6.0.1-ghc8.7.20181205
 -lHSbytestring-0.10.9.0-ghc8.7.20181205
 -lHSdeepseq-1.4.4.0-ghc8.7.20181205 -lHSarray-0.5.2.0-ghc8.7.20181205
 -lHSbase-4.12.0.0-ghc8.7.20181205 -lHSinteger-gmp-1.0.2.0-ghc8.7.20181205
 -lHSghc-prim-0.5.3-ghc8.7.20181205 -lHSrts_thr-ghc8.7.20181205 -lffi
 -ltinfo -lrt -lutil -ldl -lgmp -lm -lrt -ldl -lnuma
 *** Deleting temp files:
 Deleting: /run/user/1000/ghc13514_0/ghc_1.c
 /run/user/1000/ghc13514_0/ghc_3.rsp /run/user/1000/ghc13514_0/ghc_4.s
 /run/user/1000/ghc13514_0/ghc_6.rsp /run/user/1000/ghc13514_0/ghc_7.rsp
 /run/user/1000/ghc13514_0/ghc_2.o /run/user/1000/ghc13514_0/ghc_5.o
 *** Deleting temp dirs:
 Deleting: /run/user/1000/ghc13514_0
 }}}

 Note that **make also uses `-lffi`**. Hence I will proceed under the
 assumption that `-lffi` is correct, and the problem that needs to be
 solved in getting the linker to correctly find the locally built libffi
 .so file.

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


More information about the ghc-tickets mailing list