title: Qt5, Visual Studio 2012 Express and OpenMp. How to?
body: <p>I am trying to compile <a href="http://www.kevinbeason.com/smallpt/" rel="nofollow">http://www.kevinbeason.com/smallpt/</a> raytracer using Qt5 and Visual Studio 2012 compiler.</p>
  
  <p>It works Okay but when I try to use openmp by adding</p>
  
  <pre><code>QMAKE_CXXFLAGS += -fopenmp
  LIBS += -fopenmp
  </code></pre>
  
  <p>to project.pro
  , Qt says that /fopenmp is not recognized and ignored.</p>
  
  <p>When I compile using VS command</p>
  
  <pre><code>cl /c /O2 /EHsc /openmp main.cpp
  </code></pre>
  
  <p>it works and I get a program 3 times faster then the one compiled from Qt.</p>
  
  <p>How to make Qt recognize openmp and how to enable the other optimizations in the command line?</p>
  
  <p>Thanks in advance.</p>