[Mesa-dev] [PATCH 5/8] build: Fix out-of-tree generation of builtin_function.cpp
Kenneth Graunke
kenneth at whitecape.org
Wed Aug 1 15:55:17 PDT 2012
On 08/01/2012 03:02 PM, Matt Turner wrote:
> ---
> I'm unsure about removing 'builtin/profiles/* ...' but they caused
> the build to fail if they were there.
>
> src/glsl/Makefile.am | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/glsl/Makefile.am b/src/glsl/Makefile.am
> index 0ab6672..c8c8f1c 100644
> --- a/src/glsl/Makefile.am
> +++ b/src/glsl/Makefile.am
> @@ -92,8 +92,8 @@ glsl_parser.cc glsl_parser.h: glsl_parser.yy
> BUILT_SOURCES = glsl_parser.h builtin_function.cpp
> CLEANFILES = glsl_lexer.cc glsl_parser.cc $(BUILT_SOURCES)
>
> -builtin_function.cpp: builtins/profiles/* builtins/ir/* builtins/glsl/* builtins/tools/generate_builtins.py builtins/tools/texture_builtins.py builtin_compiler$(EXEEXT)
> - $(AM_V_GEN) $(PYTHON2) $(PYTHON_FLAGS) builtins/tools/generate_builtins.py ./builtin_compiler > builtin_function.cpp || rm -f builtin_function.cpp
> +builtin_function.cpp: builtin_compiler$(EXEEXT)
> + $(AM_V_GEN) $(PYTHON2) $(PYTHON_FLAGS) $(srcdir)/builtins/tools/generate_builtins.py ./builtin_compiler > builtin_function.cpp || rm -f builtin_function.cpp
>
> glcpp/libglcpp.la:
> cd glcpp ; $(MAKE) $(AM_MAKEFLAGS)
As I mentioned on IRC, the idea here is to regenerate
builtin_function.cpp whenever any of the files in the
src/builtins/{profiles,ir,glsl} directories change. For example, if I
want to change abs(), I'd edit src/glsl/builtins/ir/abs.ir, and I'd want
that to cause a regen.
So, nak on this one, but the rest of the series gets a:
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
More information about the mesa-dev
mailing list