I would like to create a project file that will work with both msvc and gcc.
In the examples for speed optimization, you do cl /O2 and g++ -O3 .
But I do not know how to tell the project file to make a difference. I would like something like:
msvc:QMAKE_CXXFLAGS_RELEASE += /O2 /openmp /arch:AVX else:QMAKE_CXXFLAGS_RELEASE += -O3 -march=native -fopenmp -D_GLIBCXX_PARALLEL
which does not work sadly.
Another way is to change mkspecs and associate new ones with my application, but it is not very portable. Thanks!
source share