diff configure.in @ 1667:f1b5a5086e46

[project @ 1995-12-26 04:14:18 by jwe]
author jwe
date Tue, 26 Dec 1995 04:15:08 +0000
parents 913a157f1e02
children 6e8ac624ed9b
line wrap: on
line diff
--- a/configure.in	Sun Dec 24 09:10:40 1995 +0000
+++ b/configure.in	Tue Dec 26 04:15:08 1995 +0000
@@ -20,7 +20,7 @@
 ### along with Octave; see the file COPYING.  If not, write to the Free
 ### Software Foundation, 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
-AC_REVISION($Revision: 1.143 $)
+AC_REVISION($Revision: 1.144 $)
 AC_PREREQ(2.0)
 AC_INIT(src/octave.cc)
 AC_CONFIG_HEADER(config.h)
@@ -39,6 +39,72 @@
 fi
 AC_SUBST(target_host_type)
 
+### some defaults
+
+AC_PREFIX_DEFAULT(/usr/local)
+
+exec_prefix='$(prefix)'
+bindir='$(exec_prefix)/bin'
+datadir='$(prefix)/lib'
+libdir='$(exec_prefix)/lib'
+includedir='$(prefix)/include/octave'
+mandir='$(prefix)/man/man1'
+infodir='$(prefix)/info'
+fcnfiledir='$(datadir)/octave/$(version)/m'
+localfcnfiledir='$(datadir)/octave/site/m'
+localfcnfilepath='$(localfcnfiledir)//'
+archlibdir='$(libdir)/octave/$(version)/exec/$(target_host_type)'
+octfiledir='$(libdir)/octave/$(version)/oct/$(target_host_type)'
+localoctfiledir='$(datadir)/octave/site/oct/$(target_host_type)'
+localoctfilepath='$(localoctfiledir)//'
+fcnfilepath='.:$(localoctfilepath):$(localfcnfilepath):$(octfiledir)//:$(fcnfiledir)//'
+imagedir='$(datadir)/octave/$(version)/imagelib'
+imagepath='.:$(imagedir)//'
+
+AC_MSG_RESULT([defining prefix to be $prefix])
+AC_MSG_RESULT([defining exec_prefix to be $exec_prefix])
+AC_MSG_RESULT([defining bindir to be $bindir])
+AC_MSG_RESULT([defining datadir to be $datadir])
+AC_MSG_RESULT([defining libdir to be $libdir])
+AC_MSG_RESULT([defining includedir to be $includedir])
+AC_MSG_RESULT([defining mandir to be $mandir])
+AC_MSG_RESULT([defining infodir to be $infodir])
+AC_MSG_RESULT([defining fcnfiledir to be $fcnfiledir])
+AC_MSG_RESULT([defining localfcnfiledir to be $localfcnfiledir])
+AC_MSG_RESULT([defining localfcnfilepath to be $localfcnfilepath])
+AC_MSG_RESULT([defining archlibdir to be $archlibdir])
+AC_MSG_RESULT([defining octfiledir to be $octfiledir])
+AC_MSG_RESULT([defining localoctfiledir to be $localoctfiledir])
+AC_MSG_RESULT([defining localoctfilepath to be $localoctfilepath])
+AC_MSG_RESULT([defining fcnfilepath to be $fcnfilepath])
+AC_MSG_RESULT([defining imagedir to be $imagedir])
+AC_MSG_RESULT([defining imagepath to be $imagepath])
+
+AC_SUBST(exec_prefix)
+AC_SUBST(bindir)
+AC_SUBST(datadir)
+AC_SUBST(libdir)
+AC_SUBST(includedir)
+AC_SUBST(mandir)
+AC_SUBST(infodir)
+AC_SUBST(fcnfiledir)
+AC_SUBST(localfcnfiledir)
+AC_SUBST(localfcnfilepath)
+AC_SUBST(archlibdir)
+AC_SUBST(octfiledir)
+AC_SUBST(localoctfiledir)
+AC_SUBST(localoctfilepath)
+AC_SUBST(fcnfilepath)
+AC_SUBST(imagedir)
+AC_SUBST(imagepath)
+
+### Path separator.
+
+SEPCHAR=":"
+AC_MSG_RESULT([defining SEPCHAR to be $SEPCHAR])
+AC_DEFINE(SEPCHAR, [']$SEPCHAR['])
+AC_DEFINE(SEPCHAR_STR, ["]$SEPCHAR["])
+
 ### Allow the user to force us to use f2c.
 
 AC_ARG_WITH(f2c,
@@ -58,43 +124,6 @@
   use_f2c=false
 fi
 
-### Allow the user to experiment with dynamic linking using GNU dld.
-
-AC_ARG_ENABLE(dld,
-  [  --enable-dld            use DLD for dynamic linking (not all systems)],
-  [if test $enableval = no; then use_dld=false; else use_dld=true; fi],
-  use_dld=false)
-AC_SUBST(use_dld)
-
-### Allow the user to experiment with dynamic linking using dlopen/dlsym.
-
-AC_ARG_ENABLE(dl,
-  [  --enable-dl             use dlopen/dlsym for dynamic linking (not all systems)],
-  [if test $enableval = no; then use_dl=false; else use_dl=true; fi],
-  use_dl=false)
-AC_SUBST(use_dl)
-
-### Allow the user to experiment with dynamic linking using
-### shl_load/shl_findsym (HP/UX only?).
-
-AC_ARG_ENABLE(shl,
-  [  --enable-shl            use shl_load/shl_findsym for dynamic linking (HP only?)],
-  [if test $enableval = no; then use_shl=false; else use_shl=true; fi],
-  use_shl=false)
-AC_SUBST(use_shl)
-
-### Allow compilation of smaller kernel.  This only works if some form
-### of dynamic linking is also supported and used.
-
-AC_ARG_ENABLE(lite-kernel,
-  [  --enable-lite-kernel    compile smaller kernel (requires DLD)],
-  [if test $enableval = no; then lite_kernel=false; else lite_kernel=true; fi],
-  lite_kernel=false)
-if $lite_kernel; then
-  AC_DEFINE(OCTAVE_LITE, 1)
-fi
-AC_SUBST(lite_kernel)
-
 ### Allow the user disable support for GNU info.
 
 INFO_DIR=info
@@ -153,139 +182,6 @@
 AC_SUBST(LIBREADLINE)
 AC_SUBST(READLINE_DIR)
 
-### some defaults
-
-AC_PREFIX_DEFAULT(/usr/local)
-
-exec_prefix='$(prefix)'
-bindir='$(exec_prefix)/bin'
-datadir='$(prefix)/lib'
-libdir='$(exec_prefix)/lib'
-includedir='$(prefix)/include/octave'
-mandir='$(prefix)/man/man1'
-infodir='$(prefix)/info'
-fcnfiledir='$(datadir)/octave/$(version)/m'
-localfcnfiledir='$(datadir)/octave/site/m'
-localfcnfilepath='$(localfcnfiledir)//'
-archlibdir='$(libdir)/octave/$(version)/exec/$(target_host_type)'
-octfiledir='$(libdir)/octave/$(version)/oct/$(target_host_type)'
-localoctfiledir='$(datadir)/octave/site/oct/$(target_host_type)'
-localoctfilepath='$(localoctfiledir)//'
-fcnfilepath='.:$(localoctfilepath):$(localfcnfilepath):$(octfiledir)//:$(fcnfiledir)//'
-imagedir='$(datadir)/octave/$(version)/imagelib'
-imagepath='.:$(imagedir)//'
-
-AC_MSG_RESULT([defining prefix to be $prefix])
-AC_MSG_RESULT([defining exec_prefix to be $exec_prefix])
-AC_MSG_RESULT([defining bindir to be $bindir])
-AC_MSG_RESULT([defining datadir to be $datadir])
-AC_MSG_RESULT([defining libdir to be $libdir])
-AC_MSG_RESULT([defining includedir to be $includedir])
-AC_MSG_RESULT([defining mandir to be $mandir])
-AC_MSG_RESULT([defining infodir to be $infodir])
-AC_MSG_RESULT([defining fcnfiledir to be $fcnfiledir])
-AC_MSG_RESULT([defining localfcnfiledir to be $localfcnfiledir])
-AC_MSG_RESULT([defining localfcnfilepath to be $localfcnfilepath])
-AC_MSG_RESULT([defining archlibdir to be $archlibdir])
-AC_MSG_RESULT([defining octfiledir to be $octfiledir])
-AC_MSG_RESULT([defining localoctfiledir to be $localoctfiledir])
-AC_MSG_RESULT([defining localoctfilepath to be $localoctfilepath])
-AC_MSG_RESULT([defining fcnfilepath to be $fcnfilepath])
-AC_MSG_RESULT([defining imagedir to be $imagedir])
-AC_MSG_RESULT([defining imagepath to be $imagepath])
-AC_SUBST(exec_prefix)
-AC_SUBST(bindir)
-AC_SUBST(datadir)
-AC_SUBST(libdir)
-AC_SUBST(includedir)
-AC_SUBST(mandir)
-AC_SUBST(infodir)
-AC_SUBST(fcnfiledir)
-AC_SUBST(localfcnfiledir)
-AC_SUBST(localfcnfilepath)
-AC_SUBST(archlibdir)
-AC_SUBST(octfiledir)
-AC_SUBST(localoctfiledir)
-AC_SUBST(localoctfilepath)
-AC_SUBST(fcnfilepath)
-AC_SUBST(imagedir)
-AC_SUBST(imagepath)
-
-### Path separator.
-
-AC_DEFINE(SEPCHAR, [':'])
-AC_DEFINE(SEPCHAR_STR, [":"])
-
-### Do special stuff if using dld.
-
-DLD_DIR=
-LIBDLD=
-LIBOCTDLD='liboctdld.a'
-LD_STATIC_FLAG=
-if $use_dld; then
-  DLD_DIR=dld
-  LIBDLD='../dld/libdld.a'
-  LD_STATIC_FLAG=-static
-  AC_DEFINE(WITH_DLD, 1)
-fi
-
-### Don't link these functions if small kernel option requested.
-
-if $lite_kernel; then
-  LIBOCTDLD=
-fi
-
-### Also use -static if compiling on Alpha OSF/1 1.3 systems.
-
-case "$canonical_host_type" in
-  alpha-dec-osf1.3)
-    LD_STATIC_FLAG=-static
-  ;;
-esac
-
-if test -n "$DLD_DIR"; then
-  AC_MSG_RESULT([defining DLD_DIR to be $DLD_DIR])
-fi
-if test -n "$LIBDLD"; then
-  AC_MSG_RESULT([defining LIBDLD to be $LIBDLD])
-fi
-if test -n "$LIBOCTDLD"; then
-  AC_MSG_RESULT([defining LIBOCTDLD to be $LIBOCTDLD])
-fi
-if test -n "$LD_STATIC_FLAG"; then
-  AC_MSG_RESULT([defining LD_STATIC_FLAG to be $LD_STATIC_FLAG])
-fi
-AC_SUBST(DLD_DIR)
-AC_SUBST(LIBDLD)
-AC_SUBST(LIBOCTDLD)
-AC_SUBST(LD_STATIC_FLAG)
-
-### See if the optional nonlinear programming code is present.
-
-AC_MSG_CHECKING([for npsol])
-if test -f $srcdir/libcruft/npsol/npsol.f; then
-  AC_MSG_RESULT(yes)
-else
-  AC_MSG_RESULT(no)
-  AC_DEFINE(NPSOL_MISSING, 1)
-fi
-
-AC_MSG_CHECKING([for qpsol])
-if test -f $srcdir/libcruft/qpsol/qpsol.f; then
-  AC_MSG_RESULT(yes)
-else
-  AC_MSG_RESULT(no)
-  AC_DEFINE(QPSOL_MISSING, 1)
-fi
-
-AC_MSG_CHECKING([for fsqp])
-if test -f $srcdir/libcruft/fsqp/fsqpd.f; then
-  AC_MSG_RESULT(yes)
-else
-  AC_MSG_RESULT(no)
-  AC_DEFINE(FSQP_MISSING, 1)
-fi
-
 ### See which C++ compiler to use (we expect to find g++).
 
 EXTERN_CXXFLAGS="$CXXFLAGS"
@@ -367,13 +263,125 @@
 ### support for IEEE floating point.
 
 case "$canonical_host_type" in
-  i386-*-linux | i486-*-linux | i586-*-linux)
+  i[345]86-*-linux)
     GCC_IEEE_FP_FLAG="-mieee-fp"
     AC_MSG_RESULT([defining GCC_IEEE_FP_FLAG to be $GCC_IEEE_FP_FLAG])
   ;;
 esac
+AC_SUBST(GCC_IEEE_FP_FLAG)
 
-AC_SUBST(GCC_IEEE_FP_FLAG)
+### Use -static if compiling on Alpha OSF/1 1.3 systems.
+
+case "$canonical_host_type" in
+  alpha-dec-osf1.3)
+    LD_STATIC_FLAG=-static
+  ;;
+esac
+
+### Handle dynamic linking and shared library options.
+
+### Allow the user to experiment with dynamic linking using GNU dld.
+
+DLD_DIR=
+LIBDLD=
+LIBOCTDLD='liboctdld.a'
+LD_STATIC_FLAG=
+AC_ARG_ENABLE(dld,
+  [  --enable-dld            use DLD for dynamic linking (not all systems)],
+  [if test $enableval = no; then use_dld=false; else use_dld=true; fi],
+  use_dld=false)
+if $use_dld; then
+  DLD_DIR=dld
+  LIBDLD='../dld/libdld.a'
+  LD_STATIC_FLAG=-static
+  AC_DEFINE(WITH_DLD, 1)
+fi
+AC_SUBST(use_dld)
+
+### Allow the user to experiment with dynamic linking using dlopen/dlsym.
+
+AC_ARG_ENABLE(dl,
+  [  --enable-dl             use dlopen/dlsym for dynamic linking (not all systems)],
+  [if test $enableval = no; then use_dl=false; else use_dl=true; fi],
+  use_dl=false)
+AC_SUBST(use_dl)
+
+### Allow the user to experiment with dynamic linking using
+### shl_load/shl_findsym (HP/UX only?).
+
+AC_ARG_ENABLE(shl,
+  [  --enable-shl            use shl_load/shl_findsym for dynamic linking (HP only?)],
+  [if test $enableval = no; then use_shl=false; else use_shl=true; fi],
+  use_shl=false)
+AC_SUBST(use_shl)
+
+### Enable creation of shared libraries.  Currently only works with
+### gcc on some systems.
+
+AC_ARG_ENABLE(shared,
+  [  --shared                create shared libraries (not all systems)],
+  [if test $enableval = no; then shared_libs=false; else shared_libs=true; fi],
+  shared_libs=false)
+AC_SUBST(shared_libs)
+
+if $shared_libs; then
+  CPICFLAG=-fPIC
+  CXXPICFLAG=-fPIC
+  FPICFLAG=-fPIC
+  case "$cannonical_host_type" in
+    alpha-dec-osf* | rs6000-ibm-aix*)
+      CPICFLAG=
+      CXXPICFLAG=
+      FPICFLAG=
+    ;;
+    hppa*-hp-hpux*)
+      FPICFLAG=+Z
+    ;;
+    *-sgi-*)
+      FPICFLAG=-KPIC
+    ;;
+    sparc-sun-sunos*)
+      FPICFLAG=-PIC
+    ;;
+  esac
+else
+  FPICFLAG=
+  CPICFLAG=
+  CXXPICFLAG=
+fi
+AC_MSG_RESULT([defining FPICFLAG to be $FPICFLAG])
+AC_MSG_RESULT([defining CPICFLAG to be $CPICFLAG])
+AC_MSG_RESULT([defining CXXPICFLAG to be $CXXPICFLAG])
+
+### Allow compilation of smaller kernel.  This only works if some form
+### of dynamic linking is also supported and used.
+
+AC_ARG_ENABLE(lite-kernel,
+  [  --enable-lite-kernel    compile smaller kernel (requires dynamic linking)],
+  [if test $enableval = no; then lite_kernel=false; else lite_kernel=true; fi],
+  lite_kernel=false)
+if $lite_kernel; then
+  LIBOCTDLD=
+  AC_DEFINE(OCTAVE_LITE, 1)
+fi
+AC_SUBST(lite_kernel)
+
+if test -n "$DLD_DIR"; then
+  AC_MSG_RESULT([defining DLD_DIR to be $DLD_DIR])
+fi
+if test -n "$LIBDLD"; then
+  AC_MSG_RESULT([defining LIBDLD to be $LIBDLD])
+fi
+if test -n "$LIBOCTDLD"; then
+  AC_MSG_RESULT([defining LIBOCTDLD to be $LIBOCTDLD])
+fi
+if test -n "$LD_STATIC_FLAG"; then
+  AC_MSG_RESULT([defining LD_STATIC_FLAG to be $LD_STATIC_FLAG])
+fi
+AC_SUBST(DLD_DIR)
+AC_SUBST(LIBDLD)
+AC_SUBST(LIBOCTDLD)
+AC_SUBST(LD_STATIC_FLAG)
 
 ### Special checks for odd OS specific things.
 
@@ -593,6 +601,32 @@
   AC_MSG_ERROR([I couldn't find termios.h, termio.h, or sgtty.h!])
 fi
 
+### See if the optional nonlinear programming code is present.
+
+AC_MSG_CHECKING([for npsol])
+if test -f $srcdir/libcruft/npsol/npsol.f; then
+  AC_MSG_RESULT(yes)
+else
+  AC_MSG_RESULT(no)
+  AC_DEFINE(NPSOL_MISSING, 1)
+fi
+
+AC_MSG_CHECKING([for qpsol])
+if test -f $srcdir/libcruft/qpsol/qpsol.f; then
+  AC_MSG_RESULT(yes)
+else
+  AC_MSG_RESULT(no)
+  AC_DEFINE(QPSOL_MISSING, 1)
+fi
+
+AC_MSG_CHECKING([for fsqp])
+if test -f $srcdir/libcruft/fsqp/fsqpd.f; then
+  AC_MSG_RESULT(yes)
+else
+  AC_MSG_RESULT(no)
+  AC_DEFINE(FSQP_MISSING, 1)
+fi
+
 ### Checks for functions.
 
 AC_CHECK_FUNCS(setvbuf getcwd gethostname bzero bcopy rindex vfprintf vsprintf)