known_extensions=''
nonxs_ext=''
static_ext=''
-usei18n_lang=''
+uselanginfo=''
useopcode=''
useposix=''
extras=''
d_strlcpy=''
d_strnlen=''
d_strtod=''
+d_strtod_l=''
d_strtol=''
d_strtold=''
d_strtold_l=''
ccname=''
ccversion=''
perllibs=''
-: set usei18n_lang=false in your hint file to disable the I18N_Langinfo extension.
-usei18n_lang=true
: set useposix=false in your hint file to disable the POSIX extension.
useposix=true
: set useopcode=false in your hint file to disable the Opcode extension.
useopcode=true
+: set uselanginfo=false in your hint file to disable the I18N::Langinfo extension.
+uselanginfo=true
archname64=''
ccflags_uselargefiles=''
ldflags_uselargefiles=''
;;
MiNT) osname=mint
;;
+ minix) osname=minix
+ osvers=`$uname -r`
+ ;;
netbsd*) osname=netbsd
osvers="$3"
;;
compile_ok='
mc_file=$1;
shift;
-$cc -o ${mc_file} $optimize $ccflags $ldflags $* ${mc_file}.c $libs;'
+$cc -o ${mc_file} $optimize $ccflags $ldflags $* ${mc_file}.c $libs > /dev/null 2>&1;'
: stub, used only to satisfy other units
i_stdlib='define'
solaris)
xxx="-R $shrpdir"
;;
- freebsd|mirbsd|netbsd|openbsd|interix|dragonfly|bitrig)
+ freebsd|minix|mirbsd|netbsd|openbsd|interix|dragonfly|bitrig)
xxx="-Wl,-R$shrpdir"
;;
bsdos|linux|irix*|dec_osf|gnu*|haiku)
#ifdef I_STDLIB
#include <stdlib.h>
#endif
+#$i_inttypes I_INTTYPES
+#ifdef I_INTTYPES
+#include <inttypes.h>
+#endif
+#ifndef INTPTR_MAX
+#define intptr_t int
+#endif
int null_printf (char* pat,...) __attribute__((__format__(__printf__,1,2)));
-int null_printf (char* pat,...) { return (int)pat; }
+int null_printf (char* pat,...) { return (int)(intptr_t)pat; }
int main () { exit(null_printf(NULL)); }
EOCP
if $cc $ccflags -o attrib attrib.c >attrib.out 2>&1 ; then
set dup3 d_dup3
eval $inlibc
+: see if this is an xlocale.h system
+set xlocale.h i_xlocale
+eval $inhdr
+
+: see if newlocale exists
+set newlocale d_newlocale
+eval $inlibc
+
+: see if freelocale exists
+set freelocale d_freelocale
+eval $inlibc
+
+: see if uselocale exists
+set uselocale d_uselocale
+eval $inlibc
+
+: see if duplocale exists
+set duplocale d_duplocale
+eval $inlibc
+
+: see if querylocale exists
+set querylocale d_querylocale
+eval $inlibc
+
: see if eaccess exists
set eaccess d_eaccess
eval $inlibc
set d_fpos64_t
eval $setvar
-: see if this is an xlocale.h system
-set xlocale.h i_xlocale
-eval $inhdr
-
-: see if newlocale exists
-set newlocale d_newlocale
-eval $inlibc
-
-: see if freelocale exists
-set freelocale d_freelocale
-eval $inlibc
-
-: see if uselocale exists
-set uselocale d_uselocale
-eval $inlibc
-
-: see if duplocale exists
-set duplocale d_duplocale
-eval $inlibc
-
-: see if querylocale exists
-set querylocale d_querylocale
-eval $inlibc
-
: see if frexpl exists
set frexpl d_frexpl
eval $inlibc
extern int errno;
#endif
int main() {
- struct semid_ds arg;
+ union semun
+#ifndef HAS_UNION_SEMUN
+ {
+ int val;
+ struct semid_ds *buf;
+ unsigned short *array;
+ }
+#endif
+ arg;
+ struct semid_ds argbuf;
int sem, st;
#if defined(IPC_PRIVATE) && defined(S_IRWXU) && defined(S_IRWXG) && defined(S_IRWXO) && defined(IPC_CREAT)
sem = semget(IPC_PRIVATE, 1, S_IRWXU|S_IRWXG|S_IRWXO|IPC_CREAT);
if (sem > -1) {
+ arg.buf = &argbuf;
# ifdef IPC_STAT
- st = semctl(sem, 0, IPC_STAT, &arg);
+ st = semctl(sem, 0, IPC_STAT, arg);
if (st == 0)
printf("semid_ds\n");
else
# endif /* IPC_STAT */
printf("semctl IPC_STAT failed: errno = %d\n", errno);
# ifdef IPC_RMID
- if (semctl(sem, 0, IPC_RMID, &arg) != 0)
+ if (semctl(sem, 0, IPC_RMID, arg) != 0)
# endif /* IPC_RMID */
printf("semctl IPC_RMID failed: errno = %d\n", errno);
} else
set strtod d_strtod
eval $inlibc
+: see if strtod_l exists
+set strtod_l d_strtod_l
+eval $inlibc
+
: see if strtol exists
set strtol d_strtol
eval $inlibc
#ifndef DB_VERSION_MAJOR
u_int32_t hash_cb (const void* ptr, size_t size)
{
+ return 0;
}
HASHINFO info;
int main()
#ifndef DB_VERSION_MAJOR
size_t prefix_cb (const DBT *key1, const DBT *key2)
{
+ return 0;
}
BTREEINFO info;
int main()
: add -D_FORTIFY_SOURCE if feasible and not already there
case "$gccversion" in
-[4567].*) case "$optimize$ccflags" in
+[456789].*) case "$optimize$ccflags" in
*-O*) case "$ccflags$cppsymbols" in
*_FORTIFY_SOURCE=*) # Don't add it again.
echo "You seem to have -D_FORTIFY_SOURCE already, not adding it." >&4
$define) avail_ext="$avail_ext $xxx" ;;
esac
;;
- I18N/Langinfo|i18n_lan)
- case "$usei18n_lang" in
- true|define|y) avail_ext="$avail_ext $xxx" ;;
- esac
- ;;
IPC/SysV|ipc/sysv)
: XXX Do we need a useipcsysv variable here
case "${d_msg}${d_sem}${d_shm}" in
true|$define|y) avail_ext="$avail_ext $xxx" ;;
esac
;;
+ I18N/Langinfo|langinfo)
+ case "$uselanginfo" in
+ true|define|y) avail_ext="$avail_ext $xxx" ;;
+ esac
+ ;;
Sys/Syslog|sys/syslog)
case $osname in
amigaos) ;; # not really very useful on AmigaOS
d_strlcpy='$d_strlcpy'
d_strnlen='$d_strnlen'
d_strtod='$d_strtod'
+d_strtod_l='$d_strtod_l'
d_strtol='$d_strtol'
d_strtold='$d_strtold'
d_strtold_l='$d_strtold_l'
usedl='$usedl'
usedtrace='$usedtrace'
usefaststdio='$usefaststdio'
-usei18n_lang='$i18n_lang'
useithreads='$useithreads'
usekernprocpathname='$usekernprocpathname'
+uselanginfo='$uselanginfo'
uselargefiles='$uselargefiles'
uselongdouble='$uselongdouble'
usemallocwrap='$usemallocwrap'