mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-22 16:43:03 +01:00
Changes to detect socklen_t properly, and a bit more on install
This commit is contained in:
parent
5df7da6266
commit
d8dd574545
167
configure
vendored
167
configure
vendored
@ -2030,153 +2030,44 @@ fi
|
||||
done
|
||||
|
||||
|
||||
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
|
||||
echo "configure:2035: 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 2040 "configure"
|
||||
#AC_CHECK_TYPE(socklen_t, int)
|
||||
echo $ac_n "checking Checking for socklen_t type""... $ac_c" 1>&6
|
||||
echo "configure:2036: checking Checking for socklen_t type" >&5
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2038 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <stdlib.h>
|
||||
#include <stdarg.h>
|
||||
#include <string.h>
|
||||
#include <float.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:2048: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
ac_cv_header_stdc=yes
|
||||
else
|
||||
echo "$ac_err" >&5
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
ac_cv_header_stdc=no
|
||||
fi
|
||||
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 2065 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <string.h>
|
||||
EOF
|
||||
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
||||
egrep "memchr" >/dev/null 2>&1; then
|
||||
:
|
||||
else
|
||||
rm -rf conftest*
|
||||
ac_cv_header_stdc=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
|
||||
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 2083 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <stdlib.h>
|
||||
EOF
|
||||
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
||||
egrep "free" >/dev/null 2>&1; then
|
||||
:
|
||||
else
|
||||
rm -rf conftest*
|
||||
ac_cv_header_stdc=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
|
||||
fi
|
||||
|
||||
if test $ac_cv_header_stdc = yes; then
|
||||
# /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
|
||||
if test "$cross_compiling" = yes; then
|
||||
:
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2104 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <ctype.h>
|
||||
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
|
||||
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
|
||||
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
|
||||
int main () { int i; for (i = 0; i < 256; i++)
|
||||
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
|
||||
exit (0); }
|
||||
|
||||
EOF
|
||||
if { (eval echo configure:2115: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
:
|
||||
else
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -fr conftest*
|
||||
ac_cv_header_stdc=no
|
||||
fi
|
||||
rm -fr conftest*
|
||||
fi
|
||||
|
||||
fi
|
||||
fi
|
||||
|
||||
echo "$ac_t""$ac_cv_header_stdc" 1>&6
|
||||
if test $ac_cv_header_stdc = yes; then
|
||||
cat >> confdefs.h <<\EOF
|
||||
#define STDC_HEADERS 1
|
||||
EOF
|
||||
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
|
||||
echo "configure:2139: checking for socklen_t" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2144 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#if STDC_HEADERS
|
||||
#include <stdlib.h>
|
||||
#include <stddef.h>
|
||||
#endif
|
||||
EOF
|
||||
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
||||
egrep "(^|[^a-zA-Z_0-9])socklen_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
|
||||
rm -rf conftest*
|
||||
ac_cv_type_socklen_t=yes
|
||||
else
|
||||
rm -rf conftest*
|
||||
ac_cv_type_socklen_t=no
|
||||
fi
|
||||
rm -f conftest*
|
||||
#include <sys/socket.h>
|
||||
|
||||
fi
|
||||
echo "$ac_t""$ac_cv_type_socklen_t" 1>&6
|
||||
if test $ac_cv_type_socklen_t = no; then
|
||||
int main() {
|
||||
socklen_t a;
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2048: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
echo "$ac_t""yes" 1>&6
|
||||
else
|
||||
echo "configure: failed program was:" >&5
|
||||
cat conftest.$ac_ext >&5
|
||||
rm -rf conftest*
|
||||
cat >> confdefs.h <<\EOF
|
||||
#define socklen_t int
|
||||
EOF
|
||||
|
||||
echo "$ac_t""no" 1>&6
|
||||
fi
|
||||
rm -f conftest*
|
||||
|
||||
|
||||
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
|
||||
echo "configure:2173: checking whether byte ordering is bigendian" >&5
|
||||
echo "configure:2064: checking whether byte ordering is bigendian" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
ac_cv_c_bigendian=unknown
|
||||
# See if sys/param.h defines the BYTE_ORDER macro.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2180 "configure"
|
||||
#line 2071 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
@ -2187,11 +2078,11 @@ int main() {
|
||||
#endif
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2191: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2082: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
# It does; now see whether it defined to BIG_ENDIAN or not.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2195 "configure"
|
||||
#line 2086 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
@ -2202,7 +2093,7 @@ int main() {
|
||||
#endif
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2206: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2097: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
ac_cv_c_bigendian=yes
|
||||
else
|
||||
@ -2222,7 +2113,7 @@ if test "$cross_compiling" = yes; then
|
||||
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2226 "configure"
|
||||
#line 2117 "configure"
|
||||
#include "confdefs.h"
|
||||
main () {
|
||||
/* Are we little or big endian? From Harbison&Steele. */
|
||||
@ -2235,7 +2126,7 @@ main () {
|
||||
exit (u.c[sizeof (long) - 1] == 1);
|
||||
}
|
||||
EOF
|
||||
if { (eval echo configure:2239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
if { (eval echo configure:2130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
|
||||
then
|
||||
ac_cv_c_bigendian=no
|
||||
else
|
||||
@ -2259,12 +2150,12 @@ EOF
|
||||
fi
|
||||
|
||||
echo $ac_n "checking for working const""... $ac_c" 1>&6
|
||||
echo "configure:2263: checking for working const" >&5
|
||||
echo "configure:2154: checking for working const" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2268 "configure"
|
||||
#line 2159 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
int main() {
|
||||
@ -2313,7 +2204,7 @@ ccp = (char const *const *) p;
|
||||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:2317: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:2208: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
ac_cv_c_const=yes
|
||||
else
|
||||
|
11
configure.in
11
configure.in
@ -33,7 +33,16 @@ AC_CHECK_HEADERS(ctype.h)
|
||||
AC_CHECK_HEADERS(string.h)
|
||||
AC_CHECK_HEADERS(signal.h)
|
||||
|
||||
AC_CHECK_TYPE(socklen_t, int)
|
||||
#AC_CHECK_TYPE(socklen_t, int)
|
||||
AC_MSG_CHECKING(Checking for socklen_t type)
|
||||
AC_TRY_COMPILE([#include <stdlib.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
],
|
||||
[socklen_t a;],
|
||||
[AC_MSG_RESULT(yes)],
|
||||
[AC_DEFINE(socklen_t, int) AC_MSG_RESULT(no)])
|
||||
|
||||
|
||||
AC_C_BIGENDIAN
|
||||
AC_C_CONST
|
||||
|
@ -26,7 +26,7 @@
|
||||
# Contributor(s):
|
||||
#
|
||||
#
|
||||
# $Id: Makefile.in,v 1.3 2001-08-13 08:14:38 skywalker Exp $
|
||||
# $Id: Makefile.in,v 1.4 2001-08-14 17:41:39 skywalker Exp $
|
||||
#
|
||||
|
||||
ROOT=../..
|
||||
@ -82,7 +82,8 @@ package : @FIREBIRD_ARCH_TYPE@packages
|
||||
runclassicinstall: $(LastClassicInstallFlg)
|
||||
|
||||
$(LastClassicInstallFlg) : $(BIN)/gsec
|
||||
sh $(InstallRoot)/classic/CSTarInstall.sh
|
||||
(cd $(ROOT); sh src/install/classic/CSTarInstall.sh)
|
||||
# (cd $(ROOT); sh $(InstallRoot)/classic/CSTarInstall.sh)
|
||||
touch $(LastClassicInstallFlg)
|
||||
|
||||
|
||||
|
@ -26,7 +26,7 @@
|
||||
# Contributor(s):
|
||||
#
|
||||
#
|
||||
# $Id: make.rules,v 1.6 2001-08-13 08:14:38 skywalker Exp $
|
||||
# $Id: make.rules,v 1.7 2001-08-14 17:41:39 skywalker Exp $
|
||||
#
|
||||
|
||||
#____________________________________________________________________________
|
||||
@ -79,7 +79,7 @@ export FIREBIRD
|
||||
# I would like to remove this one.
|
||||
SOURCE=$(ROOT)/src
|
||||
|
||||
CFLAGS:= $(CFLAGS) -g -pipe -MMD -p -fPIC -I$(ROOT)/src -I$(ROOT)/src/include
|
||||
CFLAGS:= $(CFLAGS) -g -pipe -MMD -p -fPIC -Wall -I$(ROOT)/src -I$(ROOT)/src/include
|
||||
|
||||
CXXFLAGS:= $(CXXFLAGS) $(CFLAGS)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user