1
0
forked from 0ad/0ad

Use SDL2 by default everywhere.

SDL1 can still be forced passing --sdl1 to update-workspaces.sh.
Eventually, if no blocking issues arise, SDL1 support could be dropped
after next release.

This was SVN commit r16586.
This commit is contained in:
fabio 2015-04-27 08:49:16 +00:00
parent 487d6a1afc
commit 502e1a3960
3 changed files with 13 additions and 14 deletions

View File

@ -585,16 +585,16 @@ extern_lib_defs = {
includedirs { libraries_dir .. "sdl2/include/SDL" }
elseif not _OPTIONS["android"] then
-- Support SDL*_CONFIG for overriding the default PATH-based sdl*-config
if _OPTIONS["sdl2"] then
sdl_config_path = os.getenv("SDL2_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl2-config"
end
else
if _OPTIONS["sdl1"] then
sdl_config_path = os.getenv("SDL_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl-config"
end
else
sdl_config_path = os.getenv("SDL2_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl2-config"
end
end
pkgconfig_cflags(nil, sdl_config_path.." --cflags")
@ -604,16 +604,16 @@ extern_lib_defs = {
if os.is("windows") then
add_default_lib_paths("sdl2")
elseif not _OPTIONS["android"] then
if _OPTIONS["sdl2"] then
sdl_config_path = os.getenv("SDL2_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl2-config"
end
else
if _OPTIONS["sdl1"] then
sdl_config_path = os.getenv("SDL_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl-config"
end
else
sdl_config_path = os.getenv("SDL2_CONFIG")
if not sdl_config_path then
sdl_config_path = "sdl2-config"
end
end
pkgconfig_libs(nil, sdl_config_path.." --libs")
end

View File

@ -7,7 +7,7 @@ newoption { trigger = "icc", description = "Use Intel C++ Compiler (Linux only;
newoption { trigger = "jenkins-tests", description = "Configure CxxTest to use the XmlPrinter runner which produces Jenkins-compatible output" }
newoption { trigger = "minimal-flags", description = "Only set compiler/linker flags that are really needed. Has no effect on Windows builds" }
newoption { trigger = "outpath", description = "Location for generated project files" }
newoption { trigger = "sdl2", description = "Experimental build using SDL 2" }
newoption { trigger = "sdl1", description = "Build using deprecated SDL 1.2" }
newoption { trigger = "with-system-mozjs31", description = "Search standard paths for libmozjs31, instead of using bundled copy" }
newoption { trigger = "with-system-nvtt", description = "Search standard paths for nvidia-texture-tools library, instead of using bundled copy" }
newoption { trigger = "without-audio", description = "Disable use of OpenAL/Ogg/Vorbis APIs" }

View File

@ -66,7 +66,6 @@ cd "$(dirname $0)"
# Now in build/workspaces/ (where we assume this script resides)
if [ "`uname -s`" = "Darwin" ]; then
premake_args="${premake_args} --sdl2"
# Set *_CONFIG variables on OS X, to override the path to e.g. sdl2-config
export GLOOX_CONFIG=${GLOOX_CONFIG:="$(pwd)/../../libraries/osx/gloox/bin/gloox-config"}
export ICU_CONFIG=${ICU_CONFIG:="$(pwd)/../../libraries/osx/icu/bin/icu-config"}