How do I generate preprocessor output on qt Creator ?
the standard -E option for mingw32 doesn't work.
thanks
How do I generate preprocessor output on qt Creator ?
the standard -E option for mingw32 doesn't work.
thanks
The -E option for gcc/g++ and does work quite happily in the MingW GCC compiler.
Adding -E to the QMAKE_CFLAGS and QMAKE_CXXFLAGS varaibles adds the -E option to the compiler calls. Something like:However, the way that the Makefile is written by qmake means that two things will happen:Qt Code:
QMAKE_CFLAGS = $$QMAKE_CFLAGS -E QMAKE_CXXFLAGS = $$QMAKE_CXXFLAGS -ETo copy to clipboard, switch view to plain text mode
- The preprocessed output will be captured into the object (.o) file
- The link will fail because the object file is actually a text file
Bookmarks