Cabal 오류: c 컴파일된 프로그램을 실행할 수 없습니다.

Cabal 오류: c 컴파일된 프로그램을 실행할 수 없습니다.

이전 버전의 cabal-install을 사용하고 있어서 cabal-install 1.20을 다운로드했는데 설치하는 동안 오류가 발생했습니다.

추가 참고 사항: GHC 7.8.3
운영 체제: CentOS 6.6

실수:

Building network-2.4.2.3...
.......
......
......
usr/bin/ld: cannot find -lHSparsec-3.1.7-ghc7.8.3
collect2: ld returned 1 exit status
error during cabal-install bootstrap:
building the network package failed.

"cabal install network-2.5.0.0"을 실행하려고 하면 다음 오류가 발생합니다.

root@gains: cabal install network-2.5.0.0
Resolving dependencies...
Configuring network-2.5.0.0...
configure: WARNING: unrecognized options: --with-compiler, --with-gcc
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking for gcc... 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... configure: error: in `/tmp/network-2.5.0.023068/network-2.5.0.0':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
cabal: Error: some packages failed to install:
network-2.5.0.0 failed during the configure step. The exception was:
ExitFailure 1

답변1

실수:

checking whether we are cross compiling... configure: error: in `/tmp/network-2.5.0.023068/network-2.5.0.0':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details

그래서 명령어를 실행하고 yum groupinstall "development tools", c 컴파일러 도구를 설치하고, c 프로그램을 컴파일할 수 있었습니다. 그 다음에,

checking whether we are cross compiling... configure: error: in /tmp/network-2.5.0.023068/network-2.5.0.0':

mount -o remount,exec,suid /tmp오류를 해결하려고 노력했습니다 . 이는 파일 시스템의 실행 권한 문제 때문입니다.

관련 정보