Added autoconf check for "inline". You can now use it, it will be

defined to (empty) for compilers that do not have it.
This commit is contained in:
Marcus Meissner 1999-04-26 14:58:58 +00:00 committed by Alexandre Julliard
parent ce597b48c9
commit 1a8bbd7ca9
3 changed files with 77 additions and 33 deletions

106
configure vendored
View File

@ -4181,13 +4181,53 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
echo "configure:4186: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
#line 4193 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
if { (eval echo configure:4200: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
fi
rm -f conftest*
done
fi
echo "$ac_t""$ac_cv_c_inline" 1>&6
case "$ac_cv_c_inline" in
inline | yes) ;;
no) cat >> confdefs.h <<\EOF
#define inline
EOF
;;
*) cat >> confdefs.h <<EOF
#define inline $ac_cv_c_inline
EOF
;;
esac
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
echo "configure:4186: checking for ANSI C header files" >&5
echo "configure:4226: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4191 "configure"
#line 4231 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@ -4195,7 +4235,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:4199: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:4239: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out`
if test -z "$ac_err"; then
rm -rf conftest*
@ -4212,7 +4252,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 4216 "configure"
#line 4256 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@ -4230,7 +4270,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 4234 "configure"
#line 4274 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@ -4251,7 +4291,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
#line 4255 "configure"
#line 4295 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@ -4262,7 +4302,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
if { (eval echo configure:4266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
if { (eval echo configure:4306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
:
else
@ -4286,12 +4326,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
echo "configure:4290: checking for size_t" >&5
echo "configure:4330: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4295 "configure"
#line 4335 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@ -4319,7 +4359,7 @@ EOF
fi
echo $ac_n "checking size of long long""... $ac_c" 1>&6
echo "configure:4323: checking size of long long" >&5
echo "configure:4363: checking size of long long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -4327,7 +4367,7 @@ else
ac_cv_sizeof_long_long=0
else
cat > conftest.$ac_ext <<EOF
#line 4331 "configure"
#line 4371 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@ -4338,7 +4378,7 @@ main()
exit(0);
}
EOF
if { (eval echo configure:4342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
if { (eval echo configure:4382: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_long=`cat conftestval`
else
@ -4362,12 +4402,12 @@ EOF
if test "$ac_cv_header_sys_vfs_h" = "yes"
then
echo $ac_n "checking "whether sys/vfs.h defines statfs"""... $ac_c" 1>&6
echo "configure:4366: checking "whether sys/vfs.h defines statfs"" >&5
echo "configure:4406: checking "whether sys/vfs.h defines statfs"" >&5
if eval "test \"`echo '$''{'wine_cv_sys_vfs_has_statfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4371 "configure"
#line 4411 "configure"
#include "confdefs.h"
#include <sys/types.h>
@ -4384,7 +4424,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:4388: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4428: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wine_cv_sys_vfs_has_statfs=yes
else
@ -4411,12 +4451,12 @@ fi
if test "$ac_cv_header_sys_statfs_h" = "yes"
then
echo $ac_n "checking "whether sys/statfs.h defines statfs"""... $ac_c" 1>&6
echo "configure:4415: checking "whether sys/statfs.h defines statfs"" >&5
echo "configure:4455: checking "whether sys/statfs.h defines statfs"" >&5
if eval "test \"`echo '$''{'wine_cv_sys_statfs_has_statfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4420 "configure"
#line 4460 "configure"
#include "confdefs.h"
#include <sys/types.h>
@ -4431,7 +4471,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:4435: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4475: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wine_cv_sys_statfs_has_statfs=yes
else
@ -4458,12 +4498,12 @@ fi
if test "$ac_cv_header_sys_mount_h" = "yes"
then
echo $ac_n "checking "whether sys/mount.h defines statfs"""... $ac_c" 1>&6
echo "configure:4462: checking "whether sys/mount.h defines statfs"" >&5
echo "configure:4502: checking "whether sys/mount.h defines statfs"" >&5
if eval "test \"`echo '$''{'wine_cv_sys_mount_has_statfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4467 "configure"
#line 4507 "configure"
#include "confdefs.h"
#include <sys/types.h>
@ -4478,7 +4518,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:4482: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4522: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wine_cv_sys_mount_has_statfs=yes
else
@ -4504,7 +4544,7 @@ fi
echo $ac_n "checking "for statfs.f_bfree"""... $ac_c" 1>&6
echo "configure:4508: checking "for statfs.f_bfree"" >&5
echo "configure:4548: checking "for statfs.f_bfree"" >&5
if eval "test \"`echo '$''{'wine_cv_statfs_bfree'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -4513,7 +4553,7 @@ else
wine_cv_statfs_bfree=no
else
cat > conftest.$ac_ext <<EOF
#line 4517 "configure"
#line 4557 "configure"
#include "confdefs.h"
#include <sys/types.h>
@ -4540,7 +4580,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:4544: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4584: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wine_cv_statfs_bfree=yes
else
@ -4564,7 +4604,7 @@ EOF
fi
echo $ac_n "checking "for statfs.f_bavail"""... $ac_c" 1>&6
echo "configure:4568: checking "for statfs.f_bavail"" >&5
echo "configure:4608: checking "for statfs.f_bavail"" >&5
if eval "test \"`echo '$''{'wine_cv_statfs_bavail'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -4573,7 +4613,7 @@ else
wine_cv_statfs_bavail=no
else
cat > conftest.$ac_ext <<EOF
#line 4577 "configure"
#line 4617 "configure"
#include "confdefs.h"
#include <sys/types.h>
@ -4600,7 +4640,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:4604: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4644: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
wine_cv_statfs_bavail=yes
else
@ -4625,7 +4665,7 @@ fi
echo $ac_n "checking "for working sigaltstack"""... $ac_c" 1>&6
echo "configure:4629: checking "for working sigaltstack"" >&5
echo "configure:4669: checking "for working sigaltstack"" >&5
if eval "test \"`echo '$''{'ac_cv_c_working_sigaltstack'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@ -4634,7 +4674,7 @@ else
else
cat > conftest.$ac_ext <<EOF
#line 4638 "configure"
#line 4678 "configure"
#include "confdefs.h"
#include <stdio.h>
@ -4672,7 +4712,7 @@ else
}
EOF
if { (eval echo configure:4676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
if { (eval echo configure:4716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_c_working_sigaltstack="yes"
else
@ -4699,12 +4739,12 @@ fi
echo $ac_n "checking "for msg_accrights in struct msghdr"""... $ac_c" 1>&6
echo "configure:4703: checking "for msg_accrights in struct msghdr"" >&5
echo "configure:4743: checking "for msg_accrights in struct msghdr"" >&5
if eval "test \"`echo '$''{'ac_cv_c_msg_accrights'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 4708 "configure"
#line 4748 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
@ -4712,7 +4752,7 @@ int main() {
struct msghdr hdr; hdr.msg_accrights=0
; return 0; }
EOF
if { (eval echo configure:4716: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:4756: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_msg_accrights="yes"
else

View File

@ -491,6 +491,7 @@ AC_HEADER_STAT()
dnl **** Check for types ****
AC_C_CONST()
AC_C_INLINE()
AC_TYPE_SIZE_T()
AC_CHECK_SIZEOF(long long,0)

View File

@ -3,6 +3,9 @@
/* Define to empty if the keyword does not work. */
#undef const
/* Define as __inline if that's what the C compiler calls it. */
#undef inline
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t