From: Steve Peters Date: Sun, 5 Nov 2006 01:40:34 +0000 (-0600) Subject: Configure patch to add detection for DIR.dd_fd member variable X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=de52168c09035e3cc60829f317f4f46c3a4bbc3a;p=p5sagit%2Fp5-mst-13.2.git Configure patch to add detection for DIR.dd_fd member variable From: "Steve Peters" Message-ID: p4raw-id: //depot/perl@29238 --- diff --git a/Configure b/Configure index 0e4de27..533bf25 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$$ <&4 + $cat >try.c < +#endif +#include + +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 , 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 be17a38..ce98b3d 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 675d934c..e84b02e 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 0c6b247..0f89187 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 957c05b..abcea7e 100644 --- a/config_h.SH +++ b/config_h.SH @@ -4456,5 +4456,11 @@ sed <$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 47537f0..aeb18fe 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 03e4261..ad559c8 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 0aa2b78..81bdd03 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 08d181b..86771d9 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 4824a3e..450effb 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 b1d6c71..2e903d1 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 cd2dca4..077685d 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 8f45dd0..7030d74 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 0fbc876..0c50145 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 8549af7..7ac7fe9 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'