Detection of malloc_size and malloc_good_size
authorH.Merijn Brand <h.m.brand@xs4all.nl>
Mon, 12 Sep 2005 13:26:31 +0000 (13:26 +0000)
committerH.Merijn Brand <h.m.brand@xs4all.nl>
Mon, 12 Sep 2005 13:26:31 +0000 (13:26 +0000)
p4raw-id: //depot/perl@25387

Configure
Porting/Glossary
config_h.SH
handy.h

index 7be96c6..e5dd705 100755 (executable)
--- a/Configure
+++ b/Configure
@@ -26,7 +26,7 @@
 
 # $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $
 #
-# Generated on Tue Sep  6 16:35:32 CEST 2005 [metaconfig 3.0 PL70]
+# Generated on Mon Sep 12 15:44:06 CEST 2005 [metaconfig 3.0 PL70]
 # (with additional metaconfig patches by perlbug@perl.org)
 
 cat >c1$$ <<EOF
@@ -550,6 +550,8 @@ longlongsize=''
 d_lseekproto=''
 d_lstat=''
 d_madvise=''
+d_malloc_good_size=''
+d_malloc_size=''
 d_mblen=''
 d_mbstowcs=''
 d_mbtowc=''
@@ -14247,6 +14249,14 @@ eval $inlibc
 set madvise d_madvise
 eval $inlibc
 
+: see if malloc_size exists
+set malloc_size d_malloc_size
+eval $inlibc
+
+: see if malloc_size_good exists
+set malloc_good_size d_malloc_good_size
+eval $inlibc
+
 : see if mblen exists
 set mblen d_mblen
 eval $inlibc
@@ -21112,6 +21122,8 @@ d_longlong='$d_longlong'
 d_lseekproto='$d_lseekproto'
 d_lstat='$d_lstat'
 d_madvise='$d_madvise'
+d_malloc_good_size='$d_malloc_good_size'
+d_malloc_size='$d_malloc_size'
 d_mblen='$d_mblen'
 d_mbstowcs='$d_mbstowcs'
 d_mbtowc='$d_mbtowc'
index ac31fa5..3f18f41 100644 (file)
@@ -1215,6 +1215,14 @@ d_madvise (d_madvise.U):
        This variable conditionally defines HAS_MADVISE if madvise() is
        available to map a file into memory.
 
+d_malloc_size (d_malloc_size.U):
+       This symbol, if defined, indicates that the malloc_size
+       routine is available for use.
+
+d_malloc_good_size (d_malloc_good_size.U):
+       This symbol, if defined, indicates that the malloc_good_size
+       routine is available for use.
+
 d_mblen (d_mblen.U):
        This variable conditionally defines the HAS_MBLEN symbol, which
        indicates to the C program that the mblen() routine is available
index d8a263b..e4662b2 100644 (file)
@@ -1948,6 +1948,18 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
  */
 #$d_madvise HAS_MADVISE                /**/
 
+/* HAS_MALLOC_SIZE:
+ *     This symbol, if defined, indicates that the malloc_size
+ *     routine is available for use.
+ */
+#$d_malloc_size HAS_MALLOC_SIZE                /**/
+
+/* HAS_MALLOC_GOOD_SIZE:
+ *     This symbol, if defined, indicates that the malloc_good_size
+ *     routine is available for use.
+ */
+#$d_malloc_good_size HAS_MALLOC_GOOD_SIZE      /**/
+
 /* HAS_MEMCHR:
  *     This symbol, if defined, indicates that the memchr routine is available
  *     to locate characters within a C string.
diff --git a/handy.h b/handy.h
index 7b5eb16..dbf70d8 100644 (file)
--- a/handy.h
+++ b/handy.h
@@ -175,7 +175,7 @@ typedef U64TYPE U64;
 #endif
 
 /* HMB H.Merijn Brand - a placeholder for preparing Configure patches */
-#if defined(LIBM_LIB_VERSION)
+#if defined(HAS_MALLOC_SIZE) && defined(HAS_MALLOC_GOOD_SIZE)
 /* Not (yet) used at top level, but mention them for metaconfig */
 #endif