summaryrefslogtreecommitdiff
path: root/src/mesa/slang/library/SConscript
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2010-06-23 22:30:26 -0600
committerBrian Paul <brianp@vmware.com>2010-06-23 22:30:26 -0600
commitca12aefdacd22fb42e3f1d3852db4c12de886554 (patch)
treeb7462a02c678d3d755896c22a0f7f8387cb148c0 /src/mesa/slang/library/SConscript
parentf2122d47248e59a0f23c15d7f647d7e2072c8d79 (diff)
parentec2b92f98c2e7f161521b447cc1d9a36bce3707c (diff)
Merge branch 'shader-file-reorg'
1. Move all GL entrypoint functions and files into src/mesa/main/ This includes the ARB vp/vp, NV vp/fp, ATI fragshader and GLSL bits that were in src/mesa/shader/ 2. Move src/mesa/shader/slang/ to src/mesa/slang/ to reduce the tree depth 3. Rename src/mesa/shader/ to src/mesa/program/ since all the remaining files are concerned with GPU programs. 4. Misc code refactoring. In particular, I got rid of most of the GLSL-related ctx->Driver hook functions. None of the drivers used them. Conflicts: src/mesa/drivers/dri/i965/brw_context.c
Diffstat (limited to 'src/mesa/slang/library/SConscript')
-rw-r--r--src/mesa/slang/library/SConscript52
1 files changed, 52 insertions, 0 deletions
diff --git a/src/mesa/slang/library/SConscript b/src/mesa/slang/library/SConscript
new file mode 100644
index 0000000000..792a7953d3
--- /dev/null
+++ b/src/mesa/slang/library/SConscript
@@ -0,0 +1,52 @@
+#######################################################################
+# SConscript for GLSL builtin library
+
+Import('*')
+
+env = env.Clone()
+
+# See also http://www.scons.org/wiki/UsingCodeGenerators
+
+def glsl_compile_emitter(target, source, env):
+ env.Depends(target, glsl_compile)
+ return (target, source)
+
+bld_frag = Builder(
+ action = Action(glsl_compile[0].abspath + ' fragment $SOURCE $TARGET', '$CODEGENCODESTR'),
+ emitter = glsl_compile_emitter,
+ suffix = '.gc',
+ src_suffix = '_gc.h')
+
+bld_vert = Builder(
+ action = Action(glsl_compile[0].abspath + ' vertex $SOURCE $TARGET', '$CODEGENCODESTR'),
+ emitter = glsl_compile_emitter,
+ suffix = '.gc',
+ src_suffix = '_gc.h')
+
+env['BUILDERS']['bld_frag'] = bld_frag
+env['BUILDERS']['bld_vert'] = bld_vert
+
+# Generate GLSL builtin library binaries
+env.bld_frag(
+ '#src/mesa/slang/library/slang_core_gc.h',
+ '#src/mesa/slang/library/slang_core.gc')
+env.bld_frag(
+ '#src/mesa/slang/library/slang_common_builtin_gc.h',
+ '#src/mesa/slang/library/slang_common_builtin.gc')
+env.bld_frag(
+ '#src/mesa/slang/library/slang_fragment_builtin_gc.h',
+ '#src/mesa/slang/library/slang_fragment_builtin.gc')
+env.bld_vert(
+ '#src/mesa/slang/library/slang_vertex_builtin_gc.h',
+ '#src/mesa/slang/library/slang_vertex_builtin.gc')
+
+# Generate GLSL 1.20 builtin library binaries
+env.bld_frag(
+ '#src/mesa/slang/library/slang_120_core_gc.h',
+ '#src/mesa/slang/library/slang_120_core.gc')
+env.bld_frag(
+ '#src/mesa/slang/library/slang_builtin_120_common_gc.h',
+ '#src/mesa/slang/library/slang_builtin_120_common.gc')
+env.bld_frag(
+ '#src/mesa/slang/library/slang_builtin_120_fragment_gc.h',
+ '#src/mesa/slang/library/slang_builtin_120_fragment.gc')