Re: [Interest] qmake bug. Any workaround?
I've created additional .cpp file in which I've just included disarm.cpp. This helped. But I would like to get a solution which will work after any changes are made to Detours lib so I do not have to make such modifications in the future. On 1/15/2021 6:36 PM, Allan Sandfeld Jensen wrote: Rename disarm.cpp to a header file, and include that in two different source files? 'Allan ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] qmake bug. Any workaround?
On Freitag, 15. Januar 2021 15:54:25 CET Alexander Dyagilev wrote: > Hello, > > I am trying to create a .pro file to compile Microsoft Detours lib. > > Failed, it generates linker error: > > detours.obj:-1: error: LNK2019: unresolved external symbol > DetourCopyInstruction referenced in function DetourAttachEx > > This function is defined in disasm.cpp in case there are no special > defines existing. > > But, there are disolarm.cpp disolarm64.cpp disolia64.cpp disolx64.cpp > disolx86.cpp sources which defines platform-depended definitions and > then includes this disasm.cpp. > > E.g. disolarm.cpp contains of only these 2 lines of code: > #define DETOURS_ARM_OFFLINE_LIBRARY > #include "disasm.cpp" > > In this case disasm.cpp defines DetourCopyInstructionARM instead of > DetourCopyInstruction. > > Qmake has the bug (https://bugreports.qt.io/browse/QTBUG-24906) which > causes qmake to DROP disasm.cpp from SOURCES because it's included in > these source files . Thus plain DetourCopyInstruction is not defined > anywhere. > > If I replace #include "disasm.cpp" lines with file's content, all works > fine. But this is not a workaround I want. > Rename disarm.cpp to a header file, and include that in two different source files? 'Allan ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
Re: [Interest] qmake bug. Any workaround?
On Friday, 15 January 2021 06:54:25 PST Alexander Dyagilev wrote: > Is there one which can be used in a real project? Why is this ugly bug > not fixed yet (8 years has passed)? Because it's not a bug, it's an intentional feature. -- Thiago Macieira - thiago.macieira (AT) intel.com Software Architect - Intel DPG Cloud Engineering ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest
[Interest] qmake bug. Any workaround?
Hello, I am trying to create a .pro file to compile Microsoft Detours lib. Failed, it generates linker error: detours.obj:-1: error: LNK2019: unresolved external symbol DetourCopyInstruction referenced in function DetourAttachEx This function is defined in disasm.cpp in case there are no special defines existing. But, there are disolarm.cpp disolarm64.cpp disolia64.cpp disolx64.cpp disolx86.cpp sources which defines platform-depended definitions and then includes this disasm.cpp. E.g. disolarm.cpp contains of only these 2 lines of code: #define DETOURS_ARM_OFFLINE_LIBRARY #include "disasm.cpp" In this case disasm.cpp defines DetourCopyInstructionARM instead of DetourCopyInstruction. Qmake has the bug (https://bugreports.qt.io/browse/QTBUG-24906) which causes qmake to DROP disasm.cpp from SOURCES because it's included in these source files . Thus plain DetourCopyInstruction is not defined anywhere. If I replace #include "disasm.cpp" lines with file's content, all works fine. But this is not a workaround I want. Is there one which can be used in a real project? Why is this ugly bug not fixed yet (8 years has passed)? ___ Interest mailing list Interest@qt-project.org https://lists.qt-project.org/listinfo/interest