lucy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nwelln...@apache.org
Subject [lucy-commits] [6/8] git commit: refs/heads/c-bindings-cfc - Compile lemon directly from CFC Makefile
Date Tue, 12 Feb 2013 20:11:52 GMT
Compile lemon directly from CFC Makefile


Project: http://git-wip-us.apache.org/repos/asf/lucy/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucy/commit/a4d59e20
Tree: http://git-wip-us.apache.org/repos/asf/lucy/tree/a4d59e20
Diff: http://git-wip-us.apache.org/repos/asf/lucy/diff/a4d59e20

Branch: refs/heads/c-bindings-cfc
Commit: a4d59e2042a5cfaf84d9c203603946a64d312222
Parents: 7e2a4ef
Author: Nick Wellnhofer <wellnhofer@aevum.de>
Authored: Tue Feb 12 20:44:14 2013 +0100
Committer: Nick Wellnhofer <wellnhofer@aevum.de>
Committed: Tue Feb 12 21:10:23 2013 +0100

----------------------------------------------------------------------
 clownfish/compiler/common/charmonizer.main |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy/blob/a4d59e20/clownfish/compiler/common/charmonizer.main
----------------------------------------------------------------------
diff --git a/clownfish/compiler/common/charmonizer.main b/clownfish/compiler/common/charmonizer.main
index e8b6f28..4e9b028 100644
--- a/clownfish/compiler/common/charmonizer.main
+++ b/clownfish/compiler/common/charmonizer.main
@@ -132,9 +132,6 @@ S_write_makefile() {
     chaz_MakeFile_add_var(makefile, "EXE_EXT", exe_ext);
     chaz_MakeFile_add_var(makefile, "OBJ_EXT", obj_ext);
 
-    chaz_MakeFile_add_var(makefile, "LEMON_EXE",
-                          "$(LEMON_DIR)" DIR_SEP "lemon$(EXE_EXT)");
-
     chaz_MakeFile_add_var(makefile, "CC", chaz_CC_get_cc());
 
     chaz_CC_set_optimization_level("2");
@@ -146,6 +143,9 @@ S_write_makefile() {
     chaz_MakeVar_append(var, chaz_CC_get_cflags());
     chaz_MakeVar_append(var, chaz_CC_get_extra_cflags());
 
+    chaz_MakeFile_add_var(makefile, "LEMON_OBJS",
+                          "$(LEMON_DIR)" DIR_SEP "lemon$(OBJ_EXT)");
+
     sfc.common_objs   = chaz_MakeFile_add_var(makefile, "COMMON_OBJS", NULL);
     sfc.test_cfc_objs = chaz_MakeFile_add_var(makefile, "TEST_CFC_OBJS", NULL);
 
@@ -156,6 +156,9 @@ S_write_makefile() {
     chaz_MakeVar_append(sfc.test_cfc_objs, "t" DIR_SEP "test_cfc$(OBJ_EXT)");
 
     chaz_MakeFile_add_var(makefile, "CFC_OBJS", "cfc$(OBJ_EXT)");
+
+    chaz_MakeFile_add_var(makefile, "LEMON_EXE",
+                          "$(LEMON_DIR)" DIR_SEP "lemon$(EXE_EXT)");
     chaz_MakeFile_add_var(makefile, "CFC_EXE", "cfc$(EXE_EXT)");
     chaz_MakeFile_add_var(makefile, "TEST_CFC_EXE",
                           "t" DIR_SEP "test_cfc$(EXE_EXT)");
@@ -164,8 +167,7 @@ S_write_makefile() {
 
     chaz_MakeFile_add_rule(makefile, "all", "$(CFC_EXE)");
 
-    rule = chaz_MakeFile_add_rule(makefile, "$(LEMON_EXE)", NULL);
-    chaz_MakeRule_add_command_make(rule, "$(LEMON_DIR)", NULL);
+    chaz_MakeFile_add_exe(makefile, "$(LEMON_EXE)", "$(LEMON_OBJS)");
 
     rule = chaz_MakeFile_add_rule(makefile, parse_header_c, NULL);
     chaz_MakeRule_add_prereq(rule, "$(LEMON_EXE)");
@@ -185,6 +187,7 @@ S_write_makefile() {
     rule = chaz_MakeFile_add_rule(makefile, "test", "$(TEST_CFC_EXE)");
     chaz_MakeRule_add_command(rule, "$(TEST_CFC_EXE)");
 
+    chaz_MakeFile_add_to_cleanup(makefile, "$(LEMON_OBJS)");
     chaz_MakeFile_add_to_cleanup(makefile, "$(COMMON_OBJS)");
     chaz_MakeFile_add_to_cleanup(makefile, "$(CFC_OBJS)");
     chaz_MakeFile_add_to_cleanup(makefile, "$(TEST_CFC_OBJS)");


Mime
View raw message