Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Fitzsimmons <fitzsim@redhat.com>2002-06-25 03:05:08 +0400
committerThomas Fitzsimmons <fitzsim@redhat.com>2002-06-25 03:05:08 +0400
commitd5487d3fb771c118a7568b95e08d7a4ebebce7fa (patch)
treeeafdb0cc409eb40355b4ef19655cdd48d9147eaf
parent59c6d6c4b5ed8ddfff8b3fef309ff435322c38bc (diff)
* libc/search/db_local.h: New file.
* libc/include/db.h: Remove. * libc/search/Makefile.am (LIB_SOURCES): Add db_local.h. * libc/search/hash.c (MIN,MAX): Add macros. Change <db.h> to "db_local.h". * libc/search/hash_bigkey.c: Likewise. * libc/search/hash_buf.c: Likewise. * libc/search/hash_func.c: Likewise. * libc/search/hash_log2.c: Likewise. * libc/search/hash_page.c: Likewise.
-rw-r--r--newlib/ChangeLog15
-rw-r--r--newlib/libc/search/Makefile.am1
-rw-r--r--newlib/libc/search/Makefile.in1
-rw-r--r--newlib/libc/search/db_local.h (renamed from newlib/libc/include/db.h)0
-rw-r--r--newlib/libc/search/hash.c6
-rw-r--r--newlib/libc/search/hash_bigkey.c6
-rw-r--r--newlib/libc/search/hash_buf.c6
-rw-r--r--newlib/libc/search/hash_func.c2
-rw-r--r--newlib/libc/search/hash_log2.c2
-rw-r--r--newlib/libc/search/hash_page.c2
10 files changed, 34 insertions, 7 deletions
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index 115d68eed..772b268e3 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,4 +1,17 @@
-Mon Jun 24 21:17:02 2002 J"orn Rennecke <joern.rennecke@superh.com>
+2002-06-24 Thomas Fitzsimmons <fitzsim@redhat.com>
+
+ * libc/search/db_local.h: New file.
+ * libc/include/db.h: Remove.
+ * libc/search/Makefile.am (LIB_SOURCES): Add db_local.h.
+ * libc/search/hash.c (MIN,MAX): Add macros. Change <db.h> to
+ "db_local.h".
+ * libc/search/hash_bigkey.c: Likewise.
+ * libc/search/hash_buf.c: Likewise.
+ * libc/search/hash_func.c: Likewise.
+ * libc/search/hash_log2.c: Likewise.
+ * libc/search/hash_page.c: Likewise.
+
+2002-06-24 J"orn Rennecke <joern.rennecke@superh.com>
* libc/machine/sh/strcpy.S: New file.
* libc/machine/sh/Makefile.am (lib_a_SOURCES): Add rule for it.
diff --git a/newlib/libc/search/Makefile.am b/newlib/libc/search/Makefile.am
index 35aa511f9..b888a9de1 100644
--- a/newlib/libc/search/Makefile.am
+++ b/newlib/libc/search/Makefile.am
@@ -6,6 +6,7 @@ INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
LIB_SOURCES = \
bsearch.c \
+ db_local.h \
extern.h \
hash.c \
hash.h \
diff --git a/newlib/libc/search/Makefile.in b/newlib/libc/search/Makefile.in
index 6a67280ce..e4fb8d684 100644
--- a/newlib/libc/search/Makefile.in
+++ b/newlib/libc/search/Makefile.in
@@ -110,6 +110,7 @@ INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
LIB_SOURCES = \
bsearch.c \
+ db_local.h \
extern.h \
hash.c \
hash.h \
diff --git a/newlib/libc/include/db.h b/newlib/libc/search/db_local.h
index 53f9d17ff..53f9d17ff 100644
--- a/newlib/libc/include/db.h
+++ b/newlib/libc/search/db_local.h
diff --git a/newlib/libc/search/hash.c b/newlib/libc/search/hash.c
index 498ee3fcc..5bd4fb77e 100644
--- a/newlib/libc/search/hash.c
+++ b/newlib/libc/search/hash.c
@@ -53,7 +53,7 @@ static char sccsid[] = "@(#)hash.c 8.9 (Berkeley) 6/16/94";
#include <assert.h>
#endif
-#include <db.h>
+#include "db_local.h"
#include "hash.h"
#include "page.h"
#include "extern.h"
@@ -77,6 +77,10 @@ static void swap_header(HTAB *);
static void swap_header_copy(HASHHDR *, HASHHDR *);
#endif
+/* Macros for min/max. */
+#define MIN(a,b) (((a)<(b))?(a):(b))
+#define MAX(a,b) (((a)>(b))?(a):(b))
+
/* Fast arithmetic, relying on powers of 2, */
#define MOD(x, y) ((x) & ((y) - 1))
diff --git a/newlib/libc/search/hash_bigkey.c b/newlib/libc/search/hash_bigkey.c
index 8f8c58d10..821acd078 100644
--- a/newlib/libc/search/hash_bigkey.c
+++ b/newlib/libc/search/hash_bigkey.c
@@ -40,6 +40,10 @@ static char sccsid[] = "@(#)hash_bigkey.c 8.3 (Berkeley) 5/31/94";
#endif /* LIBC_SCCS and not lint */
#include <sys/cdefs.h>
+/* Macros for min/max. */
+#define MIN(a,b) (((a)<(b))?(a):(b))
+#define MAX(a,b) (((a)>(b))?(a):(b))
+
/*
* PACKAGE: hash
* DESCRIPTION:
@@ -69,7 +73,7 @@ static char sccsid[] = "@(#)hash_bigkey.c 8.3 (Berkeley) 5/31/94";
#include <assert.h>
#endif
-#include <db.h>
+#include "db_local.h"
#include "hash.h"
#include "page.h"
#include "extern.h"
diff --git a/newlib/libc/search/hash_buf.c b/newlib/libc/search/hash_buf.c
index 33cdb7c20..3979bcdd5 100644
--- a/newlib/libc/search/hash_buf.c
+++ b/newlib/libc/search/hash_buf.c
@@ -66,7 +66,7 @@ static char sccsid[] = "@(#)hash_buf.c 8.5 (Berkeley) 7/15/94";
#include <assert.h>
#endif
-#include <db.h>
+#include "db_local.h"
#include "hash.h"
#include "page.h"
#include "extern.h"
@@ -93,6 +93,10 @@ static BUFHEAD *newbuf(HTAB *, __uint32_t, BUFHEAD *);
#define MRU_INSERT(B) BUF_INSERT((B), &hashp->bufhead)
#define LRU_INSERT(B) BUF_INSERT((B), LRU)
+/* Macros for min/max. */
+#define MIN(a,b) (((a)<(b))?(a):(b))
+#define MAX(a,b) (((a)>(b))?(a):(b))
+
/*
* We are looking for a buffer with address "addr". If prev_bp is NULL, then
* address is a bucket index. If prev_bp is not NULL, then it points to the
diff --git a/newlib/libc/search/hash_func.c b/newlib/libc/search/hash_func.c
index deeb21e60..52cb31ccb 100644
--- a/newlib/libc/search/hash_func.c
+++ b/newlib/libc/search/hash_func.c
@@ -40,7 +40,7 @@ static char sccsid[] = "@(#)hash_func.c 8.2 (Berkeley) 2/21/94";
#include <sys/cdefs.h>
#include <sys/types.h>
-#include <db.h>
+#include "db_local.h"
#include "hash.h"
#include "page.h"
#include "extern.h"
diff --git a/newlib/libc/search/hash_log2.c b/newlib/libc/search/hash_log2.c
index bbcddb0c7..9414f26c2 100644
--- a/newlib/libc/search/hash_log2.c
+++ b/newlib/libc/search/hash_log2.c
@@ -41,7 +41,7 @@ static char sccsid[] = "@(#)hash_log2.c 8.2 (Berkeley) 5/31/94";
#include <sys/types.h>
-#include <db.h>
+#include "db_local.h"
__uint32_t
__log2(num)
diff --git a/newlib/libc/search/hash_page.c b/newlib/libc/search/hash_page.c
index a92dfa6e7..896aee8d5 100644
--- a/newlib/libc/search/hash_page.c
+++ b/newlib/libc/search/hash_page.c
@@ -69,7 +69,7 @@ static char sccsid[] = "@(#)hash_page.c 8.7 (Berkeley) 8/16/94";
#include <assert.h>
#endif
-#include <db.h>
+#include "db_local.h"
#include "hash.h"
#include "page.h"
#include "extern.h"