Installing binary tarball fails on Linux

"/usr/local/bin/haddock-ghc-7.4.1" cat utils/haddock/haddock.wrapper >> "/usr/local/bin/haddock-ghc-7.4.1" chmod +x "/usr/local/bin/haddock-ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/latex/" /usr/bin/install -c -m 644 utils/haddock/html/frames.html "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 644 utils/haddock/html/haddock-util.js "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/haskell_icon.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/minus.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/plus.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/xhaddock.css "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/hslogo-16.png "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/minus.gif "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/ocean.css "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/plus.gif "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/synopsis.png "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/latex/haddock.sty "/usr/local/lib/ghc-7.4.1/latex/" "rm" -f "/usr/local/bin/haddock" ln -s haddock-ghc-7.4.1 "/usr/local/bin/haddock" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/hsc2hs" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/hsc2hs" echo '#!/bin/sh' >> "/usr/local/bin/hsc2hs" echo 'exedir="/usr/local/lib/ghc-7.4.1"' >> "/usr/local/bin/hsc2hs" echo 'exeprog="hsc2hs"' >> "/usr/local/bin/hsc2hs" echo 'executablename="$exedir/$exeprog"' >> "/usr/local/bin/hsc2hs" echo 'datadir="/usr/local/share"' >> "/usr/local/bin/hsc2hs" echo 'bindir="/usr/local/bin"' >> "/usr/local/bin/hsc2hs" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/hsc2hs" echo 'HSC2HS_EXTRA="--cflag=-fno-stack-protector "' >> "/usr/local/bin/hsc2hs" cat utils/hsc2hs/hsc2hs.wrapper >> "/usr/local/bin/hsc2hs" chmod +x "/usr/local/bin/hsc2hs" /usr/bin/install -c -m 644 utils/hsc2hs/template-hsc.h "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-pkg-7.4.1" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/ghc-pkg-7.4.1" echo '#!/bin/sh' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'exeprog="ghc-pkg"' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'executablename="$exedir/$exeprog"' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'datadir="/usr/local/share"' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'bindir="/usr/local/bin"' >> "/usr/local/bin/ghc-pkg-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/ghc-pkg-7.4.1" cat utils/ghc-pkg/ghc-pkg.wrapper >> "/usr/local/bin/ghc-pkg-7.4.1" chmod +x "/usr/local/bin/ghc-pkg-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-pkg" ln -s ghc-pkg-7.4.1 "/usr/local/bin/ghc-pkg" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/runghc" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/runghc" echo '#!/bin/sh' >> "/usr/local/bin/runghc" echo 'exedir="/usr/local/lib/ghc-7.4.1"' >> "/usr/local/bin/runghc" echo 'exeprog="runghc"' >> "/usr/local/bin/runghc" echo 'executablename="$exedir/$exeprog"' >> "/usr/local/bin/runghc" echo 'datadir="/usr/local/share"' >> "/usr/local/bin/runghc" echo 'bindir="/usr/local/bin"' >> "/usr/local/bin/runghc" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/runghc" cat utils/runghc/runghc.wrapper >> "/usr/local/bin/runghc" chmod +x "/usr/local/bin/runghc" "rm" -f "/usr/local/bin/runhaskell" ln -s runghc "/usr/local/bin/runhaskell" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-7.4.1" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/ghc-7.4.1" echo '#!/bin/sh' >> "/usr/local/bin/ghc-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"' >> "/usr/local/bin/ghc-7.4.1" echo 'exeprog="ghc-stage2"' >> "/usr/local/bin/ghc-7.4.1" echo 'executablename="$exedir/$exeprog"' >> "/usr/local/bin/ghc-7.4.1" echo 'datadir="/usr/local/share"' >> "/usr/local/bin/ghc-7.4.1" echo 'bindir="/usr/local/bin"' >> "/usr/local/bin/ghc-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/ghc-7.4.1" echo 'executablename="$exedir/ghc"' >> "/usr/local/bin/ghc-7.4.1" cat ghc/ghc.wrapper >> "/usr/local/bin/ghc-7.4.1" chmod +x "/usr/local/bin/ghc-7.4.1" "rm" -f "/usr/local/bin/ghc" ln -s ghc-7.4.1 "/usr/local/bin/ghc" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" for i in driver/ghc-usage.txt driver/ghci-usage.txt rts/dist/build/libHSrts.a rts/dist/build/libHSrts_p.a rts/dist/build/libHSrts-ghc7.4.1.so rts/dist/build/libHSrts_l.a rts/dist/build/libHSrts_debug.a rts/dist/build/libHSrts_thr.a rts/dist/build/libHSrts_thr_debug.a rts/dist/build/libHSrts_thr_l.a rts/dist/build/libHSrts_thr_p.a rts/dist/build/libHSrts_debug-ghc7.4.1.so rts/dist/build/libHSrts_thr-ghc7.4.1.so rts/dist/build/libHSrts_thr_debug-ghc7.4.1.so rts/dist/build/libffi.so rts/dist/build/libffi.so.5 rts/dist/build/libffi.so.5.0.10 settings; do \ case $i in \ *.a) \ /usr/bin/install -c -m 644 $i "/usr/local/lib/ghc-7.4.1"; \ true /usr/local/lib/ghc-7.4.1/`basename $i` ;; \ *.dll) \ /usr/bin/install -c -m 644 -s $i "/usr/local/lib/ghc-7.4.1" ;; \ *.so) \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1" ;; \ *.dylib) \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1";; \ *) \ /usr/bin/install -c -m 644 $i "/usr/local/lib/ghc-7.4.1"; \ esac; \ done /usr/bin/gcc -E -undef -traditional -P -DINSTALLING -DLIB_DIR='"/usr/local/lib/ghc-7.4.1"' -DINCLUDE_DIR='"/usr/local/lib/ghc-7.4.1/include"' -DPAPI_INCLUDE_DIR="" -DPAPI_LIB_DIR="" -x c -Iincludes rts/package.conf.in -o rts/package.conf.install.raw grep -v '^#pragma GCC' rts/package.conf.install.raw | sed -e 's/""//g' -e 's/:[ ]*,/: /g' >rts/package.conf.install /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" for i in utils/haddock/dist/build/tmp/haddock utils/hsc2hs/dist-install/build/tmp/hsc2hs utils/ghc-pkg/dist-install/build/tmp/ghc-pkg utils/runghc/dist-install/build/tmp/runghc ghc/stage2/build/tmp/ghc-stage2; do \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1"; \ done "mv" "/usr/local/lib/ghc-7.4.1/ghc-stage2" "/usr/local/lib/ghc-7.4.1/ghc" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" "rm" -rf "/usr/local/lib/ghc-7.4.1/package.conf.d" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/package.conf.d" "/usr/local/lib/ghc-7.4.1/ghc-pkg" --force --global-conf "/usr/local/lib/ghc-7.4.1/package.conf.d" update rts/package.conf.install Reading package info from "rts/package.conf.install" ... done. "utils/ghc-cabal/dist-install/build/tmp/ghc-cabal" install "/usr/local/lib/ghc-7.4.1/ghc" "/usr/local/lib/ghc-7.4.1/ghc-pkg" "strip" "/usr/local/lib/ghc-7.4.1" libraries/ghc-prim dist-install '' '/usr/local' '/usr/local/lib/ghc-7.4.1' '/usr/local/share/doc/ghc/html/libraries' NO Installing library in /usr/local/lib/ghc-7.4.1/ghc-prim-0.2.0.0 ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got
Hi, I tried to install the GHC 7.4.1 32-bit binary tarball today and ran into the error below. Are 32-bit GHC's not supported on 64-bit Linuxes? The error: Installing library in /usr/local/lib/ghc-7.4.1/ghc-prim-0.2.0.0 ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got 129742) Full log: $ tar jxf ghc-7.4.1-i386-unknown-linux.tar.bz2 $ cd ghc-7.4.1/ tibell@tibell:ghc-7.4.1$ ./configure --prefix=/usr/local checking for path to top of build tree... /tmp/ghc-7.4.1 Build platform inferred as: i386-unknown-linux Host platform inferred as: i386-unknown-linux Target platform inferred as: i386-unknown-linux GHC build : i386-unknown-linux GHC host : i386-unknown-linux GHC target : i386-unknown-linux checking for perl... /usr/bin/perl checking if your perl works in shell scripts... yes checking for a BSD-compatible install... /usr/bin/install -c checking whether ln -s works... yes checking for gsed... sed checking for gcc... /usr/bin/gcc checking for gcc... /usr/bin/gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether /usr/bin/gcc accepts -g... yes checking for /usr/bin/gcc option to accept ISO C89... none needed checking version of gcc... 4.4.3 checking how to run the C preprocessor... /usr/bin/gcc -E checking whether ld understands --hash-size=31... checking whether ld understands --reduce-memory-overheads... checking for extra options to pass gcc when compiling via C... -fwrapv checking Setting up CFLAGS, LDFLAGS, IGNORE_LINKER_LD_FLAGS and CPPFLAGS... done checking Setting up CONF_CC_OPTS_STAGE0, CONF_GCC_LINKER_OPTS_STAGE0, CONF_LD_LINKER_OPTS_STAGE0 and CONF_CPP_OPTS_STAGE0... done checking Setting up CONF_CC_OPTS_STAGE1, CONF_GCC_LINKER_OPTS_STAGE1, CONF_LD_LINKER_OPTS_STAGE1 and CONF_CPP_OPTS_STAGE1... done checking Setting up CONF_CC_OPTS_STAGE2, CONF_GCC_LINKER_OPTS_STAGE2, CONF_LD_LINKER_OPTS_STAGE2 and CONF_CPP_OPTS_STAGE2... done checking for .subsections_via_symbols... no checking for GNU non-executable stack support... yes checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking size of void *... 8 checking for ar... /usr/bin/ar checking whether /usr/bin/ar is GNU ar... yes checking for ar arguments... q checking whether ranlib is needed... no configure: creating ./config.status config.status: creating settings config.status: creating mk/config.mk config.status: creating mk/install.mk **************************************************** Configuration done, ready to 'make install' (see README and INSTALL files for more info.) **************************************************** $ sudo make install make -r --no-print-directory -f ghc.mk install BINDIST=YES NO_INCLUDE_DEPS=YES /usr/bin/install -c -m 755 -d "/usr/local/share/man" /usr/bin/install -c -m 755 -d "/usr/local/share/man/man1" /usr/bin/install -c -m 644 docs/man/ghc.1 "/usr/local/share/man/man1" "rm" -f driver/split/dist/ghc-split echo '#!/usr/bin/perl' >> driver/split/dist/ghc-split echo '$TARGETPLATFORM = "i386-unknown-linux";' >> driver/split/dist/ghc-split echo '$TABLES_NEXT_TO_CODE = "YES";' >> driver/split/dist/ghc-split cat driver/split/dist/ghc-split.prl >> driver/split/dist/ghc-split /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 driver/split/dist/ghc-split "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghci-7.4.1" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/ghci-7.4.1" echo '#!/bin/sh' >> "/usr/local/bin/ghci-7.4.1" echo 'exec "/usr/local/bin/ghc-7.4.1" --interactive ${1+"$@"}' >> "/usr/local/bin/ghci-7.4.1" chmod +x "/usr/local/bin/ghci-7.4.1" "rm" -f "/usr/local/bin/ghci" ln -s ghci-7.4.1 "/usr/local/bin/ghci" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/." && /usr/bin/install -c -m 644 includes/./*.h "/usr/local/lib/ghc-7.4.1/include/./" && /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts" && /usr/bin/install -c -m 644 includes/rts/*.h "/usr/local/lib/ghc-7.4.1/include/rts/" && /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts/prof" && /usr/bin/install -c -m 644 includes/rts/prof/*.h "/usr/local/lib/ghc-7.4.1/include/rts/prof/" && /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts/storage" && /usr/bin/install -c -m 644 includes/rts/storage/*.h "/usr/local/lib/ghc-7.4.1/include/rts/storage/" && /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/stg" && /usr/bin/install -c -m 644 includes/stg/*.h "/usr/local/lib/ghc-7.4.1/include/stg/" && true /usr/bin/install -c -m 644 includes/ghcautoconf.h includes/ghcplatform.h includes/dist-ghcconstants/header/GHCConstants.h includes/dist-derivedconstants/header/DerivedConstants.h "/usr/local/lib/ghc-7.4.1/include/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include" /usr/bin/install -c -m 644 rts/dist/build/ffi.h rts/dist/build/ffitarget.h "/usr/local/lib/ghc-7.4.1/include/" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/haddock-ghc-7.4.1" create () { touch "$1" && chmod 755 "$1" ; } && create "/usr/local/bin/haddock-ghc-7.4.1" echo '#!/bin/sh' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'exeprog="haddock"' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'executablename="$exedir/$exeprog"' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'datadir="/usr/local/share"' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'bindir="/usr/local/bin"' >> "/usr/local/bin/haddock-ghc-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' 129742) make[1]: *** [install_packages] Error 1 make: *** [install] Error 2 -- Johan

The 64-bit version work so I guess that means that a 32-bit GHC/64-bit OS combination only works on OS X? -- Johan

On Thu, Feb 23, 2012 at 10:27 PM, Johan Tibell
The 64-bit version work so I guess that means that a 32-bit GHC/64-bit OS combination only works on OS X?
Did you get it working on linux? I'm getting the same error myself: ... ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got 129742) make[1]: *** [install_packages] Error 1 make: *** [install] Error 2 -- Andrea

On 28/09/2012 00:47, Andrea Vezzosi wrote:
On Thu, Feb 23, 2012 at 10:27 PM, Johan Tibell
wrote: The 64-bit version work so I guess that means that a 32-bit GHC/64-bit OS combination only works on OS X?
Did you get it working on linux?
I'm getting the same error myself: ... ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got 129742) make[1]: *** [install_packages] Error 1 make: *** [install] Error 2
This probably means that you have packages installed in your ~/.cabal from a 32-bit GHC and you're using a 64-bit one, or vice-versa. To avoid this problem you can configure cabal to put built packages into a directory containing the platform name. Cheers, Simon

On 01/10/2012 12:05, Simon Marlow wrote:
This probably means that you have packages installed in your ~/.cabal from a 32-bit GHC and you're using a 64-bit one, or vice-versa. To avoid this problem you can configure cabal to put built packages into a directory containing the platform name.
How does one do this? I ran into this problem a while ago and couldn't figure it out: http://stackoverflow.com/questions/12393750/how-can-i-configure-cabal-to-use... Ganesh

On 01/10/2012 13:00, Ganesh Sittampalam wrote:
On 01/10/2012 12:05, Simon Marlow wrote:
This probably means that you have packages installed in your ~/.cabal from a 32-bit GHC and you're using a 64-bit one, or vice-versa. To avoid this problem you can configure cabal to put built packages into a directory containing the platform name.
How does one do this? I ran into this problem a while ago and couldn't figure it out: http://stackoverflow.com/questions/12393750/how-can-i-configure-cabal-to-use...
I do this at work where I share the same home dir between several different machines, and my .cabal/config contains install-dirs user prefix: /home/simonmar/.cabal bindir: $prefix/bin/$arch-$os -- libdir: $prefix/lib libsubdir: $pkgid/$compiler/$arch-$os -- libexecdir: $prefix/libexec -- datadir: $prefix/share -- datasubdir: $pkgid -- docdir: $datadir/doc/$pkgid -- htmldir: $docdir/html -- haddockdir: $htmldir Hope this helps. Cheers, Simon

Hi, Am Montag, den 08.10.2012, 12:08 +0100 schrieb Simon Marlow:
On 01/10/2012 13:00, Ganesh Sittampalam wrote:
On 01/10/2012 12:05, Simon Marlow wrote:
This probably means that you have packages installed in your ~/.cabal from a 32-bit GHC and you're using a 64-bit one, or vice-versa. To avoid this problem you can configure cabal to put built packages into a directory containing the platform name.
How does one do this? I ran into this problem a while ago and couldn't figure it out: http://stackoverflow.com/questions/12393750/how-can-i-configure-cabal-to-use...
I do this at work where I share the same home dir between several different machines, and my .cabal/config contains
install-dirs user prefix: /home/simonmar/.cabal bindir: $prefix/bin/$arch-$os -- libdir: $prefix/lib libsubdir: $pkgid/$compiler/$arch-$os -- libexecdir: $prefix/libexec -- datadir: $prefix/share -- datasubdir: $pkgid -- docdir: $datadir/doc/$pkgid -- htmldir: $docdir/html -- haddockdir: $htmldir
any chance of making that the default, at least for libsubdir? I also stumble over it when I use a i386 schroot to test stuff. Greetings, Joachim -- Joachim "nomeata" Breitner Debian Developer nomeata@debian.org | ICQ# 74513189 | GPG-Keyid: 4743206C JID: nomeata@joachim-breitner.de | http://people.debian.org/~nomeata

On 08/10/2012 12:57, Joachim Breitner wrote:
Hi,
Am Montag, den 08.10.2012, 12:08 +0100 schrieb Simon Marlow:
On 01/10/2012 13:00, Ganesh Sittampalam wrote:
On 01/10/2012 12:05, Simon Marlow wrote:
This probably means that you have packages installed in your ~/.cabal from a 32-bit GHC and you're using a 64-bit one, or vice-versa. To avoid this problem you can configure cabal to put built packages into a directory containing the platform name.
How does one do this? I ran into this problem a while ago and couldn't figure it out: http://stackoverflow.com/questions/12393750/how-can-i-configure-cabal-to-use...
I do this at work where I share the same home dir between several different machines, and my .cabal/config contains
install-dirs user prefix: /home/simonmar/.cabal bindir: $prefix/bin/$arch-$os -- libdir: $prefix/lib libsubdir: $pkgid/$compiler/$arch-$os -- libexecdir: $prefix/libexec -- datadir: $prefix/share -- datasubdir: $pkgid -- docdir: $datadir/doc/$pkgid -- htmldir: $docdir/html -- haddockdir: $htmldir
any chance of making that the default, at least for libsubdir? I also stumble over it when I use a i386 schroot to test stuff.
Head over to https://github.com/haskell/cabal/ and create an issue (or a pull request!). Cheers, Simon

On 23/02/2012 21:24, Johan Tibell wrote:
Hi,
I tried to install the GHC 7.4.1 32-bit binary tarball today and ran into the error below. Are 32-bit GHC's not supported on 64-bit Linuxes?
The error:
Installing library in /usr/local/lib/ghc-7.4.1/ghc-prim-0.2.0.0 ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got 129742)
Is it possible you also had the 64-bit version installed? To install the two side-by-side, you have to set the --prefix or --libdir so they don't clash. Also, the 32-bit version won't work out of the box on a 64-bit Linux install without some -optc -m32 -opta -m32 -optl -m32. Cheers, Simon
Full log:
$ tar jxf ghc-7.4.1-i386-unknown-linux.tar.bz2
$ cd ghc-7.4.1/ tibell@tibell:ghc-7.4.1$ ./configure --prefix=/usr/local checking for path to top of build tree... /tmp/ghc-7.4.1 Build platform inferred as: i386-unknown-linux Host platform inferred as: i386-unknown-linux Target platform inferred as: i386-unknown-linux GHC build : i386-unknown-linux GHC host : i386-unknown-linux GHC target : i386-unknown-linux checking for perl... /usr/bin/perl checking if your perl works in shell scripts... yes checking for a BSD-compatible install... /usr/bin/install -c checking whether ln -s works... yes checking for gsed... sed checking for gcc... /usr/bin/gcc checking for gcc... /usr/bin/gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether /usr/bin/gcc accepts -g... yes checking for /usr/bin/gcc option to accept ISO C89... none needed checking version of gcc... 4.4.3 checking how to run the C preprocessor... /usr/bin/gcc -E checking whether ld understands --hash-size=31... checking whether ld understands --reduce-memory-overheads... checking for extra options to pass gcc when compiling via C... -fwrapv checking Setting up CFLAGS, LDFLAGS, IGNORE_LINKER_LD_FLAGS and CPPFLAGS... done checking Setting up CONF_CC_OPTS_STAGE0, CONF_GCC_LINKER_OPTS_STAGE0, CONF_LD_LINKER_OPTS_STAGE0 and CONF_CPP_OPTS_STAGE0... done checking Setting up CONF_CC_OPTS_STAGE1, CONF_GCC_LINKER_OPTS_STAGE1, CONF_LD_LINKER_OPTS_STAGE1 and CONF_CPP_OPTS_STAGE1... done checking Setting up CONF_CC_OPTS_STAGE2, CONF_GCC_LINKER_OPTS_STAGE2, CONF_LD_LINKER_OPTS_STAGE2 and CONF_CPP_OPTS_STAGE2... done checking for .subsections_via_symbols... no checking for GNU non-executable stack support... yes checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking size of void *... 8 checking for ar... /usr/bin/ar checking whether /usr/bin/ar is GNU ar... yes checking for ar arguments... q checking whether ranlib is needed... no configure: creating ./config.status config.status: creating settings config.status: creating mk/config.mk config.status: creating mk/install.mk **************************************************** Configuration done, ready to 'make install' (see README and INSTALL files for more info.) ****************************************************
"/usr/local/bin/haddock-ghc-7.4.1" cat utils/haddock/haddock.wrapper>> "/usr/local/bin/haddock-ghc-7.4.1" chmod +x "/usr/local/bin/haddock-ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/latex/" /usr/bin/install -c -m 644 utils/haddock/html/frames.html "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 644 utils/haddock/html/haddock-util.js "/usr/local/lib/ghc-7.4.1/html/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/haskell_icon.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/minus.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/plus.gif "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Classic.theme/xhaddock.css "/usr/local/lib/ghc-7.4.1/html/Classic.theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/hslogo-16.png "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/minus.gif "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/ocean.css "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/plus.gif "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/html/Ocean.std-theme/synopsis.png "/usr/local/lib/ghc-7.4.1/html/Ocean.std-theme/" /usr/bin/install -c -m 644 utils/haddock/latex/haddock.sty "/usr/local/lib/ghc-7.4.1/latex/" "rm" -f "/usr/local/bin/haddock" ln -s haddock-ghc-7.4.1 "/usr/local/bin/haddock" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/hsc2hs" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/hsc2hs" echo '#!/bin/sh'>> "/usr/local/bin/hsc2hs" echo 'exedir="/usr/local/lib/ghc-7.4.1"'>> "/usr/local/bin/hsc2hs" echo 'exeprog="hsc2hs"'>> "/usr/local/bin/hsc2hs" echo 'executablename="$exedir/$exeprog"'>> "/usr/local/bin/hsc2hs" echo 'datadir="/usr/local/share"'>> "/usr/local/bin/hsc2hs" echo 'bindir="/usr/local/bin"'>> "/usr/local/bin/hsc2hs" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/hsc2hs" echo 'HSC2HS_EXTRA="--cflag=-fno-stack-protector "'>> "/usr/local/bin/hsc2hs" cat utils/hsc2hs/hsc2hs.wrapper>> "/usr/local/bin/hsc2hs" chmod +x "/usr/local/bin/hsc2hs" /usr/bin/install -c -m 644 utils/hsc2hs/template-hsc.h "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-pkg-7.4.1" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/ghc-pkg-7.4.1" echo '#!/bin/sh'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'exeprog="ghc-pkg"'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'executablename="$exedir/$exeprog"'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'datadir="/usr/local/share"'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'bindir="/usr/local/bin"'>> "/usr/local/bin/ghc-pkg-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/ghc-pkg-7.4.1" cat utils/ghc-pkg/ghc-pkg.wrapper>> "/usr/local/bin/ghc-pkg-7.4.1" chmod +x "/usr/local/bin/ghc-pkg-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-pkg" ln -s ghc-pkg-7.4.1 "/usr/local/bin/ghc-pkg" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/runghc" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/runghc" echo '#!/bin/sh'>> "/usr/local/bin/runghc" echo 'exedir="/usr/local/lib/ghc-7.4.1"'>> "/usr/local/bin/runghc" echo 'exeprog="runghc"'>> "/usr/local/bin/runghc" echo 'executablename="$exedir/$exeprog"'>> "/usr/local/bin/runghc" echo 'datadir="/usr/local/share"'>> "/usr/local/bin/runghc" echo 'bindir="/usr/local/bin"'>> "/usr/local/bin/runghc" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/runghc" cat utils/runghc/runghc.wrapper>> "/usr/local/bin/runghc" chmod +x "/usr/local/bin/runghc" "rm" -f "/usr/local/bin/runhaskell" ln -s runghc "/usr/local/bin/runhaskell" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghc-7.4.1" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/ghc-7.4.1" echo '#!/bin/sh'>> "/usr/local/bin/ghc-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"'>> "/usr/local/bin/ghc-7.4.1" echo 'exeprog="ghc-stage2"'>> "/usr/local/bin/ghc-7.4.1" echo 'executablename="$exedir/$exeprog"'>> "/usr/local/bin/ghc-7.4.1" echo 'datadir="/usr/local/share"'>> "/usr/local/bin/ghc-7.4.1" echo 'bindir="/usr/local/bin"'>> "/usr/local/bin/ghc-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' "/usr/local/bin/ghc-7.4.1" echo 'executablename="$exedir/ghc"'>> "/usr/local/bin/ghc-7.4.1" cat ghc/ghc.wrapper>> "/usr/local/bin/ghc-7.4.1" chmod +x "/usr/local/bin/ghc-7.4.1" "rm" -f "/usr/local/bin/ghc" ln -s ghc-7.4.1 "/usr/local/bin/ghc" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" for i in driver/ghc-usage.txt driver/ghci-usage.txt rts/dist/build/libHSrts.a rts/dist/build/libHSrts_p.a rts/dist/build/libHSrts-ghc7.4.1.so rts/dist/build/libHSrts_l.a rts/dist/build/libHSrts_debug.a rts/dist/build/libHSrts_thr.a rts/dist/build/libHSrts_thr_debug.a rts/dist/build/libHSrts_thr_l.a rts/dist/build/libHSrts_thr_p.a rts/dist/build/libHSrts_debug-ghc7.4.1.so rts/dist/build/libHSrts_thr-ghc7.4.1.so rts/dist/build/libHSrts_thr_debug-ghc7.4.1.so rts/dist/build/libffi.so rts/dist/build/libffi.so.5 rts/dist/build/libffi.so.5.0.10 settings; do \ case $i in \ *.a) \ /usr/bin/install -c -m 644 $i "/usr/local/lib/ghc-7.4.1"; \ true /usr/local/lib/ghc-7.4.1/`basename $i` ;; \ *.dll) \ /usr/bin/install -c -m 644 -s $i "/usr/local/lib/ghc-7.4.1" ;; \ *.so) \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1" ;; \ *.dylib) \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1";; \ *) \ /usr/bin/install -c -m 644 $i "/usr/local/lib/ghc-7.4.1"; \ esac; \ done /usr/bin/gcc -E -undef -traditional -P -DINSTALLING -DLIB_DIR='"/usr/local/lib/ghc-7.4.1"' -DINCLUDE_DIR='"/usr/local/lib/ghc-7.4.1/include"' -DPAPI_INCLUDE_DIR="" -DPAPI_LIB_DIR="" -x c -Iincludes rts/package.conf.in -o rts/package.conf.install.raw grep -v '^#pragma GCC' rts/package.conf.install.raw | sed -e 's/""//g' -e 's/:[ ]*,/: /g'>rts/package.conf.install /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" for i in utils/haddock/dist/build/tmp/haddock utils/hsc2hs/dist-install/build/tmp/hsc2hs utils/ghc-pkg/dist-install/build/tmp/ghc-pkg utils/runghc/dist-install/build/tmp/runghc ghc/stage2/build/tmp/ghc-stage2; do \ /usr/bin/install -c -m 755 $i "/usr/local/lib/ghc-7.4.1"; \ done "mv" "/usr/local/lib/ghc-7.4.1/ghc-stage2" "/usr/local/lib/ghc-7.4.1/ghc" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" "rm" -rf "/usr/local/lib/ghc-7.4.1/package.conf.d" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/package.conf.d" "/usr/local/lib/ghc-7.4.1/ghc-pkg" --force --global-conf "/usr/local/lib/ghc-7.4.1/package.conf.d" update rts/package.conf.install Reading package info from "rts/package.conf.install" ... done. "utils/ghc-cabal/dist-install/build/tmp/ghc-cabal" install "/usr/local/lib/ghc-7.4.1/ghc" "/usr/local/lib/ghc-7.4.1/ghc-pkg" "strip" "/usr/local/lib/ghc-7.4.1" libraries/ghc-prim dist-install '' '/usr/local' '/usr/local/lib/ghc-7.4.1' '/usr/local/share/doc/ghc/html/libraries' NO Installing library in /usr/local/lib/ghc-7.4.1/ghc-prim-0.2.0.0 ghc-cabal: Bad interface file: dist-install/build/GHC/Classes.hi magic number mismatch: old/corrupt interface file? (wanted 33214052, got
$ sudo make install make -r --no-print-directory -f ghc.mk install BINDIST=YES NO_INCLUDE_DEPS=YES /usr/bin/install -c -m 755 -d "/usr/local/share/man" /usr/bin/install -c -m 755 -d "/usr/local/share/man/man1" /usr/bin/install -c -m 644 docs/man/ghc.1 "/usr/local/share/man/man1" "rm" -f driver/split/dist/ghc-split echo '#!/usr/bin/perl'>> driver/split/dist/ghc-split echo '$TARGETPLATFORM = "i386-unknown-linux";'>> driver/split/dist/ghc-split echo '$TABLES_NEXT_TO_CODE = "YES";'>> driver/split/dist/ghc-split cat driver/split/dist/ghc-split.prl >> driver/split/dist/ghc-split /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 driver/split/dist/ghc-split "/usr/local/lib/ghc-7.4.1" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/ghci-7.4.1" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/ghci-7.4.1" echo '#!/bin/sh'>> "/usr/local/bin/ghci-7.4.1" echo 'exec "/usr/local/bin/ghc-7.4.1" --interactive ${1+"$@"}'>> "/usr/local/bin/ghci-7.4.1" chmod +x "/usr/local/bin/ghci-7.4.1" "rm" -f "/usr/local/bin/ghci" ln -s ghci-7.4.1 "/usr/local/bin/ghci" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/."&& /usr/bin/install -c -m 644 includes/./*.h "/usr/local/lib/ghc-7.4.1/include/./"&& /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts"&& /usr/bin/install -c -m 644 includes/rts/*.h "/usr/local/lib/ghc-7.4.1/include/rts/"&& /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts/prof"&& /usr/bin/install -c -m 644 includes/rts/prof/*.h "/usr/local/lib/ghc-7.4.1/include/rts/prof/"&& /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/rts/storage"&& /usr/bin/install -c -m 644 includes/rts/storage/*.h "/usr/local/lib/ghc-7.4.1/include/rts/storage/"&& /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include/stg"&& /usr/bin/install -c -m 644 includes/stg/*.h "/usr/local/lib/ghc-7.4.1/include/stg/"&& true /usr/bin/install -c -m 644 includes/ghcautoconf.h includes/ghcplatform.h includes/dist-ghcconstants/header/GHCConstants.h includes/dist-derivedconstants/header/DerivedConstants.h "/usr/local/lib/ghc-7.4.1/include/" /usr/bin/install -c -m 755 -d "/usr/local/lib/ghc-7.4.1/include" /usr/bin/install -c -m 644 rts/dist/build/ffi.h rts/dist/build/ffitarget.h "/usr/local/lib/ghc-7.4.1/include/" /usr/bin/install -c -m 755 -d "/usr/local/bin" "rm" -f "/usr/local/bin/haddock-ghc-7.4.1" create () { touch "$1"&& chmod 755 "$1" ; }&& create "/usr/local/bin/haddock-ghc-7.4.1" echo '#!/bin/sh'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'exedir="/usr/local/lib/ghc-7.4.1"'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'exeprog="haddock"'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'executablename="$exedir/$exeprog"'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'datadir="/usr/local/share"'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'bindir="/usr/local/bin"'>> "/usr/local/bin/haddock-ghc-7.4.1" echo 'topdir="/usr/local/lib/ghc-7.4.1"' 129742) make[1]: *** [install_packages] Error 1 make: *** [install] Error 2
-- Johan
_______________________________________________ Glasgow-haskell-users mailing list Glasgow-haskell-users@haskell.org http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
participants (5)
-
Andrea Vezzosi
-
Ganesh Sittampalam
-
Joachim Breitner
-
Johan Tibell
-
Simon Marlow