On 19/01/13 00:44, Stephen Paul Weber wrote:

Needs the patch to add QNX as a supported OS (first patch from
<http://www.haskell.org/pipermail/cvs-ghc/2012-December/079078.html>) to
even try to configure, which is expected.  After applying that patch:

I'll get that patch committed.

./configure --target=i486-pc-nto-qnx8.0.0 --prefix="${QNX_HOST}/usr"

succeeds.  Copied build.mk.sample to build.mk and added:

Stage1Only = YES

as instructed.  Uncommented the "quick" build type.  Type "make" and get:

$ make
+ test -f mk/config.mk.old
+ cp -p mk/config.mk mk/config.mk.old
touch -r mk/config.mk.old mk/config.mk
+ test -f mk/project.mk.old
+ cp -p mk/project.mk mk/project.mk.old
touch -r mk/project.mk.old mk/project.mk
+ test -f compiler/ghc.cabal.old
+ cp -p compiler/ghc.cabal compiler/ghc.cabal.old
touch -r compiler/ghc.cabal.old compiler/ghc.cabal
===--- building phase 0
make -r --no-print-directory -f ghc.mk phase=0 phase_0_builds
libraries/hpc/ghc.mk:3: libraries/hpc/dist-boot/package-data.mk: No such
file or directory
libraries/Cabal/Cabal/ghc.mk:3:
libraries/Cabal/Cabal/dist-boot/package-data.mk: No such file or directory
libraries/binary/ghc.mk:3: libraries/binary/dist-boot/package-data.mk:
No such file or directory
libraries/bin-package-db/ghc.mk:3:
libraries/bin-package-db/dist-boot/package-data.mk: No such file or
directory
libraries/hoopl/ghc.mk:3: libraries/hoopl/dist-boot/package-data.mk: No
such file or directory
libraries/transformers/ghc.mk:3:
libraries/transformers/dist-boot/package-data.mk: No such file or directory
compiler/ghc.mk:439: compiler/stage1/package-data.mk: No such file or
directory
utils/hsc2hs/ghc.mk:15: utils/hsc2hs/dist/package-data.mk: No such file
or directory
ghc/ghc.mk:109: ghc/stage1/package-data.mk: No such file or directory
libraries/dph/ghc.mk:123: *** dph_th_deps(v):
libraries/dph/dph-base_dist-install_GHCI_LIB not defined!.  Stop.
make: *** [all] Error 2

So, I have commented out the dph libraries from ./packages
I think this is still expected behaviour.  Should something about this
possibility be added to the wiki page?

Yes, you need to omit the dph packages when getting the subrepos. I've added that to the page.

The next thing to happen is I run into
<http://hackage.haskell.org/trac/ghc/ticket/7519>, so I apply the patch
from there and continue.

building integer-gmp fails with:

cd libraries/integer-gmp/gmp; (set -o igncr 2>/dev/null) && set -o
igncr; export SHELLOPTS; \
         PATH=`pwd`:$PATH; \
         export PATH; \
         cd gmpbuild && \

CC=/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/bin/i486-pc-nto-qnx8.0.0-gcc
NM=/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/bin/i486-pc-nto-qnx8.0.0-nm
AR=/usr/bin/ar /bin/sh configure \
           --enable-shared=no \
           --host=i386-unknown-linux --build=i386-unknown-linux
checking build system type... i386-unknown-linux-gnu
checking host system type... i386-unknown-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking ABI=32
checking whether
/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/bin/i486-pc-nto-qnx8.0.0-gcc
is gcc... yes
checking compiler
/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/bin/i486-pc-nto-qnx8.0.0-gcc
-m32 -O2 -pedantic -fomit-frame-pointer ... no, program does not run
checking compiler
/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/bin/i486-pc-nto-qnx8.0.0-gcc
-O2 -pedantic -fomit-frame-pointer ... no, program does not run
configure: error: could not find a working compiler, see config.log for
details
make[1]: *** [libraries/integer-gmp/gmp/gmp.h] Error 1
make: *** [all] Error 2

I'm not sure why it does not get the target right, but I can work around
this by adding the following to build.mk:

INTEGER_LIBRARY=integer-simple

Right, I've added this to the page too.

So I do this and continue, which leads me to:

make[1]: *** No rule to make target
`libraries/integer-gmp/dist-install/build/GHC/Integer.hi', needed by
`libraries/base/dist-install/build/GHC/Base.o'.  Stop.
make: *** [all] Error 2

Oh, it didn't switch.  Hmm.

I believe a 'make distclean' is necessary after changing INTEGER_LIBRARY, because it gets stuck into GHC's Config.hs early on. I ran into exactly this in my build. Also added this to the page.

Success!  I type `make install` which results in:

Installing library in
/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/lib/ghc-7.7.20130118/transformers-0.3.0.0

"/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/lib/ghc-7.7.20130118/bin/ghc-pkg"
--force --global-package-db
"/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/lib/ghc-7.7.20130118/package.conf.d"
update rts/package.conf.install
/bin/sh: 1:
/home/singpolyma/bbndk/host_10_0_9_404/linux/x86/usr/lib/ghc-7.7.20130118/bin/ghc-pkg:
not found
make[1]: *** [install_packages] Error 127
make: *** [install] Error 2


Ok, we should fix 'make install'.  I didn't have much luck with it either.

Cheers,
        Simon



_______________________________________________
ghc-devs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/ghc-devs

Reply via email to