source: branches/libc-0.6/src/gcc/libf2c/libU77/configure.in

Last change on this file was 1392, checked in by bird, 21 years ago

This commit was generated by cvs2svn to compensate for changes in r1391,
which included commits to RCS files with non-trunk default branches.

  • Property cvs2svn:cvs-rev set to 1.1.1.2
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 3.9 KB
Line 
1# Process this file with autoconf to produce a configure script.
2# Copyright (C) 1995, 1998, 1999 Free Software Foundation, Inc.
3# Contributed by Dave Love (d.love@dl.ac.uk).
4#
5#This file is part of the GNU Fortran libU77 library.
6#
7#This library is free software; you can redistribute it and/or modify
8#it under the terms of the GNU General Public License as published by
9#the Free Software Foundation; either version 2, or (at your option)
10#any later version.
11#
12#GNU Fortran is distributed in the hope that it will be useful,
13#but WITHOUT ANY WARRANTY; without even the implied warranty of
14#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15#GNU Library General Public License for more details.
16#
17#You should have received a copy of the GNU Library General Public
18#License along with GNU Fortran; see the file COPYING. If not, write
19#to Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
20#USA.
21
22AC_PREREQ(2.12.1)
23AC_INIT(access_.c)
24AC_CONFIG_HEADER(config.h:config.hin)
25
26dnl FIXME AC_PROG_CC wants CC to be able to link things, but it may
27dnl not be able to.
28define([AC_PROG_CC_WORKS],[])
29
30# For g77 we'll set CC to point at the built gcc, but this will get it into
31# the makefiles
32AC_PROG_CC
33
34# These defines are necessary to get 64-bit file size support.
35# NetBSD 1.4 header files does not support XOPEN_SOURCE == 600, but it
36# handles 64-bit file sizes without needing these defines.
37AC_MSG_CHECKING(whether _XOPEN_SOURCE may be defined)
38AC_TRY_COMPILE([#define _XOPEN_SOURCE 600L
39#include <unistd.h>],,
40may_use_xopen_source=yes,
41may_use_xopen_source=no)
42AC_MSG_RESULT($may_use_xopen_source)
43if test $may_use_xopen_source = yes; then
44 AC_DEFINE(_XOPEN_SOURCE, 600L, [Get Single Unix Specification semantics])
45 # The following is needed by irix6.2 so that struct timeval is declared.
46 AC_DEFINE(_XOPEN_SOURCE_EXTENDED, 1, [Get Single Unix Specification semantics])
47 # The following is needed by Solaris2.5.1 so that struct timeval is declared.
48 AC_DEFINE(__EXTENSIONS__, 1, [Solaris extensions])
49 AC_DEFINE(_FILE_OFFSET_BITS, 64, [Get 64-bit file size support])
50fi
51
52dnl Checks for programs.
53
54LIBTOOL='$(SHELL) ../libtool'
55AC_SUBST(LIBTOOL)
56
57dnl AC_C_CROSS
58dnl Gives misleading `(cached)' message from the check.
59if test "$CROSS";then
60 ac_cv_c_cross=yes
61else
62 ac_cv_c_cross=no
63fi
64
65test "$AR" || AR=ar
66AC_SUBST(AR)
67AC_PROG_MAKE_SET
68
69dnl This is only because we (horribly) punt the chmod job to the program at
70dnl present. Note that the result of this test could be wrong in the cross
71dnl case.
72AC_PATH_PROG(ac_cv_prog_chmod, chmod, no)
73if test "$ac_cv_prog_chmod" != no || test "$CROSS"; then
74 MAYBES=chmod_.o
75 AC_DEFINE_UNQUOTED(CHMOD_PATH,"$ac_cv_prog_chmod")
76else
77 MAYBES=""
78fi
79
80dnl Checks for header files.
81AC_HEADER_STDC
82AC_HEADER_TIME
83AC_CHECK_HEADERS(limits.h unistd.h sys/time.h string.h stdlib.h \
84 sys/param.h sys/times.h)
85
86dnl Checks for typedefs, structures, and compiler characteristics.
87AC_C_CONST
88AC_TYPE_SIZE_T
89AC_TYPE_MODE_T
90
91AC_TYPE_PID_T
92dnl The next 3 demand a dummy fileblocks.o (added to LIBOJS). We don't use
93dnl LIBOJS, though.
94AC_STRUCT_ST_BLKSIZE
95AC_STRUCT_ST_BLOCKS
96AC_STRUCT_ST_RDEV
97AC_STRUCT_TM
98
99dnl Some systems (SVR4, SCO OpenServer) need -lsocket for gethostname()
100AC_CHECK_LIB(socket, gethostname, [LIBS="$LIBS -lsocket"])
101
102dnl Checks for library functions.
103
104AC_CHECK_FUNCS(symlink getcwd getwd lstat gethostname strerror clock \
105 getrusage times alarm getlogin getgid getuid kill link ttyname)
106
107dnl The standard autoconf HAVE_STRUCT_TIMEZONE doesn't actually check
108dnl for struct timezone, as you might think. We also need to check how
109dnl to call gettimeofday if we have it.
110LIBU77_GETTIMEOFDAY
111
112test $ac_cv_func_symlink = yes && MAYBES="$MAYBES symlnk_.o"
113test $ac_cv_func_lstat = yes && MAYBES="$MAYBES lstat_.o"
114test $ac_cv_func_gethostname = yes && MAYBES="$MAYBES hostnm_.o"
115test $ac_cv_func_clock = yes && MAYBES="$MAYBES mclock_.o"
116AC_SUBST(MAYBES)
117
118AC_SUBST(CROSS)
119AC_SUBST(RANLIB)
120AC_SUBST(RANLIB_TEST)
121
122AC_OUTPUT(Makefile)
Note: See TracBrowser for help on using the repository browser.