changeset 1663:8bae4d6cdd10

[xemacs-hg @ 2003-09-03 20:43:46 by james] Nickolay Pakoulin's patch to fix the C++ build for make-dump-id.
author james
date Wed, 03 Sep 2003 20:43:46 +0000
parents 1393f296cac6
children 6b0f041b5252
files lib-src/ChangeLog lib-src/make-dump-id.c
diffstat 2 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lib-src/ChangeLog	Tue Sep 02 21:52:24 2003 +0000
+++ b/lib-src/ChangeLog	Wed Sep 03 20:43:46 2003 +0000
@@ -1,3 +1,7 @@
+2003-08-29  Nickolay Pakoulin  <npak@ispras.ru>
+
+	* make-dump-id.c (main): Set "C" linking rule for dump_id
+
 2003-06-30  Andrew Begel  <abegel@CS.Berkeley.EDU>
 
 	* make-docfile.c (write_c_args): Escape newlines that arise in the
--- a/lib-src/make-dump-id.c	Tue Sep 02 21:52:24 2003 +0000
+++ b/lib-src/make-dump-id.c	Wed Sep 03 20:43:46 2003 +0000
@@ -64,6 +64,10 @@
       return EXIT_FAILURE;
     }
 
+  /* dump_id is declared as extern "C" in lrecord.h */
+  fprintf (f, "#if defined (__cplusplus)\n");
+  fprintf (f, "extern \"C\"\n");
+  fprintf (f, "#endif /* __cplusplus */\n");
   fprintf (f, "unsigned int dump_id = %uU;\n", generate_dump_id ());
 
   if ((fclose (f)) != 0)