einbinden einer .dll /.a datei
Verfasst: 24. August 2008 11:10
Guten Tag
ich habe mir das qextserialport runtergeladen und kompilliert. nun habe ich eine .a und .dll datei erhalten und noch diverse andere dateien. Jedoch brauche ich ja nur die .dll oder die.a einbinden, so dass das qespta Programm läuft? Nur die Frage ist wie. Habe es schon unter Project-> properties ->c/c++ includes paths and symbols hinzugefügt (ganzen ordner)
und auch unter Project->properties ->C/c++ project paths->libaries die .a und .dll datei hinzufügt. Desweiteren habe ich die .pro datei auch so geändert
jedoch gibt es immer die selbe Fehlermeldung
ich habe mir das qextserialport runtergeladen und kompilliert. nun habe ich eine .a und .dll datei erhalten und noch diverse andere dateien. Jedoch brauche ich ja nur die .dll oder die.a einbinden, so dass das qespta Programm läuft? Nur die Frage ist wie. Habe es schon unter Project-> properties ->c/c++ includes paths and symbols hinzugefügt (ganzen ordner)
und auch unter Project->properties ->C/c++ project paths->libaries die .a und .dll datei hinzufügt. Desweiteren habe ich die .pro datei auch so geändert
Code: Alles auswählen
PROJECT = QESPTA
TEMPLATE = app
DEPENDPATH += .
INCLUDEPATH += C:\Dokumente \
und \
Einstellungen\user\Desktop\qextserialport-1.2win-alpha\build\libqserialportd.a
QMAKE_LIBDIR += ../../build
OBJECTS_DIR = obj
MOC_DIR = moc
UI_DIR = uic
CONFIG += qt \
thread \
warn_on
HEADERS += MainWindow.h \
MessageWindow.h \
QespTest.h
SOURCES += main.cpp \
MainWindow.cpp \
MessageWindow.cpp \
QespTest.cpp
CONFIG(debug, debug|release):LIBS += qextserialport
unix:DEFINES = _TTY_POSIX_
win32:DEFINES = _TTY_WIN_ \
QWT_DLL \
QT_DLLCode: Alles auswählen
mingw32-make debug
mingw32-make -f Makefile.Debug
mingw32-make[1]: Entering directory `C:/Dokumente und Einstellungen/user/workspacec++/qespta'
g++ -c -g -Wall -frtti -fexceptions -mthreads -D_TTY_WIN_ -DQWT_DLL -DQT_DLL -DQT_THREAD_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN -I"..\..\..\..\Qt\4.4.1\include\QtCore" -I"..\..\..\..\Qt\4.4.1\include\QtCore" -I"..\..\..\..\Qt\4.4.1\include\QtGui" -I"..\..\..\..\Qt\4.4.1\include\QtGui" -I"..\..\..\..\Qt\4.4.1\include" -I"c:\Dokumente" -I"und" -I"Einstellungen\user\Desktop\qextserialport-1.2win-alpha\build\libqserialportd.a" -I"c:\Qt\4.4.1\include\ActiveQt" -I"moc" -I"uic" -I"..\..\..\..\Qt\4.4.1\mkspecs\win32-g++" -o obj\main.o main.cpp
g++ -c -g -Wall -frtti -fexceptions -mthreads -D_TTY_WIN_ -DQWT_DLL -DQT_DLL -DQT_THREAD_SUPPORT -DQT_DLL -DQT_GUI_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN -I"..\..\..\..\Qt\4.4.1\include\QtCore" -I"..\..\..\..\Qt\4.4.1\include\QtCore" -I"..\..\..\..\Qt\4.4.1\include\QtGui" -I"..\..\..\..\Qt\4.4.1\include\QtGui" -I"..\..\..\..\Qt\4.4.1\include" -I"c:\Dokumente" -I"und" -I"Einstellungen\user\Desktop\qextserialport-1.2win-alpha\build\libqserialportd.a" -I"c:\Qt\4.4.1\include\ActiveQt" -I"moc" -I"uic" -I"..\..\..\..\Qt\4.4.1\mkspecs\win32-g++" -o obj\QespTest.o QespTest.cpp
QespTest.cpp:4:28: qextserialport.h: No such file or directory
QespTest.cpp: In constructor `QespTest::QespTest(QWidget*)':
QespTest.cpp:16: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:17: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:17: error: `BAUD9600' undeclared (first use this function)
QespTest.cpp:17: error: (Each undeclared identifier is reported only once for each function it appears in.)
QespTest.cpp:18: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:18: error: `FLOW_OFF' undeclared (first use this function)
QespTest.cpp:19: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:19: error: `PAR_NONE' undeclared (first use this function)
QespTest.cpp:20: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:20: error: `DATA_8' undeclared (first use this function)
QespTest.cpp:21: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:21: error: `STOP_1' undeclared (first use this function)
QespTest.cpp:23: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:64: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp: In destructor `virtual QespTest::~QespTest()':
QespTest.cpp:69: warning: possible problem detected in invocation of delete operator:
QespTest.cpp:69: warning: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: warning: forward declaration of `struct QextSerialPort'
QespTest.cpp:69: note: neither the destructor nor the class-specific operator delete will be called, even if they are declared when the class is defined.
QespTest.cpp: In member function `void QespTest::transmitMsg()':
QespTest.cpp:75: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp: In member function `void QespTest::receiveMsg()':
QespTest.cpp:85: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:89: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp: In member function `void QespTest::closePort()':
QespTest.cpp:115: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:116: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp: In member function `void QespTest::openPort()':
QespTest.cpp:121: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
QespTest.cpp:122: error: invalid use of undefined type `struct QextSerialPort'
QespTest.h:10: error: forward declaration of `struct QextSerialPort'
mingw32-make[1]: *** [obj/QespTest.o] Error 1
mingw32-make[1]: Leaving directory `C:/Dokumente und Einstellungen/user/workspacec++/qespta'
mingw32-make: *** [debug] Error 2