Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-2-0]: src Pull up revision 1.18 (requested by jmc in ticket #527):



details:   https://anonhg.NetBSD.org/src/rev/bdb6467a5bb6
branches:  netbsd-2-0
changeset: 561521:bdb6467a5bb6
user:      tron <tron%NetBSD.org@localhost>
date:      Tue Jun 22 07:21:53 2004 +0000

description:
Pull up revision 1.18 (requested by jmc in ticket #527):
Completely rework how tools/compat is done. Purge all uses/references to
_NETBSD_SOURCE as this makes cross building from older/newer versions of
NetBSD harder, not easier (and also makes the resulting tools 'different')
Wrap all required code with the inclusion of nbtool_config.h, attempt to
only use POSIX code in all places (or when reasonable test w. configure and
provide definitions: ala u_int, etc).
Reviewed by lukem. Tested on FreeBSD 4.9, Redhat Linux ES3, NetBSD 1.6.2 x86
NetBSD current (x86 and amd64) and Solaris 9.
Fixes PR's: PR#17762 PR#25944

diffstat:

 include/glob.h                 |  4 ++--
 lib/libc/db/hash/hash_bigkey.c |  8 ++++++--
 usr.bin/m4/eval.c              |  8 ++++++--
 usr.bin/xlint/lint1/init.c     |  8 ++++++--
 4 files changed, 20 insertions(+), 8 deletions(-)

diffs (96 lines):

diff -r 70da8231e9c1 -r bdb6467a5bb6 include/glob.h
--- a/include/glob.h    Tue Jun 22 07:21:29 2004 +0000
+++ b/include/glob.h    Tue Jun 22 07:21:53 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: glob.h,v 1.17 2003/08/07 09:44:10 agc Exp $    */
+/*     $NetBSD: glob.h,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $       */
 
 /*
  * Copyright (c) 1989, 1993
@@ -81,7 +81,7 @@
 #define        GLOB_NOMATCH    (-3)    /* No match, and GLOB_NOCHECK was not set. */
 #define        GLOB_NOSYS      (-4)    /* Implementation does not support function. */
 
-#if defined(_NETBSD_SOURCE)
+#if defined(_NETBSD_SOURCE) || defined(HAVE_NBTOOL_CONFIG_H)
 #define        GLOB_ALTDIRFUNC 0x0040  /* Use alternately specified directory funcs. */
 #define        GLOB_BRACE      0x0080  /* Expand braces ala csh. */
 #define        GLOB_MAGCHAR    0x0100  /* Pattern had globbing characters. */
diff -r 70da8231e9c1 -r bdb6467a5bb6 lib/libc/db/hash/hash_bigkey.c
--- a/lib/libc/db/hash/hash_bigkey.c    Tue Jun 22 07:21:29 2004 +0000
+++ b/lib/libc/db/hash/hash_bigkey.c    Tue Jun 22 07:21:53 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: hash_bigkey.c,v 1.17 2003/08/07 16:42:42 agc Exp $     */
+/*     $NetBSD: hash_bigkey.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $        */
 
 /*-
  * Copyright (c) 1990, 1993, 1994
@@ -32,12 +32,16 @@
  * SUCH DAMAGE.
  */
 
+#if HAVE_NBTOOL_CONFIG_H
+#include "nbtool_config.h"
+#endif
+
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
 #if 0
 static char sccsid[] = "@(#)hash_bigkey.c      8.3 (Berkeley) 5/31/94";
 #else
-__RCSID("$NetBSD: hash_bigkey.c,v 1.17 2003/08/07 16:42:42 agc Exp $");
+__RCSID("$NetBSD: hash_bigkey.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $");
 #endif
 #endif /* LIBC_SCCS and not lint */
 
diff -r 70da8231e9c1 -r bdb6467a5bb6 usr.bin/m4/eval.c
--- a/usr.bin/m4/eval.c Tue Jun 22 07:21:29 2004 +0000
+++ b/usr.bin/m4/eval.c Tue Jun 22 07:21:53 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: eval.c,v 1.17 2003/08/07 11:14:30 agc Exp $    */
+/*     $NetBSD: eval.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $       */
 /*     $OpenBSD: eval.c,v 1.41 2001/10/10 23:25:31 espie Exp $ */
 
 /*
@@ -33,12 +33,16 @@
  * SUCH DAMAGE.
  */
 
+#if HAVE_NBTOOL_CONFIG_H
+#include "nbtool_config.h"
+#endif
+
 #include <sys/cdefs.h>
 #if defined(__RCSID) && !defined(lint)
 #if 0
 static char sccsid[] = "@(#)eval.c     8.2 (Berkeley) 4/27/95";
 #else
-__RCSID("$NetBSD: eval.c,v 1.17 2003/08/07 11:14:30 agc Exp $");
+__RCSID("$NetBSD: eval.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $");
 #endif
 #endif /* not lint */
 
diff -r 70da8231e9c1 -r bdb6467a5bb6 usr.bin/xlint/lint1/init.c
--- a/usr.bin/xlint/lint1/init.c        Tue Jun 22 07:21:29 2004 +0000
+++ b/usr.bin/xlint/lint1/init.c        Tue Jun 22 07:21:53 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: init.c,v 1.17 2002/12/06 03:27:39 thorpej Exp $        */
+/*     $NetBSD: init.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $       */
 
 /*
  * Copyright (c) 1994, 1995 Jochen Pohl
@@ -31,9 +31,13 @@
  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
 
+#if HAVE_NBTOOL_CONFIG_H
+#include "nbtool_config.h"
+#endif
+
 #include <sys/cdefs.h>
 #if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: init.c,v 1.17 2002/12/06 03:27:39 thorpej Exp $");
+__RCSID("$NetBSD: init.c,v 1.17.2.1 2004/06/22 07:21:53 tron Exp $");
 #endif
 
 #include <stdlib.h>



Home | Main Index | Thread Index | Old Index