summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJose Fonseca <jfonseca@vmware.com>2016-04-18 11:47:07 +0100
committerJose Fonseca <jfonseca@vmware.com>2016-04-26 17:17:00 +0100
commit9a25c8af1b7fad0e7b3f3f3b4cbf6ae6e32e0e4d (patch)
treee10e148b80cb33316990f97f4bf4f81bd0264df3
parentc068610a7df370af94fd6177598a35c4425a75f9 (diff)
downloadexternal_mesa3d-9a25c8af1b7fad0e7b3f3f3b4cbf6ae6e32e0e4d.zip
external_mesa3d-9a25c8af1b7fad0e7b3f3f3b4cbf6ae6e32e0e4d.tar.gz
external_mesa3d-9a25c8af1b7fad0e7b3f3f3b4cbf6ae6e32e0e4d.tar.bz2
scons: Whenever possible decide what to do based on platform and not compiler.
Because compilers like GCC and Clang are effectively available everywhere so their presence/absence is seldom conclusive. Furthermore, all compilers we use now have stdint.h. Reviewed-by: Roland Scheidegger <sroland@vmware.com> Reviewed-by: Brian Paul <brianp@vmware.com>
-rw-r--r--src/gallium/drivers/svga/SConscript7
-rw-r--r--src/gallium/winsys/svga/drm/SConscript10
-rw-r--r--src/mapi/glapi/SConscript3
-rw-r--r--src/mesa/SConscript3
4 files changed, 9 insertions, 14 deletions
diff --git a/src/gallium/drivers/svga/SConscript b/src/gallium/drivers/svga/SConscript
index 0ee6246..aee337f 100644
--- a/src/gallium/drivers/svga/SConscript
+++ b/src/gallium/drivers/svga/SConscript
@@ -8,10 +8,9 @@ if env['suncc']:
print 'warning: not building svga'
Return()
-if env['gcc'] or env['clang']:
- env.Append(CPPDEFINES = [
- 'HAVE_STDINT_H',
- ])
+env.Append(CPPDEFINES = [
+ 'HAVE_STDINT_H',
+])
env.Prepend(CPPPATH = [
'include',
diff --git a/src/gallium/winsys/svga/drm/SConscript b/src/gallium/winsys/svga/drm/SConscript
index 2585053..2cb11e6 100644
--- a/src/gallium/winsys/svga/drm/SConscript
+++ b/src/gallium/winsys/svga/drm/SConscript
@@ -4,12 +4,10 @@ env = env.Clone()
env.PkgUseModules('DRM')
-if env['gcc'] or env['clang'] or env['icc']:
- env.Append(CCFLAGS = ['-fvisibility=hidden'])
- env.Append(CPPDEFINES = [
- 'HAVE_STDINT_H',
- '-D_FILE_OFFSET_BITS=64',
- ])
+env.Append(CPPDEFINES = [
+ 'HAVE_STDINT_H',
+ '-D_FILE_OFFSET_BITS=64',
+])
env.Prepend(CPPPATH = [
'#/src/gallium/drivers/svga',
diff --git a/src/mapi/glapi/SConscript b/src/mapi/glapi/SConscript
index 8ded46f..994778a 100644
--- a/src/mapi/glapi/SConscript
+++ b/src/mapi/glapi/SConscript
@@ -52,8 +52,7 @@ for s in mapi_sources:
#
# Assembly sources
#
-if (env['gcc'] or env['clang']) and \
- env['platform'] not in ('cygwin', 'darwin', 'windows'):
+if env['platform'] not in ('cygwin', 'darwin', 'windows'):
GLAPI = '#src/mapi/glapi/'
sources = [GLAPI + 'gen/gl_and_es_API.xml'] + env.Glob(GLAPI + 'gen/*.xml')
diff --git a/src/mesa/SConscript b/src/mesa/SConscript
index 5b80a21..7174101 100644
--- a/src/mesa/SConscript
+++ b/src/mesa/SConscript
@@ -82,8 +82,7 @@ format_unpack = env.CodeGenerate(
#
# Assembly sources
#
-if (env['gcc'] or env['clang']) and \
- env['platform'] not in ('cygwin', 'darwin', 'windows', 'haiku'):
+if env['platform'] not in ('cygwin', 'darwin', 'windows', 'haiku'):
if env['machine'] == 'x86':
env.Append(CPPDEFINES = [
'USE_X86_ASM',