Bug 52130

Summary: [PATCH] Fix compiling error in src/glsl/Makefile.am
Product: Mesa Reporter: Homer Hsing <homer.xing>
Component: OtherAssignee: mesa-dev
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: jon.turney
Version: git   
Hardware: All   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Homer Hsing 2012-07-16 02:58:34 UTC
glsl_lexer.cc has been renamed to glsl_lexer.cpp. Therefore Makefile.am should be updated. This patch fixes compiling error. 

diff --git a/src/glsl/Makefile.am b/src/glsl/Makefile.am
index d86153c..1a0219f 100644
--- a/src/glsl/Makefile.am
+++ b/src/glsl/Makefile.am
@@ -94,7 +94,7 @@ glsl_parser.cc glsl_parser.h: glsl_parser.yy
 	$(AM_V_GEN) $(YACC) -v -o glsl_parser.cc -p "_mesa_glsl_" --defines=glsl_parser.h $<
 
 BUILT_SOURCES = glsl_parser.h builtin_function.cpp
-CLEANFILES = glsl_lexer.cc glsl_parser.cc $(BUILT_SOURCES)
+CLEANFILES = glsl_lexer.cpp 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
Comment 1 Jon Turney 2012-07-16 11:25:43 UTC
(In reply to comment #0)
> glsl_lexer.cc has been renamed to glsl_lexer.cpp. 

Not intentionally.

> Therefore Makefile.am should be updated. This patch fixes compiling error. 

This patch only changes the name of a file in CLEANFILES.  There are plenty of other references to glsl_lexer.cc across the source.

Can you attach a build log which shows the failure?
Comment 2 Homer Hsing 2012-07-17 01:54:21 UTC
I was wrong. glsl_lexer.cc is automatically generated from src/glsl/glsl_lexer.ll 

I guess maybe glsl_lexer.cpp is generated in the past some time, causing the compiling error ... 

The latest code generates glsl_lexer.cc, and it compiles well. 

I suggest we close current bug report.
Comment 3 Kenneth Graunke 2012-07-17 06:43:31 UTC
Closing at the reporter's suggestion.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.