Difference between revisions of "Opencv"

From AIRWiki
Jump to: navigation, search
(How to compile)
(How to compile)
 
Line 8: Line 8:
 
   instead of  
 
   instead of  
 
     set(EXTRA_C_FLAGS_RELEASE "${EXTRA_C_FLAGS_RELEASE} -mfpmath=387")
 
     set(EXTRA_C_FLAGS_RELEASE "${EXTRA_C_FLAGS_RELEASE} -mfpmath=387")
 +
  and at line 950
 +
                set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -march=native -mtune=native")
 +
            MESSAGE(EDIT:: -march=native -mtune=native)
 +
 +
  instead of  set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -march=i686")

Latest revision as of 10:45, 6 June 2011

How to compile

in cmake-gui select these options
- run cat /proc/cpuinfo and check which "sse" options are supported. Check them in cmake file
- edit the CMakeLists.txt file and at line 1007 put these lines

               set(EXTRA_C_FLAGS_RELEASE "${EXTRA_C_FLAGS_RELEASE} -mfpmath=sse")

MESSAGE(EDIT:: mfpmath=sse)

 instead of 
   set(EXTRA_C_FLAGS_RELEASE "${EXTRA_C_FLAGS_RELEASE} -mfpmath=387")
 and at line 950 
               set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -march=native -mtune=native")
           	MESSAGE(EDIT:: -march=native -mtune=native)
  instead of  set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -march=i686")