* Grunt work :) Use variables to set flags to ease futur modifications

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3146 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
gregory.hainaut 2010-06-03 15:12:29 +00:00
parent 00647fd299
commit 6055ca126b
15 changed files with 230 additions and 79 deletions

View File

@ -3,22 +3,33 @@
# plugin name
set(CDVDisoName CDVDiso)
set(CommonFlags
-Wall
-m32
-fpic
-fpermissive
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -m32 -g -fpic -fpermissive)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -m32 -O2 -fpic -fomit-frame-pointer -fpermissive)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -m32 -O2 -fpic -fomit-frame-pointer -fpermissive)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# CDVDiso sources

View File

@ -3,22 +3,35 @@
# plugin name
set(CDVDlinuzName CDVDlinuz)
set(CommonFlags
-Wall
-m32
-fPIC
-D_LARGEFILE64_SOURCE
)
set(OptimizationFlags
-O2
-DNDEBUG
-fomit-frame-pointer
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -m32 -g -fPIC -D_LARGEFILE64_SOURCE)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -m32 -O2 -fPIC -fomit-frame-pointer -D_LARGEFILE64_SOURCE -DNDEBUG)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -m32 -O2 -fPIC -fomit-frame-pointer -D_LARGEFILE64_SOURCE -DNDEBUG)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# CDVDlinuz sources

View File

@ -3,22 +3,32 @@
# plugin name
set(CDVDnullName CDVDnull)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# CDVDnull sources

View File

@ -3,22 +3,32 @@
# plugin name
set(FWnullName FWnull)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# FWnull sources

View File

@ -3,22 +3,33 @@
# plugin name
set(GSnullName GSnull)
set(CommonFlags
-Wall
-m32
-fPIC
-msse2
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2 -msse2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# GSnull sources

View File

@ -3,22 +3,32 @@
# plugin name
set(PadNullName PadNull)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# PadNull sources

View File

@ -3,22 +3,32 @@
# plugin name
set(SPU2nullName SPU2null)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# SPU2null sources

View File

@ -3,22 +3,32 @@
# plugin name
set(USBnullName USBnull)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# USBnull sources

View File

@ -3,22 +3,32 @@
# plugin name
set(dev9nullName dev9null)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# dev9null sources

View File

@ -3,22 +3,32 @@
# plugin name
set(onepadName onepad)
set(CommonFlags
-Wall
-m32
-fPIC
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# onepad sources

View File

@ -13,22 +13,33 @@ set(CMAKE_CXX_FLAGS_DEVEL "")
set(CMAKE_C_FLAGS_RELEASE "")
set(CMAKE_CXX_FLAGS_RELEASE "")
set(CommonFlags
-Wall
-m32
-FPIC
-msse2
)
set(OptimizationFlags
-DNDEBUG
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -DNDEBUG)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -DNDEBUG)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# spu2x sources

View File

@ -3,22 +3,31 @@
# plugin name
set(zerogsName zerogs)
set(CommonFlags
-Wall
-m32
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -m32 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -m32 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# zerogs sources

View File

@ -3,22 +3,34 @@
# plugin name
set(zeropadName zeropad)
set(CommonFlags
-Wall
-m32
-fpic
)
set(OptimizationFlags
-O2
-fomit-frame-pointer
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -m32 -g -fpic)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -m32 -O2 -fpic -fomit-frame-pointer)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -m32 -O2 -fpic -fomit-frame-pointer)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# zeropad sources

View File

@ -3,22 +3,33 @@
# plugin name
set(zerospu2Name zerospu2)
set(CommonFlags
-Wall
-m32
-fPIC
-msse2
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -g)
add_definitions(${CommonFlags} -g)
endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(-Wall -fPIC -m32 -msse2 -O2)
add_definitions(${CommonFlags} ${OptimizationFlags})
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# zerospu2 sources

View File

@ -31,6 +31,9 @@ set(CommonFlags
-DZEROGS_SSE2
)
set(OptimizationFlags
-O2
)
# Debug - Build
if(CMAKE_BUILD_TYPE STREQUAL Debug)
@ -41,13 +44,13 @@ endif(CMAKE_BUILD_TYPE STREQUAL Debug)
# Devel - Build
if(CMAKE_BUILD_TYPE STREQUAL Devel)
# add defines
add_definitions(${CommonFlags} -g -O2 -W -DZEROGS_DEVBUILD)
add_definitions(${CommonFlags} ${OptimizationFlags} -g -W -DZEROGS_DEVBUILD)
endif(CMAKE_BUILD_TYPE STREQUAL Devel)
# Release - Build
if(CMAKE_BUILD_TYPE STREQUAL Release)
# add defines
add_definitions(${CommonFlags} -O2 -W)
add_definitions(${CommonFlags} ${OptimizationFlags} -W)
endif(CMAKE_BUILD_TYPE STREQUAL Release)
# zzogl sources