2015-01-22 20 views
0

이것은 매우 기본적인 질문입니다. 나는이 포럼의 역사를 검색하고 C/C++에서이 응용 프로그램에 직접 적용 할 수있는 것을 발견하지 못했습니다. Fedora20에서 코드를 작성합니다. 나는 다음과 같은 라이브러리를 가지고, yum을 사용하여 설치 :qprinter가 C++에서 발견되지 않습니다.

qt5-qtbase-devel qt5-qtdeclarative-devel qt5-qtscript-devel 
qt5-qtwebkit-devel qt5-qtsvg-devel qt5-qttools-devel 

[[email protected] subsurface]# qmake-qt5 --version 
QMake version 3.0 
Using Qt version 5.4.0 in /usr/lib64 

이 같은 qmake를를 사용

make-qt5 

오류가 표시되지, 내가 생성 된 파일 확인 및 헤더 파일 확인을 꼭 확인 가정합니다. 메이크업시

, 다음 Qt는 관련 오류 :

[[email protected] subsurface]# make 

(1)

compiling main.cpp 
In file included from /usr/include/QtGui/QTextEdit:1:0, 
      from .uic/ui_mainwindow.h:26, 
      from qt-ui/mainwindow.h:14, 
      from main.cpp:11: 
/usr/include/QtGui/qtextedit.h:235:16: error: ‘QPrinter’ has not been declared 
void print(QPrinter *printer) const; 
      ^

(2)

In file included from qt-ui/tableview.h:10:0, 
       from .uic/ui_diveplanner.h:26, 
       from qt-ui/diveplanner.h:140, 
       from .uic/ui_mainwindow.h:30, 
       from qt-ui/mainwindow.h:14, 
       from main.cpp:11: 
.uic/ui_tableview.h: In member function ‘void Ui_TableView::retranslateUi(QGroupBox*)’: 
.uic/ui_tableview.h:49:87: error: ‘UnicodeUTF8’ is not a member of ‘QApplication’ 
     TableView->setWindowTitle(QApplication::translate("TableView", "GroupBox", 0, QApplication::UnicodeUTF8)); 

나는 하나 또는 두 개 더 실종 의심 Qt 라이브러리. QPrinter와 UnicodeUTF8을 포함하는 라이브러리 파일은 무엇입니까? 조언이 필요하십니까? 이 PacketSender-2.0 프로젝트에 나를 위해 일한

답변

0

종류와 관련, 빌렘

# yum remove qt-devel 
# yum install qt5-qtbase-devel -y 

$ make clean 
$ qmake-qt5 
$ make