waifulib: sdl2: allow override version if using conan(actually not planned to do so, just in case)

This commit is contained in:
Alibek Omarov 2019-10-18 02:58:34 +03:00
parent 03fb9aea38
commit 3f9dd8f72b

View File

@ -66,9 +66,14 @@ def configure(conf):
conf.env.HAVE_SDL2 = 0 conf.env.HAVE_SDL2 = 0
if not conf.env.HAVE_SDL2 and conf.env.CONAN: if not conf.env.HAVE_SDL2 and conf.env.CONAN:
if not conf.env.SDL2_VERSION:
version = '2.0.10'
else:
version = conf.env.SDL2_VERSION
conf.load('conan') conf.load('conan')
conf.add_conan_remote('bincrafters', 'https://api.bintray.com/conan/bincrafters/public-conan') conf.add_conan_remote('bincrafters', 'https://api.bintray.com/conan/bincrafters/public-conan')
conf.add_dependency('sdl2/2.0.9@bincrafters/stable', options = { 'shared': 'True' } ) conf.add_dependency('sdl2/%s@bincrafters/stable' % version, options = { 'shared': 'True' } )
if conf.env.HAVE_SDL2 and conf.options.SDL2_SANITY_CHECK: if conf.env.HAVE_SDL2 and conf.options.SDL2_SANITY_CHECK:
try: try: