BigHeadSammy
28th November 2016, 03:27
Dear all,
I used Qt4.7.3 and mingw4.4 to generate definition file like this
<.def File>
EXPORTS
A@1
B@2
C@3
D@4
Here is my qt pro setting
QMAKE_LFLAGS += -output-def=DefFileNamePath
However, now I use Qt4.8.6 and mingw4.8.2 to generate definition file.
The above method in qt pro setting is not work. (It generate nothing.)
So, I change another way like this in qt pro setting
(https://forum.qt.io/topic/52907/definition-file-with-qt/4)
<.def File>
EXPORTS
_ZTI15DLLE @1 DATA
_ZTI16DLLF @2 DATA
_ZTI17DLLG @3 DATA
_ZTI18DLLH @4 DATA
A@1
B@2
C@3
D@4
Here is my qt pro setting
QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath
if i use "QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath" this way to generate definition file,
it will cause unexpected error like crash when i use relate DLL later.
i have two questions:
(1) What difference between "QMAKE_LFLAGS += -output-def=DefFileNamePath" and "QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath"?
(2) Is there any way to generate the same definition file format whatever in qt4.7.3+mingw4.4 or qt4.8.6+mingw4.8.2 ?
please give me some advice
thanks!
I used Qt4.7.3 and mingw4.4 to generate definition file like this
<.def File>
EXPORTS
A@1
B@2
C@3
D@4
Here is my qt pro setting
QMAKE_LFLAGS += -output-def=DefFileNamePath
However, now I use Qt4.8.6 and mingw4.8.2 to generate definition file.
The above method in qt pro setting is not work. (It generate nothing.)
So, I change another way like this in qt pro setting
(https://forum.qt.io/topic/52907/definition-file-with-qt/4)
<.def File>
EXPORTS
_ZTI15DLLE @1 DATA
_ZTI16DLLF @2 DATA
_ZTI17DLLG @3 DATA
_ZTI18DLLH @4 DATA
A@1
B@2
C@3
D@4
Here is my qt pro setting
QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath
if i use "QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath" this way to generate definition file,
it will cause unexpected error like crash when i use relate DLL later.
i have two questions:
(1) What difference between "QMAKE_LFLAGS += -output-def=DefFileNamePath" and "QMAKE_LFLAGS += -Wl,--output-def,DefFileNamePath"?
(2) Is there any way to generate the same definition file format whatever in qt4.7.3+mingw4.4 or qt4.8.6+mingw4.8.2 ?
please give me some advice
thanks!