changeset 3892:56db014d8980

[project @ 2002-04-05 04:08:56 by jwe]
author jwe
date Fri, 05 Apr 2002 04:08:56 +0000
parents e2cbe8e31e06
children abd8659eea11
files ChangeLog Makeconf.in acconfig.h aclocal.m4 configure.in install-octave.in src/ChangeLog src/Makefile.in src/oct-conf.h.in src/toplev.cc
diffstat 10 files changed, 51 insertions(+), 63 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2002-04-04  John W. Eaton  <jwe@bevo.che.wisc.edu>
+
+	* Makeconf.in: Set and substitute EXEEXT, not EXE.
+
+	* configure.in (EXE): Delete check and substitution.
+	* install-octave.in: Use EXEEXT instead of EXE.
+
+	* configure.in: Use AC_CHECK_MEMBERS, not OCTAVE_STRUCT_GR_PASSWD.
+	Use AC_CHECK_TYPES, not AC_CHECK_TYPE or OCTAVE_CHECK_TYPE.
+	* aclocal.m4 (OCTAVE_STRUCT_GR_PASSWD, OCTAVE_CHECK_TYPE): Delete.
+	* acconfig.h (dev_t, ino_t, nlink_t, sigset_t): Typedef if not found.
+
 2002-04-03  John W. Eaton  <jwe@bevo.che.wisc.edu>
 
 	* aclocal.m4: Replace AC_LANG_SAVE, AC_LANG_C, AC_LANG_CPLUSPLUS,
--- a/Makeconf.in
+++ b/Makeconf.in
@@ -19,7 +19,7 @@
 
 #### Start of system configuration section. ####
 
-EXE = @EXE@
+EXEEXT = @EXEEXT@
 
 LEX = @LEX@
 LFLAGS = @LFLAGS@
@@ -364,7 +364,7 @@
   -e "s;%OCTAVE_CONF_DEPEND_FLAGS%;\"${DEPEND_FLAGS}\";" \
   -e "s;%OCTAVE_CONF_DEPEND_EXTRA_SED_PATTERN%;\"${DEPEND_EXTRA_SED_PATTERN}\";" \
   -e "s;%OCTAVE_CONF_DLFCN_INCFLAGS%;\"${DLFCN_INCFLAGS}\";" \
-  -e "s;%OCTAVE_CONF_EXE%;\"${EXE}\";" \
+  -e "s;%OCTAVE_CONF_EXEEXT%;\"${EXEEXT}\";" \
   -e "s;%OCTAVE_CONF_F2C%;\"${F2C}\";" \
   -e "s;%OCTAVE_CONF_F2CFLAGS%;\"${F2CFLAGS}\";" \
   -e "s;%OCTAVE_CONF_F77%;\"${F77}\";" \
--- a/acconfig.h
+++ b/acconfig.h
@@ -41,3 +41,19 @@
 #  define F77_FUNC(x,X) x ## _
 #  define F77_FUNC_(x,X) x ## __
 #endif
+
+#if !defined(HAVE_DEV_T)
+typedef dev_t short
+#endif
+
+#if !defined(HAVE_INO_T)
+typedef ino_t unsigned long
+#endif
+
+#if !defined(HAVE_NLINK_T)
+typedef nlink_t short
+#endif
+
+#if !defined(HAVE_SIGSET_T)
+typedef sigset_t int
+#endif
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -72,18 +72,6 @@
 AC_SUBST(ARFLAGS)
 ])
 dnl
-dnl See if struct group has a gr_passwd field.
-dnl
-AC_DEFUN(OCTAVE_STRUCT_GR_PASSWD,
-[AC_CACHE_CHECK([for gr_passwd in struct group], octave_cv_struct_gr_passwd,
-[AC_TRY_COMPILE([#include <sys/types.h>
-#include <grp.h>], [struct group s; s.gr_passwd;],
-octave_cv_struct_gr_passwd=yes, octave_cv_struct_gr_passwd=no)])
-if test $octave_cv_struct_gr_passwd = yes; then
-  AC_DEFINE(HAVE_GR_PASSWD,1,[Define if your system's struct group has a gr_passwd field.])
-fi
-])
-dnl
 dnl See if the standard string class has npos as a member.
 dnl
 AC_DEFUN(OCTAVE_STRING_NPOS,
@@ -268,31 +256,6 @@
 fi
 ])
 dnl
-dnl This check originally from bash 2.0.
-dnl
-dnl Check for typedef'd symbols in header files, but allow the caller to
-dnl specify the include files to be checked in addition to the default.
-dnl 
-dnl OCTAVE_CHECK_TYPE(TYPE, HEADERS, DEFAULT[, VALUE-IF-FOUND])
-AC_DEFUN(OCTAVE_CHECK_TYPE,
-[AC_REQUIRE([AC_HEADER_STDC])dnl
-AC_MSG_CHECKING(for $1)
-AC_CACHE_VAL(octave_cv_type_$1,
-[AC_EGREP_CPP($1, [#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#endif
-$2
-], octave_cv_type_$1=yes, octave_cv_type_$1=no)])
-AC_MSG_RESULT($octave_cv_type_$1)
-ifelse($#, 4, [if test $octave_cv_type_$1 = yes; then
-	AC_DEFINE($4, 1, [Define if you have typedef $1.])
-	fi])
-if test $octave_cv_type_$1 = no; then
-  AC_DEFINE($1, $3, [Define to typedef for $1.])
-fi
-])
-dnl
 dnl Check to see if C++ compiler needs the new friend template declaration 
 dnl syntax. 
 dnl
--- a/configure.in
+++ b/configure.in
@@ -22,7 +22,7 @@
 ### 02111-1307, USA. 
 
 AC_INIT
-AC_REVISION($Revision: 1.354 $)
+AC_REVISION($Revision: 1.355 $)
 AC_PREREQ(2.52)
 AC_CONFIG_SRCDIR([src/octave.cc])
 AC_CONFIG_HEADER(config.h)
@@ -352,7 +352,7 @@
 	WITH_HDF5=true
         HDF5_LIBS="-l$hdf5_lib -lz"
         LIBS="$HDF5_LIBS $LIBS"
-        AC_DEFINE(HAVE_HDF5,1,[Define if HDF5 is available.])])])])
+        AC_DEFINE(HAVE_HDF5, 1, [Define if HDF5 is available.])])])])
 fi
 
 # Checks for FFTW header and library.
@@ -382,7 +382,7 @@
 
 if test "$with_fftw" = yes; then
   FFT_DIR=''
-  AC_DEFINE(HAVE_FFTW,1,[Define if the FFTW library is available.])
+  AC_DEFINE(HAVE_FFTW, 1, [Define if the FFTW library is available.])
 fi
 
 # ----------------------------------------------------------------------
@@ -1014,7 +1014,7 @@
 AC_STRUCT_TIMEZONE
 AC_FUNC_CLOSEDIR_VOID
 
-OCTAVE_STRUCT_GR_PASSWD
+AC_CHECK_MEMBERS(struct group.gr_passwd)
 
 octave_found_termlib=no
 for termlib in ncurses curses termcap terminfo termlib; do
@@ -1063,10 +1063,8 @@
 AC_TYPE_PID_T
 AC_TYPE_SIZE_T
 AC_TYPE_UID_T
-AC_CHECK_TYPE(dev_t, short)
-AC_CHECK_TYPE(ino_t, unsigned long)
-AC_CHECK_TYPE(nlink_t, short)
-OCTAVE_CHECK_TYPE(sigset_t, [#include <signal.h>], int)
+AC_CHECK_TYPES([dev_t, ino_t, nlink_t, nlink_t])
+AC_CHECK_TYPES(sigset_t, , , [#include <signal.h>])
 
 ### A system dependent kluge or two.
 
@@ -1122,14 +1120,6 @@
 OCTAVE_PROG_PAGER
 OCTAVE_PROG_GPERF
 
-EXE=
-case "$canonical_host_type" in
-  *-*-cygwin32)
-    EXE=.exe
-  ;;
-esac
-AC_SUBST(EXE)
-
 ### Even though we include config.h, we need to have the preprocessor
 ### defines available in a variable for the octave-bug script.  Use
 ### UGLY_DEFS for that.
--- a/install-octave.in
+++ b/install-octave.in
@@ -59,7 +59,7 @@
   echo_c='\c'
 fi
 
-EXE=@EXE@
+EXEEXT=@EXEEXT@
 SHLEXT=@SHLEXT@
 SHLEXT_VER=$SHLEXT.$version
 
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,10 @@
+2002-04-04  John W. Eaton  <jwe@bevo.che.wisc.edu>
+
+	* toplev.cc (octave_config_info): Define struct member EXEEXT, not EXE.
+	* Makefile.in (install-bin): Use $(EXEEXT), not $(EXE).
+	* oct-conf.h.in (OCTAVE_CONF_EXEEXT): Define and substitute
+	OCTAVE_CONF_EXEEXT, not OCTAVE_CONF_EXE.
+
 2002-04-03  Steven G. Johnson <stevenj@alum.mit.edu>
 
 	* DLD-FUNCTIONS/balance.cc: Use F77_FUNC instead of F77_FCN.
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -326,9 +326,9 @@
 
 install-bin:
 	$(top_srcdir)/mkinstalldirs $(bindir)
-	rm -f $(bindir)/octave$(EXE)
-	$(INSTALL_PROGRAM) octave$(EXE) $(bindir)/octave-$(version)$(EXE)
-	cd $(bindir); $(LN_S) octave-$(version)$(EXE) octave$(EXE)
+	rm -f $(bindir)/octave$(EXEEXT)
+	$(INSTALL_PROGRAM) octave$(EXEEXT) $(bindir)/octave-$(version)$(EXEEXT)
+	cd $(bindir); $(LN_S) octave-$(version)$(EXEEXT) octave$(EXEEXT)
 .PHONY: install-bin
 
 install-oct:
@@ -378,7 +378,7 @@
 .PHONY: install-inc
 
 uninstall:
-	rm -f $(bindir)/octave$(EXE)
+	rm -f $(bindir)/octave$(EXEEXT)
 	rm -f $(octlibdir)/liboctinterp.$(LIBEXT)
 	rm -f $(octlibdir)/liboctinterp.$(SHLEXT)
 	rm -f $(octlibdir)/liboctinterp.$(SHLEXT_VER)
--- a/src/oct-conf.h.in
+++ b/src/oct-conf.h.in
@@ -104,8 +104,8 @@
 #define OCTAVE_CONF_DLFCN_INCFLAGS %OCTAVE_CONF_DLFCN_INCFLAGS%
 #endif
 
-#ifndef OCTAVE_CONF_EXE
-#define OCTAVE_CONF_EXE %OCTAVE_CONF_EXE%
+#ifndef OCTAVE_CONF_EXEEXT
+#define OCTAVE_CONF_EXEEXT %OCTAVE_CONF_EXEEXT%
 #endif
 
 #ifndef OCTAVE_CONF_F2CFLAGS
--- a/src/toplev.cc
+++ b/src/toplev.cc
@@ -665,7 +665,7 @@
   m ["CXX_VERSION"] = OCTAVE_CONF_CXX_VERSION;
   m ["DEFAULT_PAGER"] = OCTAVE_DEFAULT_PAGER;
   m ["DLFCN_INCFLAGS"] = OCTAVE_CONF_DLFCN_INCFLAGS;
-  m ["EXE"] = OCTAVE_CONF_EXE;
+  m ["EXEEXT"] = OCTAVE_CONF_EXEEXT;
   m ["F2C"] = OCTAVE_CONF_F2C;
   m ["F2CFLAGS"] = OCTAVE_CONF_F2CFLAGS;
   m ["F77"] = OCTAVE_CONF_F77;