[Mesa-dev] [PATCH] swr: add linux to scons build
Kyriazis, George
george.kyriazis at intel.com
Fri Apr 14 18:23:25 UTC 2017
On Apr 14, 2017, at 12:44 PM, Emil Velikov <emil.l.velikov at gmail.com<mailto:emil.l.velikov at gmail.com>> wrote:
On 13 April 2017 at 20:17, George Kyriazis <george.kyriazis at intel.com<mailto:george.kyriazis at intel.com>> wrote:
Make swr compile for both linux and windows.
---
src/gallium/drivers/swr/SConscript | 7 +------
src/gallium/targets/libgl-xlib/SConscript | 2 +-
2 files changed, 2 insertions(+), 7 deletions(-)
diff --git a/src/gallium/drivers/swr/SConscript b/src/gallium/drivers/swr/SConscript
index eca5dba..5e3784b 100644
--- a/src/gallium/drivers/swr/SConscript
+++ b/src/gallium/drivers/swr/SConscript
@@ -17,11 +17,6 @@ if env['LLVM_VERSION'] < distutils.version.LooseVersion('3.9'):
env['swr'] = False
Return()
-if env['platform'] != 'windows':
- print "warning: swr scons build only supports windows: not building swr"
- env['swr'] = False
- Return()
-
env.MSVC2013Compat()
env = env.Clone()
@@ -205,7 +200,7 @@ envavx2.Append(CPPDEFINES = ['KNOB_ARCH=KNOB_ARCH_AVX2'])
if env['platform'] == 'windows':
envavx2.Append(CCFLAGS = ['/arch:AVX2'])
else:
- envavx2.Append(CCFLAGS = ['-mavx2'])
+ envavx2.Append(CCFLAGS = ['-mavx2', '-mfma', '-mbmi2', '-mf16c'])
swrAVX2 = envavx2.SharedLibrary(
target = 'swrAVX2',
diff --git a/src/gallium/targets/libgl-xlib/SConscript b/src/gallium/targets/libgl-xlib/SConscript
index d01bb3c..a81ac79 100644
--- a/src/gallium/targets/libgl-xlib/SConscript
+++ b/src/gallium/targets/libgl-xlib/SConscript
@@ -49,7 +49,7 @@ if env['llvm']:
env.Prepend(LIBS = [llvmpipe])
if env['swr']:
- env.Append(CPPDEFINES = 'HAVE_SWR')
+ env.Append(CPPDEFINES = 'GALLIUM_SWR')
Seems like we want the same fix in src/gallium/targets/osmesa/SConscript.
Please squash that alongside a small note in docs/relnotes/17.1.0.html
Checkin is already submitted, so I’ll make a foliow-up commit with those changes.
With the above
Reviewed-by: Emil Velikov <emil.velikov at collabora.com<mailto:emil.velikov at collabora.com>>
As a follow-up commit can we have $sed -i s/HAVE_/GALLIUM_
src/gallium/targets/libgl-xlib/* && git commit -asm “…”
Yes, I want to fix this, too, and I was planning on doing it on a later commit.
Thanks,
George
Thanks
Emil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170414/687fa799/attachment-0001.html>
More information about the mesa-dev
mailing list