summaryrefslogtreecommitdiff
path: root/src/gallium/targets/graw-xlib
diff options
context:
space:
mode:
authorJosé Fonseca <jfonseca@vmware.com>2010-11-01 13:30:22 +0000
committerJosé Fonseca <jfonseca@vmware.com>2010-11-01 13:30:22 +0000
commit601498ae73e654c2de997ea75075613a694d604d (patch)
treefb1eb85143f5222b3c4b4d059276095e658506f5 /src/gallium/targets/graw-xlib
parenta84bd587c68a48c675aae538934a0de48421ff08 (diff)
scons: Revamp how to specify targets to build.
Use scons target and dependency system instead of ad-hoc options. Now is simply a matter of naming what to build. For example: scons libgl-xlib scons libgl-gdi scons graw-progs scons llvmpipe and so on. And there is also the possibility of scepcified subdirs, e.g. scons src/gallium/drivers If nothing is specified then everything will be build. There might be some rough corners over the next days. Please bare with me.
Diffstat (limited to 'src/gallium/targets/graw-xlib')
-rw-r--r--src/gallium/targets/graw-xlib/SConscript19
-rw-r--r--src/gallium/targets/graw-xlib/graw_util.c50
2 files changed, 5 insertions, 64 deletions
diff --git a/src/gallium/targets/graw-xlib/SConscript b/src/gallium/targets/graw-xlib/SConscript
index 21fce948f4..f795309787 100644
--- a/src/gallium/targets/graw-xlib/SConscript
+++ b/src/gallium/targets/graw-xlib/SConscript
@@ -3,13 +3,8 @@
Import('*')
-if env['platform'] != 'linux':
- Return()
-
env = env.Clone()
-env.Tool('x11')
-
env.Prepend(LIBS = [
ws_xlib,
trace,
@@ -18,26 +13,24 @@ env.Prepend(LIBS = [
# gallium,
])
+env.Prepend(LIBS = env['X11_LIBS'])
+
env.Append(CPPPATH = [
'#src/gallium/drivers',
'#src/gallium/include/state_tracker',
])
-
sources = [
'graw_xlib.c',
- 'graw_util.c',
+ graw_util
]
-env.Tool('x11')
-
if True:
env.Append(CPPDEFINES = 'GALLIUM_SOFTPIPE')
env.Prepend(LIBS = [softpipe])
if env['llvm']:
env.Append(CPPDEFINES = 'GALLIUM_LLVMPIPE')
- env.Tool('udis86')
env.Prepend(LIBS = [llvmpipe])
# Need this for trace, identity drivers referenced by
@@ -51,8 +44,6 @@ graw = env.SharedLibrary(
source = sources,
)
-env.InstallSharedLibrary(graw, version=(1, 0))
-
-graw = env.FindIxes(graw, 'SHLIBPREFIX', 'SHLIBSUFFIX')
+graw = env.InstallSharedLibrary(graw, version=(1, 0))
-Export('graw')
+env.Alias('graw-xlib', graw)
diff --git a/src/gallium/targets/graw-xlib/graw_util.c b/src/gallium/targets/graw-xlib/graw_util.c
deleted file mode 100644
index fc7c9ae6f9..0000000000
--- a/src/gallium/targets/graw-xlib/graw_util.c
+++ /dev/null
@@ -1,50 +0,0 @@
-
-#include "pipe/p_compiler.h"
-#include "pipe/p_context.h"
-#include "pipe/p_state.h"
-#include "tgsi/tgsi_text.h"
-#include "util/u_memory.h"
-#include "state_tracker/graw.h"
-
-
-/* Helper functions. These are the same for all graw implementations.
- */
-void *graw_parse_geometry_shader(struct pipe_context *pipe,
- const char *text)
-{
- struct tgsi_token tokens[1024];
- struct pipe_shader_state state;
-
- if (!tgsi_text_translate(text, tokens, Elements(tokens)))
- return NULL;
-
- state.tokens = tokens;
- return pipe->create_gs_state(pipe, &state);
-}
-
-void *graw_parse_vertex_shader(struct pipe_context *pipe,
- const char *text)
-{
- struct tgsi_token tokens[1024];
- struct pipe_shader_state state;
-
- if (!tgsi_text_translate(text, tokens, Elements(tokens)))
- return NULL;
-
- state.tokens = tokens;
- return pipe->create_vs_state(pipe, &state);
-}
-
-void *graw_parse_fragment_shader(struct pipe_context *pipe,
- const char *text)
-{
- struct tgsi_token tokens[1024];
- struct pipe_shader_state state;
-
- if (!tgsi_text_translate(text, tokens, Elements(tokens)))
- return NULL;
-
- state.tokens = tokens;
- return pipe->create_fs_state(pipe, &state);
-}
-