2014-06-08 3 views
1

저는과 python2.7을 redhat 6에 작성 중입니다. 소스에서 python2.7을 설치 했으므로 다른 모든 작업에 유용합니다.Linux에서 PYQT를 빌드 할 수 없습니다.

\# python2.7 configure.py 

당신의 Qt는 설치의 레이아웃을 결정 ...
오류 : 당신의 Qt는 설치의 레이아웃을 결정하지 못했습니다 내가 python2.7 configure.py를 실행하면, 나는 다음과 같은 오류가 발생합니다. 문제에 대한 자세한 내용을 보려면 --verbose 플래그 을 사용하여 다시 시도하십시오.

나는이 주위에 방법, 작업 나타났다 다음 명령을 발행하는 것입니다 읽었습니다 :이 성공적으로 완료

\# python2.7 configure.py --qmake /usr/bin/qmake-qt4 -g 

. 하지만 make를 실행하면 다음과 같은 오류가 발생합니다.

make[1]: Entering directory /root/Downloads/PyQt-x11-gpl-4.11/qpy<br /> 
make[2]: Entering directory /root/Downloads/PyQt-x11-gpl-4.11/qpy/QtCore<br /> 
g++ -m64 -Wl,-O1 -o w_qpycore  -lQtGui -lQtCore -lpthread<br /> 
/usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../lib64/crt1.o:<br /> 
In function _start: (.text+0x20): undefined reference to main<br /> 
collect2: ld returned 1 exit status<br /> 
make[2]: [w_qpycore] Error 1<br /> 
make[2]: Leaving directory /root/Downloads/PyQt-x11-gpl-4.11/qpy/QtCore<br /> 
make[1]: \*\*\* [all] Error 2<br /> 
make[1]: Leaving directory /root/Downloads/PyQt-x11-gpl-4.11/qpy<br /> 
make: \*\*\* [all] Error 2<br /> 

어떤 도움을 주셔서 감사합니다. - 마크

답변

1

당신과 같은 문제가 있습니다. 그것을 알아 냈다 -

Querying qmake about your Qt installation... 
    Determining the details of your Qt installation... 
    An internal error occured. Please report all the output from the program, 
    including the following traceback, to [email protected] 
    Traceback (most recent call last): 
     File "configure-ng.py", line 2816, in <module> 
     main(sys.argv) 
     File "configure-ng.py", line 2780, in main 
     target_config.from_introspection(opts.verbose, opts.debug) 
     File "configure-ng.py", line 695, in from_introspection 
     self.qt_shared = (lines[1] == 'shared') 
    IndexError: list index out of range 

편집 : 우리는 대신 'configure-ng.py'를 사용하는데,하지만 난 것을 실행할 때이 오류가있어 들었다.

나는 Qt 4.6이 로컬에 설치되어 있었으며 설치 프로그램은 Qt 4.7 이상을 기대하고있다. (오류 메시지가 그렇게 말하지는 않았지만). 나는 (CentOS는에 6 일)이 저장소를 사용하여 Qt는 4.8을 설치 : 그 REPOS를 추가 한 후 https://lists.fedoraproject.org/pipermail/fedora-kde/2013-March/012437.html

을, 난 그냥 냠 것은 QT QT-(STABLE)를 설치했고, 그것은 4.6에서 내 Qt는 업그레이드 - 후> 4.8

1. python configure-ng.py 
    2. make 
    3. make install 

EDIT2 : 다음 PyQt4 원본 파일 CD 및 로컬 Qt는 4.8을 얻는 것은 우리가 직장에서 Qt는 4.7을 필요로 밝혀졌습니다. 몇 가지 조사 후 밝혀 이러한 버전은 행복 함께 있습니다

PyQt 4.10.4 
    SIP 4.15.4 
    QT 4.7.4 

Qt는 4.7 RPM을 여기에서 찾을 수 있습니다 : http://joseph.freivald.com/linux/2011/09/23/qt-4-7-4-and-qt-creator-2-3-0-for-centosrhel-5/

PyQt는 4.11 Qt를 4.7 작동하지 않는다 (적어도 나를 위해, 내가 야에가 CentOS 6.4) 이러한 버전의 경우 위의 1,2,3 단계를 따르십시오.

관련 문제