Module Name:    src
Committed By:   pooka
Date:           Fri Apr 25 17:50:01 UTC 2014

Modified Files:
        src/sys/rump/librump: makerumpif.sh

Log Message:
create multi-inclusion protectors; some compilers don't like duplicate typedefs


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/rump/librump/makerumpif.sh

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/rump/librump/makerumpif.sh
diff -u src/sys/rump/librump/makerumpif.sh:1.7 src/sys/rump/librump/makerumpif.sh:1.8
--- src/sys/rump/librump/makerumpif.sh:1.7	Fri Apr 25 13:07:31 2014
+++ src/sys/rump/librump/makerumpif.sh	Fri Apr 25 17:50:01 2014
@@ -1,6 +1,6 @@
 #!/bin/sh
 #
-#	$NetBSD: makerumpif.sh,v 1.7 2014/04/25 13:07:31 pooka Exp $
+#	$NetBSD: makerumpif.sh,v 1.8 2014/04/25 17:50:01 pooka Exp $
 #
 # Copyright (c) 2009 Antti Kantee.  All rights reserved.
 #
@@ -78,9 +78,9 @@ sed -e '
 ' ${1} | awk -F\| -v topdir=${TOPDIR} '
 function fileheaders(file, srcstr)
 {
-	printf("/*\t$NetBSD: makerumpif.sh,v 1.7 2014/04/25 13:07:31 pooka Exp $\t*/\n\n") > file
+	printf("/*\t$NetBSD: makerumpif.sh,v 1.8 2014/04/25 17:50:01 pooka Exp $\t*/\n\n") > file
 	printf("/*\n * Automatically generated.  DO NOT EDIT.\n") > file
-	genstr = "$NetBSD: makerumpif.sh,v 1.7 2014/04/25 13:07:31 pooka Exp $"
+	genstr = "$NetBSD: makerumpif.sh,v 1.8 2014/04/25 17:50:01 pooka Exp $"
 	gsub("\\$", "", genstr)
 	printf(" * from: %s\n", srcstr) > file
 	printf(" * by:   %s\n", genstr) > file
@@ -145,6 +145,10 @@ $1 == "WRAPPERS"{gencalls = topdir "/" $
 		printf("\n") > pubhdr
 		printf("\n") > privhdr
 
+		printf("#ifndef _RUMP_PRIF_%s_H_\n", toupper(myname)) > privhdr
+		printf("#define _RUMP_PRIF_%s_H_\n", toupper(myname)) > privhdr
+		printf("\n") > privhdr
+
 		printf("\n#include <sys/cdefs.h>\n") > gencalls
 		printf("#include <sys/systm.h>\n") > gencalls
 		printf("\n#include <rump/rump.h>\n") > gencalls
@@ -217,4 +221,6 @@ $1 == "WRAPPERS"{gencalls = topdir "/" $
 	if (isweak)
 		printf("__weak_alias(rump_%s,rump_%s_unavailable);\n", \
 		    funname, myname) > gencalls
-}'
+}
+
+END { printf("\n#endif /* _RUMP_PRIF_%s_H_ */\n", toupper(myname)) > privhdr }'

Reply via email to