annotate configure.in @ 706:164e497d6039

[project @ 1994-09-15 15:21:45 by jwe]
author jwe
date Thu, 15 Sep 1994 15:21:47 +0000
parents 45764610984a
children 6caaaf4c5dd4
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
1 dnl configure.in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
2 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
3 dnl Process this file with autoconf to produce a configure script.
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
4 dnl Requires GNU autoconf 1.8 or later.
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
5 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
6 dnl Copyright (C) 1992, 1993, 1994 John W. Eaton
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
7 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
8 dnl This file is part of Octave.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
9 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
10 dnl Octave is free software; you can redistribute it and/or modify it
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
11 dnl under the terms of the GNU General Public License as published by the
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
12 dnl Free Software Foundation; either version 2, or (at your option) any
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
13 dnl later version.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
14 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
15 dnl Octave is distributed in the hope that it will be useful, but WITHOUT
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
16 dnl ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
17 dnl FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
18 dnl for more details.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
19 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
20 dnl You should have received a copy of the GNU General Public License
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
21 dnl along with Octave; see the file COPYING. If not, write to the Free
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
22 dnl Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
23 dnl
706
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
24 AC_REVISION($Revision: 1.46 $)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
25 AC_PREREQ(1.8)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
26 AC_INIT(src/octave.cc)
679
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
27 AC_CONFIG_HEADER(config.h kpathsea/c-auto.h)
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
28 dnl
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
29 AC_DEFINE(OCTAVE_SOURCE, 1)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
30 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
31 dnl See if we were given the target host type. If not, use
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
32 dnl config.guess to try to guess the target host type.
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
33 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
34 if test $# -gt 0; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
35 TARGET=`eval echo $\{\`echo $#\`\}`
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
36 case $TARGET in
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
37 -*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
38 target_host_type=
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
39 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
40 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
41 target_host_type=$TARGET
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
42 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
43 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
44 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
45 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
46 if test -z "$target_host_type" -o "$target_host_type" = unknown; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
47 target_host_type=`sh $srcdir/config.guess`
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
48 if test -z "$target_host_type"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
49 AC_WARN([unable to guess system type])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
50 target_host_type=unknown
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
51 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
52 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
53 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
54 dnl Use config.sub to come up with a standard vendor-host-os triple.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
55 dnl
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
56 canonical_host_type=`sh $srcdir/config.sub $target_host_type 2>&1`
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
57 status=$?
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
58 if test $status -eq 0; then
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
59 echo "configuring Octave for a $target_host_type"
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
60 else
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
61 canonical_host_type=unknown
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
62 AC_WARN([configuring Octave for an unknown system type])
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
63 fi
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
64 AC_SUBST(target_host_type)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
65 AC_VERBOSE([target_host_type is $target_host_type])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
66 AC_VERBOSE([canonical_host_type is $canonical_host_type])
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
67 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
68 dnl Allow the user to force us to use f2c.
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
69 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
70 AC_WITH(f2c, use_f2c=true, use_f2c=false)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
71 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
72 dnl Allow the user to experiment with dynamic linking using GNU dld.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
73 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
74 AC_ENABLE(dld, use_dld=true, use_dld=false)dnl
702
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
75 AC_SUBST(use_dld)dnl
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
76 dnl
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
77 dnl Allow compilation of smaller kernel. This only works if some form
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
78 dnl of dynamic linking is also supported and used.
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
79 dnl
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
80 AC_ENABLE(lite-kernel, lite_kernel=true, lite_kernel=false)dnl
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
81 if $lite_kernel; then
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
82 AC_DEFINE(OCTAVE_LITE, 1)dnl
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
83 fi
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
84 AC_SUBST(lite_kernel)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
85 dnl
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
86 dnl some defaults
424
9056cee2487d [project @ 1994-05-23 21:21:34 by jwe]
jwe
parents: 407
diff changeset
87 dnl
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
88 exec_prefix='$(prefix)'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
89 bindir='$(exec_prefix)/bin'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
90 datadir='$(prefix)/lib'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
91 libdir='$(exec_prefix)/lib'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
92 includedir='$(prefix)/include'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
93 mandir='$(prefix)/man/man1'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
94 infodir='$(prefix)/info'
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
95 fcnfiledir='$(datadir)/octave/$(version)/m'
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
96 localfcnfilepath='$(datadir)/octave/site-m'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
97 archlibdir='$(libdir)/octave/$(version)/$(target_host_type)/exec'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
98 octfiledir='$(archlibdir)/oct'
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
99 localoctfilepath='$(datadir)/octave/$(target_host_type)/site-oct'
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
100 fcnfilepath='.:$(localoctfilepath):$(localfcnfilepath):$(octfiledir):$(fcnfiledir)//'
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
101 imagepath='.:$(fcnfiledir)/imagelib//'
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
102 dnl
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
103 dnl Handle --enable-run-in-place. This option makes Octave look for
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
104 dnl info and function files in the same directory tree as the sources.
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
105 dnl
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
106 AC_ENABLE(run-in-place, [
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
107 run_in_place=true;
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
108 if test "$enableval" = "yes"; then
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
109 builddir="."
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
110 else
679
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
111 builddir=$enableval
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
112 fi
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
113 ], run_in_place=false)dnl
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
114 dnl
425
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
115 if $run_in_place; then
424
9056cee2487d [project @ 1994-05-23 21:21:34 by jwe]
jwe
parents: 407
diff changeset
116 AC_DEFINE(RUN_IN_PLACE, 1)dnl
425
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
117 case "$srcdir" in
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
118 /*)
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
119 absolute_srcdir=$srcdir
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
120 ;;
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
121 *)
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
122 AC_WARN([making srcdir absolute -- may lose with automounter])
425
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
123 absolute_srcdir=`(cd $srcdir; pwd)`
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
124 ;;
4eb46050dba3 [project @ 1994-05-23 22:04:30 by jwe]
jwe
parents: 424
diff changeset
125 esac
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
126 case "$builddir" in
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
127 /*)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
128 absolute_builddir=$builddir
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
129 ;;
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
130 *)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
131 AC_WARN([making builddir absolute -- may lose with automounter])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
132 absolute_builddir=`(cd $builddir; pwd)`
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
133 ;;
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
134 esac
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
135 absolute_builddir=$absolute_builddir
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
136 prefix=$absolute_srcdir
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
137 infodir=$absolute_srcdir/info
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
138 fcnfiledir=$absolute_srcdir/scripts
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
139 archlibdir=$absolute_builddir
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
140 fcnfilepath='.:$(fcnfiledir)//'
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
141 imagepath='.:$(fcnfiledir)/imagelib//'
424
9056cee2487d [project @ 1994-05-23 21:21:34 by jwe]
jwe
parents: 407
diff changeset
142 fi
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
143 AC_VERBOSE([setting prefix to $prefix])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
144 AC_VERBOSE([setting exec_prefix to $exec_prefix])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
145 AC_VERBOSE([setting bindir to $bindir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
146 AC_VERBOSE([setting datadir to $datadir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
147 AC_VERBOSE([setting libdir to $libdir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
148 AC_VERBOSE([setting includedir to $includedir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
149 AC_VERBOSE([setting mandir to $mandir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
150 AC_VERBOSE([setting infodir to $infodir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
151 AC_VERBOSE([setting fcnfiledir to $fcnfiledir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
152 AC_VERBOSE([setting localfcnfilepath to $localfcnfilepath])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
153 AC_VERBOSE([setting archlibdir to $archlibdir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
154 AC_VERBOSE([setting octfiledir to $octfiledir])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
155 AC_VERBOSE([setting localoctfilepath to $localoctfilepath])
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
156 AC_VERBOSE([setting fcnfilepath to $fcnfilepath])
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
157 AC_VERBOSE([setting imagepath to $imagepath])
666
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
158 AC_SUBST(exec_prefix)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
159 AC_SUBST(bindir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
160 AC_SUBST(datadir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
161 AC_SUBST(libdir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
162 AC_SUBST(includedir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
163 AC_SUBST(mandir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
164 AC_SUBST(infodir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
165 AC_SUBST(fcnfiledir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
166 AC_SUBST(localfcnfilepath)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
167 AC_SUBST(archlibdir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
168 AC_SUBST(octfiledir)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
169 AC_SUBST(localoctfilepath)
fb4f6556b443 [project @ 1994-09-06 21:22:46 by jwe]
jwe
parents: 638
diff changeset
170 AC_SUBST(fcnfilepath)
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
171 AC_SUBST(imagepath)
424
9056cee2487d [project @ 1994-05-23 21:21:34 by jwe]
jwe
parents: 407
diff changeset
172 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
173 DYNAMIC_LD_OBJ=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
174 DLD_DIR=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
175 LIBDLD=
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
176 LIBOCTDLD='../liboctdld.a'
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
177 LD_STATIC_FLAG=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
178 if $use_dld; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
179 DYNAMIC_LD_OBJ='dynamic-ld.o'
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
180 DLD_DIR=dld
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
181 LIBDLD='../libdld.a'
702
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
182 # don't link them in only if doing dynamic linking and small kernel
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
183 # requested.
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
184 if $lite_kernel; then
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
185 LIBOCTDLD=
45764610984a [project @ 1994-09-15 02:32:47 by jwe]
jwe
parents: 684
diff changeset
186 fi
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
187 LD_STATIC_FLAG=-static
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
188 AC_DEFINE(WITH_DLD, 1)dnl
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
189 fi
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
190 if test -n "$DYNAMIC_LD_OBJ"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
191 AC_VERBOSE([setting DYNAMIC_LD_OBJ to $DYNAMIC_LD_OBJ])
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
192 fi
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
193 if test -n "$DLD_DIR"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
194 AC_VERBOSE([setting DLD_DIR to $DLD_DIR])
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
195 fi
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
196 if test -n "$LIBDLD"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
197 AC_VERBOSE([setting LIBDLD to $LIBDLD])
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
198 fi
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
199 if test -n "$LIBOCTDLD"; then
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
200 AC_VERBOSE([setting LIBOCTDLD to $LIBOCTDLD])
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
201 fi
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
202 if test -n "$LD_STATIC_FLAG"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
203 AC_VERBOSE([setting LD_STATIC_FLAG to $LD_STATIC_FLAG])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
204 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
205 AC_SUBST(DYNAMIC_LD_OBJ)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
206 AC_SUBST(DLD_DIR)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
207 AC_SUBST(LIBDLD)dnl
518
2349d5721cd9 [project @ 1994-07-19 14:31:14 by jwe]
jwe
parents: 505
diff changeset
208 AC_SUBST(LIBOCTDLD)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
209 AC_SUBST(LD_STATIC_FLAG)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
210 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
211 dnl See if the optional nonlinear programming code is present.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
212 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
213 AC_CHECKING([for npsol])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
214 if test -f $srcdir/libcruft/npsol/npsol.f; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
215 :
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
216 else
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
217 AC_DEFINE(NPSOL_MISSING, 1)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
218 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
219 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
220 AC_CHECKING([for qpsol])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
221 if test -f $srcdir/libcruft/qpsol/qpsol.f; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
222 :
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
223 else
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
224 AC_DEFINE(QPSOL_MISSING, 1)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
225 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
226 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
227 AC_CHECKING([for fsqp])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
228 if test -f $srcdir/libcruft/fsqp/fsqpd.f; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
229 :
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
230 else
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
231 AC_DEFINE(FSQP_MISSING, 1)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
232 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
233 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
234 dnl See which C++ compiler to use (we expect to find g++).
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
235 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
236 AC_PROG_CXX
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
237 AC_PROG_CXXCPP
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
238 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
239 dnl Do special things for g++.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
240 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
241 ADD_CXX_WALL=false
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
242 gxx_version=`$CXX -v 2>&1 | grep "^g.. version" | sed 's/^g.. version *//'`
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
243 case "$gxx_version" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
244 2.5.*|2.6.*|2.7.*|2.8.*|2.9.*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
245 CXXFLAGS="-g -O"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
246 AC_VERBOSE([setting CXXFLAGS to $CXXFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
247 EXTERNAL_TEMPLATES="-fexternal-templates"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
248 AC_VERBOSE([setting EXTERNAL_TEMPLATES to $EXTERNAL_TEMPLATES])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
249 ADD_CXX_WALL=true
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
250 AC_DEFINE(USE_EXTERNAL_TEMPLATES, 1)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
251 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
252 1.*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
253 AC_WARN([g++ version $gxx_version will not work to compile Octave])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
254 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
255 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
256 AC_WARN([Octave has only been tested with g++, and I can't find it])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
257 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
258 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
259 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
260 AC_SUBST(CXXFLAGS)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
261 AC_SUBST(EXTERNAL_TEMPLATES)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
262 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
263 dnl See which C compiler to use (we expect to find gcc).
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
264 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
265 AC_PROG_CC
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
266 AC_PROG_CPP
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
267 AC_GCC_TRADITIONAL
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
268 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
269 dnl Do special things for gcc.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
270 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
271 ADD_CC_WALL=false
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
272 gcc_version=`$CC -v 2>&1 | grep "^gcc version" | sed 's/^gcc version *//'`
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
273 case "$gcc_version" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
274 2.*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
275 CFLAGS="-g -O"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
276 AC_VERBOSE([setting CFLAGS to $CFLAGS])
638
2f2e66230c22 [project @ 1994-08-23 21:27:01 by jwe]
jwe
parents: 602
diff changeset
277 LDFLAGS="-g"
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
278 AC_VERBOSE([setting LDFLAGS to $LDFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
279 ADD_CC_WALL=true
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
280 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
281 1.*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
282 AC_WARN([gcc version $gcc_version is likely to cause problems])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
283 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
284 *)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
285 AC_WARN([Octave has only been tested with gcc, and I can't find it])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
286 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
287 esac
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
288 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
289 AC_SUBST(CFLAGS)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
290 AC_SUBST(LDFLAGS)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
291 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
292 dnl On Linux systems we need to compile with -mieee-fp to get full
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
293 dnl support for IEEE floating point.
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
294 dnl
350
52f8902e06f9 [project @ 1994-02-10 08:08:57 by jwe]
jwe
parents: 324
diff changeset
295 case "$canonical_host_type" in
52f8902e06f9 [project @ 1994-02-10 08:08:57 by jwe]
jwe
parents: 324
diff changeset
296 i386-*-linux | i486-*-linux | i586-*-linux)
52f8902e06f9 [project @ 1994-02-10 08:08:57 by jwe]
jwe
parents: 324
diff changeset
297 GCC_IEEE_FP_FLAG="-mieee-fp"
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
298 AC_VERBOSE([setting GCC_IEEE_FP_FLAG to $GCC_IEEE_FP_FLAG])
324
7bf8cd7cafde [project @ 1994-02-02 10:58:58 by jwe]
jwe
parents: 317
diff changeset
299 ;;
7bf8cd7cafde [project @ 1994-02-02 10:58:58 by jwe]
jwe
parents: 317
diff changeset
300 esac
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
301 dnl
324
7bf8cd7cafde [project @ 1994-02-02 10:58:58 by jwe]
jwe
parents: 317
diff changeset
302 AC_SUBST(GCC_IEEE_FP_FLAG)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
303 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
304 dnl Special checks for odd OS specific things.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
305 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
306 AC_ISC_POSIX
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
307 AC_MINIX
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
308 AC_AIX
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
309 AC_DYNIX_SEQ
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
310 AC_IRIX_SUN
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
311 AC_SCO_INTL
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
312 AC_XENIX_DIR
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
313 dnl
602
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
314 dnl How big are ints and how are they oriented?
589
81b973e373f9 [project @ 1994-08-07 23:32:10 by jwe]
jwe
parents: 588
diff changeset
315 dnl
81b973e373f9 [project @ 1994-08-07 23:32:10 by jwe]
jwe
parents: 588
diff changeset
316 AC_SIZEOF_TYPE(short)
81b973e373f9 [project @ 1994-08-07 23:32:10 by jwe]
jwe
parents: 588
diff changeset
317 AC_SIZEOF_TYPE(int)
81b973e373f9 [project @ 1994-08-07 23:32:10 by jwe]
jwe
parents: 588
diff changeset
318 AC_SIZEOF_TYPE(long)
602
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
319 AC_WORDS_BIGENDIAN
589
81b973e373f9 [project @ 1994-08-07 23:32:10 by jwe]
jwe
parents: 588
diff changeset
320 dnl
588
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
321 dnl Try to determine the floating point format.
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
322 dnl
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
323 AC_CHECKING([floating point format])
602
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
324 changequote(,)dnl
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
325 XCFLAGS=`echo $CFLAGS | sed 's/-O[^ \t]*//'`
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
326 changequote([,])dnl
8b6294ae881e [project @ 1994-08-13 16:29:27 by jwe]
jwe
parents: 589
diff changeset
327 ${CC-cc} -DDP $XCFLAGS $LDFLAGS $srcdir/float-type.c -o conftest >/dev/null 2>&1
588
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
328 FLOAT_FORMAT=`./conftest`
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
329 case "$FLOAT_FORMAT" in
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
330 IEEE_BIG_ENDIAN)
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
331 AC_DEFINE(IEEE_BIG_ENDIAN, 1)dnl
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
332 ;;
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
333 IEEE_LITTLE_ENDIAN)
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
334 AC_DEFINE(IEEE_LITTLE_ENDIAN, 1)dnl
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
335 ;;
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
336 VAX_D_FLOAT)
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
337 AC_DEFINE(VAX_D_FLOAT, 1)dnl
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
338 ;;
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
339 VAX_G_FLOAT)
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
340 AC_DEFINE(VAX_G_FLOAT, 1)dnl
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
341 ;;
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
342 *)
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
343 AC_WARN("unrecognized floating point format!")
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
344 ;;
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
345 esac
9b02a14aaaea [project @ 1994-08-07 23:03:57 by jwe]
jwe
parents: 521
diff changeset
346 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
347 dnl Does the C compiler handle alloca() and const correctly?
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
348 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
349 AC_ALLOCA
679
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
350 dnl
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
351 dnl It would be nicer to test for the requisite putenv features directly,
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
352 dnl but can't figure out how to do that.
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
353 dnl
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
354 if test "`(uname) 2>/dev/null`" = NetBSD \
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
355 || test "`(uname) 2>/dev/null`" = FreeBSD; then
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
356 AC_DEFINE(SMART_PUTENV)
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
357 fi
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
358 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
359 AC_CONST
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
360 dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
361 dnl If we haven't been forced to use f2c, try to find a Fortran compiler
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
362 dnl under any one of several common Un*x Fortran compiler names.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
363 dnl Put fc last to avoid confusion with some vendor's /bin/sh fc
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
364 dnl builtin.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
365 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
366 dnl xlf : IBM / AIX
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
367 dnl cf77 : Cray / Unicos
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
368 dnl g77 : GNU Fortran (someday...)
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
369 dnl fc : Convex
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
370 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
371 dnl I don't think the Cray compiler will ever work like f2c...
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
372 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
373 if $use_f2c; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
374 true
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
375 else
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
376 F77=
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
377 AC_PROGRAMS_CHECK(F77, xlf cf77 f77 g77 fc)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
378
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
379 # If it looks like we have a Fortran compiler, try to determine
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
380 # whether it might be compatible with f2c.
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
381
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
382 if test -n "$F77"; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
383 AC_CHECKING([$F77/f2c compatibility])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
384 export F77
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
385 export CC
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
386 tmpdef=`sh $srcdir/f2c-compat.sh $srcdir/flibs.sh`
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
387 status=$?
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
388 if test $status -eq 0; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
389 if test "$tmpdef" = '-DF77_APPEND_UNDERSCORE=1'; then
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
390 AC_DEFINE(F77_APPEND_UNDERSCORE, 1)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
391 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
392 else
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
393 F77=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
394 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
395 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
396 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
397 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
398 dnl If we can't find a Fortran compiler, or if it looks like it isn't
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
399 dnl compatible with f2c, try to find f2c.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
400 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
401 if test -z "$F77"; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
402 AC_PROGRAM_CHECK(F2C, f2c, f2c, [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
403 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
404 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
405 F2CFLAGS=
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
406 AC_VERBOSE([setting F2CFLAGS to $F2CFLAGS])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
407 FFLAGS="-O"
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
408 AC_VERBOSE([setting FFLAGS to $FFLAGS])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
409 if test -n "$F77"; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
410 export F77
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
411 FLIBS=`sh $srcdir/flibs.sh`
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
412 AC_VERBOSE([setting FLIBS to $FLIBS])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
413 DOT_O_DOT_F_C1=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
414 DOT_O_DOT_F_C2=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
415 DOT_O_DOT_F_C3=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
416 DOT_O_DOT_F_C4=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
417 DEFAULT_DOT_C_FROM_DOT_F=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
418 DEFAULT_DOT_O_FROM_DOT_F=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
419 elif test -n "$F2C" || $use_f2c; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
420 AC_HAVE_LIBRARY(f2c, FLIBS=-lf2c, [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
421 if test -z "$FLIBS" ; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
422 AC_HAVE_LIBRARY(F77, FLIBS=-lF77, [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
423 if test -n "$FLIBS" ; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
424 AC_HAVE_LIBRARY(I77, FLIBS="$FLIBS -lI77", [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
425 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
426 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
427 if test -z "$FLIBS" ; then
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
428 AC_WARN([I found f2c but not libf2c.a, or libF77.a and libI77.a])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
429 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
430 DEFAULT_DOT_C_FROM_DOT_F='# A rule for making C source from Fortran source.\
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
431 # If we are using f2c we should also turn off the default rule for\
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
432 # making objects from .f files so that we do not invoke the fortran\
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
433 # compiler by mistake.\
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
434 \
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
435 \%.c : \%.f\
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
436 cat $< | $(F2C) $(F2CFLAGS) > $(@F)'
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
437 AC_VERBOSE([setting DEFAULT_DOT_C_FROM_DOT_F to $DEFAULT_DOT_C_FROM_DOT_F])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
438 DEFAULT_DOT_O_FROM_DOT_F='\%.o : \%.f'
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
439 AC_VERBOSE([setting DEFAULT_DOT_O_FROM_DOT_F to $DEFAULT_DOT_O_FROM_DOT_F])
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
440 AC_DEFINE(F77_APPEND_UNDERSCORE, 1)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
441 else
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
442 AC_WARN([in order to build octave, you must have a compatible])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
443 AC_WARN([Fortran compiler or f2c installed and in your path.])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
444 AC_WARN([See the file INSTALL for more information.])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
445 AC_WARN([Continuing anyway...])
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
446 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
447 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
448 AC_SUBST(FFLAGS)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
449 AC_SUBST(FLIBS)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
450 AC_SUBST(F2C)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
451 AC_SUBST(F2CFLAGS)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
452 AC_SUBST(DEFAULT_DOT_C_FROM_DOT_F)dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
453 AC_SUBST(DEFAULT_DOT_O_FROM_DOT_F)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
454 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
455 dnl Checks for header files.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
456 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
457 AC_STDC_HEADERS
679
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
458 AC_HAVE_HEADERS(assert.h float.h limits.h memory.h pwd.h stdlib.h)dnl
402
431896eee4db [project @ 1994-04-15 07:04:00 by jwe]
jwe
parents: 369
diff changeset
459 AC_HAVE_HEADERS(string.h varargs.h unistd.h floatingpoint.h)dnl
431896eee4db [project @ 1994-04-15 07:04:00 by jwe]
jwe
parents: 369
diff changeset
460 AC_HAVE_HEADERS(sys/utsname.h sys/time.h sys/fcntl.h)dnl
431896eee4db [project @ 1994-04-15 07:04:00 by jwe]
jwe
parents: 369
diff changeset
461 AC_HAVE_HEADERS(sys/ttold.h sys/ptem.h sys/select.h)dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
462 AC_DIR_HEADER
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
463 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
464 dnl Use sgtty on Ultrix so that using DEC Migrate to convert a Mips
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
465 dnl binary to an Alpha binary will work.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
466 dnl
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
467 case "$canonical_host_type" in
521
af19ffbbe91d [project @ 1994-07-20 18:12:53 by jwe]
jwe
parents: 518
diff changeset
468 mips-dec-ultrix* | alpha-dec-osf*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
469 AC_HEADER_CHECK(sgtty.h, AC_DEFINE(HAVE_SGTTY_H, 1), [])
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
470 ;;
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
471 esac
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
472 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
473 case "$DEFS" in
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
474 *HAVE_SGTTY_H*)
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
475 ;;
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
476 *)
294
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
477 AC_HEADER_CHECK(termios.h, AC_DEFINE(HAVE_TERMIOS_H, 1),
9f0bbc75741f [project @ 1994-01-16 01:16:26 by jwe]
jwe
parents: 287
diff changeset
478 AC_HEADER_CHECK(termio.h, AC_DEFINE(HAVE_TERMIO_H, 1),
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
479 AC_HEADER_CHECK(sgtty.h, AC_DEFINE(HAVE_SGTTY_H, 1), [])))
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
480 ;;
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
481 esac
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
482 case "$DEFS" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
483 *HAVE_TERMIOS_H* | *HAVE_TERMIO_H* | *HAVE_SGTTY_H*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
484 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
485 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
486 AC_ERROR([I couldn't find termios.h, termio.h, or sgtty.h!])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
487 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
488 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
489 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
490 dnl Checks for functions.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
491 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
492 AC_HAVE_FUNCS(setvbuf getcwd gethostname bzero rindex vfprintf vsprintf)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
493 AC_HAVE_FUNCS(stricmp strnicmp strcasecmp strncasecmp strerror)dnl
679
93c63deed7aa [project @ 1994-09-09 13:50:40 by jwe]
jwe
parents: 670
diff changeset
494 AC_HAVE_FUNCS(atexit on_exit tempnam memmove putenv)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
495 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
496 dnl Check to see if we have IEEE math functions, and if so, which ones.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
497 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
498 dnl For Linux: add -mieee-fp flag to CFLAGS when checking for IEEE FP
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
499 dnl functions, otherwise we may not find them.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
500 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
501 dnl Also just using AC_HAVE_FUNCS doesn't seem to work to find isinf
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
502 dnl and isnan on Linux systems, so we use AC_FUNC_CHECK, and if that
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
503 dnl fails, we try again by including math.h and invoking the function
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
504 dnl with an argument.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
505 dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
506 dnl Also check for some additional trig functions that aren't ANSI but
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
507 dnl are often available. If they are missing, we try to replace them
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
508 dnl with functions from the BSD/NET2 math library.
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
509 dnl
28
969b6494a10c [project @ 1993-08-10 21:17:28 by jwe]
jwe
parents: 5
diff changeset
510 AC_HAVE_LIBRARY(-lm)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
511 dnl
360
273f0b941c51 [project @ 1994-02-11 17:38:57 by jwe]
jwe
parents: 351
diff changeset
512 XCFLAGS="$CFLAGS"
351
aaf43fb91f39 [project @ 1994-02-10 08:55:38 by jwe]
jwe
parents: 350
diff changeset
513 CFLAGS="$CFLAGS $GCC_IEEE_FP_FLAG"
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
514 for func in finite isnan isinf
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
515 do
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
516 trfunc=`echo $func | tr '[a-z]' '[A-Z]'`
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
517 AC_FUNC_CHECK([$func],
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
518 AC_DEFINE(HAVE_[$trfunc], 1),
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
519 AC_COMPILE_CHECK([$func], [#include <math.h>], [
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
520 /* The GNU C library defines this for functions which it implements
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
521 to always fail with ENOSYS. Some functions are actually named
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
522 something starting with __ and the normal name is an alias. */
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
523 #if defined (__stub_$func) || defined (__stub___$func)
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
524 choke me
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
525 #else
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
526 /* Override any gcc2 internal prototype to avoid an error. */
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
527 $func (1.0);
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
528 #endif
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
529 ],
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
530 AC_DEFINE(HAVE_[$trfunc], 1), []))dnl
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
531 done
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
532 dnl
468
c35a1ee8d272 [project @ 1994-06-06 01:13:08 by jwe]
jwe
parents: 425
diff changeset
533 AC_HAVE_FUNCS(infinity quiet_nan)dnl
638
2f2e66230c22 [project @ 1994-08-23 21:27:01 by jwe]
jwe
parents: 602
diff changeset
534 AC_HAVE_FUNCS(erf erfc lgamma)dnl
468
c35a1ee8d272 [project @ 1994-06-06 01:13:08 by jwe]
jwe
parents: 425
diff changeset
535 dnl
706
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
536 AC_COMPILE_CHECK([signgam declaration in math.h],
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
537 [#include <math.h>],
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
538 [int foo = signgam + 1;],
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
539 AC_DEFINE(SIGNGAM_DECLARED, 1), [])dnl
164e497d6039 [project @ 1994-09-15 15:21:45 by jwe]
jwe
parents: 702
diff changeset
540 dnl
360
273f0b941c51 [project @ 1994-02-11 17:38:57 by jwe]
jwe
parents: 351
diff changeset
541 CFLAGS="$XCFLAGS"
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
542 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
543 dnl Check for nonstandard but common trig functions that we need.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
544 dnl If they are missing, we replace them using functions from the BSD
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
545 dnl math library, and we may need to replace some other functions too.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
546 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
547 AC_REPLACE_FUNCS(acosh asinh atanh)
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
548 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
549 if test -n "$LIBOBJS"; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
550 for func in $LIBOBJS
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
551 do
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
552 case "$func" in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
553 *acosh.o*)
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
554 AC_DEFINE(ACOSH_MISSING, 1)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
555 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
556 *asinh.o*)
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
557 AC_DEFINE(ASINH_MISSING, 1)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
558 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
559 *atanh.o*)
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
560 AC_DEFINE(ATANH_MISSING, 1)dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
561 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
562 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
563 done
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
564 case $LIBOBJS in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
565 *acosh.o* | *asinh.o*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
566 AC_REPLACE_FUNCS(copysign)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
567 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
568 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
569 case $LIBOBJS in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
570 *acosh.o* | *asinh.o* | *atanh.o*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
571 AC_REPLACE_FUNCS(log1p)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
572 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
573 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
574 case $LIBOBJS in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
575 *log1p*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
576 AC_REPLACE_FUNCS(log__L)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
577 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
578 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
579 case $LIBOBJS in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
580 *log1p*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
581 AC_REPLACE_FUNCS(finite)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
582 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
583 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
584 case $LIBOBJS in
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
585 *copysign* | *finite* | *log1p*)
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
586 AC_REPLACE_FUNCS(logb scalb)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
587 ;;
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
588 esac
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
589 fi
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
590 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
591 dnl Checks for OS specific cruft.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
592 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
593 AC_STRUCT_TM
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
594 AC_SETVBUF_REVERSED
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
595 TERMLIBS=""
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
596 for termlib in termcap terminfo curses termlib ; do
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
597 AC_HAVE_LIBRARY(${termlib}, [TERMLIBS="${TERMLIBS} -l${termlib}"])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
598 case "${TERMLIBS}" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
599 *-l${termlib}*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
600 AC_VERBOSE([setting TERMLIBS to $TERMLIBS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
601 break
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
602 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
603 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
604 done
505
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
605 dnl
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
606 AC_COMPILE_CHECK([struct exception in math.h],
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
607 [#include <math.h>],
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
608 [struct exception *x; x->type; x->name;],
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
609 AC_DEFINE(EXCEPTION_IN_MATH, 1), [])dnl
f264c1454c2b [project @ 1994-07-09 06:02:45 by jwe]
jwe
parents: 468
diff changeset
610 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
611 AC_SUBST(TERMLIBS)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
612 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
613 dnl Define VOID_SIGHANDLER for readline.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
614 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
615 AC_RETSIGTYPE
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
616 case "$RETSIGTYPE" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
617 int)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
618 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
619 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
620 VOID_SIGHANDLER="-DVOID_SIGHANDLER=1"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
621 AC_VERBOSE([defining VOID_SIGHANDLER to be 1])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
622 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
623 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
624 AC_SUBST(VOID_SIGHANDLER)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
625 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
626 dnl Checks for other programs used for building, testing, installing,
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
627 dnl and running Octave.
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
628 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
629 dnl For now, don't define LEXLIB to be -lfl -- we don't use anything in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
630 dnl it, and it might not be installed.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
631 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
632 dnl Also make sure that we generate an interactive scanner if we are
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
633 dnl using flex.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
634 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
635 AC_PROG_LEX
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
636 case "$LEX" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
637 flex*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
638 LFLAGS="-t -I"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
639 AC_VERBOSE([setting LFLAGS to be $LFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
640 LEXLIB=
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
641 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
642 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
643 LFLAGS="-t"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
644 AC_VERBOSE([setting LFLAGS to be $LFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
645 AC_WARN([I didn't find flex, but that's only a problem])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
646 AC_WARN([if you need to reconstruct lex.cc])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
647 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
648 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
649 AC_SUBST(LFLAGS)dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
650 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
651 AC_PROG_YACC
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
652 case "$YACC" in
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
653 bison*)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
654 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
655 *)
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
656 AC_WARN([I didn't find bison, but that's only a problem])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
657 AC_WARN([if you need to reconstruct parse.cc])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
658 ;;
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
659 esac
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
660 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
661 AC_PROG_RANLIB
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
662 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
663 AC_PROGRAM_CHECK(RUNTEST, runtest, runtest, [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
664 AC_PROGRAM_CHECK(EXPECT, expect, expect, [])dnl
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
665 if test -z "$EXPECT" ; then
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
666 RUNTEST=
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
667 fi
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
668 AC_SUBST(RUNTEST)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
669 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
670 AC_PROG_INSTALL
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
671 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
672 AC_PROGRAM_CHECK(GNUPLOT_BINARY, gnuplot, gnuplot, [])dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
673 if test -z "$GNUPLOT_BINARY"; then
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
674 AC_WARN([I didn't find gnuplot. It isn't necessary to have gnuplot])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
675 AC_WARN([installed, but you won't be able to use any of Octave's])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
676 AC_WARN([plotting commands without it.])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
677 AC_WARN([])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
678 AC_WARN([If gnuplot is installed but it isn't in your path, you can])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
679 AC_WARN([tell Octave where to find it by typing the command])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
680 AC_WARN([])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
681 AC_WARN([gnuplot_binary = "/full/path/to/gnuplot/binary"])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
682 AC_WARN([])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
683 AC_WARN([at the Octave prompt.])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
684 fi
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
685 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
686 AC_PROGRAMS_CHECK(DEFAULT_PAGER, less more page pg, [])dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
687 if test -z "$DEFAULT_PAGER"; then
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
688 AC_WARN([I couldn't find `less', `more', `page', or `pg'])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
689 elif test "$DEFAULT_PAGER" = less; then
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
690 DEFAULT_PAGER="less -e"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
691 AC_VERBOSE([setting DEFAULT_PAGER to be $DEFAULT_PAGER])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
692 fi
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
693 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
694 dnl Even though we include config.h in most files, some need to be
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
695 dnl compiled with the -D options on the compiler command line. Use
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
696 dnl UGLY_DEFS for that.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
697 dnl
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
698 UGLY_DEFS="$DEFS"
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
699 AC_VERBOSE([setting UGLY_DEFS to be $UGLY_DEFS])
236
93bbd907de34 [project @ 1993-11-30 20:21:19 by jwe]
jwe
parents: 219
diff changeset
700 AC_SUBST(UGLY_DEFS)dnl
369
f436b7a5f26a [project @ 1994-02-17 04:49:21 by jwe]
jwe
parents: 365
diff changeset
701 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
702 dnl Maybe add -Wall to compiler flags now that we're done feature
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
703 dnl testing.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
704 dnl
670
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
705 dnl To get gcc and g++ to be really picky, try these adding these
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
706 dnl options to CFLAGS and CXXFLAGS along with -Wall:
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
707 dnl
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
708 dnl -ansi
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
709 dnl -pedantic
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
710 dnl -Wwrite-strings
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
711 dnl -Wid-clash-31
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
712 dnl -Wpointer-arith
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
713 dnl -Wcast-qual
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
714 dnl -Wenum-clash
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
715 dnl -Wcast-align
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
716 dnl -Wtraditional
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
717 dnl -Wstrict-prototypes
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
718 dnl -Wmissing-prototypes
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
719 dnl -Wnested-externs
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
720 dnl -Woverloaded-virtual
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
721 dnl -Winline
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
722 dnl -felide-constructors
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
723 dnl -fnonnull-objects
991303b21bae [project @ 1994-09-07 17:47:52 by jwe]
jwe
parents: 666
diff changeset
724 dnl
405
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
725 if $ADD_CXX_WALL; then
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
726 CXXFLAGS="$CXXFLAGS -Wall"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
727 AC_VERBOSE([adding -Wall to CXXFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
728 fi
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
729 if $ADD_CC_WALL; then
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
730 CFLAGS="$CFLAGS -Wall"
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
731 AC_VERBOSE([adding -Wall to CFLAGS])
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
732 fi
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
733 dnl
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
734 dnl Do the substitutions in all the Makefiles.
fa84be0c4fed [project @ 1994-04-20 05:53:20 by jwe]
jwe
parents: 402
diff changeset
735 dnl
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
736 define([tmpA], [Makefile Makeconf libcruft/Makefile libcruft/Makerules])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
737 define([tmpB], [liboctave/Makefile src/Makefile dld/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
738 define([tmpC], [info/Makefile readline/Makefile readline/doc/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
739 define([tmpD], [readline/examples/Makefile doc/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
740 define([tmpE], [test/Makefile kpathsea/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
741 define([srcdirs], [tmpA tmpB tmpC tmpD tmpE])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
742 dnl
39
82c3febbaf04 [project @ 1993-08-10 22:14:20 by jwe]
jwe
parents: 28
diff changeset
743 define([tmpa], [libcruft/blas/Makefile libcruft/balgen/Makefile])dnl
80
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
744 define([tmpb], [libcruft/dassl/Makefile libcruft/eispack/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
745 define([tmpc], [libcruft/fftpack/Makefile libcruft/fsqp/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
746 define([tmpd], [libcruft/lapack/Makefile libcruft/linpack/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
747 define([tmpe], [libcruft/minpack/Makefile libcruft/misc/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
748 define([tmpf], [libcruft/npsol/Makefile libcruft/odepack/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
749 define([tmpg], [libcruft/qpsol/Makefile libcruft/quadpack/Makefile])dnl
74f0d57ee66c [project @ 1993-08-30 19:47:16 by jwe]
jwe
parents: 39
diff changeset
750 define([tmph], [libcruft/ranlib/Makefile libcruft/villad/Makefile])dnl
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
751 dnl
5
9c27e323492f [project @ 1993-08-08 01:29:13 by jwe]
jwe
parents:
diff changeset
752 define([cruftdirs], [tmpa tmpb tmpc tmpd tmpe tmpf tmpg tmph])dnl
684
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
753 define([tmpSA], [scripts/Makefile scripts/control/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
754 define([tmpSB], [scripts/general/Makefile scripts/image/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
755 define([tmpSC], [scripts/linear-algebra/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
756 define([tmpSD], [scripts/miscellaneous/Makefile scripts/plot/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
757 define([tmpSE], [scripts/polynomial/Makefile scripts/set/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
758 define([tmpSF], [scripts/signal/Makefile scripts/special-matrix/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
759 define([tmpSG], [scripts/statistics/Makefile])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
760 define([scriptdirs], [tmpSA tmpSB tmpSC tmpSD tmpSE tmpSF tmpSG])dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
761 dnl
4e67ff861c84 [project @ 1994-09-09 17:39:43 by jwe]
jwe
parents: 679
diff changeset
762 AC_OUTPUT([srcdirs cruftdirs scriptdirs])dnl