make clean and build.xml updates Signed-off-by: Alain Dargelas <alainmarcel@yahoo.com>
diff --git a/Makefile b/Makefile index 2643191..2138ba2 100644 --- a/Makefile +++ b/Makefile
@@ -11,8 +11,9 @@ cd build; ../tests/regression.tcl mt=0 clean: - rm -rf build; - chmod -fR u+rwx dist; rm -rf dist; + rm -rf dist; + $(MAKE) -C build clean + rm -rf build install: cd build; make install
diff --git a/grammar/build.xml b/grammar/build.xml index 456e1c7..f217507 100644 --- a/grammar/build.xml +++ b/grammar/build.xml
@@ -24,7 +24,7 @@ <!-- set global properties for this build --> <property name="antlr_tool_location" - value="../antlr4/antlr4-4.7.2/tool/target/antlr4-4.7.2-complete.jar"/> + value="../third_party/antlr4/antlr4-4.7.2-complete.jar"/> <property name="antlr_tool_target" value="org.antlr.v4.Tool"/> <property name="antlr_test_rig" value="org.antlr.v4.gui.TestRig"/> <property name="sv_parser_grammar" value="SV3_1a"/> @@ -47,9 +47,9 @@ <target name="compile_cpp" depends="init" description="compile the Grammar files for C++"> <!-- Compile the G4 files for C++, only generates C++ files --> - <echo>Antlr Compile SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4 </echo> + <echo>Antlr Compile SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4 </echo> <java classpath="${antlr_tool_location}" classname="${antlr_tool_target}" fork="true" maxmemory="4096m" > - <arg line="${antlr_tool_cpp_options} SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> + <arg line="${antlr_tool_cpp_options} SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> </java> </target> @@ -58,30 +58,9 @@ <target name="compile_java" depends="init" description="Compile the Grammar files for Java for Testing purposes"> <!-- Compile the G4 files for Java target--> - <echo>Antlr Compile SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4</echo> + <echo>Antlr Compile SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4</echo> <java classpath="${antlr_tool_location}" classname="${antlr_tool_target}"> - <arg line=" SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> - </java> - - </target> - - <target name="compile_full_cpp" depends="init" - description="compile the Grammar files for C++"> - <!-- Compile the G4 files for C++, only generates C++ files --> - <echo>Antlr Compile SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4 </echo> - <java classpath="${antlr_tool_location}" classname="${antlr_tool_target}" fork="true" maxmemory="4096m" > - <arg line="${antlr_tool_cpp_options} SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> - </java> - - </target> - - - <target name="compile_full_java" depends="init" - description="Compile the Grammar files for Java for Testing purposes"> - <!-- Compile the G4 files for Java target--> - <echo>Antlr Compile SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4</echo> - <java classpath="${antlr_tool_location}" classname="${antlr_tool_target}"> - <arg line=" SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> + <arg line=" SV3_1aPpLexer.g4 SV3_1aPpParser.g4 SV3_1aLexer.g4 SV3_1aParser.g4 SV3_1aSplitterLexer.g4 SV3_1aSplitterParser.g4" /> </java> </target> @@ -95,27 +74,6 @@ fork="true"/> </target> - <target name="copy_cpp"> - <!-- Copy generated files to Project area --> - <copy todir="../SVIncCompil/parser/"> - <fileset dir="." includes="*.cpp *.h *.tokens"/> - </copy> - </target> - - <target name="copy_pp_cpp"> - <!-- Copy generated files to Project area --> - <copy todir="../SVIncCompil/parser/"> - <fileset dir="." includes="*Pp*.cpp *Pp*.h *Pp*.tokens"/> - </copy> - </target> - - <target name="copy_lib_cpp"> - <!-- Copy generated files to Project area --> - <copy todir="../SVIncCompil/parser/"> - <fileset dir="." includes="*Lib*.cpp *Lib*.h *Lib*.tokens"/> - </copy> - </target> - <target name="clean" description="clean up"> <!-- Delete the generated files: *.cpp, *.h, *.tokens *.java -->