1998-02-01 02:37:08 +01:00
|
|
|
# Process this file with autoconf to produce a configure script.
|
1999-10-12 10:39:35 +02:00
|
|
|
# Copyright (C) 1995, 1998, 1999 Free Software Foundation, Inc.
|
1998-02-01 02:37:08 +01:00
|
|
|
# Contributed by Dave Love (d.love@dl.ac.uk).
|
|
|
|
#
|
|
|
|
#This file is part of the GNU Fortran libU77 library.
|
|
|
|
#
|
|
|
|
#This library is free software; you can redistribute it and/or modify
|
|
|
|
#it under the terms of the GNU General Public License as published by
|
|
|
|
#the Free Software Foundation; either version 2, or (at your option)
|
|
|
|
#any later version.
|
|
|
|
#
|
|
|
|
#GNU Fortran is distributed in the hope that it will be useful,
|
|
|
|
#but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
#GNU Library General Public License for more details.
|
|
|
|
#
|
|
|
|
#You should have received a copy of the GNU Library General Public
|
|
|
|
#License along with GNU Fortran; see the file COPYING. If not, write
|
|
|
|
#to Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
|
|
|
|
#USA.
|
|
|
|
|
1998-11-23 14:58:48 +01:00
|
|
|
AC_PREREQ(2.12.1)
|
1998-02-01 02:37:08 +01:00
|
|
|
AC_INIT(access_.c)
|
1998-07-16 02:07:42 +02:00
|
|
|
AC_CONFIG_HEADER(config.h:config.hin)
|
1998-02-01 02:37:08 +01:00
|
|
|
|
2001-07-18 17:16:10 +02:00
|
|
|
# These defines are necessary to get 64-bit file size support.
|
|
|
|
|
|
|
|
AC_DEFINE(_XOPEN_SOURCE, 500L, [Get Single Unix Specification semantics])
|
|
|
|
# The following is needed by irix6.2 so that struct timeval is declared.
|
|
|
|
AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [Get Single Unix Specification semantics])
|
2001-09-22 15:32:38 +02:00
|
|
|
# The following is needed by Solaris2.5.1 so that struct timeval is declared.
|
|
|
|
AC_DEFINE(__EXTENSIONS__, 1, [Solaris extensions])
|
2001-07-18 17:16:10 +02:00
|
|
|
AC_DEFINE(_FILE_OFFSET_BITS, 64, [Get 64-bit file size support])
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
dnl Checks for programs.
|
2001-02-09 08:14:35 +01:00
|
|
|
|
|
|
|
dnl FIXME AC_PROG_CC wants CC to be able to link things, but it may
|
|
|
|
dnl not be able to.
|
|
|
|
define([AC_PROG_CC_WORKS],[])
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
# For g77 we'll set CC to point at the built gcc, but this will get it into
|
|
|
|
# the makefiles
|
|
|
|
AC_PROG_CC
|
2001-10-01 00:06:23 +02:00
|
|
|
|
|
|
|
LIBTOOL='$(SHELL) ../libtool'
|
|
|
|
AC_SUBST(LIBTOOL)
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
dnl AC_C_CROSS
|
|
|
|
dnl Gives misleading `(cached)' message from the check.
|
|
|
|
if test "$CROSS";then
|
|
|
|
ac_cv_c_cross=yes
|
|
|
|
else
|
|
|
|
ac_cv_c_cross=no
|
|
|
|
fi
|
|
|
|
|
1998-07-12 07:02:03 +02:00
|
|
|
test "$AR" || AR=ar
|
|
|
|
AC_SUBST(AR)
|
|
|
|
AC_PROG_MAKE_SET
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
dnl This is only because we (horribly) punt the chmod job to the program at
|
|
|
|
dnl present. Note that the result of this test could be wrong in the cross
|
|
|
|
dnl case.
|
|
|
|
AC_PATH_PROG(ac_cv_prog_chmod, chmod, no)
|
|
|
|
if test "$ac_cv_prog_chmod" != no || test "$CROSS"; then
|
|
|
|
MAYBES=chmod_.o
|
|
|
|
AC_DEFINE_UNQUOTED(CHMOD_PATH,"$ac_cv_prog_chmod")
|
|
|
|
else
|
|
|
|
MAYBES=""
|
|
|
|
fi
|
|
|
|
|
|
|
|
dnl Checks for header files.
|
|
|
|
AC_HEADER_STDC
|
|
|
|
AC_HEADER_TIME
|
|
|
|
AC_CHECK_HEADERS(limits.h unistd.h sys/time.h string.h stdlib.h \
|
|
|
|
sys/param.h sys/times.h)
|
|
|
|
|
|
|
|
dnl Checks for typedefs, structures, and compiler characteristics.
|
|
|
|
AC_C_CONST
|
|
|
|
AC_TYPE_SIZE_T
|
|
|
|
AC_TYPE_MODE_T
|
|
|
|
|
|
|
|
AC_TYPE_PID_T
|
|
|
|
dnl The next 3 demand a dummy fileblocks.o (added to LIBOJS). We don't use
|
|
|
|
dnl LIBOJS, though.
|
|
|
|
AC_STRUCT_ST_BLKSIZE
|
|
|
|
AC_STRUCT_ST_BLOCKS
|
|
|
|
AC_STRUCT_ST_RDEV
|
|
|
|
AC_STRUCT_TM
|
|
|
|
|
1998-07-06 11:01:43 +02:00
|
|
|
dnl Some systems (SVR4, SCO OpenServer) need -lsocket for gethostname()
|
|
|
|
AC_CHECK_LIB(socket, gethostname, [LIBS="$LIBS -lsocket"])
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
dnl Checks for library functions.
|
|
|
|
|
|
|
|
AC_CHECK_FUNCS(symlink getcwd getwd lstat gethostname strerror clock \
|
1999-10-12 10:39:35 +02:00
|
|
|
getrusage times alarm getlogin getgid getuid kill link ttyname)
|
|
|
|
|
|
|
|
dnl The standard autoconf HAVE_STRUCT_TIMEZONE doesn't actually check
|
|
|
|
dnl for struct timezone, as you might think. We also need to check how
|
|
|
|
dnl to call gettimeofday if we have it.
|
|
|
|
LIBU77_GETTIMEOFDAY
|
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
test $ac_cv_func_symlink = yes && MAYBES="$MAYBES symlnk_.o"
|
|
|
|
test $ac_cv_func_lstat = yes && MAYBES="$MAYBES lstat_.o"
|
|
|
|
test $ac_cv_func_gethostname = yes && MAYBES="$MAYBES hostnm_.o"
|
|
|
|
test $ac_cv_func_clock = yes && MAYBES="$MAYBES mclock_.o"
|
|
|
|
AC_SUBST(MAYBES)
|
|
|
|
|
|
|
|
AC_SUBST(CROSS)
|
|
|
|
AC_SUBST(RANLIB)
|
|
|
|
AC_SUBST(RANLIB_TEST)
|
2001-07-07 20:51:58 +02:00
|
|
|
|
1998-02-01 02:37:08 +01:00
|
|
|
AC_OUTPUT(Makefile)
|