Include swr library and include -DHAVE_SWR in the compile line.
v3: split to a separate commit
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
env.Append(CPPDEFINES = 'HAVE_LLVMPIPE')
drivers += [llvmpipe]
+ if env['swr']:
+ env.Append(CPPDEFINES = 'HAVE_SWR')
+ drivers += [swr]
+
if env['gcc'] and env['machine'] != 'x86_64':
# DEF parser in certain versions of MinGW is busted, as does not behave as
# MSVC. mingw-w64 works fine.
env.Append(CPPDEFINES = ['GALLIUM_LLVMPIPE'])
env.Prepend(LIBS = [llvmpipe])
+ if env['swr']:
+ env.Append(CPPDEFINES = 'HAVE_SWR')
+ env.Prepend(LIBS = [swr])
+
if env['platform'] != 'darwin':
# Disallow undefined symbols, except with Address Sanitizer, since libasan
# is not linked on shared libs, as it should be LD_PRELOAD'ed instead
env.Append(CPPDEFINES = 'GALLIUM_LLVMPIPE')
env.Prepend(LIBS = [llvmpipe])
+ if env['swr']:
+ env.Append(CPPDEFINES = 'HAVE_SWR')
+ env.Prepend(LIBS = [swr])
+
if env['platform'] == 'windows':
if env['gcc'] and env['machine'] != 'x86_64':
sources += ['osmesa.mingw.def']