2017-10-28 7 views
0

FreeBSD 10.3을 실행하는 컴퓨터에서 GHC 마스터 소스 코드를 컴파일하려했지만 컴파일 오류가 발생했습니다.GHC 소스 코드를 컴파일 할 때 이러한 컴파일 오류를 해결하는 방법

1. $ git clone --recursive git://git.haskell.org/ghc.git 
2. $ ./boot 
3. $ ./configure --prefix=$HOME 
4. $ gmake -j2 

을 그리고 컴파일 오류 : 나는 단계를 수행 않았다 내가 먼저 내 CC 환경 값으로 GCC를 사용

Common.hsc: In function 'main': 
Common.hsc:225:16: error: 'OFDEL' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:225:16: note: each undeclared identifier is reported only once for each function it appears in 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:226:16: error: 'OFILL' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:227:16: error: 'NL0' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:228:16: error: 'NL1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:229:16: error: 'CR0' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:230:16: error: 'CR1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:231:16: error: 'CR2' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:232:16: error: 'CR3' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:234:16: error: 'TAB1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:235:16: error: 'TAB2' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:237:16: error: 'BS0' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:238:16: error: 'BS1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:239:16: error: 'VT0' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:240:16: error: 'VT1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:241:16: error: 'FF0' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 
     ^
Common.hsc:242:16: error: 'FF1' undeclared (first use in this function) 
/root/test/ghc/inplace/lib/template-hsc.h:38:10: note: in definition of macro 'hsc_const' 
    if ((x) < 0)          \ 

, 다음 clang로 전환뿐만 아니라 실패했습니다. ghc8.0, alex, happy 등의 전제 조건이 모두 설치되어 있고 최신 gcc가 설치되어 있습니다.

답변

1

급속한 개발 및 연구를 목표로하는 시스템은 종종 설정에 많은주의를 기울이고 작업해야합니다.

예. 시스템 설정에 대한 지침을 따르셨습니까? here? 이 지침은 configuregmake 명령이 없음을 나타냅니다.

표준 터미널 제어 패키지의 termios.h 헤더에 정의 된 상수가 없다는 오류 메시지가 표시됩니다. 가능한 많은 원인이 있습니다. 그러나 configuregmake 명령이 주요한 용의자입니다.

또한이 페이지는 gcc 4.6이 새 것임을 유의하십시오. 즉, 꽤 오래 업데이트되지 않았 음을 의미합니다. 당신은 당신을 위해 당신의 직업을 삭감했을지도 모릅니다.

관련 문제