lucy-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nwelln...@apache.org
Subject [lucy-commits] [2/2] git commit: Use cfc logfile as make target
Date Sun, 09 Mar 2014 11:56:51 GMT
Use cfc logfile as make target

This makes dependency checks more reliable.


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

Branch: refs/heads/master
Commit: 37d8cfcd307356566e6665d0855353e65fc50a69
Parents: af553f1
Author: Nick Wellnhofer <wellnhofer@aevum.de>
Authored: Sun Mar 9 12:54:35 2014 +0100
Committer: Nick Wellnhofer <wellnhofer@aevum.de>
Committed: Sun Mar 9 12:54:35 2014 +0100

----------------------------------------------------------------------
 runtime/common/charmonizer.c    | 15 +++++++--------
 runtime/common/charmonizer.main | 15 +++++++--------
 2 files changed, 14 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37d8cfcd/runtime/common/charmonizer.c
----------------------------------------------------------------------
diff --git a/runtime/common/charmonizer.c b/runtime/common/charmonizer.c
index 24fbedb..329499d 100644
--- a/runtime/common/charmonizer.c
+++ b/runtime/common/charmonizer.c
@@ -7151,6 +7151,8 @@ S_write_makefile(struct chaz_CLIArgs *args) {
                                            exe_ext, NULL);
     char *autogen_inc_dir = chaz_Util_join(dir_sep, "autogen", "include",
                                            NULL);
+    char *autogen_target  = chaz_Util_join(dir_sep, "autogen",
+                                           "hierarchy.json", NULL);
 
     chaz_MakeFile *makefile;
     chaz_MakeVar  *var;
@@ -7235,27 +7237,23 @@ S_write_makefile(struct chaz_CLIArgs *args) {
     rule = chaz_MakeFile_add_rule(makefile, cfc_exe, NULL);
     chaz_MakeRule_add_make_command(rule, cfc_dir, NULL);
 
-    rule = chaz_MakeFile_add_rule(makefile, "autogen", cfc_exe);
+    rule = chaz_MakeFile_add_rule(makefile, autogen_target, cfc_exe);
     chaz_MakeRule_add_prereq(rule, "$(CLOWNFISH_HEADERS)");
     scratch = chaz_Util_join("", cfc_exe, " --source=", core_dir,
                              " --dest=autogen --header=cfc_header", NULL);
     chaz_MakeRule_add_command(rule, scratch);
-    /* TODO: Find a way to touch the autogen directory on Windows. */
-    if (chaz_Make_shell_type() == CHAZ_OS_POSIX) {
-        chaz_MakeRule_add_command(rule, "touch autogen");
-    }
     free(scratch);
 
     /* Needed for parallel builds. */
     scratch = chaz_Util_join(dir_sep, "autogen", "source", "cfish_parcel.c",
                              NULL);
-    rule = chaz_MakeFile_add_rule(makefile, scratch, "autogen");
+    rule = chaz_MakeFile_add_rule(makefile, scratch, autogen_target);
     scratch = chaz_Util_join(dir_sep, "autogen", "source",
                              "testcfish_parcel.c", NULL);
-    rule = chaz_MakeFile_add_rule(makefile, scratch, "autogen");
+    rule = chaz_MakeFile_add_rule(makefile, scratch, autogen_target);
     free(scratch);
 
-    chaz_MakeFile_add_rule(makefile, "$(CLOWNFISH_OBJS)", "autogen");
+    chaz_MakeFile_add_rule(makefile, "$(CLOWNFISH_OBJS)", autogen_target);
 
     link_flags = chaz_CC_new_cflags();
     chaz_CFlags_enable_debugging(link_flags);
@@ -7334,6 +7332,7 @@ S_write_makefile(struct chaz_CLIArgs *args) {
     free(cfc_exe);
     free(test_cfish_exe);
     free(autogen_inc_dir);
+    free(autogen_target);
     free(lib_filename);
     free(test_command);
 }

http://git-wip-us.apache.org/repos/asf/lucy-clownfish/blob/37d8cfcd/runtime/common/charmonizer.main
----------------------------------------------------------------------
diff --git a/runtime/common/charmonizer.main b/runtime/common/charmonizer.main
index 5db08b1..e6b35a7 100644
--- a/runtime/common/charmonizer.main
+++ b/runtime/common/charmonizer.main
@@ -157,6 +157,8 @@ S_write_makefile(struct chaz_CLIArgs *args) {
                                            exe_ext, NULL);
     char *autogen_inc_dir = chaz_Util_join(dir_sep, "autogen", "include",
                                            NULL);
+    char *autogen_target  = chaz_Util_join(dir_sep, "autogen",
+                                           "hierarchy.json", NULL);
 
     chaz_MakeFile *makefile;
     chaz_MakeVar  *var;
@@ -241,27 +243,23 @@ S_write_makefile(struct chaz_CLIArgs *args) {
     rule = chaz_MakeFile_add_rule(makefile, cfc_exe, NULL);
     chaz_MakeRule_add_make_command(rule, cfc_dir, NULL);
 
-    rule = chaz_MakeFile_add_rule(makefile, "autogen", cfc_exe);
+    rule = chaz_MakeFile_add_rule(makefile, autogen_target, cfc_exe);
     chaz_MakeRule_add_prereq(rule, "$(CLOWNFISH_HEADERS)");
     scratch = chaz_Util_join("", cfc_exe, " --source=", core_dir,
                              " --dest=autogen --header=cfc_header", NULL);
     chaz_MakeRule_add_command(rule, scratch);
-    /* TODO: Find a way to touch the autogen directory on Windows. */
-    if (chaz_Make_shell_type() == CHAZ_OS_POSIX) {
-        chaz_MakeRule_add_command(rule, "touch autogen");
-    }
     free(scratch);
 
     /* Needed for parallel builds. */
     scratch = chaz_Util_join(dir_sep, "autogen", "source", "cfish_parcel.c",
                              NULL);
-    rule = chaz_MakeFile_add_rule(makefile, scratch, "autogen");
+    rule = chaz_MakeFile_add_rule(makefile, scratch, autogen_target);
     scratch = chaz_Util_join(dir_sep, "autogen", "source",
                              "testcfish_parcel.c", NULL);
-    rule = chaz_MakeFile_add_rule(makefile, scratch, "autogen");
+    rule = chaz_MakeFile_add_rule(makefile, scratch, autogen_target);
     free(scratch);
 
-    chaz_MakeFile_add_rule(makefile, "$(CLOWNFISH_OBJS)", "autogen");
+    chaz_MakeFile_add_rule(makefile, "$(CLOWNFISH_OBJS)", autogen_target);
 
     link_flags = chaz_CC_new_cflags();
     chaz_CFlags_enable_debugging(link_flags);
@@ -340,6 +338,7 @@ S_write_makefile(struct chaz_CLIArgs *args) {
     free(cfc_exe);
     free(test_cfish_exe);
     free(autogen_inc_dir);
+    free(autogen_target);
     free(lib_filename);
     free(test_command);
 }


Mime
View raw message