summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2006-12-23 15:59:11 +0000
committerBruno Haible <bruno@clisp.org>2009-06-23 12:14:34 +0200
commitd0f50e797d7de6cf5febbee619ec0ea29cd560a1 (patch)
tree495a801d433eb0c90725ed31560cf89338d623fd
parent3331744ae506cbf35536fbf600f901811f0b6d54 (diff)
downloadexternal_gettext-d0f50e797d7de6cf5febbee619ec0ea29cd560a1.zip
external_gettext-d0f50e797d7de6cf5febbee619ec0ea29cd560a1.tar.gz
external_gettext-d0f50e797d7de6cf5febbee619ec0ea29cd560a1.tar.bz2
Test for CC=c++ at configure-time, so that we don't confuse a fully C++
build with a mixed C/C++ build.
-rw-r--r--gnulib-local/ChangeLog9
-rw-r--r--gnulib-local/Makefile.am1
-rwxr-xr-xgnulib-local/build-aux/moopp4
-rw-r--r--gnulib-local/modules/moo3
4 files changed, 14 insertions, 3 deletions
diff --git a/gnulib-local/ChangeLog b/gnulib-local/ChangeLog
index d0f0b17..46d2919 100644
--- a/gnulib-local/ChangeLog
+++ b/gnulib-local/ChangeLog
@@ -1,3 +1,12 @@
+2006-12-22 Bruno Haible <bruno@clisp.org>
+
+ Test for CC=c++ at configure-time.
+ * m4/moo.m4: New file.
+ * build-aux/moopp: Emit test of IS_CPLUSPLUS instead of __cplusplus.
+ * modules/moo (Files): Add m4/moo.m4.
+ (configure.ac): Set to gl_MOO.
+ * Makefile.am (EXTRA_DIST): Add m4/moo.m4.
+
2006-12-23 Bruno Haible <bruno@clisp.org>
Support platforms with neither terminfo nor termcap functions, like
diff --git a/gnulib-local/Makefile.am b/gnulib-local/Makefile.am
index 5e65356..cb3ad96 100644
--- a/gnulib-local/Makefile.am
+++ b/gnulib-local/Makefile.am
@@ -265,6 +265,7 @@ m4/libcroco.m4 \
m4/libglib.m4 \
m4/libxml.m4 \
m4/java.m4 \
+m4/moo.m4 \
m4/quotearg.m4.diff \
m4/quote.m4.diff \
m4/relocatable.m4 \
diff --git a/gnulib-local/build-aux/moopp b/gnulib-local/build-aux/moopp
index 2792df8..92c98bb 100755
--- a/gnulib-local/build-aux/moopp
+++ b/gnulib-local/build-aux/moopp
@@ -468,7 +468,7 @@ func_emit_source_h ()
echo "/* ${main_classname}_t is defined as a pointer to struct ${main_repclassalias}."
echo " In C++ mode, we use a smart pointer class."
echo " In C mode, we have no other choice than a typedef to the root class type. */"
- echo "#ifdef __cplusplus"
+ echo "#if IS_CPLUSPLUS"
echo "struct ${main_classname}_t"
echo "{"
echo "private:"
@@ -610,7 +610,7 @@ func_emit_source_c ()
else
rootclassname="$main_classname"
fi
- echo "#ifndef __cplusplus"
+ echo "#if !IS_CPLUSPLUS"
echo "#define ${main_classname}_representation any_${rootclassname}_representation"
echo "#endif"
echo "#include \"${main_classname}.priv.h\""
diff --git a/gnulib-local/modules/moo b/gnulib-local/modules/moo
index 714d387..4c2628b 100644
--- a/gnulib-local/modules/moo
+++ b/gnulib-local/modules/moo
@@ -4,11 +4,12 @@ Minimal object-oriented programming style.
Files:
build-aux/moopp
lib/moo.h
+m4/moo.m4
Depends-on:
configure.ac:
-AC_REQUIRE([AC_C_INLINE])
+gl_MOO
Makefile.am:
MOOPPFLAGS =