Opened 13 years ago
Closed 12 years ago
#31781 closed defect (fixed)
ghc will not build on Lion
Reported by: | bowman@… | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.0.3 |
Keywords: | Cc: | ryandesign (Ryan Carsten Schmidt), newpdt@…, daniel.hjort@…, quark@…, MartinBuchmann (Martin Buchmann), info@…, amarqueslee@…, roland@… | |
Port: | ghc |
Description (last modified by ryandesign (Ryan Carsten Schmidt))
On OSX Lion, using XCode 4.2 and a fresh install of macports I am unable to build ghc.
Here is what I take to be the relevant portion of the build log:
:info:configure checking for ld... /usr/bin/ld :info:configure checking for path to top of build tree... ghc: could not execute: /usr/bin/gcc-4.2 :info:configure ./configure: line 3314: utils/pwd/pwd: No such file or directory :info:configure configure: error: cannot determine current directory :info:configure shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4" && ./configure --prefix=/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/destroot/opt/local --datadir=/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/destroot/opt/local/share/ghc-6.10.4 --with-gmp-includes=/opt/local/include --with-gmp-libraries=/opt/local/lib --with-ghc='/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-bootstrap/bin/ghc' --with-gcc=/usr/bin/gcc-4.2 --build=x86_64-apple-darwin --host=x86_64-apple-darwin --target=x86_64-apple-darwin " returned error 1 :error:configure Target org.macports.configure returned: configure failure: shell command failed (see log for details) :debug:configure Backtrace: configure failure: shell command failed (see log for details) while executing "$procedure $targetname" :info:configure Warning: the following items did not execute (for ghc): org.macports.activate org.macports.configure org.macports.build org.macports.destroot org.macports.install :notice:configure Log for ghc is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/main.log
configure complains that gcc-4.2 is not installed. Of course gcc-4.2 will not build on Lion, so I'm not sure if a symlink is supposed to be in place of what.
Attachments (3)
Change History (22)
Changed 13 years ago by bowman@…
comment:1 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | gwright@… added |
---|---|
Description: | modified (diff) |
Owner: | changed from macports-tickets@… to ryandesign@… |
Port: | ghc added |
Status: | new → assigned |
comment:2 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Hopefully r86459 fixes this. Wait 30 minutes, "sudo port selfupdate", "sudo port clean ghc" and try again.
comment:3 Changed 13 years ago by bowman@…
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Thank you, that addresses the problem above. Now the build fails a bit further on. Here's the relevant excerpt from the log:
:info:build <<ghc: 482406536 bytes, 35 GCs, 7261302/12616368 avg/max bytes residency (4 samples), 33M in use, 0.00 INIT (0.00 elapsed), 0.56 MUT (9.97 elapsed), 0.18 GC (0.24 elapsed) :ghc>> :info:build :info:build GHC/Float.lhs:621:18: :info:build Warning: Defaulting the following constraint(s) to type `Double' :info:build `Floating a' arising from a use of `log' at GHC/Float.lhs:621:18-40 :info:build `RealFrac a' :info:build arising from a use of `ceiling' at GHC/Float.lhs:(621,8)-(623,41) :info:build In the first argument of `(+)', namely `log (fromInteger (f + 1))' :info:build In the first argument of `(/)', namely :info:build `(log (fromInteger (f + 1)) :info:build + fromIntegral e * log (fromInteger b))' :info:build In the first argument of `ceiling', namely :info:build `((log (fromInteger (f + 1)) :info:build + fromIntegral e * log (fromInteger b)) :info:build / log (fromInteger base))' :info:build <<ghc: 2240166912 bytes, 1900 GCs, 16639963/30502480 avg/max bytes residency (14 samples), 80M in use, 0.00 INIT (0.00 elapsed), 2.25 MUT (13.73 elapsed), 1.48 GC (1.92 elapsed) :ghc>> :info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/ghc/stage1-inplace/ghc -package-name base-4.1.0.0 -hide-all-packages -no-user-package-conf -split-objs -i -idist/build -i. -idist/build/autogen -Idist/build/autogen -Idist/build -Iinclude -I/opt/local/include -optP-include -optPdist/build/autogen/cabal_macros.h -#include "HsBase.h" -odir dist/build -hidir dist/build -stubdir dist/build -package ghc-prim-0.1.0.0 -package integer-0.1.0.1 -package rts-1.0 -O -package-name base -XMagicHash -XExistentialQuantification -XRank2Types -XScopedTypeVariables -XUnboxedTuples -XForeignFunctionInterface -XUnliftedFFITypes -XDeriveDataTypeable -XGeneralizedNewtypeDeriving -XFlexibleInstances -XStandaloneDeriving -XPatternGuards -XEmptyDataDecls -XCPP -idist/build -H32m -O -L/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libffi -I/opt/local/include -L/opt/local/lib -O2 -Rghc-timing -XGenerics -Wall -fno-warn-deprecated-flags -c GHC/Read.lhs -o dist/build/GHC/Read.o -ohi dist/build/GHC/Read.hi :info:build ghc: could not execute: /opt/local/bin/gcc-apple-4.2 :info:build <<ghc: 810911728 bytes, 75 GCs, 8666062/14457080 avg/max bytes residency (5 samples), 37M in use, 0.00 INIT (0.00 elapsed), 0.83 MUT (4.39 elapsed), 0.33 GC (0.35 elapsed) :ghc>> :info:build make[2]: *** [dist/build/GHC/Read.o] Error 1 :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries/base' :info:build make[1]: *** [make.library.base] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries' :info:build make: *** [stage1] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4' :info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4" && /usr/bin/make -j2 -w all " returned error 2 :error:build Target org.macports.build returned: shell command failed (see log for details) :debug:build Backtrace: shell command failed (see log for details) while executing "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "$procedure $targetname" :info:build Warning: the following items did not execute (for ghc): org.macports.activate org.macports.build org.macports.destroot org.macports.install :notice:build Log for ghc is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/main.log
comment:4 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | ryandesign@… added; gwright@… removed |
---|---|
Owner: | changed from ryandesign@… to gwright@… |
Status: | reopened → new |
Ok, I don't know what to do about that. Reassigning to maintainer.
P.S: Don't forget to use WikiFormatting.
comment:8 Changed 13 years ago by MartinBuchmann (Martin Buchmann)
Cc: | Martin.Buchmann@… added |
---|
Cc Me!
comment:9 Changed 13 years ago by daniel.hjort@…
It builds for me now. If someone can confirm maybe the ticket can be closed.
Changed 13 years ago by info@…
Attachment: | main.3.log added |
---|
comment:10 follow-up: 11 Changed 13 years ago by info@…
still broken for me:
[...] :info:build <<ghc: 231226968 bytes, 18 GCs, 5403862/13519000 avg/max bytes residency (4 samples), 34M in use, 0.00 INIT (0.00 elapsed), 0.20 MUT (1.83 elapsed), 0.12 GC (0.19 elapsed) :ghc>> :info:build make[3]: *** [dist/build/Data/Array/Parallel/Prelude/Base/Int.p_o] Error 1 :info:build make[2]: *** [all] Error 1 :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries/dph/dph-seq' :info:build make[1]: *** [make.library.dph/dph-seq] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries' :info:build make: *** [stage1] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4' :info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4" && /usr/bin/make -j2 -w all " returned error 2 :error:build Target org.macports.build returned: shell command failed (see log for details) :debug:build Backtrace: shell command failed (see log for details) while executing "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "$procedure $targetname" :info:build Warning: the following items did not execute (for ghc): org.macports.activate org.macports.build org.macports.destroot org.macports.install :error:build Failed to install ghc :debug:build could not read "/opt/local/share/man/man3p/warnings::register-5.8.3pm": no such file or directory while executing "file type $file" :notice:build Log for ghc is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/main.log
comment:11 Changed 13 years ago by info@…
Replying to info@…:
still broken for me:
[...] :info:build <<ghc: 231226968 bytes, 18 GCs, 5403862/13519000 avg/max bytes residency (4 samples), 34M in use, 0.00 INIT (0.00 elapsed), 0.20 MUT (1.83 elapsed), 0.12 GC (0.19 elapsed) :ghc>> :info:build make[3]: *** [dist/build/Data/Array/Parallel/Prelude/Base/Int.p_o] Error 1 :info:build make[2]: *** [all] Error 1 :info:build make[2]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries/dph/dph-seq' :info:build make[1]: *** [make.library.dph/dph-seq] Error 2 :info:build make[1]: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4/libraries' :info:build make: *** [stage1] Error 2 :info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4' :info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/work/ghc-6.10.4" && /usr/bin/make -j2 -w all " returned error 2 :error:build Target org.macports.build returned: shell command failed (see log for details) :debug:build Backtrace: shell command failed (see log for details) while executing "command_exec build" (procedure "portbuild::build_main" line 8) invoked from within "$procedure $targetname" :info:build Warning: the following items did not execute (for ghc): org.macports.activate org.macports.build org.macports.destroot org.macports.install :error:build Failed to install ghc :debug:build could not read "/opt/local/share/man/man3p/warnings::register-5.8.3pm": no such file or directory while executing "file type $file" :notice:build Log for ghc is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_ghc/ghc/main.log
# port selfupdate [...] # port -u upgrade outdated [...] # port install pandoc [...] ---> Building ghc ---> Staging ghc into destroot ---> Installing ghc @6.10.4_5 ---> Activating ghc @6.10.4_5 ---> Cleaning ghc [...]
comment:12 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | info@… added |
---|
So... not broken anymore after all then?
comment:13 Changed 13 years ago by info@…
don't know what caused the error two days ago, but ghc is now installed
comment:15 Changed 13 years ago by amarqueslee@…
Not sure if this should be here or in a new ticket.
ghc installs from me, but won't compile anything:
$ ghc hello.hs ghc: could not execute: /usr/bin/gcc-4.2
Somewhere it's still being configured to point to the wrong gcc.
I tried giving it the right version of gcc with
-pgmc `which gcc`
but ghc still seems to not be able to find my gcc.
Thanks in advance for the help!
comment:16 Changed 13 years ago by amarqueslee@…
Can't believe I didn't think of this immediately, but a pseudo-fix is:
cd /usr/bin sudo ln -s gcc gcc-4.2 #enter password
Ghc now compiles, but ld warns about a couple of invalid flags and things being passed through when ghc links... I get the feeling undefined behaviour will come back and bite me for this when i least expect it...
comment:18 Changed 12 years ago by raimue (Rainer Müller)
Owner: | changed from gwright@… to macports-tickets@… |
---|
Port abandoned, #35561.
comment:19 Changed 12 years ago by neverpanic (Clemens Lang)
Resolution: | → fixed |
---|---|
Status: | new → closed |
Since the Lion buildbot has successfully built ghc (see http://packages.macports.org/ghc/) I think this is obsolete. Please re-open if the problem still persists.
main.log