dnl Process this file with autoconf to produce a configure script.
dnl The order you want to use is:
dnl aclocal (only need this once)
dnl autoconf
dnl autoheader
dnl automake -v --add-missing
dnl ./configure
dnl make
dnl
dnl *NOTE* Red Hat 5.2 (and later?) comes with a libtool-1.2b rpm which
dnl WILL NOT WORK with some combination of automake-1.3 or autoconf-2.13
dnl or libtool-1.2. You should download libtool-1.2, rpm -e libtool, and
dnl install 1.2 (use "configure --prefix=/usr" to keep it from going in
dnl /usr/local). The other way to go (which I have not tried) is getting
dnl libtool-1.2b from http://www.profitpress.com/gord/src/ and installing
dnl it on Irix.
dnl
dnl The inst'able version of libtool-1.3, autoconf-2.13, and automake-1.4
dnl are at orchietta.boston:/d2/dist (they will be in the freeware distribution
dnl later). One problem with using those is that they're newer than the
dnl versions you have on Linux! The libtool-1.2 tarball works with autoconf
dnl 2.12 and automake 1.3.
dnl
dnl XXX rusty add notes on changing compiler flags etc.
dnl
dnl THINGS WHICH ARE STILL BROKEN
dnl
dnl protoinst. I'm sure there's a bad way to build that stuff, and maybe
dnl even a good way, but I haven't found it. Right now I have a hand-
dnl assembled tree of symlinks under proto which point to the headers
dnl in lib.
dnl packaging. SGI's install gave us a lot of flexibility, and we used it.
dnl We have a lot of custom paths & stuff (/usr/sysadm, /var/sysadm,
dnl etc.), so either we need to pound automake etc. into letting us
dnl install whatever we want wherever we want it, or change our stuff to
dnl handle being installed in /usr/local/...
dnl makedepends. The generated Makefiles don't include the Makedepends
dnl files, so I removed the makedepends flags. We should figure out how
dnl to fix that & put them back. (g++ I think wants to put each file's
dnl dependencies in a separate file.d instead of a single directory-wide
dnl Makedepend file, too.)
dnl
dnl Uncomment to keep from using the cache file. (It was causing problems
dnl with GCC and GXX being set to "yes" even when the compilers aren't GNU.)
dnl define([AC_CACHE_LOAD], )dnl
dnl define([AC_CACHE_SAVE], )dnl
AC_INIT(category/cluster/ClusterCategory.c++)
AM_INIT_AUTOMAKE(sysadm_failsafe2, 0.0.1a)
dnl Put configuration #defines in config.h.
AM_CONFIG_HEADER(config.h)
dnl **********************************************************************
dnl **
dnl ** Command-line arguments
dnl **
dnl **********************************************************************
dnl This is sort of a perversion of the AC_ARGS_WITH macro, but I want
dnl people to be able to set their CFLAGS on the command line.
AC_ARG_WITH(CFLAGS, [ --with-CFLAGS=\"flags\" set CFLAGS and CXXFLAGS to the given value], [CFLAGS=$withval; CXXFLAGS=$withval])
AC_ARG_WITH(EXTRA_INCS, [ --with-EXTRA_INCS=\"flags\"
set EXTRA_INCS to the given value. For example:
--with-EXTRA_INCS=\"-I/path/to/failsafe/includes\"], [EXTRA_INCS=$withval])
AC_ARG_WITH(EXTRA_LIBS, [ --with-EXTRA_LIBS=\"flags\"
set EXTRA_LIBS to the given value. For example:
--with-EXTRA_LIBS=\"-L/path/to/failsafe/libs\"], [EXTRA_LIBS=$withval])
AC_ARG_WITH(JAVAPATH, [ --with-JAVAPATH=\"/path/to/java\"
look in JAVAPATH for java, javac, and jar], [JAVAPATH=$withval], JAVAPATH=${JAVAPATH:-$PATH})
dnl **********************************************************************
dnl **
dnl ** Installation directories
dnl **
dnl **********************************************************************
dnl RHDIR is the root of the rhino directory structure,
dnl EXCEPT for RHVARDIR.
dnl RHDIR=$prefix
dnl is it just me, or is this stupid?
dnl RHDIR=`echo $RHDIR | sed s#NONE#/usr/sysadm#`
dnl This should be configurable!
RHDIR=/usr/sysadm
AC_SUBST(RHDIR)
dnl RHBINDIR is the directory where we want to install most rhino
dnl executables (but not privcmds).
RHBINDIR="$RHDIR/bin"
AC_SUBST(RHBINDIR)
dnl RHPRIVBINDIR is the directory where we want to install privcmds.
RHPRIVBINDIR="$RHDIR/privbin"
AC_SUBST(RHPRIVBINDIR)
dnl RHPRIVNMDIR is the directory where we want to install the mappings
dnl of privcmds to human-readable names.
RHPRIVNMDIR="$RHDIR/privnames"
AC_SUBST(RHPRIVNMDIR)
dnl dnl RHDEFPRIVDIR is the directory where config files enabling specific
dnl dnl privcmds go.
dnl dnl XXX THIS IS BOGUS
dnl RHDEFPRIVDIR='/var/sysadm/defaultPrivileges'
dnl AC_SUBST(RHDEFPRIVDIR)
dnl RHWEBBINDIR is the directory where we want to install web-related
dnl executables.
RHWEBBINDIR="$RHDIR/web"
AC_SUBST(RHWEBBINDIR)
dnl RHJARDIR is the directory where we want to install client jar files.
RHJARDIR="$RHDIR/java"
AC_SUBST(RHJARDIR)
dnl dnl RHPROTODIR is the directory where we want to install Rhino
dnl dnl protocol modules.
dnl RHPROTODIR='$(RHDIR)/protocols'
dnl AC_SUBST(RHPROTODIR)
dnl dnl RHSERVDIR is the directory where we want to install Rhino
dnl dnl server modules.
dnl RHSERVDIR='$(RHDIR)/services'
dnl AC_SUBST(RHSERVDIR)
dnl RHCATDIR is the directory where we want to install Rhino
dnl category modules.
RHCATDIR="$RHDIR/category"
AC_SUBST(RHCATDIR)
dnl RHASSOCDIR is the directory where we want to install Rhino
dnl association modules.
RHASSOCDIR="$RHDIR/association"
AC_SUBST(RHASSOCDIR)
dnl dnl RHAUTHDIR is the directory where we want to install Rhino
dnl dnl server authentication modules.
dnl RHAUTHDIR='$(RHSERVDIR)/authScheme'
dnl AC_SUBST(RHAUTHDIR)
dnl dnl The difference between RHAUTHDSODIR and RHAUTHDIR is not
dnl dnl clear to me.
dnl RHAUTHDSODIR='$(RHDIR)/authdso'
dnl AC_SUBST(RHAUTHDSODIR)
dnl RHTASKREGDIR is the task registry directory.
RHTASKREGDIR='/var/sysadm/taskRegistry'
AC_SUBST(RHTASKREGDIR)
dnl dnl RHINCDIR is the directory where we want to install Rhino
dnl dnl headers which Rhino-based applications would compile with.
dnl RHINCDIR=$includedir/sysadm
dnl AC_SUBST(RHINCDIR)
dnl RHLIBDIR is the directory where Rhino libraries have been installed.
if test -d "$RHDIR/lib"; then
RHLIBDIR="$RHDIR/lib"
elif test -d /usr/lib32/internal; then
RHLIBDIR=/usr/lib32/internal
else
AC_MSG_ERROR(I can't find your Rhino libraries in $RHDIR/lib or /usr/lib32/internal)
fi
AC_SUBST(RHLIBDIR)
dnl dnl RHCGIDIR is the directory where we want to install Rhino
dnl dnl CGI scripts.
dnl dnl XXX THIS IS BOGUS
dnl RHCGIDIR="/var/www/cgi-bin/sysadm"
dnl AC_SUBST(RHCGIDIR)
dnl dnl RHVARDIR is the directory where... some... stuff goes.
dnl dnl XXX THIS IS BOGUS
dnl RHVARDIR="/var/sysadm"
dnl AC_SUBST(RHVARDIR)
dnl RHPRODDIR is the directory where some product-specific stuff goes,
dnl like the installed product version number.
dnl XXX THIS IS BOGUS
RHPRODDIR="/var/sysadm/products/com.sgi.fsmgr"
AC_SUBST(RHPRODDIR)
dnl BOGODIR is a bogus directory which we'll use because we don't
dnl want to install our .java files, but automake doesn't handle
dnl noinst_JAVA correctly.
BOGODIR="/var/tmp/bogus/XXXremove.me"
AC_SUBST(BOGODIR)
LSYSADMCATEGORY=-lsysadmCategory
AC_SUBST(LSYSADMCATEGORY)
LSYSADMUTIL=-lsysadmUtil
AC_SUBST(LSYSADMUTIL)
LSYSADMPARAM=-lsysadmParam
AC_SUBST(LSYSADMPARAM)
LSYSADMFILEBASEDCATEGORY=-lsysadmFileBasedCategory
AC_SUBST(LSYSADMFILEBASEDCATEGORY)
LFAM=-lfam
AC_SUBST(LFAM)
LFSCXCAMCATEGORY='$(top_srcdir)/lib/libfscxCamCategory/libfscxCamCategory.la'
AC_SUBST(LFSCXCAMCATEGORY)
dnl
dnl Checks for programs.
dnl
dnl Nuts! On IRIX, we want to use the SGI compilers, not GNU.
if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
AC_PATH_PROG(CC, cc)
AC_PATH_PROG(CXX, CC)
fi
AC_PROG_CC
AC_PROG_CXX
AC_PROG_CXXCPP
AC_PROG_RANLIB
AC_PROG_INSTALL
dnl I don't know why, but automake wants to use ./mkinstalldirs.
dnl AC_PATH_PROG(MKINSTALLDIRS, mkinstalldirs)
AC_PROG_MAKE_SET
dnl AC_PROG_AWK
dnl AC_PATH_PROG(LIBTOOL, libtool)
dnl AC_LIBTOOL_DLOPEN
AM_PROG_LIBTOOL
dnl autoconf/automake expects GNU tar, so find it on IRIX.
AC_PATH_PROG(TAR, tar, /usr/freeware/bin/tar, /usr/freeware/bin:$PATH)
dnl dnl We want to use our own mkprivnames. The RhinoExample configure.in
dnl dnl should set this to /usr/sysadm/bin/mkprivnames.
dnl MKPRIVNAMES='$(top_srcdir)/cmd/mkprivnames/mkprivnames'
dnl AC_SUBST(MKPRIVNAMES)
AC_PATH_PROG(JARLINKS, jarlinks, die, /usr/sysadm/bin:/usr/local/bin:$PATH)
if test "$JARLINKS" = 'die'; then
AC_ERROR("Couldn\'t find jarlinks in /usr/sysadm/bin:/usr/local/bin:$PATH")
fi
dnl The RhinoExample configure.in should set this to its own
dnl packages subdir, and then the rest of the stuff below.
dnl RHCLASSPATH='$(top_srcdir)/packages:$(top_srcdir)/packages/swingall.jar'
dnl AC_SUBST(RHCLASSPATH)
CLASSPATH='$(top_srcdir)/packages:$(RHJARDIR)/sysadm.jar:$(RHJARDIR)/sysadmP.jar:$(RHJARDIR)/swingall.jar'
AC_PATH_PROG(JAVA, java, die, $JAVAPATH)
if test "$JAVA" = "die"; then
AC_MSG_ERROR([Didn't find java in $JAVAPATH
Try running configure --with-JAVAPATH=/path/to/java/bin])
fi
AC_PATH_PROG(JAVAC, javac, die, $JAVAPATH)
if test "$JAVAC" = "die"; then
AC_MSG_ERROR([Didn't find javac in $JAVAPATH
Try running configure --with-JAVAPATH=/path/to/java/bin])
fi
AC_PATH_PROG(JAR, jar, die, $JAVAPATH)
if test "$JAR" = "die"; then
AC_MSG_ERROR([Didn't find jar in $JAVAPATH
Try running configure --with-JAVAPATH=/path/to/java/bin])
fi
dnl This comes with rhino, and is installed in the system bin dir.
AC_PATH_PROG(FTRJAVA, ftrjava)
dnl This comes with rhino on IRIX?
AC_PATH_PROG(JAVAWAIT, javawait)
if test "no$JAVAWAIT" != "no"; then
JAVAWAIT="$JAVAWAIT -command"
fi
AC_SUBST(JAVAWAIT)
dnl
dnl Checks for libraries.
dnl
dnl (we don't need any of these for the simple tcpmux test... we will need to
dnl fix many of these later, though, and comment them in.)
dnl
dnl dnl Replace `main' with a function in -lX11:
dnl AC_CHECK_LIB(X11, main)
dnl dnl Replace `main' with a function in -lXm:
dnl AC_CHECK_LIB(Xm, main)
dnl dnl Replace `main' with a function in -lXt:
dnl AC_CHECK_LIB(Xt, main)
dnl dnl Replace `main' with a function in -lcam:
dnl AC_CHECK_LIB(cam, main)
dnl dnl Replace `main' with a function in -lcmd:
dnl AC_CHECK_LIB(cmd, main)
dnl dnl Replace `main' with a function in -lcrypt:
dnl AC_CHECK_LIB(crypt, main)
dnl this is unbelievably lame
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl LCRYPT=
dnl else
dnl LCRYPT=-lcrypt
dnl fi
dnl AC_SUBST(LCRYPT)
dnl dnl Replace `main' with a function in -ldl:
dnl AC_CHECK_LIB(dl, main)
dnl this is unbelievably lame
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl LDL=
dnl else
dnl LDL=-ldl
dnl fi
dnl AC_SUBST(LDL)
dnl dnl Replace `main' with a function in -lfam:
dnl AC_CHECK_LIB(fam, main)
dnl dnl Replace `main' with a function in -lgen:
dnl AC_CHECK_LIB(gen, main)
dnl this is unbelievably lame
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl LGEN=-lgen
dnl else
dnl LGEN=
dnl fi
dnl AC_SUBST(LGEN)
dnl dnl this is unbelievably lame
dnl AC_MSG_CHECKING([for libcmd (THIS TEST IS BOGUS)])
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl LCMD=-lcmd
dnl else
dnl LCMD=
dnl fi
dnl AC_SUBST(LCMD)
dnl AC_MSG_RESULT([$LCMD])
LCAM=-lcam
AC_SUBST(LCAM)
dnl dnl Replace `main' with a function in -lm:
dnl AC_CHECK_LIB(m, main)
dnl dnl Replace `main' with a function in -lns:
dnl AC_CHECK_LIB(ns, main)
dnl dnl Replace `main' with a function in -lpthread:
dnl AC_CHECK_LIB(pthread, main)
dnl dnl Replace `main' with a function in -lsaAdminObj:
dnl AC_CHECK_LIB(saAdminObj, main)
dnl dnl Replace `main' with a function in -lsaNetwork:
dnl AC_CHECK_LIB(saNetwork, main)
dnl dnl Replace `main' with a function in -lsaPrivilege:
dnl AC_CHECK_LIB(saPrivilege, main)
dnl dnl Replace `main' with a function in -lsaauth:
dnl AC_CHECK_LIB(saauth, main)
dnl dnl Replace `main' with a function in -lsalog:
dnl AC_CHECK_LIB(salog, main)
dnl dnl Replace `main' with a function in -lsatest:
dnl AC_CHECK_LIB(satest, main)
dnl dnl Replace `main' with a function in -lsysadmAdminObj:
dnl AC_CHECK_LIB(sysadmAdminObj, main)
dnl dnl Replace `main' with a function in -lsysadmCamCategory:
dnl AC_CHECK_LIB(sysadmCamCategory, main)
dnl dnl Replace `main' with a function in -lsysadmCategory:
dnl AC_CHECK_LIB(sysadmCategory, main)
dnl dnl Replace `main' with a function in -lsysadmComm:
dnl AC_CHECK_LIB(sysadmComm, main)
dnl dnl Replace `main' with a function in -lsysadmFam:
dnl AC_CHECK_LIB(sysadmFam, main)
dnl dnl Replace `main' with a function in -lsysadmParam:
dnl AC_CHECK_LIB(sysadmParam, main)
dnl dnl Replace `main' with a function in -lsysadmUtil:
dnl AC_CHECK_LIB(sysadmUtil, main)
dnl
dnl Look for Motif libraries. This sets LMOTIF to the -L flag which
dnl will tell the linker where to find the installed Motif libs. This
dnl isn't really consistent with other variables we're setting, where
dnl LMOTIF would mean "-L/usr/X11R6/lib -lXm"; you may want to change
dnl this to do LXM, LXT, and LX11. *Watch out* though, the automake 1.3
dnl pattern for AC_SUBST doesn't handle numbers in variable names.
dnl
dnl for d in /usr/lib /usr/lib32 /usr/X11R6/lib /usr/X11/lib ; do
dnl AC_MSG_CHECKING([for Motif library $d/libXm.{so,a}])
dnl if test -f $d/libXm.so || test -f $d/libXm.a ; then
dnl LMOTIF="-L$d"
dnl AC_MSG_RESULT([found it])
dnl break
dnl else
dnl AC_MSG_RESULT([not there])
dnl fi
dnl done
dnl if test ${LMOTIF:-hosed} = 'hosed'; then
dnl AC_MSG_ERROR([I couldn't find your Motif libraries!])
dnl fi
dnl # Let's assume -L/usr/lib & -L/usr/lib32 are redundant and ignore them.
dnl if test $LMOTIF = '-L/usr/lib' || test $LMOTIF = '-L/usr/lib32' ; then
dnl LMOTIF=""
dnl fi
dnl AC_SUBST(LMOTIF)
dnl echo "CMD_SUBDIRS == $CMD_SUBDIRS"
dnl echo "LIB_SUBDIRS == $LIB_SUBDIRS"
dnl dnl
dnl dnl Check to see if we should build tcpmux. This may modify CMD_SUBDIRS.
dnl dnl
dnl AC_MSG_CHECKING([for tcpmux])
dnl dnl XXX IS THIS CHECK BOGUS?
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl # CMD_SUBDIRS is complete.
dnl dnl AC_MSG_RESULT([not building tcpmux])
dnl dnl XXX DO NOT BUILD TCPMUX ON IRIX
dnl AC_MSG_RESULT([building tcpmux for testing purposes])
dnl CMD_SUBDIRS="$CMD_SUBDIRS tcpmux"
dnl else
dnl # We want to build tcpmux.
dnl CMD_SUBDIRS="$CMD_SUBDIRS tcpmux"
dnl AC_MSG_RESULT([building tcpmux])
dnl fi
dnl echo "now CMD_SUBDIRS == $CMD_SUBDIRS"
dnl echo "now LIB_SUBDIRS == $LIB_SUBDIRS"
dnl dnl
dnl dnl Check to see if we should build readlog. This may modify CMD_SUBDIRS.
dnl dnl The only reason to not build readlog is that it hasn't been ported yet.
dnl dnl
dnl AC_MSG_CHECKING([for readlog (THIS CHECK IS BOGUS)])
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl CMD_SUBDIRS="$CMD_SUBDIRS readlog"
dnl AC_MSG_RESULT([building readlog])
dnl else
dnl AC_MSG_RESULT([not building readlog])
dnl fi
dnl echo "and now CMD_SUBDIRS == $CMD_SUBDIRS"
dnl echo "and now LIB_SUBDIRS == $LIB_SUBDIRS"
dnl
dnl Checks for header files.
dnl
dnl AC_HEADER_STDC
dnl AC_HEADER_DIRENT
dnl AC_HEADER_SYS_WAIT
dnl AC_CHECK_HEADERS(fcntl.h limits.h sys/time.h syslog.h unistd.h)
dnl AC_CHECK_HEADER(sys/imon.h, AC_DEFINE(HAVE_IMON, 1), AC_DEFINE(HAVE_IMON, 0))
dnl AC_CHECK_HEADER(sys/statvfs.h, AC_DEFINE(HAVE_STATVFS, 1), AC_DEFINE(HAVE_STATVFS, 0))
dnl AC_CHECK_HEADER(sys/syssgi.h, AC_DEFINE(HAVE_SYSSGI, 1), AC_DEFINE(HAVE_SYSSGI, 0))
dnl AC_CHECK_HEADER(deflt.h, AC_DEFINE(HAVE_DEFLT_H, 1), AC_DEFINE(HAVE_DEFLT_H, 0))
dnl
dnl AC_CHECK_FUNC(_daemonize, AC_DEFINE(HAVE_DAEMONIZE, 1), AC_DEFINE(HAVE_DAEMONIZE, 0))
dnl
dnl AC_EGREP_HEADER(xpasswd, pwd.h, AC_DEFINE(HAVE_XPASSWD, 1), AC_DEFINE(HAVE_XPASSWD, 0))
dnl dnl see if we have access to the undocumented Xt functions _XtRegisterWindow
dnl dnl and _XtUnregisterWindow. This test is bogus.
dnl AC_MSG_CHECKING([for undocumented Xt functions (THIS TEST IS BOGUS)])
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl AC_DEFINE(HAVE_XtRegisterWindow, 1)
dnl AC_MSG_RESULT(yes)
dnl else
dnl AC_DEFINE(HAVE_XtRegisterWindow, 0)
dnl AC_MSG_RESULT(no)
dnl fi
dnl dnl
dnl dnl Test for Motif headers. This sets IMOTIF to the -I flag which
dnl dnl will tell the compiler where to find the installed Motif headers.
dnl dnl
dnl for d in /usr/include /usr/X11R6/include /usr/X11 ; do
dnl AC_MSG_CHECKING([for $d/Xm/Xm.h])
dnl if test -f $d/Xm/Xm.h; then
dnl IMOTIF="-I$d"
dnl AC_MSG_RESULT([found it])
dnl break
dnl else
dnl AC_MSG_RESULT([not there])
dnl fi
dnl done
dnl if test ${IMOTIF:-hosed} = 'hosed'; then
dnl AC_MSG_ERROR(I couldn't find your Motif headers!)
dnl fi
dnl # Let's assume -I/usr/include is redundant and ignore it.
dnl if test $IMOTIF = '-I/usr/include'; then
dnl IMOTIF=""
dnl fi
dnl AC_SUBST(IMOTIF)
dnl dnl see if we need to include pfmt.c in libsysadmUtil. This is so horribly
dnl dnl lame. PFM_C and PFMT_LO will be set to "pfmt.c" and "pfmt.lo" if it's
dnl dnl needed, and "" if it's not. It truly sucks that I couldn't get away with
dnl dnl using just one or the other.
dnl AC_MSG_CHECKING([whether pfmt.c is needed (THIS TEST IS BOGUS)])
dnl if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
dnl PFMT_C=""
dnl PFMT_O=""
dnl AC_MSG_RESULT(no)
dnl else
dnl PFMT_C="pfmt.c"
dnl PFMT_LO="pfmt.lo"
dnl AC_MSG_RESULT(yes)
dnl fi
dnl AC_SUBST(PFMT_C)
dnl AC_SUBST(PFMT_LO)
dnl
dnl Checks for typedefs, structures, and compiler characteristics.
dnl
dnl (we don't need any of these for the simple tcpmux test... we will need to
dnl fix many of these later, though, and comment them in.)
dnl
dnl Good candidates for this section would be support for bool and namespaces.
dnl
dnl AC_C_CONST
dnl AC_TYPE_UID_T
dnl AC_C_INLINE
dnl AC_TYPE_MODE_T
dnl AC_TYPE_OFF_T
dnl AC_TYPE_PID_T
dnl AC_TYPE_SIZE_T
dnl AC_STRUCT_ST_RDEV
dnl AC_HEADER_TIME
dnl AC_STRUCT_TM
dnl dnl
dnl dnl Test for stat.st_fstype member (a char[] on IRIX)
dnl dnl
dnl AC_MSG_CHECKING([for stat.st_fstype string])
dnl AC_LANG_SAVE
dnl AC_LANG_CPLUSPLUS
dnl AC_TRY_COMPILE([#include <sys/stat.h>], [struct stat st; char *s = st.st_fstype; ], have_stat_st_fstype_string=yes, have_stat_st_fstype_string=no)
dnl AC_LANG_RESTORE
dnl if test "$have_stat_st_fstype_string" = "yes"; then
dnl AC_DEFINE(HAVE_STAT_ST_FSTYPE_STRING, 1)
dnl else
dnl AC_DEFINE(HAVE_STAT_ST_FSTYPE_STRING, 0)
dnl fi
dnl AC_MSG_RESULT($have_stat_st_fstype_string)
dnl dnl
dnl dnl Test for prmap_sgi_t
dnl dnl
dnl AC_CACHE_CHECK([for prmap_sgi_t], rhino_cv_have_prmap_sgi_t, [
dnl AC_LANG_SAVE
dnl AC_LANG_CPLUSPLUS
dnl AC_TRY_COMPILE([#include <sys/procfs.h>], [prmap_sgi_t f; f.pr_lockcnt = 0; ], rhino_cv_have_prmap_sgi_t=yes, rhino_cv_have_prmap_sgi_t=no)
dnl AC_LANG_RESTORE
dnl ])
dnl if test "$rhino_cv_have_prmap_sgi_t" = "yes"; then
dnl AC_DEFINE(HAVE_PRMAP_SGI_T)
dnl fi
dnl dnl
dnl dnl Test for built-in C++ bool type
dnl dnl
dnl AC_MSG_CHECKING([for built-in bool])
dnl AC_LANG_SAVE
dnl AC_LANG_CPLUSPLUS
dnl AC_TRY_COMPILE(, [bool foo = true; if(foo) foo = false; ], have_bool=yes, have_bool=no)
dnl AC_LANG_RESTORE
dnl if test "$have_bool" = "yes"; then
dnl AC_DEFINE(HAVE_BOOL, 1)
dnl else
dnl AC_DEFINE(HAVE_BOOL, 0)
dnl fi
dnl AC_MSG_RESULT($have_bool)
dnl dnl
dnl dnl Test for C++ namespace support
dnl dnl
dnl AC_MSG_CHECKING([for C++ namespace support])
dnl AC_LANG_SAVE
dnl AC_LANG_CPLUSPLUS
dnl dnl why do I need the "optional" cross-compiling action?
dnl AC_TRY_RUN([namespace foo { int bar(void) { return 0; } } int main(void) { return foo::bar(); } ], have_namespace=yes, have_namespace=no, have_namespace=no)
dnl dnl AC_TRY_COMPILE([namespace foo { int bar(void) { return 0; } } int main(void) { return foo::bar(); } ], have_namespace=yes, have_namespace=no)
dnl AC_LANG_RESTORE
dnl if test "$have_namespace" = "yes"; then
dnl AC_DEFINE(HAVE_NAMESPACE, 1)
dnl else
dnl AC_DEFINE(HAVE_NAMESPACE, 0)
dnl fi
dnl AC_MSG_RESULT($have_namespace)
dnl dnl this is a test
dnl AC_DEFINE(HAVE_BOOL, 3)
dnl AC_DEFINE(FOOBAR, 3)
dnl dnl WOFF: figure out what kinds of warning flags the compiler prefers
dnl AC_SUBST(WOFF)
dnl
dnl dnl XXX this is lame
dnl AC_MSG_CHECKING([for full warning flag])
dnl if test -n "$GXX"; then
dnl FULLWARN=-Wall
dnl else
dnl FULLWARN=-fullwarn
dnl fi
dnl AC_SUBST(FULLWARN)
dnl AC_MSG_RESULT($FULLWARN)
dnl
dnl See if "echo" needs -e flag.
dnl
AC_PATH_PROG(ECHO, echo)
AC_MSG_CHECKING([for echo -e flag])
if test "`$ECHO -e foo`" = 'foo'; then
ECHO="$ECHO -e"
fi
AC_SUBST(ECHO)
AC_MSG_RESULT($ECHO)
dnl
dnl Find the root of the web server's document tree
dnl
AC_MSG_CHECKING([for web server document root (THIS TEST IS BOGUS)])
webroots="\
/home/httpd/html \
/var/www/htdocs \
/usr/freeware/apache/share/httpd/htdocs"
for d in $webroots; do
if test -d $d; then
WEBROOTDIR=$d
break
fi
done
AC_SUBST(WEBROOTDIR)
AC_MSG_RESULT($WEBROOTDIR)
dnl
dnl Checks for library functions.
dnl
dnl (we don't need any of these for the simple tcpmux test... we will need to
dnl fix many of these later, though, and comment them in.)
dnl
dnl AC_PROG_GCC_TRADITIONAL
dnl AC_HEADER_MAJOR
dnl AC_FUNC_STRFTIME
dnl AC_FUNC_UTIME_NULL
dnl AC_FUNC_VPRINTF
dnl AC_CHECK_FUNCS(getcwd gethostname gettimeofday getwd mkdir putenv rmdir select socket strdup strerror strspn strtol strtoul)
dnl
dnl This adds #!gmake as the first line of each of these files. We need this
dnl on IRIX to use gmake instead of smake/pmake/etc., which will croak on the
dnl gmake Makefiles.
dnl
AC_OUTPUT_COMMANDS(
[
if test `uname` = 'IRIX' || test `uname` = 'IRIX64'; then
TMPFILE=configure.tmp
for f in $CONFIG_FILES; do
if test `basename $f` != 'Makefile'; then
# echo "skipping $f"
continue
fi
echo "adding #!gmake to $f"
if test -s $TMPFILE; then
echo "gahh, file $TMPFILE already exists"
exit 1
fi
mv $f $TMPFILE
echo '#!gmake' > $f
cat $TMPFILE >> $f
rm $TMPFILE
done
fi
])
dnl
dnl The list of files to generate.
dnl
AC_OUTPUT(
Makefile
association/Makefile
association/clustersAssocWithMachine/Makefile
association/logGroupsAssocWithCluster/Makefile
association/machinesAssocWithCluster/Makefile
association/machinesAssocWithFailoverPolicy/Makefile
association/resourceGroupsAssocWithCluster/Makefile
association/resourceGroupsAssocWithFailoverPolicy/Makefile
association/resourceGroupsAssocWithMachine/Makefile
association/resourceGroupsAssocWithResource/Makefile
association/resourcesAssocWithCluster/Makefile
association/resourcesAssocWithMachine/Makefile
association/resourcesAssocWithResourceGroup/Makefile
association/resourcesAssocWithResourceType/Makefile
association/resourcesAssocWithResource/Makefile
association/resourceTypesAssocWithCluster/Makefile
association/resourceTypesAssocWithMachine/Makefile
association/resourceTypesAssocWithResourceType/Makefile
build/Makefile
build/rpm/Makefile
build/rpm/rpm.spec
category/Makefile
category/cluster/Makefile
category/cluster-fake/Makefile
category/enumerate/Makefile
category/failoverPolicy/Makefile
category/failoverPolicy-fake/Makefile
category/filesystem/Makefile
category/globalParameters/Makefile
category/haEnumerate/Makefile
category/logGroup/Makefile
category/logGroup-fake/Makefile
category/machine/Makefile
category/machine-fake/Makefile
category/resourceGroup/Makefile
category/resourceGroup-fake/Makefile
category/resourceType/Makefile
category/resourceType-fake/Makefile
category/resource/Makefile
category/resource-fake/Makefile
cmd/Makefile
dnl cmd/cxdetail/Makefile
dnl cmd/cxtask/Makefile
cmd/fsdetail/Makefile
cmd/fsdetail/fsdetail.sh
cmd/fstask/Makefile
cmd/fstask/fstask.sh
include/Makefile
include/fsmgr/Makefile
i18n/Makefile
lib/Makefile
lib/libfscxCamCategory/Makefile
man/Makefile
man/fsrelnotes/Makefile
man/relnotes/Makefile
misc/Makefile
packages/Makefile
packages/com/Makefile
packages/com/sgi/Makefile
packages/com/sgi/fsmgr/Makefile
packages/com/sgi/fsmgr/category/Makefile
packages/com/sgi/fsmgr/detailView/Makefile
packages/com/sgi/fsmgr/detailView/images/Makefile
packages/com/sgi/fsmgr/ftr/Makefile
packages/com/sgi/fsmgr/ftr/iconlib/Makefile
packages/com/sgi/fsmgr/fsPackageP.properties
packages/com/sgi/fsmgr/metatask/Makefile
packages/com/sgi/fsmgr/plugin/Makefile
packages/com/sgi/fsmgr/task/Makefile
packages/com/sgi/fsmgr/task/images/Makefile
taskRegistry/Makefile
taskRegistry/BalanceLoadTaskGroup/Makefile
taskRegistry/ClusterCategory/Makefile
taskRegistry/ClusterTaskGroup/Makefile
taskRegistry/CLServicesTaskGroup/Makefile
taskRegistry/DiagnosticsTaskGroup/Makefile
taskRegistry/FailoverPolicyCategory/Makefile
taskRegistry/FailoverPolicyTaskGroup/Makefile
taskRegistry/FilesystemCategory/Makefile
taskRegistry/FilesystemTaskGroup/Makefile
taskRegistry/FixProblemsTaskGroup/Makefile
taskRegistry/HAServicesTaskGroup/Makefile
taskRegistry/MachineCategory/Makefile
taskRegistry/MachineTaskGroup/Makefile
taskRegistry/MaintainResourceGroupTaskGroup/Makefile
taskRegistry/ManageResourceGroupTaskGroup/Makefile
taskRegistry/PreventAutoFailoverTaskGroup/Makefile
taskRegistry/ResourceCategory/Makefile
taskRegistry/ResourceGroupCategory/Makefile
taskRegistry/ResourceGroupTaskGroup/Makefile
taskRegistry/ResourceTaskGroup/Makefile
taskRegistry/ResourceTypeCategory/Makefile
taskRegistry/ResourceTypeTaskGroup/Makefile
taskRegistry/SmartMetatasksTaskGroup/Makefile
util/Makefile
util/clikeys/Makefile
util/htmlhelp/Makefile
web/Makefile
web/CXFSManager/Makefile
web/FailSafeManager/Makefile
web/FailSafeManager/fsmgrhtml.sh
)