From e2cb52becfcdd51a6228e9a58d3afd8828743d80 Mon Sep 17 00:00:00 2001 From: "gregory.hainaut@gmail.com" Date: Mon, 13 Sep 2010 15:26:04 +0000 Subject: [PATCH] cmake: * Link zz with libjpeg. Well it seems to get the library from another place, but better be safe for the future. * Use -pthread as a default option (again to be safer) * Warn about breaking of strict aliasing rule git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3761 96395faa-99c1-11dd-bbfe-3dabce05a288 --- cmake/BuildParameters.cmake | 4 ++-- pcsx2/CMakeLists.txt | 1 + plugins/zzogl-pg/opengl/CMakeLists.txt | 4 ++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/cmake/BuildParameters.cmake b/cmake/BuildParameters.cmake index a23bf175e2..a93fc98d79 100644 --- a/cmake/BuildParameters.cmake +++ b/cmake/BuildParameters.cmake @@ -99,7 +99,7 @@ if(DEFINED USER_CMAKE_C_FLAGS) string(STRIP "${USER_CMAKE_C_FLAGS}" CMAKE_C_FLAGS) endif(DEFINED USER_CMAKE_C_FLAGS) # Use some default machine flags -string(STRIP "${CMAKE_C_FLAGS} -m32 -msse -msse2 -march=i686" CMAKE_C_FLAGS) +string(STRIP "${CMAKE_C_FLAGS} -m32 -msse -msse2 -march=i686 -pthread" CMAKE_C_FLAGS) ### C++ flags @@ -110,7 +110,7 @@ if(DEFINED USER_CMAKE_CXX_FLAGS) string(STRIP "${USER_CMAKE_CXX_FLAGS}" CMAKE_CXX_FLAGS) endif(DEFINED USER_CMAKE_CXX_FLAGS) # Use some default machine flags -string(STRIP "${CMAKE_CXX_FLAGS} -m32 -msse -msse2 -march=i686" CMAKE_CXX_FLAGS) +string(STRIP "${CMAKE_CXX_FLAGS} -m32 -msse -msse2 -march=i686 -pthread" CMAKE_CXX_FLAGS) #------------------------------------------------------------------------------- # Select library system vs 3rdparty diff --git a/pcsx2/CMakeLists.txt b/pcsx2/CMakeLists.txt index 69214610c3..d3f9f9d370 100644 --- a/pcsx2/CMakeLists.txt +++ b/pcsx2/CMakeLists.txt @@ -14,6 +14,7 @@ set(CommonFlags -fno-dse -fno-tree-dse -fno-strict-aliasing + -Wstrict-aliasing # Allow to track strict aliasing issue. -pipe -Wno-format -Wno-unused-parameter diff --git a/plugins/zzogl-pg/opengl/CMakeLists.txt b/plugins/zzogl-pg/opengl/CMakeLists.txt index dd04766889..3d9c4e913b 100644 --- a/plugins/zzogl-pg/opengl/CMakeLists.txt +++ b/plugins/zzogl-pg/opengl/CMakeLists.txt @@ -14,6 +14,7 @@ set(CommonFlags -DZEROGS_SSE2 -fno-regmove -fno-strict-aliasing + -Wstrict-aliasing # Allow to track strict aliasing issue. -Wno-format -Wno-unused-parameter -Wno-unused-value @@ -156,6 +157,9 @@ target_link_libraries(${Output} ${OPENGL_LIBRARIES}) # link target with X11 target_link_libraries(${Output} ${X11_LIBRARIES}) +# link target with jpeg +target_link_libraries(${Output} ${JPEG_LIBRARIES}) + # User flags options if(NOT USER_CMAKE_LD_FLAGS STREQUAL "") target_link_libraries(${Output} "${USER_CMAKE_LD_FLAGS}")