[warning: long and broad build output logs -- better use a large
window for reading this mail]
Hi,
When trying to build ghc-6.11 using a previously built ghc-6.11 for
bootstrapping, linking ghc-stage1 fails with the following error:
"/home/kili/src/ghc/2/bin/ghc" -o ghc/stage1/build/tmp/ghc-stage1 -H32m -O
-package-conf libraries/bootstrapping.conf -i -ighc/. -ighc/stage1/build
-ighc/stage1/build/autogen -Ighc/stage1/build -Ighc/stage1/build/autogen
-O -fasm -package ghc-6.11 -XCPP -XPatternGuards -XForeignFunctionInterface
-XUnboxedTuples -XFlexibleInstances -XMagicHash -fforce-recomp -odir
ghc/stage1/build -hidir ghc/stage1/build -stubdir ghc/stage1/build -hisuf hi
-osuf o -hcsuf hc ghc/stage1/build/Main.o
/usr/bin/ld: cannot find -lHSghc-6.11.20090908
collect2: ld returned 1 exit status
Note for the following blurb: I've ghc-6.10 installed in ~src/ghc/1
and the ghc-6.11 bootstrapped from ghc-6.10 installed in ~src/ghc/2,
the build dirs are ~src/ghc/ghc-head-6.10 and ~src/ghc/ghc-head-6.11.
I ran the above command with -v for both ghc-6.11 bootstrapping
from ghc-6.10 and ghc-11 bootstrapping from ghc-6.11. Here's a diff
of the output (with linebreaks added to get a readable diff, and
actually stripping the output of gcc):
--- foo-6.10.out Wed Sep 9 12:52:01 2009
+++ foo-6.11.out Wed Sep 9 12:54:30 2009
@@ -1,69 +1,74 @@
-Glasgow Haskell Compiler, Version 6.10.4.20090719, for Haskell 98, stage 2
booted by GHC version 6.6.1
-Using package config file:
/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/./package.conf
+Glasgow Haskell Compiler, Version 6.11.20090908, for Haskell 98, stage 2
booted by GHC version 6.10.4.20090719
+Using package config file:
/home/kili/src/ghc/2/lib/ghc-6.11.20090908/package.conf
Using package config file: libraries/bootstrapping.conf
-hiding package base-3.0.3.1 to avoid conflict with later version base-4.1.0.0
-hiding package Cabal-1.6.0.3 to avoid conflict with later version Cabal-1.7.4
-hiding package hpc-0.5.0.2 to avoid conflict with later version hpc-0.5.0.3
-wired-in package ghc-prim mapped to ghc-prim-0.1.0.0
-wired-in package integer mapped to integer-0.1.0.1
-wired-in package base mapped to base-4.1.0.0
-wired-in package rts mapped to rts-1.0
-wired-in package haskell98 mapped to haskell98-1.0.1.0
-wired-in package syb mapped to syb-0.1.0.1
-wired-in package template-haskell mapped to template-haskell-2.3.0.1
-wired-in package dph-seq[""] not found.
-wired-in package dph-par[""] not found.
+package Cabal-1.7.4-a6bf1b9b26bd3f7122e6597854c353c3 is shadowed by package
Cabal-1.7.4-inplace
+package extensible-exceptions-0.1.1.0-95db30aec4429ef77db437055a224b2f is
shadowed by package extensible-exceptions-0.1.1.0-inplace
+package ghc-6.11.20090908-df2cf8e76401bbcba79d488aa8e9aac0 is shadowed by
package ghc-6.11.20090908-inplace
+package haskeline-0.6.2-07fd31854066ef833ccd4652a3574fe1 is unusable due to
missing or recursive dependencies:
+ extensible-exceptions-0.1.1.0-95db30aec4429ef77db437055a224b2f
terminfo-0.3.1-aab2f4dcbb9412ab4762b4dc65ba7888
+package hpc-0.5.0.2-ca2fcca0bd408d5f943e5cb386eb0967 is shadowed by package
hpc-0.5.0.2-inplace
+package terminfo-0.3.1-aab2f4dcbb9412ab4762b4dc65ba7888 is unusable due to
missing or recursive dependencies:
+ extensible-exceptions-0.1.1.0-95db30aec4429ef77db437055a224b2f
+hiding package base-3.0.3.0 to avoid conflict with later version base-4.1.0.0
+wired-in package ghc-prim mapped to
ghc-prim-0.1.0.0-23e37df87218eb9ab94973e9b064f6c1
+wired-in package integer-gmp mapped to
integer-gmp-0.1.0.0-515b9ecf844f01835d09f3b53bf4aa30
+wired-in package base mapped to base-4.1.0.0-b34dfe8ac6a43f644c3ca46a645a9fbc
+wired-in package rts mapped to builtin:rts
+wired-in package haskell98 mapped to
haskell98-1.0.1.0-9e1bbdf3c9f1e95d4abd5497c0cfffcc
+wired-in package template-haskell mapped to
template-haskell-2.4.0.0-6d200f036b83c0aab5cd9a7fc86a2a3b
+wired-in package dph-seq mapped to
dph-seq-0.4.0-f05786f09f5e1e219eb958c93ce48682
+wired-in package dph-par mapped to
dph-par-0.4.0-0389bfc19cf8ab727f70fb3334800928
Hsc static flags: -static
*** Linker:
gcc -v \
-o ghc/stage1/build/tmp/ghc-stage1 \
ghc/stage1/build/Main.o \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/haskell98-1.0.1.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/random-1.0.0.1 \
- -L/home/kili/src/ghc/ghc-head-6.10/compiler/stage1/build \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/hpc-0.5.0.3 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/bytestring-0.9.1.4 \
- -L/home/kili/src/ghc/ghc-head-6.10/libraries/Cabal/dist-boot/build \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/process-1.0.1.1 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/pretty-1.0.1.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/directory-1.0.0.3 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/unix-2.3.2.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/old-time-1.0.0.2 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/old-locale-1.0.0.1 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/filepath-1.1.0.2 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/containers-0.2.0.1 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/array-0.2.0.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/syb-0.1.0.1 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/base-4.1.0.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/integer-0.1.0.1 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719/ghc-prim-0.1.0.0 \
- -L/home/kili/src/ghc/1/lib/ghc-6.10.4.20090719 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/haskell98-1.0.1.0 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/random-1.0.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/time-1.1.4 \
+ -L/home/kili/src/ghc/ghc-head-6.11/compiler/stage1/build \
+ -L/home/kili/src/ghc/ghc-head-6.11/libraries/hpc/dist-boot/build \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/bytestring-0.9.1.4 \
+ -L/home/kili/src/ghc/ghc-head-6.11/libraries/Cabal/dist-boot/build \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/process-1.0.1.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/pretty-1.0.1.0 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/directory-1.0.0.2 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/unix-2.3.1.0 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/old-time-1.0.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/old-locale-1.0.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/filepath-1.1.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/containers-0.2.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/array-0.2.0.1 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/base-4.1.0.0 \
-L/usr/local/lib \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/integer-gmp-0.1.0.0 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908/ghc-prim-0.1.0.0 \
+ -L/home/kili/src/ghc/2/lib/ghc-6.11.20090908 \
+ -lHSrtsmain \
-lHShaskell98-1.0.1.0 \
-lHSrandom-1.0.0.1 \
- -lHSghc-6.11 \
- -lHShpc-0.5.0.3 \
+ -lHStime-1.1.4 \
+ -lHSghc-6.11.20090908 \
+ -lHShpc-0.5.0.2 \
-lHSbytestring-0.9.1.4 \
-lHSCabal-1.7.4 \
-lHSprocess-1.0.1.1 \
-lHSpretty-1.0.1.0 \
- -lHSdirectory-1.0.0.3 \
- -lHSunix-2.3.2.0 \
+ -lHSdirectory-1.0.0.2 \
+ -lHSunix-2.3.1.0 \
-lutil \
-pthread \
- -lHSold-time-1.0.0.2 \
+ -lHSold-time-1.0.0.1 \
-lHSold-locale-1.0.0.1 \
- -lHSfilepath-1.1.0.2 \
+ -lHSfilepath-1.1.0.1 \
-lHScontainers-0.2.0.1 \
- -lHSarray-0.2.0.0 \
- -lHSsyb-0.1.0.1 \
+ -lHSarray-0.2.0.1 \
-lHSbase-4.1.0.0 \
- -lHSinteger-0.1.0.1 \
+ -liconv \
+ -lHSinteger-gmp-0.1.0.0 \
-lHSghc-prim-0.1.0.0 \
-lHSrts \
-lm \
- -lffi \
- -lgmp \
-u ghczmprim_GHCziTypes_Izh_static_info \
-u ghczmprim_GHCziTypes_Czh_static_info \
-u ghczmprim_GHCziTypes_Fzh_static_info \
@@ -89,27 +94,26 @@
-u ghczmprim_GHCziBool_False_closure \
-u ghczmprim_GHCziBool_True_closure \
-u base_GHCziPack_unpackCString_closure \
- -u base_GHCziIOBase_stackOverflow_closure \
- -u base_GHCziIOBase_heapOverflow_closure \
+ -u base_GHCziIOziException_stackOverflow_closure \
+ -u base_GHCziIOziException_heapOverflow_closure \
-u base_ControlziExceptionziBase_nonTermination_closure \
- -u base_GHCziIOBase_blockedOnDeadMVar_closure \
- -u base_GHCziIOBase_blockedIndefinitely_closure \
+ -u base_GHCziIOziException_blockedIndefinitelyOnMVar_closure \
+ -u base_GHCziIOziException_blockedIndefinitelyOnSTM_closure \
-u base_ControlziExceptionziBase_nestedAtomically_closure \
-u base_GHCziWeak_runFinalizzerBatch_closure \
-u base_GHCziTopHandler_runIO_closure \
-u base_GHCziTopHandler_runNonIO_closure \
+ -u base_GHCziConc_ensureIOManagerIsRunning_closure \
+ -u base_GHCziConc_runSparks_closure \
-u base_GHCziConc_runHandlers_closure \
- -u base_GHCziConc_ensureIOManagerIsRunning_closure
+ -lHSffi
So the problem is that the ghc-6.11 bootstrapped from ghc-6.11 tries
to link libHSghc-6.11.20090908 instead of libHSghc-6.11 (which is
located in compiler/stage1/build).
Using the appropriate ghc-pkg (~/src/ghc/1/bin/ghc-pkg resp.
~src/ghc/2/bin/ghc-pkg) reveals the following information about the
ghc package(s) registered in libraries/bootstrapping.conf:
- Bootstrapped from ghc-6.10:
name: ghc
version: 6.11.20090908
license: BSD3
copyright:
maintainer: [email protected]
stability:
homepage: http://www.haskell.org/ghc/
package-url:
description: GHC's functionality can be useful for more things than just
[...]
category: Development
author: The GHC Team
exposed: False
exposed-modules: AsmCodeGen TargetReg NCGMonad Instruction Size Reg
[...]
hidden-modules:
import-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1/build
library-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1/build
hs-libraries: HSghc-6.11.20090908
extra-libraries:
extra-ghci-libraries:
include-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1
/home/kili/src/ghc/ghc-head-6.10/compiler/../libraries/base/cbits
/home/kili/src/ghc/ghc-head-6.10/compiler/../libraries/base/include
/home/kili/src/ghc/ghc-head-6.10/compiler/.
/home/kili/src/ghc/ghc-head-6.10/compiler/parser
/home/kili/src/ghc/ghc-head-6.10/compiler/utils
includes:
depends: Cabal-1.7.4 array-0.2.0.0 base-4.1.0.0 bytestring-0.9.1.4
containers-0.2.0.1 directory-1.0.0.3 filepath-1.1.0.2
hpc-0.5.0.3
old-time-1.0.0.2 process-1.0.1.1 unix-2.3.2.0
hugs-options:
cc-options:
ld-options:
framework-dirs:
frameworks:
haddock-interfaces:
/home/kili/src/ghc/ghc-head-6.10/compiler/stage1/doc/html/ghc/ghc.haddock
haddock-html:
/home/kili/src/ghc/ghc-head-6.10/compiler/stage1/doc/html/ghc
---
name: ghc
version: 6.11
license: BSD3
copyright:
maintainer: [email protected]
stability:
homepage: http://www.haskell.org/ghc/
package-url:
description: GHC's functionality can be useful for more things than just
[...]
category: Development
author: The GHC Team
exposed: False
exposed-modules: AsmCodeGen TargetReg NCGMonad Instruction Size Reg
[...]
hidden-modules:
import-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1/build
library-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1/build
hs-libraries: HSghc-6.11
extra-libraries:
extra-ghci-libraries:
include-dirs: /home/kili/src/ghc/ghc-head-6.10/compiler/stage1
/home/kili/src/ghc/ghc-head-6.10/compiler/../libraries/base/cbits
/home/kili/src/ghc/ghc-head-6.10/compiler/../libraries/base/include
/home/kili/src/ghc/ghc-head-6.10/compiler/.
/home/kili/src/ghc/ghc-head-6.10/compiler/parser
/home/kili/src/ghc/ghc-head-6.10/compiler/utils
includes:
depends: Cabal-1.7.4 array-0.2.0.0 base-4.1.0.0 bytestring-0.9.1.4
containers-0.2.0.1 directory-1.0.0.3 filepath-1.1.0.2
hpc-0.5.0.3
old-time-1.0.0.2 process-1.0.1.1 unix-2.3.2.0
hugs-options:
cc-options:
ld-options:
framework-dirs:
frameworks:
haddock-interfaces:
/home/kili/src/ghc/ghc-head-6.10/compiler/stage1/doc/html/ghc/ghc.haddock
haddock-html:
/home/kili/src/ghc/ghc-head-6.10/compiler/stage1/doc/html/ghc
- Bootstrapped from ghc-6.11:
name: ghc
version: 6.11.20090908
id: ghc-6.11.20090908-inplace
license: BSD3
copyright:
maintainer: [email protected]
stability:
homepage: http://www.haskell.org/ghc/
package-url:
description: GHC's functionality can be useful for more things than just
[...]
category: Development
author: The GHC Team
exposed: False
exposed-modules: AsmCodeGen TargetReg NCGMonad Instruction Size Reg
[...]
hidden-modules:
import-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1/build
library-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1/build
hs-libraries: HSghc-6.11.20090908
extra-libraries:
extra-ghci-libraries:
include-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1
/home/kili/src/ghc/ghc-head-6.11/compiler/../libraries/base/cbits
/home/kili/src/ghc/ghc-head-6.11/compiler/../libraries/base/include
/home/kili/src/ghc/ghc-head-6.11/compiler/.
/home/kili/src/ghc/ghc-head-6.11/compiler/parser
/home/kili/src/ghc/ghc-head-6.11/compiler/utils
includes:
depends: Cabal-1.7.4-inplace
array-0.2.0.1-2b9df3f40f13b4669ba097be06f7b99b
base-4.1.0.0-b34dfe8ac6a43f644c3ca46a645a9fbc
bytestring-0.9.1.4-cfa420ea93c25450e74a9f4fff6741d8
containers-0.2.0.1-2b628549f0216e431e54a23e444e6460
directory-1.0.0.2-b9e858ba415b3089cc8fa51b7c90f593
filepath-1.1.0.1-4430c23f9035dadcfcf334e6334f98d3
hpc-0.5.0.2-inplace
old-time-1.0.0.1-4cd41db27b95d29a2f085545a706fb42
process-1.0.1.1-ba9241d3587ee2a4136046c53bb8ab0b
unix-2.3.1.0-30ecc3b82d3596aedd25c9cc2a3c34bc
hugs-options:
cc-options:
ld-options:
framework-dirs:
frameworks:
haddock-interfaces:
/home/kili/src/ghc/ghc-head-6.11/compiler/stage1/doc/html/ghc/ghc.haddock
haddock-html:
/home/kili/src/ghc/ghc-head-6.11/compiler/stage1/doc/html/ghc
---
name: ghc
version: 6.11
id: ghc-6.11.20090908-inplace
license: BSD3
copyright:
maintainer: [email protected]
stability:
homepage: http://www.haskell.org/ghc/
package-url:
description: GHC's functionality can be useful for more things than just
[...]
category: Development
author: The GHC Team
exposed: False
exposed-modules: AsmCodeGen TargetReg NCGMonad Instruction Size Reg
[...]
hidden-modules:
import-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1/build
library-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1/build
hs-libraries: HSghc-6.11
extra-libraries:
extra-ghci-libraries:
include-dirs: /home/kili/src/ghc/ghc-head-6.11/compiler/stage1
/home/kili/src/ghc/ghc-head-6.11/compiler/../libraries/base/cbits
/home/kili/src/ghc/ghc-head-6.11/compiler/../libraries/base/include
/home/kili/src/ghc/ghc-head-6.11/compiler/.
/home/kili/src/ghc/ghc-head-6.11/compiler/parser
/home/kili/src/ghc/ghc-head-6.11/compiler/utils
includes:
depends: Cabal-1.7.4-inplace
array-0.2.0.1-2b9df3f40f13b4669ba097be06f7b99b
base-4.1.0.0-b34dfe8ac6a43f644c3ca46a645a9fbc
bytestring-0.9.1.4-cfa420ea93c25450e74a9f4fff6741d8
containers-0.2.0.1-2b628549f0216e431e54a23e444e6460
directory-1.0.0.2-b9e858ba415b3089cc8fa51b7c90f593
filepath-1.1.0.1-4430c23f9035dadcfcf334e6334f98d3
hpc-0.5.0.2-inplace
old-time-1.0.0.1-4cd41db27b95d29a2f085545a706fb42
process-1.0.1.1-ba9241d3587ee2a4136046c53bb8ab0b
unix-2.3.1.0-30ecc3b82d3596aedd25c9cc2a3c34bc
hugs-options:
cc-options:
ld-options:
framework-dirs:
frameworks:
haddock-interfaces:
/home/kili/src/ghc/ghc-head-6.11/compiler/stage1/doc/html/ghc/ghc.haddock
haddock-html:
/home/kili/src/ghc/ghc-head-6.11/compiler/stage1/doc/html/ghc
So it seems like there are two differently versioned ghc packages
in bootstrapping.conf (-6.11.20090908 and -6.11) and the linker
picks up the wrong one (-6.11.20090908), which doesn't exist yet.
Further more, the id: field in the build bootstrapped from ghc-6.11
is identical for both packages (ghc-6.11.20090908-inplace). I noticed
Simon M's recent push adressing some shadowing problems and mentioning
the package-id, and the above problem actually still happens with
his patch. So even if the package-id is meant to force the use of
some specific package, it won't work in this case.
Any ideas how and where to fix this?
Ciao,
Kili
_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc