* new dev option CMAKE_BUILD_PO: control regeneration of po file. By default true in release build
* Add a hack for multiarch version of wxwidget 


git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4951 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
gregory.hainaut 2011-10-31 10:25:24 +00:00
parent d398e19b4d
commit c9b1e3c1aa
7 changed files with 45 additions and 22 deletions

View File

@ -1,6 +1,7 @@
### Select the build type
# Use Release/Devel/Debug : -DCMAKE_BUILD_TYPE=Release|Devel|Debug
# Use Release/Devel/Debug : -DCMAKE_BUILD_TYPE=Release|Devel|Debug
# Enable/disable the stripping : -DCMAKE_BUILD_STRIP=TRUE|FALSE
# generation .po based on src : -DCMAKE_BUILD_PO=TRUE|FALSE
### Force the choice of 3rd party library in pcsx2 over system libraries
# Use all internal lib: -DFORCE_INTERNAL_ALL=TRUE
@ -29,7 +30,6 @@ if(NOT CMAKE_BUILD_TYPE MATCHES "Debug|Devel|Release")
message(STATUS "BuildType set to ${CMAKE_BUILD_TYPE} by default")
endif(NOT CMAKE_BUILD_TYPE MATCHES "Debug|Devel|Release")
# Set default strip option. Can be set with -DCMAKE_BUILD_STRIP=TRUE/FALSE
if(NOT DEFINED CMAKE_BUILD_STRIP)
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set(CMAKE_BUILD_STRIP TRUE)
@ -40,6 +40,16 @@ if(NOT DEFINED CMAKE_BUILD_STRIP)
endif(CMAKE_BUILD_TYPE STREQUAL "Release")
endif(NOT DEFINED CMAKE_BUILD_STRIP)
if(NOT DEFINED CMAKE_BUILD_PO)
if(CMAKE_BUILD_TYPE STREQUAL "Release")
set(CMAKE_BUILD_PO TRUE)
message(STATUS "Enable the building of po files by default in ${CMAKE_BUILD_TYPE} build !!!")
else(CMAKE_BUILD_TYPE STREQUAL "Release")
set(CMAKE_BUILD_PO FALSE)
message(STATUS "Disable the building of po files by default in ${CMAKE_BUILD_TYPE} build !!!")
endif(CMAKE_BUILD_TYPE STREQUAL "Release")
endif(NOT DEFINED CMAKE_BUILD_PO)
#-------------------------------------------------------------------------------
# Select library system vs 3rdparty
#-------------------------------------------------------------------------------

View File

@ -185,6 +185,8 @@ if(wxWidgets_FOUND)
if (EXISTS "/usr/lib/wx")
STRING(REGEX REPLACE "/usr/lib64/wx" "/usr/lib/wx" wxWidgets_INCLUDE_DIRS "${wxWidgets_INCLUDE_DIRS}")
endif (EXISTS "/usr/lib/wx")
# Multiarch ubuntu/debian
STRING(REGEX REPLACE "/usr/lib/x86_64-linux-gnu" "/usr/lib/i386-linux-gnu" wxWidgets_INCLUDE_DIRS "${wxWidgets_INCLUDE_DIRS}")
endif(CMAKE_SIZEOF_VOID_P MATCHES "8")
endif(Linux)

View File

@ -66,7 +66,9 @@ endif(Linux AND NOT GTK2_FOUND)
#---------------------------------------
# CDVDnull
#---------------------------------------
set(CDVDnull TRUE)
if(GTK2_FOUND)
set(CDVDnull TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
@ -91,19 +93,25 @@ set(CDVDlinuz TRUE)
#---------------------------------------
# dev9null
#---------------------------------------
set(dev9null TRUE)
if(GTK2_FOUND)
set(dev9null TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
# FWnull
#---------------------------------------
set(FWnull TRUE)
if(GTK2_FOUND)
set(FWnull TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
# GSnull
#---------------------------------------
set(GSnull TRUE)
if(GTK2_FOUND)
set(GSnull TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
@ -161,7 +169,9 @@ endif(GLEW_FOUND AND OPENGL_FOUND AND X11_FOUND AND CG_FOUND AND JPEG_FOUND AND
#---------------------------------------
# PadNull
#---------------------------------------
set(PadNull TRUE)
if(GTK2_FOUND)
set(PadNull TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
@ -195,7 +205,9 @@ endif(SDL_FOUND)
#---------------------------------------
# SPU2null
#---------------------------------------
set(SPU2null TRUE)
if(GTK2_FOUND)
set(SPU2null TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#---------------------------------------
@ -234,7 +246,9 @@ endif(SOUNDTOUCH_FOUND AND ALSA_FOUND)
#---------------------------------------
# USBnull
#---------------------------------------
set(USBnull TRUE)
if(GTK2_FOUND)
set(USBnull TRUE)
endif(GTK2_FOUND)
#---------------------------------------
#-------------------------------------------------------------------------------

View File

@ -53,10 +53,16 @@ MACRO(GETTEXT_CREATE_TRANSLATIONS_PCSX2 _potFile _firstPoFileArg)
GET_FILENAME_COMPONENT(_lang ${_abs_PATH} NAME_WE)
SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_lang}__${_gmoBase}.gmo)
ADD_CUSTOM_COMMAND( OUTPUT ${_gmoFile}
COMMAND ${GETTEXT_MSGMERGE_EXECUTABLE} --quiet --update --backup=none -s ${_absFile} ${_absPotFile}
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile} ${_absFile}
DEPENDS ${_absPotFile} ${_absFile} )
IF (CMAKE_BUILD_PO)
ADD_CUSTOM_COMMAND( OUTPUT ${_gmoFile}
COMMAND ${GETTEXT_MSGMERGE_EXECUTABLE} --quiet --update --backup=none -s ${_absFile} ${_absPotFile}
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile} ${_absFile}
DEPENDS ${_absPotFile} ${_absFile} )
ELSE (CMAKE_BUILD_PO)
ADD_CUSTOM_COMMAND( OUTPUT ${_gmoFile}
COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} -o ${_gmoFile} ${_absFile}
DEPENDS ${_absPotFile} ${_absFile} )
ENDIF (CMAKE_BUILD_PO)
IF (PACKAGE_MODE)
INSTALL(FILES ${_gmoFile} DESTINATION share/locale/${_lang}/LC_MESSAGES RENAME ${_potBasename}.mo)

View File

@ -18,9 +18,6 @@ set(CommonFlags
-fno-strict-aliasing
-fno-tree-dse
-pipe
-Wno-format
-Wno-unused-parameter
-Wno-unused-value
-Wunused-variable)
# set warning flags

View File

@ -18,9 +18,6 @@ set(CommonFlags
-fno-tree-dse
-fno-strict-aliasing
-pipe
-Wno-format
-Wno-unused-parameter
-Wno-unused-value
-Wunused-variable)
# set warning flags

View File

@ -15,9 +15,6 @@ set(CommonFlags
-fno-regmove
-fno-strict-aliasing
-Wstrict-aliasing # Allow to track strict aliasing issue.
-Wno-format
-Wno-unused-parameter
-Wno-unused-value
-Wunused-variable
)