Author: bernhard
Date: Wed Aug 10 12:37:01 2005
New Revision: 8908

Modified:
   trunk/config/gen/makefiles/bc.in
   trunk/config/gen/makefiles/languages.in
Log:
Ignore build errors of 'bc' when doing 'make languages'.
Build Python runtime files for 'bc' only when calling 'make maintain'.

Thanks to Amir Karger for pointing out the problem.


Modified: trunk/config/gen/makefiles/bc.in
==============================================================================
--- trunk/config/gen/makefiles/bc.in    (original)
+++ trunk/config/gen/makefiles/bc.in    Wed Aug 10 12:37:01 2005
@@ -5,6 +5,12 @@
 PERL           = ${perl}
 RM_RF          = ${rm_rf}
 
+# The runtime files are also in SVN, need to be generated only by maintainer
+PYTHON_RUNTIME_FILES = \
+    python/lib/bc/BcLexer.py \
+    python/lib/bc/BcParser.py \
+    python/lib/bc/BcTreeWalker.py
+
 # the default target
 all: build 
 
@@ -15,6 +21,10 @@ help:
        @echo ""
        @echo "  all:               BcLexer.py and BcParser.py"
        @echo "                     This is the default."
+       @echo ""
+       @echo "  maintain:          Generate Python runtime files"
+       @echo "                     Needs ANTLR and Python"
+       @echo ""
        @echo "Testing:"
        @echo "  test:              Run the test suite."
        @echo ""
@@ -29,10 +39,13 @@ help:
 test: build
        cd .. && $(PERL) -I../lib -I bc/lib bc/t/harness --use-gnu-bc
 
-build: python/lib/bc/BcParser.py 
+build:
+# Nothing to do
+
+maintain: $(PYTHON_RUNTIME_FILES)
 
 # BcLexer.py will be created too
-python/lib/bc/BcParser.py: grammar/bc_python.g
+$(PYTHON_RUNTIME_FILES): grammar/bc_python.g
        antlr -o python/lib/bc grammar/bc_python.g
 
 clean:

Modified: trunk/config/gen/makefiles/languages.in
==============================================================================
--- trunk/config/gen/makefiles/languages.in     (original)
+++ trunk/config/gen/makefiles/languages.in     Wed Aug 10 12:37:01 2005
@@ -92,11 +92,11 @@ BASIC.clean:
 
 bc : bc.dummy
 bc.dummy:
-       $(MAKE_C) bc
+       - $(MAKE_C) bc
 bc.test:
-       $(MAKE_C) bc test
+       - $(MAKE_C) bc test
 bc.clean:
-       $(MAKE_C) bc clean
+       - $(MAKE_C) bc clean
 
 befunge : befunge.dummy
 befunge.dummy:

Reply via email to