4

「cabal install sdl-mixer」を使用して、SDL-mixer haskell パッケージをインストールしようとしています。私がそうすると、エラーが発生します

Resolving dependencies...
[1 of 1] Compiling Main             ( /tmp/SDL-mixer-0.6.1-10381/SDL-mixer-0.6.1/Setup.lhs, /tmp/SDL-mixer-0.6.1-10381/SDL-mixer-0.6.1/dist/setup/Main.o )
Linking /tmp/SDL-mixer-0.6.1-10381/SDL-mixer-0.6.1/dist/setup/setup ...
Configuring SDL-mixer-0.6.1...
configure: WARNING: unrecognized options: --with-compiler, --with-gcc
checking for sdl-config... /usr/bin/sdl-config
checking for gcc... gcc
checking whether the C compiler works... no
configure: error: in `/tmp/SDL-mixer-0.6.1-10381/SDL-mixer-0.6.1':
configure: error: C compiler cannot create executables
See `config.log' for more details.
Failed to install SDL-mixer-0.6.1
cabal: Error: some packages failed to install:
SDL-mixer-0.6.1 failed during the configure step. The exception was:
ExitFailure 77

違いがある場合、私は Arch Linux を使用しています。このパッケージをインストールするにはどうすればよいですか?

4

3 に答える 3

1

ubuntu 12.04 のパッケージ ネットワークでも同じ症状が発生しました。これは、/usr/bin/ld が ld.bfd ではなくゴールドであることが原因でした。一部のパッケージでは、 --with-ld=ld.bfd を渡すだけでは明らかに不十分です。

回避策:

mkdir /tmp/ld_override

ln -s /usr/bin/ld.bfd /tmp/ld_override/ld

PATH=/tmp/ld_override:$PATH cabal install ...
于 2013-09-29T13:04:31.013 に答える