summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Huston <shuston@riverace.com>2011-05-12 18:15:09 +0000
committerSteve Huston <shuston@riverace.com>2011-05-12 18:15:09 +0000
commite2ea427ea2828daff69d160638707e9b59c13dbf (patch)
tree474969402e0ab2840cfbd541654d73b748299870
parentf583dfe2713b4b5875ea42db08798699d4b9aa61 (diff)
downloadATCD-e2ea427ea2828daff69d160638707e9b59c13dbf.tar.gz
ChangeLogTag:Thu May 12 18:08:47 UTC 2011 Steve Huston <shuston@riverace.com>
-rw-r--r--ChangeLog12
-rw-r--r--include/makeinclude/rules.local.GNU6
-rw-r--r--include/makeinclude/wrapper_macros.GNU7
3 files changed, 25 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index cfba2a3379c..ab34a698c61 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+Thu May 12 18:08:47 UTC 2011 Steve Huston <shuston@riverace.com>
+
+ * include/makeinclude/wrapper_macros.GNU: Added command settings for
+ preprocessing C and C++ source files.
+
+ * include/makeinclude/rules.local.GNU: Added rules to preprocess
+ C and C++ files when directed.
+
+ These allow one to now quickly produce a preprocessed version of
+ a source file. Ala... make -f GNUmakefile.ACE ACE.i
+ would preprocess ACE.cpp and put the result in ACE.i.
+
Fri Apr 29 14:01:29 UTC 2011 Steve Huston <shuston@riverace.com>
* tests/tests.mpc: For Message_Queue_Test add -bmaxdata:0x20000000 to
diff --git a/include/makeinclude/rules.local.GNU b/include/makeinclude/rules.local.GNU
index b32dab24548..0a675296620 100644
--- a/include/makeinclude/rules.local.GNU
+++ b/include/makeinclude/rules.local.GNU
@@ -106,6 +106,12 @@ endif
nullstring :=
CC_OUTPUT_FLAG_SEP ?= $(nullstring) #space
+%.$(PREPROCESS_SUFFIX): %.c
+ $(PREPROCESS.c) $(CC_OUTPUT_FLAG)$(CC_OUTPUT_FLAG_SEP)$@ $<
+
+%.$(PREPROCESS_SUFFIX): %.cpp
+ $(PREPROCESS.cc) $(CC_OUTPUT_FLAG)$(CC_OUTPUT_FLAG_SEP)$@ $<
+
$(VDIR)%.$(OBJEXT): %.c
$(mk_obj_out_dir)
$(COMPILE.c) $(CC_OUTPUT_FLAG)$(CC_OUTPUT_FLAG_SEP)$@ $<
diff --git a/include/makeinclude/wrapper_macros.GNU b/include/makeinclude/wrapper_macros.GNU
index 52e76c8b422..f86b0a6bdf7 100644
--- a/include/makeinclude/wrapper_macros.GNU
+++ b/include/makeinclude/wrapper_macros.GNU
@@ -157,6 +157,9 @@
# PLATFORM_SCTP_LIBS
# Platform libraries required for SCTP
# PRELINK Executable to precede linking, such as quantify
+# PREPROCESS.c Command to preprocess C
+# PREPROCESS.cc
+# Command to preprocess C++
# PURELINK If set, contains purify executable as well as all options
# PURE_CACHE_BASE_DIR
# The base directory in which Pure products will produce
@@ -923,9 +926,13 @@ POSTLINK ?=
PURELINK ?=
TEMPLATES_FLAG ?=
MVCMD ?=
+PREPROCESS_OPT ?= -E
+PREPROCESS_SUFFIX ?= i
COMPILE.c = $(CC) $(CFLAGS) $(CPPFLAGS) -c
COMPILE.cc = $(CXX) $(CCFLAGS) $(CPPFLAGS) $(PTDIRS) -c
+PREPROCESS.c ?= $(CC) $(PREPROCESS_OPT) $(CFLAGS) $(CPPFLAGS)
+PREPROCESS.cc ?= $(CXX) $(PREPROCESS_OPT) $(CCFLAGS) $(CPPFLAGS)
RC ?=
COMPILE.rc = $(RC) $(RCFLAGS)