c++ - linker ignores /openmp in qtcreator on windows -


when try compile openmp cpp file website, got link warning saying openmp flag ignored.

lnk4044:unrecognized option '/openmp'; ignored 

i have added these code pro. file

qmake_cxxflags+= -openmp qmake_lflags +=  -openmp 

or

qmake_cxxflags += -fopenmp libs += -fopenmp 

as suggeted other stack overflow questions.but not solve problem. can 1 me solve problem? using qt creator 3.1.2 msvc2013 compiler on windows 7.

msvc's linker not need or accept /openmp option. need option gcc (in case option -fopenmp). although use cmake qtcreator instead of qmake here sample last qmake file use.

msvc {   qmake_cxxflags += -openmp -arch:avx -d "_crt_secure_no_warnings"   qmake_cxxflags_release *= -o2 }  gcc {   qmake_cxxflags += -fopenmp -mavx -fabi-version=0 -ffast-math   qmake_lflags += -fopenmp   qmake_cxxflags_release *= -o3 } 

Comments

Popular posts from this blog

javascript - Jquery show_hide, what to add in order to make the page scroll to the bottom of the hidden field once button is clicked -

javascript - Highcharts multi-color line -

javascript - Enter key does not work in search box -