fts: allow compilation with C++
authorGiuseppe Scrivano <gscrivano@gnu.org>
Sun, 22 Aug 2010 14:20:42 +0000 (10:20 -0400)
committerJim Meyering <meyering@redhat.com>
Sun, 22 Aug 2010 14:20:42 +0000 (10:20 -0400)
* lib/fts_.h: Specify extern "C" linkage with C++.

ChangeLog
lib/fts_.h

index b540fd1..1337347 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2010-08-22  Giuseppe Scrivano  <gscrivano@gnu.org>
+
+       fts: allow compilation with C++
+       * lib/fts_.h: Specify extern "C" linkage with C++.
+
 2010-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
 
        Fix gnulib-tool sed script de-commentation for AIX sed.
index 75324d4..1d532b4 100644 (file)
 #  undef __THROW
 #  define __THROW
 #  undef __BEGIN_DECLS
-#  define __BEGIN_DECLS
 #  undef __END_DECLS
-#  define __END_DECLS
+#  ifdef __cplusplus
+#   define __BEGIN_DECLS extern "C" {
+#   define __END_DECLS }
+#  else
+#   define __BEGIN_DECLS
+#   define __END_DECLS
+#  endif
 # endif
 
 # include <stddef.h>