util: Move ralloc to a new src/util directory.

For a long time, we've wanted a place to put utility code which isn't
directly tied to Mesa or Gallium internals.  This patch creates a new
src/util directory for exactly that purpose, and builds the contents as
libmesautil.la.

ralloc seemed like a good first candidate.  These days, it's directly
used by mesa/main, i965, i915, and r300g, so keeping it in src/glsl
didn't make much sense.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>

v2 (Jason Ekstrand): More realloc uses and some scons fixes

Signed-off-by: Jason Ekstrand <jason.ekstrand@intel.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
Kenneth Graunke
2014-02-24 23:39:14 -08:00
committed by Jason Ekstrand
parent dcc29c18b4
commit 1e0da6233b
63 changed files with 181 additions and 57 deletions
+26
View File
@@ -0,0 +1,26 @@
import common
Import('*')
from sys import executable as python_cmd
env = env.Clone()
env.Prepend(CPPPATH = [
'#include',
'#src/mesa',
'#src/util',
])
# parse Makefile.sources
source_lists = env.ParseSourceList('Makefile.sources')
mesautil_sources = source_lists['MESA_UTIL_FILES']
mesautil = env.ConvenienceLibrary(
target = 'mesautil',
source = mesautil_sources,
)
env.Alias('mesautil', mesautil)
Export('mesautil')