summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSteve Peters <steve@fisharerojo.org>2006-11-04 19:40:34 -0600
committerH.Merijn Brand <h.m.brand@xs4all.nl>2006-11-08 16:39:21 +0000
commitde52168c09035e3cc60829f317f4f46c3a4bbc3a (patch)
treefab65e2f863fedab93a7f0bbbefe97ecbe85707e
parentab7423222bba21f69873406be80957820f00b893 (diff)
downloadperl-de52168c09035e3cc60829f317f4f46c3a4bbc3a.tar.gz
Configure patch to add detection for DIR.dd_fd member variable
From: "Steve Peters" <steve.peters@gmail.com> Message-ID: <fd7a59d30611042340p5543442ctad306aeb748b6bfe@mail.gmail.com> p4raw-id: //depot/perl@29238
-rwxr-xr-xConfigure40
-rw-r--r--Cross/config.sh-arm-linux1
-rw-r--r--NetWare/config.wc1
-rw-r--r--Porting/Glossary5
-rw-r--r--config_h.SH6
-rw-r--r--configure.com1
-rw-r--r--epoc/config.sh1
-rw-r--r--handy.h2
-rw-r--r--plan9/config_sh.sample1
-rw-r--r--symbian/config.sh1
-rwxr-xr-xuconfig.sh1
-rw-r--r--win32/config.bc1
-rw-r--r--win32/config.gc1
-rw-r--r--win32/config.vc1
-rw-r--r--win32/config.vc641
15 files changed, 62 insertions, 2 deletions
diff --git a/Configure b/Configure
index 0e4de27290..533bf25b86 100755
--- 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 Mon Nov 6 16:18:02 CET 2006 [metaconfig 3.0 PL70]
+# Generated on Wed Nov 8 17:31:20 CET 2006 [metaconfig 3.0 PL70]
# (with additional metaconfig patches by perlbug@perl.org)
cat >c1$$ <<EOF
@@ -401,6 +401,7 @@ d_cuserid=''
d_dbl_dig=''
d_dbminitproto=''
d_difftime=''
+d_dir_dd_fd=''
d_dirfd=''
d_dlerror=''
d_dlopen=''
@@ -11248,6 +11249,42 @@ set d_dirnamlen
eval $setvar
$rm -f try.c
+: Look for DIR.dd_fd
+case "$i_dirent" in
+"$define")
+ echo "Checking to see if DIR has a dd_fd member variable" >&4
+ $cat >try.c <<EOCP
+#$i_stdlib I_STDLIB
+#ifdef I_STDLIB
+#include <stdlib.h>
+#endif
+#include <dirent.h>
+
+int main() {
+ DIR dir;
+ dir.dd_fd = 1;
+ return 0;
+}
+EOCP
+ val=$undef
+ set try
+ if eval $compile; then
+ echo "Yes, it does."
+ val="$define"
+ else
+ echo "No, it does not."
+ val="$undef"
+ fi
+ ;;
+*)
+ echo "You don't have a <dirent.h>, so not checking for dd_fd." >&4
+ val="$undef"
+ ;;
+esac
+set d_dir_dd_fd
+eval $setvar
+$rm -f try try.*
+
: see if this is an sysdir system
set sys/dir.h i_sysdir
eval $inhdr
@@ -21438,6 +21475,7 @@ d_cuserid='$d_cuserid'
d_dbl_dig='$d_dbl_dig'
d_dbminitproto='$d_dbminitproto'
d_difftime='$d_difftime'
+d_dir_dd_fd='$d_dir_dd_fd'
d_dirfd='$d_dirfd'
d_dirnamlen='$d_dirnamlen'
d_dlerror='$d_dlerror'
diff --git a/Cross/config.sh-arm-linux b/Cross/config.sh-arm-linux
index be17a386d2..ce98b3d598 100644
--- a/Cross/config.sh-arm-linux
+++ b/Cross/config.sh-arm-linux
@@ -148,6 +148,7 @@ d_cuserid='define'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='define'
d_dirnamlen='undef'
d_dlerror='define'
diff --git a/NetWare/config.wc b/NetWare/config.wc
index 675d934cae..e84b02e057 100644
--- a/NetWare/config.wc
+++ b/NetWare/config.wc
@@ -135,6 +135,7 @@ d_cuserid='undef'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='undef'
d_dlerror='define'
diff --git a/Porting/Glossary b/Porting/Glossary
index 0c6b247be1..0f891872fc 100644
--- a/Porting/Glossary
+++ b/Porting/Glossary
@@ -588,6 +588,11 @@ d_difftime (d_difftime.U):
This variable conditionally defines the HAS_DIFFTIME symbol, which
indicates to the C program that the difftime() routine is available.
+d_dir_dd_fd (d_dir_dd_fd.U)
+ This variable conditionally defines the HAS_DIR_DD_FD symbol, which
+ indicates that the DIR directory stream type contains a member
+ variable called dd_fd.
+
d_dirfd (d_dirfd.U):
This variable conditionally defines the HAS_DIRFD constant,
which indicates to the C program that dirfd() is available
diff --git a/config_h.SH b/config_h.SH
index 957c05b7f4..abcea7ea0a 100644
--- a/config_h.SH
+++ b/config_h.SH
@@ -4456,5 +4456,11 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un
#define M_VOID /* Xenix strikes again */
#endif
+/* HAS_DIR_DD_FD:
+ * This symbol, if defined, indicates that the the DIR* dirstream
+ * structure contains a member variable named dd_fd.
+ */
+#$d_dir_dd_fd HAS_DIR_DD_FD /**/
+
#endif
!GROK!THIS!
diff --git a/configure.com b/configure.com
index 47537f027a..aeb18fecb8 100644
--- a/configure.com
+++ b/configure.com
@@ -5708,6 +5708,7 @@ $ WC "d_c99_variadic_macros='undef'"
$ WC "d_dbl_dig='define'"
$ WC "d_dbminitproto='undef'"
$ WC "d_difftime='define'"
+$ WC "d_dir_dd_fd='undef'"
$ WC "d_dirfd='undef'"
$ WC "d_dirnamlen='define'"
$ WC "d_dlerror='undef'"
diff --git a/epoc/config.sh b/epoc/config.sh
index 03e426133a..ad559c8ae2 100644
--- a/epoc/config.sh
+++ b/epoc/config.sh
@@ -140,6 +140,7 @@ d_cuserid='undef'
d_dbl_dig='undef'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='undef'
d_dlerror='undef'
diff --git a/handy.h b/handy.h
index 0aa2b78b0a..81bdd03a15 100644
--- 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(HAS_MALLOC_SIZE) && defined(LOCALTIME_R_NEEDS_TZSET)
+#if defined(HAS_MALLOC_SIZE) && defined(LOCALTIME_R_NEEDS_TZSET) && defined(HAS_DIR_DD_FD)
/* Not (yet) used at top level, but mention them for metaconfig */
#endif
diff --git a/plan9/config_sh.sample b/plan9/config_sh.sample
index 08d181bdf2..86771d9410 100644
--- a/plan9/config_sh.sample
+++ b/plan9/config_sh.sample
@@ -146,6 +146,7 @@ d_cuserid='define'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='undef'
d_dlerror='undef'
diff --git a/symbian/config.sh b/symbian/config.sh
index 4824a3ea69..450effb9d2 100644
--- a/symbian/config.sh
+++ b/symbian/config.sh
@@ -89,6 +89,7 @@ d_cuserid='undef'
d_dbl_dig='undef'
d_dbminitproto='undef'
d_difftime='undef'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='define'
d_dlerror='undef'
diff --git a/uconfig.sh b/uconfig.sh
index b1d6c71330..2e903d1fe4 100755
--- a/uconfig.sh
+++ b/uconfig.sh
@@ -78,6 +78,7 @@ d_cuserid='undef'
d_dbl_dig='undef'
d_dbminitproto='undef'
d_difftime='undef'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='undef'
d_dlerror='undef'
diff --git a/win32/config.bc b/win32/config.bc
index cd2dca4ad5..077685dc9a 100644
--- a/win32/config.bc
+++ b/win32/config.bc
@@ -137,6 +137,7 @@ d_cuserid='undef'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='define'
d_dlerror='define'
diff --git a/win32/config.gc b/win32/config.gc
index 8f45dd01ee..7030d746fc 100644
--- a/win32/config.gc
+++ b/win32/config.gc
@@ -137,6 +137,7 @@ d_cuserid='undef'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='define'
d_dlerror='define'
diff --git a/win32/config.vc b/win32/config.vc
index 0fbc87629b..0c50145fd7 100644
--- a/win32/config.vc
+++ b/win32/config.vc
@@ -137,6 +137,7 @@ d_cuserid='undef'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='define'
d_dlerror='define'
diff --git a/win32/config.vc64 b/win32/config.vc64
index 8549af7b51..7ac7fe99f4 100644
--- a/win32/config.vc64
+++ b/win32/config.vc64
@@ -137,6 +137,7 @@ d_cuserid='undef'
d_dbl_dig='define'
d_dbminitproto='undef'
d_difftime='define'
+d_dir_dd_fd='undef'
d_dirfd='undef'
d_dirnamlen='define'
d_dlerror='define'