aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mapi/glapi/SConscript
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2010-11-22 19:42:40 +0000
committermarha <marha@users.sourceforge.net>2010-11-22 19:42:40 +0000
commit85ef9930f56bf15181f9a0b238f03d55303cf411 (patch)
tree63b43286956ebd1c35c96e9b3d5305aabdf71a0f /mesalib/src/mapi/glapi/SConscript
parent94810d19989336862251dbf69c3f3acb18a9b06d (diff)
downloadvcxsrv-85ef9930f56bf15181f9a0b238f03d55303cf411.tar.gz
vcxsrv-85ef9930f56bf15181f9a0b238f03d55303cf411.tar.bz2
vcxsrv-85ef9930f56bf15181f9a0b238f03d55303cf411.zip
Updated to mesalib 7.9
Diffstat (limited to 'mesalib/src/mapi/glapi/SConscript')
-rw-r--r--mesalib/src/mapi/glapi/SConscript82
1 files changed, 82 insertions, 0 deletions
diff --git a/mesalib/src/mapi/glapi/SConscript b/mesalib/src/mapi/glapi/SConscript
new file mode 100644
index 000000000..40db237fc
--- /dev/null
+++ b/mesalib/src/mapi/glapi/SConscript
@@ -0,0 +1,82 @@
+#######################################################################
+# SConscript for glapi
+
+
+Import('*')
+
+if env['platform'] != 'winddk':
+
+ env = env.Clone()
+
+ env.Append(CPPDEFINES = [
+ 'MAPI_GLAPI_CURRENT',
+ ])
+
+ if env['platform'] == 'windows':
+ env.Append(CPPDEFINES = [
+ '_GDI32_', # prevent gl* being declared __declspec(dllimport) in MS headers
+ 'BUILD_GL32', # declare gl* as __declspec(dllexport) in Mesa headers
+ 'WIN32_THREADS', # use Win32 thread API
+ ])
+
+ env.Append(CPPPATH = [
+ '#/src/mapi',
+ '#/src/mesa',
+ ])
+
+ glapi_sources = [
+ 'glapi_dispatch.c',
+ 'glapi_entrypoint.c',
+ 'glapi_getproc.c',
+ 'glapi_nop.c',
+ 'glthread.c',
+ ]
+
+ mapi_sources = [
+ 'u_current.c',
+ 'u_execmem.c',
+ 'u_thread.c',
+ ]
+ for s in mapi_sources:
+ o = env.SharedObject(s[:-2], '../mapi/' + s)
+ glapi_sources.append(o)
+
+ #
+ # Assembly sources
+ #
+ if gcc and env['machine'] == 'x86':
+ env.Append(CPPDEFINES = [
+ 'USE_X86_ASM',
+ 'USE_MMX_ASM',
+ 'USE_3DNOW_ASM',
+ 'USE_SSE_ASM',
+ ])
+ glapi_sources += [
+ 'glapi_x86.S',
+ ]
+ elif gcc and env['machine'] == 'x86_64':
+ env.Append(CPPDEFINES = [
+ 'USE_X86_64_ASM',
+ ])
+ glapi_sources += [
+ 'glapi_x86-64.S'
+ ]
+ elif gcc and env['machine'] == 'ppc':
+ env.Append(CPPDEFINES = [
+ 'USE_PPC_ASM',
+ 'USE_VMX_ASM',
+ ])
+ glapi_sources += [
+ ]
+ elif gcc and env['machine'] == 'sparc':
+ glapi_sources += [
+ 'glapi_sparc.S'
+ ]
+ else:
+ pass
+
+ glapi = env.ConvenienceLibrary(
+ target = 'glapi',
+ source = glapi_sources,
+ )
+ Export('glapi')