[Pvfs2-cvs] commit by aching in pvfs2-1/maint/config: aio.m4 gm.m4
ib.m4 mx.m4 portals.m4 bdb.m4 config.guess config.sub
kernel.m4 openssl.m4 rt.m4
CVS commit program
cvs at parl.clemson.edu
Mon Jul 21 14:22:18 EDT 2008
Update of /projects/cvsroot/pvfs2-1/maint/config
In directory parlweb1:/tmp/cvs-serv20547/maint/config
Modified Files:
Tag: locking-branch
bdb.m4 config.guess config.sub kernel.m4 openssl.m4 rt.m4
Added Files:
Tag: locking-branch
aio.m4 gm.m4 ib.m4 mx.m4 portals.m4
Log Message:
Reverse merged and ported to HEAD.
--- /dev/null 2004-06-24 14:04:38.000000000 -0400
+++ aio.m4 2008-07-21 14:22:18.000000000 -0400
@@ -0,0 +1,59 @@
+
+AC_DEFUN([AX_AIO],
+[
+ libaiopath=ifelse([$1], ,,$1)
+
+ if test "x$1" != "xno"; then
+
+ AC_MSG_CHECKING([for libaio library])
+
+ if test "x${libaiopath}" != "x"; then
+ CFLAGS="${CFLAGS} -I${libaiopath}/include"
+ LDFLAGS="$LDFLAGS -L${libaiopath}/lib64 -L${libaiopath}/lib"
+ SERVER_LDFLAGS="$SERVER_LDFLAGS -L${libaiopath}/lib64 -L${libaiopath}/lib"
+ fi
+ LIBS="$LIBS -laio"
+
+ AC_COMPILE_IFELSE(
+ [#include "libaio.h"],
+ [],
+ [AC_MSG_ERROR(Invalid libaio path specified. No libaio.h found.)])
+
+ AC_TRY_LINK(
+ [#include "libaio.h"],
+ [io_context_t * b;],
+ [AC_MSG_RESULT(yes)],
+ [AC_MSG_ERROR(could not find libaio libs)])
+
+ AC_DEFINE(WITH_AIO, 1, [Define if libaio exists])
+
+ AC_CHECK_HEADERS(libaio.h)
+ fi
+])
+
+AC_DEFUN([AX_AIO_OPTIONAL],
+[
+ AC_MSG_CHECKING([for libaio library])
+ TMPLIBS=${LIBS}
+ LIBS="$LIBS -laio"
+
+ AC_COMPILE_IFELSE(
+ [#include "libaio.h"],
+ [],
+ [AC_MSG_WARN(No libaio headers found.)])
+
+ AC_TRY_LINK(
+ [#include "libaio.h"],
+ [io_context_t * b;],
+ [AC_MSG_RESULT(yes)
+ AC_DEFINE(WITH_AIO, 1, [Define if libaio exists])
+ ],
+ [
+ AC_MSG_WARN(No libaio headers found.)
+ LIBS=${TMPLIBS}
+ ])
+
+ AC_CHECK_HEADERS(libaio.h)
+
+])
+
--- /dev/null 2004-06-24 14:04:38.000000000 -0400
+++ gm.m4 2008-07-21 14:22:18.000000000 -0400
@@ -0,0 +1,72 @@
+#
+# Configure rules for GM
+#
+# Copyright (C) 2008 Pete Wyckoff <pw at osc.edu>
+#
+# See COPYING in top-level directory.
+#
+AC_DEFUN([AX_GM],
+[
+ dnl Configure options for GM install path.
+ dnl --with-gm=<dir> is shorthand for
+ dnl --with-gm-includes=<dir>/include
+ dnl --with-gm-libs=<dir>/lib (or lib64 if that exists)
+ gm_home=
+ AC_ARG_WITH(gm,
+ [ --with-gm=<dir> Location of the GM install (default no GM)],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-gm requires the path to your GM tree.])
+ elif test "$withval" != no ; then
+ gm_home="$withval"
+ fi
+ )
+ AC_ARG_WITH(gm-includes,
+ [ --with-gm-includes=<dir> Location of the GM includes],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-gm-includes requires path to GM headers.])
+ elif test "$withval" != no ; then
+ GM_INCDIR="$withval"
+ fi
+ )
+ AC_ARG_WITH(gm-libs,
+ [ --with-gm-libs=<dir> Location of the GM libraries],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-gm-libs requires path to GM libraries.])
+ elif test "$withval" != no ; then
+ GM_LIBDIR="$withval"
+ fi
+ )
+ dnl If supplied the incls and libs explicitly, use them, else populate them
+ dnl using guesses from the --with-gm dir.
+ if test -n "$gm_home" ; then
+ if test -z "$GM_INCDIR"; then
+ GM_INCDIR=$gm_home/include
+ fi
+ if test -z "$GM_LIBDIR"; then
+ GM_LIBDIR=$gm_home/lib64
+ if test ! -d "$GM_LIBDIR" ; then
+ GM_LIBDIR=$gm_home/lib
+ fi
+ fi
+ fi
+ dnl If anything GM-ish was set, go look for header.
+ if test -n "$GM_INCDIR$GM_LIBDIR" ; then
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$GM_INCDIR -I$GM_INCDIR/gm"
+ AC_CHECK_HEADER(gm.h,, AC_MSG_ERROR([Header gm.h not found.]))
+ dnl Run test is not possible on a machine that does not have a GM NIC.
+ dnl Link test would work, but just check for existence.
+ if test ! -f $GM_LIBDIR/libgm.so ; then
+ if test ! -f $GM_LIBDIR/libgm.a ; then
+ AC_MSG_ERROR([Neither GM library libgm.so or libgm.a found.])
+ fi
+ fi
+ BUILD_GM=1
+ CPPFLAGS="$save_cppflags"
+ fi
+ AC_SUBST(BUILD_GM)
+ AC_SUBST(GM_INCDIR)
+ AC_SUBST(GM_LIBDIR)
+])
+
+dnl vim: set ft=config :
--- /dev/null 2004-06-24 14:04:38.000000000 -0400
+++ ib.m4 2008-07-21 14:22:18.000000000 -0400
@@ -0,0 +1,168 @@
+AC_DEFUN([AX_IB],
+[
+ dnl Configure options for IB install path.
+ dnl --with-ib=<dir> is shorthand for
+ dnl --with-ib-includes=<dir>/include
+ dnl --with-ib-libs=<dir>/lib (or lib64 if that exists)
+ ib_home=
+ AC_ARG_WITH(ib,
+ [ --with-ib=<dir> Location of the IB installation (default no IB)],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-ib requires the path to your IB tree.])
+ elif test "$withval" != no ; then
+ ib_home="$withval"
+ fi
+ )
+ AC_ARG_WITH(ib-includes,
+ [ --with-ib-includes=<dir> Location of the IB includes],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-ib-includes requires path to IB headers.])
+ elif test "$withval" != no ; then
+ IB_INCDIR="$withval"
+ fi
+ )
+ AC_ARG_WITH(ib-libs,
+ [ --with-ib-libs=<dir> Location of the IB libraries],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-ib-libs requires path to IB libraries.])
+ elif test "$withval" != no ; then
+ IB_LIBDIR="$withval"
+ fi
+ )
+ dnl If supplied the incls and libs explicitly, use them, else populate them
+ dnl using guesses from the --with-ib dir.
+ if test -n "$ib_home" ; then
+ if test -z "$IB_INCDIR"; then
+ IB_INCDIR=$ib_home/include
+ fi
+ if test -z "$IB_LIBDIR"; then
+ IB_LIBDIR=$ib_home/lib64
+ if test ! -d "$IB_LIBDIR" ; then
+ IB_LIBDIR=$ib_home/lib
+ fi
+ fi
+ fi
+ dnl If anything IB-ish was set, go look for header.
+ if test -n "$IB_INCDIR$IB_LIBDIR" ; then
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$IB_INCDIR"
+ AC_CHECK_HEADER(vapi.h,, AC_MSG_ERROR([Header vapi.h not found.]))
+ dnl Run test is not possible on a machine that does not have an IB NIC,
+ dnl and link test is hard because we need so many little libraries. Bail
+ dnl and just check for existence; full library list is in Makefile.in.
+ if test ! -f $IB_LIBDIR/libvapi.so ; then
+ if test ! -f $IB_LIBDIR/libvapi.a ; then
+ AC_MSG_ERROR([Infiniband library libvapi.so not found.])
+ fi
+ fi
+ BUILD_IB=1
+ AC_CHECK_HEADER(wrap_common.h,
+ AC_DEFINE(HAVE_IB_WRAP_COMMON_H, 1, Define if IB wrap_common.h exists.),
+ ,
+ [#include <vapi.h>])
+ CPPFLAGS="$save_cppflags"
+ fi
+ AC_SUBST(BUILD_IB)
+ AC_SUBST(IB_INCDIR)
+ AC_SUBST(IB_LIBDIR)
+
+ dnl Configure options for OpenIB install path.
+ dnl --with-openib=<dir> is shorthand for
+ dnl --with-openib-includes=<dir>/include
+ dnl --with-openib-libs=<dir>/lib (or lib64 if that exists)
+ openib_home=
+ AC_ARG_WITH(openib,
+ [ --with-openib=<dir> Location of the OpenIB install (default no OpenIB)],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-openib requires the path to your OpenIB tree.])
+ elif test "$withval" != no ; then
+ openib_home="$withval"
+ fi
+ )
+ AC_ARG_WITH(openib-includes,
+ [ --with-openib-includes=<dir> Location of the OpenIB includes],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-openib-includes requires path to OpenIB headers.])
+ elif test "$withval" != no ; then
+ OPENIB_INCDIR="$withval"
+ fi
+ )
+ AC_ARG_WITH(openib-libs,
+ [ --with-openib-libs=<dir> Location of the OpenIB libraries],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-openib-libs requires path to OpenIB libraries.])
+ elif test "$withval" != no ; then
+ OPENIB_LIBDIR="$withval"
+ fi
+ )
+ dnl If supplied the incls and libs explicitly, use them, else populate them
+ dnl using guesses from the --with-openib dir.
+ if test -n "$openib_home" ; then
+ if test -z "$OPENIB_INCDIR"; then
+ OPENIB_INCDIR=$openib_home/include
+ fi
+ if test -z "$OPENIB_LIBDIR"; then
+ OPENIB_LIBDIR=$openib_home/lib64
+ if test ! -d "$OPENIB_LIBDIR" ; then
+ OPENIB_LIBDIR=$openib_home/lib
+ fi
+ fi
+ fi
+ dnl If anything OpenIB-ish was set, go look for header.
+ if test -n "$OPENIB_INCDIR$OPENIB_LIBDIR" ; then
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$OPENIB_INCDIR"
+ AC_CHECK_HEADER(infiniband/verbs.h,,
+ AC_MSG_ERROR([Header infiniband/verbs.h not found.]))
+ dnl Run test is not possible on a machine that does not have an IB NIC.
+ dnl Link test would work, but just check for existence.
+ if test ! -f $OPENIB_LIBDIR/libibverbs.so ; then
+ if test ! -f $OPENIB_LIBDIR/libibverbs.a ; then
+ AC_MSG_ERROR([OpenIB library libibverbs.so not found.])
+ fi
+ fi
+ BUILD_OPENIB=1
+ CPPFLAGS="$save_cppflags"
+ fi
+ AC_SUBST(BUILD_OPENIB)
+ AC_SUBST(OPENIB_INCDIR)
+ AC_SUBST(OPENIB_LIBDIR)
+
+ if test -n "$BUILD_OPENIB" ; then
+ dnl Check for which version of the ibverbs library; device opening is
+ dnl different. This format is the older one, newer is
+ dnl ibv_get_device_list.
+ save_ldflags="$LDFLAGS"
+ LDFLAGS="-L$OPENIB_LIBDIR -libverbs"
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$OPENIB_INCDIR"
+
+ AC_MSG_CHECKING(for ibv_get_devices)
+ AC_TRY_LINK([], [
+ ibv_get_devices();
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_IBV_GET_DEVICES, 1,
+ Define if libibverbs has ibv_get_devices),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl Check for existence of reregister event; it's somewhat new.
+ AC_MSG_CHECKING(for IBV_EVENT_CLIENT_REREGISTER)
+ AC_TRY_COMPILE([
+ #include "infiniband/verbs.h"
+ ], [
+ enum ibv_event_type x = IBV_EVENT_CLIENT_REREGISTER;
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_IBV_EVENT_CLIENT_REREGISTER, 1,
+ Define if libibverbs has reregister event),
+ AC_MSG_RESULT(no)
+ )
+
+ LDFLAGS="$save_ldflags"
+ CPPFLAGS="$save_cppflags"
+ fi
+])
+
+dnl vim: set ft=config :
--- /dev/null 2004-06-24 14:04:38.000000000 -0400
+++ mx.m4 2008-07-21 14:22:18.000000000 -0400
@@ -0,0 +1,100 @@
+#
+# Configure rules for MX
+#
+# Copyright (C) 2008 Pete Wyckoff <pw at osc.edu>
+#
+# See COPYING in top-level directory.
+#
+AC_DEFUN([AX_MX],
+[
+ dnl Configure options for MX install path.
+ dnl --with-mx=<dir> is shorthand for
+ dnl --with-mx-includes=<dir>/include
+ dnl --with-mx-libs=<dir>/lib (or lib64 if that exists)
+ mx_home=
+ AC_ARG_WITH(mx,
+ [ --with-mx=<dir> Location of the MX install (default no MX)],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-mx requires the path to your MX tree.])
+ elif test "$withval" != no ; then
+ mx_home="$withval"
+ fi
+ )
+ AC_ARG_WITH(mx-includes,
+ [ --with-mx-includes=<dir> Location of the MX includes],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-mx-includes requires path to MX headers.])
+ elif test "$withval" != no ; then
+ MX_INCDIR="$withval"
+ fi
+ )
+ AC_ARG_WITH(mx-libs,
+ [ --with-mx-libs=<dir> Location of the MX libraries],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-mx-libs requires path to MX libraries.])
+ elif test "$withval" != no ; then
+ MX_LIBDIR="$withval"
+ fi
+ )
+ dnl If supplied the incls and libs explicitly, use them, else populate them
+ dnl using guesses from the --with-mx dir.
+ if test -n "$mx_home" ; then
+ if test -z "$MX_INCDIR"; then
+ MX_INCDIR=$mx_home/include
+ fi
+ if test -z "$MX_LIBDIR"; then
+ MX_LIBDIR=$mx_home/lib64
+ if test ! -d "$MX_LIBDIR" ; then
+ MX_LIBDIR=$mx_home/lib
+ fi
+ fi
+ fi
+ dnl If anything MX-ish was set, go look for header.
+ if test -n "$MX_INCDIR$MX_LIBDIR" ; then
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$MX_INCDIR -I$MX_INCDIR/mx"
+ AC_CHECK_HEADER(myriexpress.h,,
+ AC_MSG_ERROR([Header myriexpress.h not found.]))
+ dnl Run test is not possible on a machine that does not have a MX NIC.
+ dnl Link test would work, but just check for existence.
+ if test ! -f $MX_LIBDIR/libmyriexpress.so ; then
+ if test ! -f $MX_LIBDIR/libmyriexpress.a ; then
+ AC_MSG_ERROR([Neither MX library libmyriexpress.so or libmyriexpress.a found.])
+ fi
+ fi
+ BUILD_MX=1
+ CPPFLAGS="$save_cppflags"
+ fi
+ AC_SUBST(BUILD_MX)
+ AC_SUBST(MX_INCDIR)
+ AC_SUBST(MX_LIBDIR)
+
+ if test -n "$BUILD_MX" ; then
+ dnl Check for existence of mx_decompose_endpoint_addr2
+ save_ldflags="$LDFLAGS"
+ LDFLAGS="-L$MX_LIBDIR $LDFLAGS"
+ save_libs="$LIBS"
+ LIBS="-lmyriexpress -lpthread $LIBS"
+ save_cppflags="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS -I$MX_INCDIR"
+
+ AC_MSG_CHECKING(for mx_decompose_endpoint_addr2)
+ AC_TRY_LINK([
+ #include "mx_extensions.h"
+ #include <stdlib.h>
+ ], [
+ mx_endpoint_addr_t epa;
+ mx_decompose_endpoint_addr2(epa, NULL, NULL, NULL);
+ ],
+ AC_MSG_RESULT(yes),
+ AC_MSG_RESULT(no)
+ AC_MSG_ERROR([Function mx_decompose_endpoint_addr2() not found.])
+ )
+
+ LDFLAGS="$save_ldflags"
+ CPPFLAGS="$save_cppflags"
+ LIBS="$save_libs"
+ fi
+])
+
+dnl vim: set ft=config :
--- /dev/null 2004-06-24 14:04:38.000000000 -0400
+++ portals.m4 2008-07-21 14:22:18.000000000 -0400
@@ -0,0 +1,151 @@
+AC_DEFUN([AX_PORTALS],
+[
+ dnl
+ dnl Configure to build Portals BMI method, if requested and available.
+ dnl Use
+ dnl --with-portals To find include files and libraries in standard
+ dnl system paths.
+ dnl --with-portals=<dir> To specify a location that has include and lib
+ dnl (or lib64) subdirectories with the goods.
+ dnl
+ dnl Or specify the -I an -L and -l flags exactly using, e.g.:
+ dnl
+ dnl --with-portals-includes="-I<dir>"
+ dnl --with-portals-libs="-L<dir> -l<name>"
+ dnl
+ dnl The C file uses #include <portals/portals3.h>, so choose your include
+ dnl path accordingly. If it did not do this, portals/errno.h would sit in
+ dnl front of the system version.
+ dnl
+ use_portals=
+ home=
+ incs=
+ libs=
+ AC_ARG_WITH(portals,
+ [ --with-portals[=<dir>] Location of the Portals install (default no Portals)],
+ if test -z "$withval" -o "$withval" = yes ; then
+ use_portals=yes
+ elif test "$withval" != no ; then
+ home="$withval"
+ fi
+ )
+ AC_ARG_WITH(portals-includes,
+ [ --with-portals-includes=<dir> Extra CFLAGS to specify Portals includes],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-portals-includes requires an argument.])
+ elif test "$withval" != no ; then
+ incs="$withval"
+ fi
+ )
+ AC_ARG_WITH(portals-libs,
+ [ --with-portals-libs=<dir> Extra LIBS to link Portals libraries],
+ if test -z "$withval" -o "$withval" = yes ; then
+ AC_MSG_ERROR([Option --with-portals-libs requires an argument.])
+ elif test "$withval" != no ; then
+ libs="$withval"
+ fi
+ )
+ dnl If supplied the incls and libs explicitly, use them, else populate them
+ dnl using guesses from the --with-portals dir.
+ if test -n "$home" ; then
+ if test -z "$incs"; then
+ incs=-I$home/include
+ fi
+ if test -z "$libs"; then
+ libs=-L$home/lib64
+ if test ! -d "$home/lib64" ; then
+ libs=-L$home/lib
+ fi
+ fi
+ fi
+
+ dnl
+ dnl Look for headers and libs.
+ dnl
+ BUILD_PORTALS=
+ PORTALS_INCS=
+ PORTALS_LIBS=
+ if test "X$use_portals$home$incs$libs" != X ; then
+ # Save stuff
+ save_cppflags="$CPPFLAGS"
+ save_libs="$LIBS"
+
+ PORTALS_INCS="$incs"
+ CPPFLAGS="$CPPFLAGS $PORTALS_INCS"
+
+ PORTALS_LIBS="$libs"
+ LIBS="$save_libs $PORTALS_LIBS"
+
+ AC_MSG_CHECKING([for portals3.h header])
+ ok=no
+ AC_TRY_COMPILE(
+ [#include <portals/portals3.h>],
+ [int m, n; m = PtlInit(&n);],
+ [ok=yes])
+
+ if test "$ok" = yes ; then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([Header portals/portals3.h not found.])
+ fi
+
+ dnl try without first, for Cray, then try TCP version
+ dnl Run test is not always possible, esp when cross-compiling or on
+ dnl a box that does not have the hardware.
+ AC_MSG_CHECKING([for portals libraries])
+ ok=no
+ AC_TRY_LINK(
+ [#include <portals/portals3.h>],
+ [int m, n; m = PtlInit(&n);],
+ [ok=yes])
+
+ if test "$ok" = no ; then
+ PORTALS_LIBS="$libs -lportals"
+ LIBS="$save_libs $PORTALS_LIBS"
+ AC_TRY_LINK(
+ [#include <portals/portals3.h>],
+ [int m, n; m = PtlInit(&n);],
+ [ok=yes])
+ fi
+
+ if test "$ok" = no ; then
+ PORTALS_LIBS="$libs -lp3api -lp3lib -lp3utcp -lp3rt -lpthread"
+ LIBS="$save_libs $PORTALS_LIBS"
+ AC_TRY_LINK(
+ [#include <portals/portals3.h>],
+ [int m, n; m = PtlInit(&n);],
+ [ok=yes])
+ fi
+
+ if test "$ok" = yes ; then
+ AC_MSG_RESULT([yes])
+ BUILD_PORTALS=1
+ else
+ AC_MSG_RESULT([no])
+ AC_MSG_ERROR([Could not link Portals library.])
+ fi
+
+ #
+ # Check for API variations.
+ #
+ AC_CHECK_FUNCS(PtlErrorStr)
+ AC_CHECK_FUNCS(PtlEventKindStr)
+
+ AC_TRY_COMPILE(
+ [#include <portals/portals3.h>],
+ [int m; ptl_process_id_t any_pid;
+ m = PtlACEntry(0, 0, any_pid, (ptl_uid_t) -1, (ptl_jid_t) -1, 0);],
+ AC_DEFINE(HAVE_PTLACENTRY_JID, 1,
+ [Define if have PtlACEntry with jid argument.]))
+
+ # Reset
+ CPPFLAGS="$save_cppflags"
+ LIBS="$save_libs"
+ fi
+ AC_SUBST(BUILD_PORTALS)
+ AC_SUBST(PORTALS_INCS)
+ AC_SUBST(PORTALS_LIBS)
+])
+
+dnl vim: set ft=config :
Index: bdb.m4
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/bdb.m4,v
diff -p -u -r1.9 -r1.9.20.1
--- bdb.m4 23 May 2006 21:08:44 -0000 1.9
+++ bdb.m4 21 Jul 2008 18:22:18 -0000 1.9.20.1
@@ -31,11 +31,11 @@ AC_DEFUN([AX_BERKELEY_DB],
fi
DB_LDFLAGS="-L${dbpath}/lib"
- LDFLAGS="${LDFLAGS} $DB_LDFLAGS"
+ LDFLAGS="$DB_LDFLAGS ${LDFLAGS}"
LIBS="${oldlibs} -ldb -lpthread"
DB_LIB="-ldb"
- CFLAGS="$oldcflags $DB_CFLAGS"
+ CFLAGS="$DB_CFLAGS $oldcflags"
AC_TRY_LINK(
[#include <db.h>],
[DB *dbp; db_create(&dbp, NULL, 0);],
@@ -181,14 +181,14 @@ AC_DEFUN([AX_BERKELEY_DB],
AC_TRY_COMPILE([
#include <db.h>
], [
- int ret;
- DB *db;
- DB_TXN *txnid;
- char *file;
- char *database;
- DBTYPE type;
- u_int32_t flags;
- int mode;
+ int ret = 0;
+ DB *db = NULL;
+ DB_TXN *txnid = NULL;
+ char *file = NULL;
+ char *database = NULL;
+ DBTYPE type = 0;
+ u_int32_t flags = 0;
+ int mode = 0;
ret = db->open(db, txnid, file, database, type, flags, mode);
], AC_MSG_RESULT(yes)
@@ -217,5 +217,19 @@ AC_DEFUN([AX_BERKELEY_DB],
AC_DEFINE(HAVE_DB_BUFFER_SMALL, 1, [Define if db library has DB_BUFFER_SMALL error]),
AC_MSG_RESULT(no))
+ dnl Test to check for db->get_pagesize
+ AC_MSG_CHECKING(for berkeley db get_pagesize function)
+ AC_TRY_COMPILE([
+ #include <db.h>
+ ], [
+ int ret = 0;
+ DB *db = NULL;
+ int pagesize;
+
+ ret = db->get_pagesize(db, &pagesize);
+ ], AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_DB_GET_PAGESIZE, 1, [Define if DB has get_pagesize function]),
+ AC_MSG_RESULT(no))
+
CFLAGS="$oldcflags"
])
Index: config.guess
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/config.guess,v
diff -p -u -r1.4 -r1.4.60.1
--- config.guess 9 Feb 2005 19:15:42 -0000 1.4
+++ config.guess 21 Jul 2008 18:22:18 -0000 1.4.60.1
@@ -1,9 +1,10 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
+# Inc.
-timestamp='2004-06-11'
+timestamp='2007-05-17'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -17,13 +18,15 @@ timestamp='2004-06-11'
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
+# 02110-1301, USA.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
+
# Originally written by Per Bothner <per at bothner.com>.
# Please send patches to <config-patches at gnu.org>. Submit a context
# diff and a properly formatted ChangeLog entry.
@@ -53,7 +56,7 @@ version="\
GNU config.guess ($timestamp)
Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -66,11 +69,11 @@ Try \`$me --help' for more information."
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
- echo "$timestamp" ; exit 0 ;;
+ echo "$timestamp" ; exit ;;
--version | -v )
- echo "$version" ; exit 0 ;;
+ echo "$version" ; exit ;;
--help | --h* | -h )
- echo "$usage"; exit 0 ;;
+ echo "$usage"; exit ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
@@ -104,7 +107,7 @@ set_cc_for_build='
trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
: ${TMPDIR=/tmp} ;
- { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
+ { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
{ test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
{ tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
{ echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
@@ -123,7 +126,7 @@ case $CC_FOR_BUILD,$HOST_CC,$CC in
;;
,,*) CC_FOR_BUILD=$CC ;;
,*,*) CC_FOR_BUILD=$HOST_CC ;;
-esac ;'
+esac ; set_cc_for_build= ;'
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi at noc.rutgers.edu 1994-08-24)
@@ -158,6 +161,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
arm*) machine=arm-unknown ;;
sh3el) machine=shl-unknown ;;
sh3eb) machine=sh-unknown ;;
+ sh5el) machine=sh5le-unknown ;;
*) machine=${UNAME_MACHINE_ARCH}-unknown ;;
esac
# The Operating System including object format, if it has switched
@@ -196,64 +200,23 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
- exit 0 ;;
- amd64:OpenBSD:*:*)
- echo x86_64-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- amiga:OpenBSD:*:*)
- echo m68k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- arc:OpenBSD:*:*)
- echo mipsel-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- cats:OpenBSD:*:*)
- echo arm-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- hp300:OpenBSD:*:*)
- echo m68k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- luna88k:OpenBSD:*:*)
- echo m88k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- mac68k:OpenBSD:*:*)
- echo m68k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- macppc:OpenBSD:*:*)
- echo powerpc-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- mvme68k:OpenBSD:*:*)
- echo m68k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- mvme88k:OpenBSD:*:*)
- echo m88k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- mvmeppc:OpenBSD:*:*)
- echo powerpc-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- pmax:OpenBSD:*:*)
- echo mipsel-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- sgi:OpenBSD:*:*)
- echo mipseb-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- sun3:OpenBSD:*:*)
- echo m68k-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
- wgrisc:OpenBSD:*:*)
- echo mipsel-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:OpenBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
- exit 0 ;;
+ UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
+ echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
+ exit ;;
*:ekkoBSD:*:*)
echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
+ *:SolidBSD:*:*)
+ echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
+ exit ;;
macppc:MirBSD:*:*)
- echo powerppc-unknown-mirbsd${UNAME_RELEASE}
- exit 0 ;;
+ echo powerpc-unknown-mirbsd${UNAME_RELEASE}
+ exit ;;
*:MirBSD:*:*)
echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
alpha:OSF1:*:*)
case $UNAME_RELEASE in
*4.0)
@@ -306,40 +269,43 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
- exit 0 ;;
- Alpha*:OpenVMS:*:*)
- echo alpha-hp-vms
- exit 0 ;;
+ exit ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# Should we change UNAME_MACHINE based on the output of uname instead
# of the specific Alpha model?
echo alpha-pc-interix
- exit 0 ;;
+ exit ;;
21064:Windows_NT:50:3)
echo alpha-dec-winnt3.5
- exit 0 ;;
+ exit ;;
Amiga*:UNIX_System_V:4.0:*)
echo m68k-unknown-sysv4
- exit 0;;
+ exit ;;
*:[Aa]miga[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-amigaos
- exit 0 ;;
+ exit ;;
*:[Mm]orph[Oo][Ss]:*:*)
echo ${UNAME_MACHINE}-unknown-morphos
- exit 0 ;;
+ exit ;;
*:OS/390:*:*)
echo i370-ibm-openedition
- exit 0 ;;
+ exit ;;
+ *:z/VM:*:*)
+ echo s390-ibm-zvmoe
+ exit ;;
*:OS400:*:*)
echo powerpc-ibm-os400
- exit 0 ;;
+ exit ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
- exit 0;;
+ exit ;;
+ arm:riscos:*:*|arm:RISCOS:*:*)
+ echo arm-unknown-riscos
+ exit ;;
SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
echo hppa1.1-hitachi-hiuxmpp
- exit 0;;
+ exit ;;
Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
# akee at wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
if test "`(/bin/universe) 2>/dev/null`" = att ; then
@@ -347,32 +313,32 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
else
echo pyramid-pyramid-bsd
fi
- exit 0 ;;
+ exit ;;
NILE*:*:*:dcosx)
echo pyramid-pyramid-svr4
- exit 0 ;;
+ exit ;;
DRS?6000:unix:4.0:6*)
echo sparc-icl-nx6
- exit 0 ;;
- DRS?6000:UNIX_SV:4.2*:7*)
+ exit ;;
+ DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
case `/usr/bin/uname -p` in
- sparc) echo sparc-icl-nx7 && exit 0 ;;
+ sparc) echo sparc-icl-nx7; exit ;;
esac ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
+ exit ;;
sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
- i86pc:SunOS:5.*:*)
+ exit ;;
+ i86pc:SunOS:5.*:* | ix86xen:SunOS:5.*:*)
echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
+ exit ;;
sun4*:SunOS:6*:*)
# According to config.sub, this is the proper way to canonicalize
# SunOS6. Hard to guess exactly what SunOS6 will be like, but
# it's likely to be more like Solaris than SunOS4.
echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
+ exit ;;
sun4*:SunOS:*:*)
case "`/usr/bin/arch -k`" in
Series*|S4*)
@@ -381,10 +347,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
esac
# Japanese Language versions have a version number like `4.1.3-JL'.
echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
- exit 0 ;;
+ exit ;;
sun3*:SunOS:*:*)
echo m68k-sun-sunos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
sun*:*:4.2BSD:*)
UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
@@ -396,10 +362,10 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
echo sparc-sun-sunos${UNAME_RELEASE}
;;
esac
- exit 0 ;;
+ exit ;;
aushp:SunOS:*:*)
echo sparc-auspex-sunos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
# The situation for MiNT is a little confusing. The machine name
# can be virtually everything (everything which is not
# "atarist" or "atariste" at least should have a processor
@@ -410,40 +376,40 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
# be no problem.
atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
echo m68k-atari-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
echo m68k-milan-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
echo m68k-hades-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
echo m68k-unknown-mint${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
m68k:machten:*:*)
echo m68k-apple-machten${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
powerpc:machten:*:*)
echo powerpc-apple-machten${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
RISC*:Mach:*:*)
echo mips-dec-mach_bsd4.3
- exit 0 ;;
+ exit ;;
RISC*:ULTRIX:*:*)
echo mips-dec-ultrix${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
VAX*:ULTRIX*:*:*)
echo vax-dec-ultrix${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
2020:CLIX:*:* | 2430:CLIX:*:*)
echo clipper-intergraph-clix${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
mips:*:*:UMIPS | mips:*:*:RISCos)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
@@ -467,32 +433,33 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:$
exit (-1);
}
EOF
- $CC_FOR_BUILD -o $dummy $dummy.c \
- && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
- && exit 0
+ $CC_FOR_BUILD -o $dummy $dummy.c &&
+ dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
+ SYSTEM_NAME=`$dummy $dummyarg` &&
+ { echo "$SYSTEM_NAME"; exit; }
echo mips-mips-riscos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
Motorola:PowerMAX_OS:*:*)
echo powerpc-motorola-powermax
- exit 0 ;;
+ exit ;;
Motorola:*:4.3:PL8-*)
echo powerpc-harris-powermax
- exit 0 ;;
+ exit ;;
Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
echo powerpc-harris-powermax
- exit 0 ;;
+ exit ;;
Night_Hawk:Power_UNIX:*:*)
echo powerpc-harris-powerunix
- exit 0 ;;
+ exit ;;
m88k:CX/UX:7*:*)
echo m88k-harris-cxux7
- exit 0 ;;
+ exit ;;
m88k:*:4*:R4*)
echo m88k-motorola-sysv4
- exit 0 ;;
+ exit ;;
m88k:*:3*:R3*)
echo m88k-motorola-sysv3
- exit 0 ;;
+ exit ;;
AViiON:dgux:*:*)
# DG/UX returns AViiON for all architectures
UNAME_PROCESSOR=`/usr/bin/uname -p`
@@ -508,29 +475,29 @@ EOF
else
echo i586-dg-dgux${UNAME_RELEASE}
fi
- exit 0 ;;
+ exit ;;
M88*:DolphinOS:*:*) # DolphinOS (SVR3)
echo m88k-dolphin-sysv3
- exit 0 ;;
+ exit ;;
M88*:*:R3*:*)
# Delta 88k system running SVR3
echo m88k-motorola-sysv3
- exit 0 ;;
+ exit ;;
XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
echo m88k-tektronix-sysv3
- exit 0 ;;
+ exit ;;
Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
echo m68k-tektronix-bsd
- exit 0 ;;
+ exit ;;
*:IRIX*:*:*)
echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
- exit 0 ;;
+ exit ;;
????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
- echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
- exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX '
+ echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
+ exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
i*86:AIX:*:*)
echo i386-ibm-aix
- exit 0 ;;
+ exit ;;
ia64:AIX:*:*)
if [ -x /usr/bin/oslevel ] ; then
IBM_REV=`/usr/bin/oslevel`
@@ -538,7 +505,7 @@ EOF
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
- exit 0 ;;
+ exit ;;
*:AIX:2:3)
if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
eval $set_cc_for_build
@@ -553,14 +520,18 @@ EOF
exit(0);
}
EOF
- $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
- echo rs6000-ibm-aix3.2.5
+ if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
+ then
+ echo "$SYSTEM_NAME"
+ else
+ echo rs6000-ibm-aix3.2.5
+ fi
elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
echo rs6000-ibm-aix3.2.4
else
echo rs6000-ibm-aix3.2
fi
- exit 0 ;;
+ exit ;;
*:AIX:*:[45])
IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
@@ -574,28 +545,28 @@ EOF
IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
fi
echo ${IBM_ARCH}-ibm-aix${IBM_REV}
- exit 0 ;;
+ exit ;;
*:AIX:*:*)
echo rs6000-ibm-aix
- exit 0 ;;
+ exit ;;
ibmrt:4.4BSD:*|romp-ibm:BSD:*)
echo romp-ibm-bsd4.4
- exit 0 ;;
+ exit ;;
ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
- exit 0 ;; # report: romp-ibm BSD 4.3
+ exit ;; # report: romp-ibm BSD 4.3
*:BOSX:*:*)
echo rs6000-bull-bosx
- exit 0 ;;
+ exit ;;
DPX/2?00:B.O.S.:*:*)
echo m68k-bull-sysv3
- exit 0 ;;
+ exit ;;
9000/[34]??:4.3bsd:1.*:*)
echo m68k-hp-bsd
- exit 0 ;;
+ exit ;;
hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
echo m68k-hp-bsd4.4
- exit 0 ;;
+ exit ;;
9000/[34678]??:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
case "${UNAME_MACHINE}" in
@@ -657,9 +628,19 @@ EOF
esac
if [ ${HP_ARCH} = "hppa2.0w" ]
then
- # avoid double evaluation of $set_cc_for_build
- test -n "$CC_FOR_BUILD" || eval $set_cc_for_build
- if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null
+ eval $set_cc_for_build
+
+ # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
+ # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
+ # generating 64-bit code. GNU and HP use different nomenclature:
+ #
+ # $ CC_FOR_BUILD=cc ./config.guess
+ # => hppa2.0w-hp-hpux11.23
+ # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
+ # => hppa64-hp-hpux11.23
+
+ if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
+ grep __LP64__ >/dev/null
then
HP_ARCH="hppa2.0w"
else
@@ -667,11 +648,11 @@ EOF
fi
fi
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
- exit 0 ;;
+ exit ;;
ia64:HP-UX:*:*)
HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
echo ia64-hp-hpux${HPUX_REV}
- exit 0 ;;
+ exit ;;
3050*:HI-UX:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
@@ -699,166 +680,182 @@ EOF
exit (0);
}
EOF
- $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
+ $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
+ { echo "$SYSTEM_NAME"; exit; }
echo unknown-hitachi-hiuxwe2
- exit 0 ;;
+ exit ;;
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
echo hppa1.1-hp-bsd
- exit 0 ;;
+ exit ;;
9000/8??:4.3bsd:*:*)
echo hppa1.0-hp-bsd
- exit 0 ;;
+ exit ;;
*9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
echo hppa1.0-hp-mpeix
- exit 0 ;;
+ exit ;;
hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
echo hppa1.1-hp-osf
- exit 0 ;;
+ exit ;;
hp8??:OSF1:*:*)
echo hppa1.0-hp-osf
- exit 0 ;;
+ exit ;;
i*86:OSF1:*:*)
if [ -x /usr/sbin/sysversion ] ; then
echo ${UNAME_MACHINE}-unknown-osf1mk
else
echo ${UNAME_MACHINE}-unknown-osf1
fi
- exit 0 ;;
+ exit ;;
parisc*:Lites*:*:*)
echo hppa1.1-hp-lites
- exit 0 ;;
+ exit ;;
C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
echo c1-convex-bsd
- exit 0 ;;
+ exit ;;
C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
- exit 0 ;;
+ exit ;;
C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
echo c34-convex-bsd
- exit 0 ;;
+ exit ;;
C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
echo c38-convex-bsd
- exit 0 ;;
+ exit ;;
C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
echo c4-convex-bsd
- exit 0 ;;
+ exit ;;
CRAY*Y-MP:*:*:*)
echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ exit ;;
CRAY*[A-Z]90:*:*:*)
echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
| sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
-e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
-e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ exit ;;
CRAY*TS:*:*:*)
echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ exit ;;
CRAY*T3E:*:*:*)
echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ exit ;;
CRAY*SV1:*:*:*)
echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ exit ;;
*:UNICOS/mp:*:*)
- echo nv1-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
+ echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
+ exit ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit 0 ;;
+ exit ;;
5000:UNIX_System_V:4.*:*)
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
- exit 0 ;;
+ exit ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
sparc*:BSD/OS:*:*)
echo sparc-unknown-bsdi${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:BSD/OS:*:*)
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:FreeBSD:*:*)
- # Determine whether the default compiler uses glibc.
- eval $set_cc_for_build
- sed 's/^ //' << EOF >$dummy.c
- #include <features.h>
- #if __GLIBC__ >= 2
- LIBC=gnu
- #else
- LIBC=
- #endif
-EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
- # GNU/KFreeBSD systems have a "k" prefix to indicate we are using
- # FreeBSD's kernel, but not the complete OS.
- case ${LIBC} in gnu) kernel_only='k' ;; esac
- echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
- exit 0 ;;
+ case ${UNAME_MACHINE} in
+ pc98)
+ echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+ amd64)
+ echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+ *)
+ echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+ esac
+ exit ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
- exit 0 ;;
- i*:MINGW*:*)
+ exit ;;
+ *:MINGW*:*)
echo ${UNAME_MACHINE}-pc-mingw32
- exit 0 ;;
+ exit ;;
+ i*:windows32*:*)
+ # uname -m includes "-pc" on this system.
+ echo ${UNAME_MACHINE}-mingw32
+ exit ;;
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
- exit 0 ;;
- x86:Interix*:[34]*)
- echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//'
- exit 0 ;;
+ exit ;;
+ *:Interix*:[3456]*)
+ case ${UNAME_MACHINE} in
+ x86)
+ echo i586-pc-interix${UNAME_RELEASE}
+ exit ;;
+ EM64T | authenticamd)
+ echo x86_64-unknown-interix${UNAME_RELEASE}
+ exit ;;
+ esac ;;
[345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
echo i${UNAME_MACHINE}-pc-mks
- exit 0 ;;
+ exit ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
# UNAME_MACHINE based on the output of uname instead of i386?
echo i586-pc-interix
- exit 0 ;;
+ exit ;;
i*:UWIN*:*)
echo ${UNAME_MACHINE}-pc-uwin
- exit 0 ;;
+ exit ;;
+ amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
+ echo x86_64-unknown-cygwin
+ exit ;;
p*:CYGWIN*:*)
echo powerpcle-unknown-cygwin
- exit 0 ;;
+ exit ;;
prep*:SunOS:5.*:*)
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
- exit 0 ;;
+ exit ;;
*:GNU:*:*)
# the GNU system
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
- exit 0 ;;
+ exit ;;
*:GNU/*:*:*)
# other systems with GNU libc and userland
echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
- exit 0 ;;
+ exit ;;
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
- exit 0 ;;
+ exit ;;
arm*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
+ avr32*:Linux:*:*)
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
+ exit ;;
cris:Linux:*:*)
echo cris-axis-linux-gnu
- exit 0 ;;
+ exit ;;
+ crisv32:Linux:*:*)
+ echo crisv32-axis-linux-gnu
+ exit ;;
+ frv:Linux:*:*)
+ echo frv-unknown-linux-gnu
+ exit ;;
ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
m32r*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
m68*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
mips:Linux:*:*)
eval $set_cc_for_build
sed 's/^ //' << EOF >$dummy.c
@@ -875,8 +872,12 @@ EOF
#endif
#endif
EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
- test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
+ eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+ /^CPU/{
+ s: ::g
+ p
+ }'`"
+ test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
mips64:Linux:*:*)
eval $set_cc_for_build
@@ -894,15 +895,22 @@ EOF
#endif
#endif
EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
- test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
+ eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+ /^CPU/{
+ s: ::g
+ p
+ }'`"
+ test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
;;
+ or32:Linux:*:*)
+ echo or32-unknown-linux-gnu
+ exit ;;
ppc:Linux:*:*)
echo powerpc-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
ppc64:Linux:*:*)
echo powerpc64-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
alpha:Linux:*:*)
case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
EV5) UNAME_MACHINE=alphaev5 ;;
@@ -916,7 +924,7 @@ EOF
objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null
if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
- exit 0 ;;
+ exit ;;
parisc:Linux:*:* | hppa:Linux:*:*)
# Look for CPU level
case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
@@ -924,25 +932,31 @@ EOF
PA8*) echo hppa2.0-unknown-linux-gnu ;;
*) echo hppa-unknown-linux-gnu ;;
esac
- exit 0 ;;
+ exit ;;
parisc64:Linux:*:* | hppa64:Linux:*:*)
echo hppa64-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
s390:Linux:*:* | s390x:Linux:*:*)
echo ${UNAME_MACHINE}-ibm-linux
- exit 0 ;;
+ exit ;;
sh64*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
sh*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
sparc:Linux:*:* | sparc64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
+ vax:Linux:*:*)
+ echo ${UNAME_MACHINE}-dec-linux-gnu
+ exit ;;
x86_64:Linux:*:*)
echo x86_64-unknown-linux-gnu
- exit 0 ;;
+ exit ;;
+ xtensa:Linux:*:*)
+ echo xtensa-unknown-linux-gnu
+ exit ;;
i*86:Linux:*:*)
# The BFD linker knows what the default object file format is, so
# first see if it will tell us. cd to the root directory to prevent
@@ -960,15 +974,15 @@ EOF
;;
a.out-i386-linux)
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
- exit 0 ;;
+ exit ;;
coff-i386)
echo "${UNAME_MACHINE}-pc-linux-gnucoff"
- exit 0 ;;
+ exit ;;
"")
# Either a pre-BFD a.out linker (linux-gnuoldld) or
# one that does not give us useful --help.
echo "${UNAME_MACHINE}-pc-linux-gnuoldld"
- exit 0 ;;
+ exit ;;
esac
# Determine whether the default compiler is a.out or elf
eval $set_cc_for_build
@@ -985,7 +999,7 @@ EOF
LIBC=gnulibc1
# endif
#else
- #ifdef __INTEL_COMPILER
+ #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)
LIBC=gnu
#else
LIBC=gnuaout
@@ -995,16 +1009,23 @@ EOF
LIBC=dietlibc
#endif
EOF
- eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
- test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
- test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
+ eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+ /^LIBC/{
+ s: ::g
+ p
+ }'`"
+ test x"${LIBC}" != x && {
+ echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
+ exit
+ }
+ test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; }
;;
i*86:DYNIX/ptx:4*:*)
# ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
# earlier versions are messed up and put the nodename in both
# sysname and nodename.
echo i386-sequent-sysv4
- exit 0 ;;
+ exit ;;
i*86:UNIX_SV:4.2MP:2.*)
# Unixware is an offshoot of SVR4, but it has its own version
# number series starting with 2...
@@ -1012,27 +1033,27 @@ EOF
# I just have to hope. -- rms.
# Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
- exit 0 ;;
+ exit ;;
i*86:OS/2:*:*)
# If we were able to find `uname', then EMX Unix compatibility
# is probably installed.
echo ${UNAME_MACHINE}-pc-os2-emx
- exit 0 ;;
+ exit ;;
i*86:XTS-300:*:STOP)
echo ${UNAME_MACHINE}-unknown-stop
- exit 0 ;;
+ exit ;;
i*86:atheos:*:*)
echo ${UNAME_MACHINE}-unknown-atheos
- exit 0 ;;
- i*86:syllable:*:*)
+ exit ;;
+ i*86:syllable:*:*)
echo ${UNAME_MACHINE}-pc-syllable
- exit 0 ;;
+ exit ;;
i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
echo i386-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
i*86:*DOS:*:*)
echo ${UNAME_MACHINE}-pc-msdosdjgpp
- exit 0 ;;
+ exit ;;
i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
@@ -1040,15 +1061,16 @@ EOF
else
echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
fi
- exit 0 ;;
- i*86:*:5:[78]*)
+ exit ;;
+ i*86:*:5:[678]*)
+ # UnixWare 7.x, OpenUNIX and OpenServer 6.
case `/bin/uname -X | grep "^Machine"` in
*486*) UNAME_MACHINE=i486 ;;
*Pentium) UNAME_MACHINE=i586 ;;
*Pent*|*Celeron) UNAME_MACHINE=i686 ;;
esac
echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
- exit 0 ;;
+ exit ;;
i*86:*:3.2:*)
if test -f /usr/options/cb.name; then
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
@@ -1066,73 +1088,73 @@ EOF
else
echo ${UNAME_MACHINE}-pc-sysv32
fi
- exit 0 ;;
+ exit ;;
pc:*:*:*)
# Left here for compatibility:
# uname -m prints for DJGPP always 'pc', but it prints nothing about
# the processor, so we play safe by assuming i386.
echo i386-pc-msdosdjgpp
- exit 0 ;;
+ exit ;;
Intel:Mach:3*:*)
echo i386-pc-mach3
- exit 0 ;;
+ exit ;;
paragon:*:*:*)
echo i860-intel-osf1
- exit 0 ;;
+ exit ;;
i860:*:4.*:*) # i860-SVR4
if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
else # Add other i860-SVR4 vendors below as they are discovered.
echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
fi
- exit 0 ;;
+ exit ;;
mini*:CTIX:SYS*5:*)
# "miniframe"
echo m68010-convergent-sysv
- exit 0 ;;
+ exit ;;
mc68k:UNIX:SYSTEM5:3.51m)
echo m68k-convergent-sysv
- exit 0 ;;
+ exit ;;
M680?0:D-NIX:5.3:*)
echo m68k-diab-dnix
- exit 0 ;;
+ exit ;;
M68*:*:R3V[5678]*:*)
- test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
- 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0)
+ test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
+ 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
OS_REL=''
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && echo i486-ncr-sysv4.3${OS_REL} && exit 0
+ && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
/bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
- && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;;
+ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
/bin/uname -p 2>/dev/null | grep 86 >/dev/null \
- && echo i486-ncr-sysv4 && exit 0 ;;
+ && { echo i486-ncr-sysv4; exit; } ;;
m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
echo m68k-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
mc68030:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
- exit 0 ;;
+ exit ;;
TSUNAMI:LynxOS:2.*:*)
echo sparc-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
rs6000:LynxOS:2.*:*)
echo rs6000-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*)
echo powerpc-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
SM[BE]S:UNIX_SV:*:*)
echo mips-dde-sysv${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
RM*:ReliantUNIX-*:*:*)
echo mips-sni-sysv4
- exit 0 ;;
+ exit ;;
RM*:SINIX-*:*:*)
echo mips-sni-sysv4
- exit 0 ;;
+ exit ;;
*:SINIX-*:*:*)
if uname -p 2>/dev/null >/dev/null ; then
UNAME_MACHINE=`(uname -p) 2>/dev/null`
@@ -1140,68 +1162,81 @@ EOF
else
echo ns32k-sni-sysv
fi
- exit 0 ;;
+ exit ;;
PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
# says <Richard.M.Bartel at ccMail.Census.GOV>
echo i586-unisys-sysv4
- exit 0 ;;
+ exit ;;
*:UNIX_System_V:4*:FTX*)
# From Gerald Hewes <hewes at openmarket.com>.
# How about differentiating between stratus architectures? -djm
echo hppa1.1-stratus-sysv4
- exit 0 ;;
+ exit ;;
*:*:*:FTX*)
# From seanf at swdc.stratus.com.
echo i860-stratus-sysv4
- exit 0 ;;
+ exit ;;
+ i*86:VOS:*:*)
+ # From Paul.Green at stratus.com.
+ echo ${UNAME_MACHINE}-stratus-vos
+ exit ;;
*:VOS:*:*)
# From Paul.Green at stratus.com.
echo hppa1.1-stratus-vos
- exit 0 ;;
+ exit ;;
mc68*:A/UX:*:*)
echo m68k-apple-aux${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
news*:NEWS-OS:6*:*)
echo mips-sony-newsos6
- exit 0 ;;
+ exit ;;
R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
if [ -d /usr/nec ]; then
echo mips-nec-sysv${UNAME_RELEASE}
else
echo mips-unknown-sysv${UNAME_RELEASE}
fi
- exit 0 ;;
+ exit ;;
BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
echo powerpc-be-beos
- exit 0 ;;
+ exit ;;
BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
echo powerpc-apple-beos
- exit 0 ;;
+ exit ;;
BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
echo i586-pc-beos
- exit 0 ;;
+ exit ;;
SX-4:SUPER-UX:*:*)
echo sx4-nec-superux${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
SX-5:SUPER-UX:*:*)
echo sx5-nec-superux${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
SX-6:SUPER-UX:*:*)
echo sx6-nec-superux${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
+ SX-7:SUPER-UX:*:*)
+ echo sx7-nec-superux${UNAME_RELEASE}
+ exit ;;
+ SX-8:SUPER-UX:*:*)
+ echo sx8-nec-superux${UNAME_RELEASE}
+ exit ;;
+ SX-8R:SUPER-UX:*:*)
+ echo sx8r-nec-superux${UNAME_RELEASE}
+ exit ;;
Power*:Rhapsody:*:*)
echo powerpc-apple-rhapsody${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:Rhapsody:*:*)
echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:Darwin:*:*)
- case `uname -p` in
- *86) UNAME_PROCESSOR=i686 ;;
- powerpc) UNAME_PROCESSOR=powerpc ;;
+ UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
+ case $UNAME_PROCESSOR in
+ unknown) UNAME_PROCESSOR=powerpc ;;
esac
echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
UNAME_PROCESSOR=`uname -p`
if test "$UNAME_PROCESSOR" = "x86"; then
@@ -1209,22 +1244,25 @@ EOF
UNAME_MACHINE=pc
fi
echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:QNX:*:4*)
echo i386-pc-qnx
- exit 0 ;;
+ exit ;;
+ NSE-?:NONSTOP_KERNEL:*:*)
+ echo nse-tandem-nsk${UNAME_RELEASE}
+ exit ;;
NSR-?:NONSTOP_KERNEL:*:*)
echo nsr-tandem-nsk${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:NonStop-UX:*:*)
echo mips-compaq-nonstopux
- exit 0 ;;
+ exit ;;
BS2000:POSIX*:*:*)
echo bs2000-siemens-sysv
- exit 0 ;;
+ exit ;;
DS/*:UNIX_System_V:*:*)
echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:Plan9:*:*)
# "uname -m" is not consistent, so use $cputype instead. 386
# is converted to i386 for consistency with other x86
@@ -1235,31 +1273,47 @@ EOF
UNAME_MACHINE="$cputype"
fi
echo ${UNAME_MACHINE}-unknown-plan9
- exit 0 ;;
+ exit ;;
*:TOPS-10:*:*)
echo pdp10-unknown-tops10
- exit 0 ;;
+ exit ;;
*:TENEX:*:*)
echo pdp10-unknown-tenex
- exit 0 ;;
+ exit ;;
KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
echo pdp10-dec-tops20
- exit 0 ;;
+ exit ;;
XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
echo pdp10-xkl-tops20
- exit 0 ;;
+ exit ;;
*:TOPS-20:*:*)
echo pdp10-unknown-tops20
- exit 0 ;;
+ exit ;;
*:ITS:*:*)
echo pdp10-unknown-its
- exit 0 ;;
+ exit ;;
SEI:*:*:SEIUX)
echo mips-sei-seiux${UNAME_RELEASE}
- exit 0 ;;
+ exit ;;
*:DragonFly:*:*)
echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
- exit 0 ;;
+ exit ;;
+ *:*VMS:*:*)
+ UNAME_MACHINE=`(uname -p) 2>/dev/null`
+ case "${UNAME_MACHINE}" in
+ A*) echo alpha-dec-vms ; exit ;;
+ I*) echo ia64-dec-vms ; exit ;;
+ V*) echo vax-dec-vms ; exit ;;
+ esac ;;
+ *:XENIX:*:SysV)
+ echo i386-pc-xenix
+ exit ;;
+ i*86:skyos:*:*)
+ echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
+ exit ;;
+ i*86:rdos:*:*)
+ echo ${UNAME_MACHINE}-pc-rdos
+ exit ;;
esac
#echo '(No uname command or uname output not recognized.)' 1>&2
@@ -1291,7 +1345,7 @@ main ()
#endif
#if defined (__arm) && defined (__acorn) && defined (__unix)
- printf ("arm-acorn-riscix"); exit (0);
+ printf ("arm-acorn-riscix\n"); exit (0);
#endif
#if defined (hp300) && !defined (hpux)
@@ -1380,11 +1434,12 @@ main ()
}
EOF
-$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0
+$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
+ { echo "$SYSTEM_NAME"; exit; }
# Apollos put the system type in the environment.
-test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; }
+test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
# Convex versions that predate uname can use getsysinfo(1)
@@ -1393,22 +1448,22 @@ then
case `getsysinfo -f cpu_type` in
c1*)
echo c1-convex-bsd
- exit 0 ;;
+ exit ;;
c2*)
if getsysinfo -f scalar_acc
then echo c32-convex-bsd
else echo c2-convex-bsd
fi
- exit 0 ;;
+ exit ;;
c34*)
echo c34-convex-bsd
- exit 0 ;;
+ exit ;;
c38*)
echo c38-convex-bsd
- exit 0 ;;
+ exit ;;
c4*)
echo c4-convex-bsd
- exit 0 ;;
+ exit ;;
esac
fi
@@ -1419,7 +1474,9 @@ This script, last modified $timestamp, h
the operating system you are using. It is advised that you
download the most up to date version of the config scripts from
- ftp://ftp.gnu.org/pub/gnu/config/
+ http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess
+and
+ http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub
If the version you run ($0) is already up to date, please
send the following data and any information you think might be
Index: config.sub
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/config.sub,v
diff -p -u -r1.4 -r1.4.60.1
--- config.sub 9 Feb 2005 19:15:43 -0000 1.4
+++ config.sub 21 Jul 2008 18:22:18 -0000 1.4.60.1
@@ -1,9 +1,10 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation,
+# Inc.
-timestamp='2004-03-12'
+timestamp='2007-06-28'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -21,14 +22,15 @@ timestamp='2004-03-12'
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330,
-# Boston, MA 02111-1307, USA.
-
+# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
+# 02110-1301, USA.
+#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
+
# Please send patches to <config-patches at gnu.org>. Submit a context
# diff and a properly formatted ChangeLog entry.
#
@@ -70,7 +72,7 @@ Report bugs and patches to <config-patch
version="\
GNU config.sub ($timestamp)
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
@@ -83,11 +85,11 @@ Try \`$me --help' for more information."
while test $# -gt 0 ; do
case $1 in
--time-stamp | --time* | -t )
- echo "$timestamp" ; exit 0 ;;
+ echo "$timestamp" ; exit ;;
--version | -v )
- echo "$version" ; exit 0 ;;
+ echo "$version" ; exit ;;
--help | --h* | -h )
- echo "$usage"; exit 0 ;;
+ echo "$usage"; exit ;;
-- ) # Stop option processing
shift; break ;;
- ) # Use stdin as input.
@@ -99,7 +101,7 @@ while test $# -gt 0 ; do
*local*)
# First pass through any local machine types.
echo $1
- exit 0;;
+ exit ;;
* )
break ;;
@@ -118,8 +120,9 @@ esac
# Here we must recognize all the valid KERNEL-OS combinations.
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
case $maybe_os in
- nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
- kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
+ nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
+ uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
+ storm-chaos* | os2-emx* | rtmk-nova*)
os=-$maybe_os
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
;;
@@ -145,7 +148,7 @@ case $os in
-convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
-c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
-harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
- -apple | -axis)
+ -apple | -axis | -knuth | -cray)
os=
basic_machine=$1
;;
@@ -170,6 +173,10 @@ case $os in
-hiux*)
os=-hiuxwe2
;;
+ -sco6)
+ os=-sco5v6
+ basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+ ;;
-sco5)
os=-sco3.2v5
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -186,6 +193,10 @@ case $os in
# Don't forget version if it is 3.2v4 or newer.
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
;;
+ -sco5v6*)
+ # Don't forget version if it is 3.2v4 or newer.
+ basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+ ;;
-sco*)
os=-sco3.2v2
basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -230,14 +241,16 @@ case $basic_machine in
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
| am33_2.0 \
- | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
+ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
+ | bfin \
| c4x | clipper \
| d10v | d30v | dlx | dsp16xx \
- | fr30 | frv \
+ | fido | fr30 | frv \
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
| i370 | i860 | i960 | ia64 \
| ip2k | iq2000 \
- | m32r | m32rle | m68000 | m68k | m88k | mcore \
+ | m32c | m32r | m32rle | m68000 | m68k | m88k \
+ | maxq | mb | microblaze | mcore | mep \
| mips | mipsbe | mipseb | mipsel | mipsle \
| mips16 \
| mips64 | mips64el \
@@ -246,6 +259,7 @@ case $basic_machine in
| mips64vr4100 | mips64vr4100el \
| mips64vr4300 | mips64vr4300el \
| mips64vr5000 | mips64vr5000el \
+ | mips64vr5900 | mips64vr5900el \
| mipsisa32 | mipsisa32el \
| mipsisa32r2 | mipsisa32r2el \
| mipsisa64 | mipsisa64el \
@@ -254,20 +268,24 @@ case $basic_machine in
| mipsisa64sr71k | mipsisa64sr71kel \
| mipstx39 | mipstx39el \
| mn10200 | mn10300 \
+ | mt \
| msp430 \
+ | nios | nios2 \
| ns16k | ns32k \
- | openrisc | or32 \
+ | or32 \
| pdp10 | pdp11 | pj | pjl \
| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
| pyramid \
- | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+ | score \
+ | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
| sh64 | sh64le \
- | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv8 | sparcv9 | sparcv9b \
- | strongarm \
+ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
+ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
+ | spu | strongarm \
| tahoe | thumb | tic4x | tic80 | tron \
| v850 | v850e \
| we32k \
- | x86 | xscale | xstormy16 | xtensa \
+ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
| z8k)
basic_machine=$basic_machine-unknown
;;
@@ -278,6 +296,9 @@ case $basic_machine in
;;
m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
;;
+ ms1)
+ basic_machine=mt-unknown
+ ;;
# We use `pc' rather than `unknown'
# because (1) that's what they normally are, and
@@ -297,20 +318,20 @@ case $basic_machine in
| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
- | avr-* \
- | bs2000-* \
+ | avr-* | avr32-* \
+ | bfin-* | bs2000-* \
| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
- | clipper-* | cydra-* \
+ | clipper-* | craynv-* | cydra-* \
| d10v-* | d30v-* | dlx-* \
| elxsi-* \
- | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
+ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
| h8300-* | h8500-* \
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
| i*86-* | i860-* | i960-* | ia64-* \
| ip2k-* | iq2000-* \
- | m32r-* | m32rle-* \
+ | m32c-* | m32r-* | m32rle-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
- | m88110-* | m88k-* | mcore-* \
+ | m88110-* | m88k-* | maxq-* | mcore-* \
| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
| mips16-* \
| mips64-* | mips64el-* \
@@ -319,6 +340,7 @@ case $basic_machine in
| mips64vr4100-* | mips64vr4100el-* \
| mips64vr4300-* | mips64vr4300el-* \
| mips64vr5000-* | mips64vr5000el-* \
+ | mips64vr5900-* | mips64vr5900el-* \
| mipsisa32-* | mipsisa32el-* \
| mipsisa32r2-* | mipsisa32r2el-* \
| mipsisa64-* | mipsisa64el-* \
@@ -326,24 +348,28 @@ case $basic_machine in
| mipsisa64sb1-* | mipsisa64sb1el-* \
| mipsisa64sr71k-* | mipsisa64sr71kel-* \
| mipstx39-* | mipstx39el-* \
+ | mmix-* \
+ | mt-* \
| msp430-* \
- | none-* | np1-* | nv1-* | ns16k-* | ns32k-* \
+ | nios-* | nios2-* \
+ | none-* | np1-* | ns16k-* | ns32k-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
| pyramid-* \
| romp-* | rs6000-* \
- | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \
+ | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
- | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
- | sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
+ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
+ | sparclite-* \
+ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
| tahoe-* | thumb-* \
| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
| tron-* \
| v850-* | v850e-* | vax-* \
| we32k-* \
- | x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
- | xtensa-* \
+ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
+ | xstormy16-* | xtensa-* \
| ymp-* \
| z8k-*)
;;
@@ -445,13 +471,20 @@ case $basic_machine in
basic_machine=j90-cray
os=-unicos
;;
- cr16c)
- basic_machine=cr16c-unknown
+ craynv)
+ basic_machine=craynv-cray
+ os=-unicosmp
+ ;;
+ cr16)
+ basic_machine=cr16-unknown
os=-elf
;;
crds | unos)
basic_machine=m68k-crds
;;
+ crisv32 | crisv32-* | etraxfs*)
+ basic_machine=crisv32-axis
+ ;;
cris | cris-* | etrax*)
basic_machine=cris-axis
;;
@@ -481,6 +514,10 @@ case $basic_machine in
basic_machine=m88k-motorola
os=-sysv3
;;
+ djgpp)
+ basic_machine=i586-pc
+ os=-msdosdjgpp
+ ;;
dpx20 | dpx20-*)
basic_machine=rs6000-bull
os=-bosx
@@ -646,6 +683,10 @@ case $basic_machine in
basic_machine=i386-pc
os=-mingw32
;;
+ mingw32ce)
+ basic_machine=arm-unknown
+ os=-mingw32ce
+ ;;
miniframe)
basic_machine=m68000-convergent
;;
@@ -659,10 +700,6 @@ case $basic_machine in
mips3*)
basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
;;
- mmix*)
- basic_machine=mmix-knuth
- os=-mmixware
- ;;
monitor)
basic_machine=m68k-rom68k
os=-coff
@@ -675,6 +712,9 @@ case $basic_machine in
basic_machine=i386-pc
os=-msdos
;;
+ ms1-*)
+ basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
+ ;;
mvs)
basic_machine=i370-ibm
os=-mvs
@@ -743,10 +783,6 @@ case $basic_machine in
np1)
basic_machine=np1-gould
;;
- nv1)
- basic_machine=nv1-cray
- os=-unicosmp
- ;;
nsr-tandem)
basic_machine=nsr-tandem
;;
@@ -754,9 +790,8 @@ case $basic_machine in
basic_machine=hppa1.1-oki
os=-proelf
;;
- or32 | or32-*)
+ openrisc | openrisc-*)
basic_machine=or32-unknown
- os=-coff
;;
os400)
basic_machine=powerpc-ibm
@@ -787,6 +822,12 @@ case $basic_machine in
pc532 | pc532-*)
basic_machine=ns32k-pc532
;;
+ pc98)
+ basic_machine=i386-pc
+ ;;
+ pc98-*)
+ basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ;;
pentium | p5 | k5 | k6 | nexgen | viac3)
basic_machine=i586-pc
;;
@@ -843,6 +884,10 @@ case $basic_machine in
basic_machine=i586-unknown
os=-pw32
;;
+ rdos)
+ basic_machine=i386-pc
+ os=-rdos
+ ;;
rom68k)
basic_machine=m68k-rom68k
os=-coff
@@ -869,6 +914,10 @@ case $basic_machine in
sb1el)
basic_machine=mipsisa64sb1el-unknown
;;
+ sde)
+ basic_machine=mipsisa32-sde
+ os=-elf
+ ;;
sei)
basic_machine=mips-sei
os=-seiux
@@ -880,6 +929,9 @@ case $basic_machine in
basic_machine=sh-hitachi
os=-hms
;;
+ sh5el)
+ basic_machine=sh5le-unknown
+ ;;
sh64)
basic_machine=sh64-unknown
;;
@@ -1029,6 +1081,10 @@ case $basic_machine in
basic_machine=hppa1.1-winbond
os=-proelf
;;
+ xbox)
+ basic_machine=i686-pc
+ os=-mingw32
+ ;;
xps | xps100)
basic_machine=xps100-honeywell
;;
@@ -1059,6 +1115,9 @@ case $basic_machine in
romp)
basic_machine=romp-ibm
;;
+ mmix)
+ basic_machine=mmix-knuth
+ ;;
rs6000)
basic_machine=rs6000-ibm
;;
@@ -1075,13 +1134,10 @@ case $basic_machine in
we32k)
basic_machine=we32k-att
;;
- sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele)
+ sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
basic_machine=sh-unknown
;;
- sh64)
- basic_machine=sh64-unknown
- ;;
- sparc | sparcv8 | sparcv9 | sparcv9b)
+ sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
basic_machine=sparc-sun
;;
cydra)
@@ -1154,20 +1210,23 @@ case $os in
| -aos* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
- | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
+ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
+ | -openbsd* | -solidbsd* \
| -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
| -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
| -chorusos* | -chorusrdb* \
| -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
- | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
+ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
+ | -uxpv* | -beos* | -mpeix* | -udk* \
| -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
| -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
- | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*)
+ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
+ | -skyos* | -haiku* | -rdos* | -toppers* | -drops*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
@@ -1185,7 +1244,7 @@ case $os in
os=`echo $os | sed -e 's|nto|nto-qnx|'`
;;
-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
- | -windows* | -osx | -abug | -netware* | -os9* | -beos* \
+ | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
| -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
;;
-mac*)
@@ -1294,6 +1353,9 @@ case $os in
-kaos*)
os=-kaos
;;
+ -zvmoe)
+ os=-zvmoe
+ ;;
-none)
;;
*)
@@ -1316,6 +1378,12 @@ else
# system, and we'll never get to this point.
case $basic_machine in
+ score-*)
+ os=-elf
+ ;;
+ spu-*)
+ os=-elf
+ ;;
*-acorn)
os=-riscix1.2
;;
@@ -1325,9 +1393,9 @@ case $basic_machine in
arm*-semi)
os=-aout
;;
- c4x-* | tic4x-*)
- os=-coff
- ;;
+ c4x-* | tic4x-*)
+ os=-coff
+ ;;
# This must come before the *-dec entry.
pdp10-*)
os=-tops20
@@ -1353,6 +1421,9 @@ case $basic_machine in
m68*-cisco)
os=-aout
;;
+ mep-*)
+ os=-elf
+ ;;
mips*-cisco)
os=-elf
;;
@@ -1371,9 +1442,15 @@ case $basic_machine in
*-be)
os=-beos
;;
+ *-haiku)
+ os=-haiku
+ ;;
*-ibm)
os=-aix
;;
+ *-knuth)
+ os=-mmixware
+ ;;
*-wec)
os=-proelf
;;
@@ -1539,7 +1616,7 @@ case $basic_machine in
esac
echo $basic_machine$os
-exit 0
+exit
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
Index: kernel.m4
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/kernel.m4,v
diff -p -u -r1.12 -r1.12.12.1
--- kernel.m4 8 Aug 2006 22:35:31 -0000 1.12
+++ kernel.m4 21 Jul 2008 18:22:18 -0000 1.12.12.1
@@ -15,8 +15,13 @@ AC_DEFUN([AX_KERNEL_FEATURES],
NOSTDINCFLAGS="-Werror-implicit-function-declaration -nostdinc -isystem `$CC -print-file-name=include`"
- CFLAGS="$USR_CFLAGS $NOSTDINCFLAGS -I$lk_src/include -I$lk_src/include/asm-i386/mach-generic -I$lk_src/include/asm-i386/mach-default -DKBUILD_STR(s)=#s -DKBUILD_BASENAME=KBUILD_STR(empty) -DKBUILD_MODNAME=KBUILD_STR(empty) -imacros $lk_src/include/linux/autoconf.h"
+ CFLAGS="$USR_CFLAGS $NOSTDINCFLAGS -I$lk_src/include -I$lk_src/include/asm/mach-default -DKBUILD_STR(s)=#s -DKBUILD_BASENAME=KBUILD_STR(empty) -DKBUILD_MODNAME=KBUILD_STR(empty) -imacros $lk_src/include/linux/autoconf.h"
+ dnl we probably need additional includes if this build is intended
+ dnl for a different architecture
+ if test -n "${ARCH}" ; then
+ CFLAGS="$CFLAGS -I$lk_src/arch/${ARCH}/include"
+ fi
AC_MSG_CHECKING(for i_size_write in kernel)
dnl if this test passes, the kernel does not have it
@@ -51,20 +56,105 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_DEFINE(HAVE_I_SIZE_READ, 1, Define if kernel has i_size_read),
)
- AC_MSG_CHECKING(for parent_ino in kernel)
+ AC_MSG_CHECKING(for iget_locked function in kernel)
+ dnl if this test passes, the kernel does not have it
+ dnl if this test fails, the kernel already defined it
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ loff_t iget_locked(struct inode *inode)
+ {
+ return 0;
+ }
+ ], [],
+ AC_MSG_RESULT(no),
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_IGET_LOCKED, 1, Define if kernel has iget_locked),
+ )
+
+ AC_MSG_CHECKING(for iget4_locked function in kernel)
+ dnl if this test passes, the kernel does not have it
+ dnl if this test fails, the kernel already defined it
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ loff_t iget4_locked(struct inode *inode)
+ {
+ return 0;
+ }
+ ], [],
+ AC_MSG_RESULT(no),
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_IGET4_LOCKED, 1, Define if kernel has iget4_locked),
+ )
+
+ AC_MSG_CHECKING(for iget5_locked function in kernel)
dnl if this test passes, the kernel does not have it
dnl if this test fails, the kernel already defined it
AC_TRY_COMPILE([
#define __KERNEL__
#include <linux/fs.h>
- ino_t parent_ino(struct dentry *dentry)
+ loff_t iget5_locked(struct inode *inode)
{
- return (ino_t)0;
+ return 0;
}
], [],
AC_MSG_RESULT(no),
AC_MSG_RESULT(yes)
- AC_DEFINE(HAVE_PARENT_INO, 1, Define if kernel has parent_ino),
+ AC_DEFINE(HAVE_IGET5_LOCKED, 1, Define if kernel has iget5_locked),
+ )
+
+ dnl Check if the kernel defines the xtvec structure.
+ dnl This is part of a POSIX extension.
+ AC_MSG_CHECKING(for struct xtvec in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/uio.h>
+ static struct xtvec xv = { 0, 0 };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_STRUCT_XTVEC, 1, Define if struct xtvec is defined in the kernel),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl 2.6.20 deprecated kmem_cache_t; some old ones do not have struct
+ dnl kmem_cache, but may have kmem_cache_s. It's a mess. Just look
+ dnl for this, and assume _t if not found.
+ dnl This test relies on gcc complaining about declaring a struct
+ dnl in a parameter list. Fragile, but nothing better is available
+ dnl to check for the existence of a struct. We cannot see the
+ dnl definition of the struct in the kernel, it's private to the
+ dnl slab implementation. And C lets you declare structs freely as
+ dnl long as you don't try to deal with their contents.
+ tmp_cflags=$CFLAGS
+ CFLAGS="$CFLAGS -Werror"
+ AC_MSG_CHECKING(for struct kmem_cache in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/kernel.h>
+ #include <linux/slab.h>
+
+ int foo(struct kmem_cache *s)
+ {
+ return (s == NULL) ? 3 : 4;
+ }
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_STRUCT_KMEM_CACHE, 1, Define if struct kmem_cache is defined in kernel),
+ AC_MSG_RESULT(no)
+ )
+ CFLAGS=$tmp_cflags
+
+ dnl 2.6.20 removed SLAB_KERNEL. Need to use GFP_KERNEL instead
+ AC_MSG_CHECKING(for SLAB_KERNEL flag in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/slab.h>
+ static int flags = SLAB_KERNEL;
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_SLAB_KERNEL, 1, Define if SLAB_KERNEL is defined in kernel),
+ AC_MSG_RESULT(no)
)
dnl The name of this field changed from memory_backed to capabilities
@@ -99,6 +189,192 @@ AC_DEFUN([AX_KERNEL_FEATURES],
)
fi
+ dnl checking if we have a readv callback in super_operations
+ AC_MSG_CHECKING(for readv callback in struct file_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct file_operations fop = {
+ .readv = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_READV_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has readv callback),
+ AC_MSG_RESULT(no)
+ )
+ dnl checking if we have a writev callback in super_operations
+ AC_MSG_CHECKING(for writev callback in struct file_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct file_operations fop = {
+ .writev = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_WRITEV_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has writev callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a find_inode_handle callback in super_operations
+ AC_MSG_CHECKING(for find_inode_handle callback in struct super_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct super_operations sop = {
+ .find_inode_handle = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_FIND_INODE_HANDLE_SUPER_OPERATIONS, 1, Define if struct super_operations in kernel has find_inode_handle callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl 2.6.18.1 removed this member
+ AC_MSG_CHECKING(for i_blksize in struct inode)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct inode i = {
+ .i_blksize = 0,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_I_BLKSIZE_IN_STRUCT_INODE, 1, Define if struct inode in kernel has i_blksize member),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl 2.6.16 removed this member
+ AC_MSG_CHECKING(for i_sem in struct inode)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct inode i = {
+ .i_sem = {0},
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_I_SEM_IN_STRUCT_INODE, 1, Define if struct inode in kernel has i_sem member),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a statfs_lite callback in super_operations
+ AC_MSG_CHECKING(for statfs_lite callback in struct super_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct super_operations sop = {
+ .statfs_lite = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_STATFS_LITE_SUPER_OPERATIONS, 1, Define if struct super_operations in kernel has statfs_lite callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a fill_handle callback in inode_operations
+ AC_MSG_CHECKING(for fill_handle callback in struct inode_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct inode_operations iop = {
+ .fill_handle = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_FILL_HANDLE_INODE_OPERATIONS, 1, Define if struct inode_operations in kernel has fill_handle callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a getattr_lite callback in inode_operations
+ AC_MSG_CHECKING(for getattr_lite callback in struct inode_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct inode_operations iop = {
+ .getattr_lite = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_GETATTR_LITE_INODE_OPERATIONS, 1, Define if struct inode_operations in kernel has getattr_lite callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a get_fs_key callback in super_operations
+ AC_MSG_CHECKING(for get_fs_key callback in struct super_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ static struct super_operations sop = {
+ .get_fs_key = NULL,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_GET_FS_KEY_SUPER_OPERATIONS, 1, Define if struct super_operations in kernel has get_fs_key callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a readdirplus callback in file_operations
+ AC_MSG_CHECKING(for readdirplus member in file_operations structure)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct file_operations filop = {
+ .readdirplus = NULL
+ };
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_READDIRPLUS_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has readdirplus callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a readdirplus_lite callback in file_operations
+ AC_MSG_CHECKING(for readdirplus_lite member in file_operations structure)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct file_operations filop = {
+ .readdirplus_lite = NULL
+ };
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_READDIRPLUSLITE_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has readdirplus_lite callback),
+ AC_MSG_RESULT(no)
+ )
+
+
+ dnl checking if we have a readx callback in file_operations
+ AC_MSG_CHECKING(for readx member in file_operations structure)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct file_operations filop = {
+ .readx = NULL
+ };
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_READX_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has readx callback),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl checking if we have a writex callback in file_operations
+ AC_MSG_CHECKING(for writex member in file_operations structure)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct file_operations filop = {
+ .writex = NULL
+ };
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_WRITEX_FILE_OPERATIONS, 1, Define if struct file_operations in kernel has writex callback),
+ AC_MSG_RESULT(no)
+ )
+
AC_MSG_CHECKING(for aio support in kernel)
dnl if this test passes, the kernel has it
dnl if this test fails, the kernel does not have it
@@ -132,44 +408,81 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_DEFINE(HAVE_AIO_VFS_SUPPORT, 1, Define if we are enabling VFS AIO support in kernel),
AC_MSG_RESULT(no)
)
+
+ tmp_cflags=$CFLAGS
+ dnl if this test passes, the signature of aio_read has changed to the new one
+ CFLAGS="$CFLAGS -Werror"
+ AC_MSG_CHECKING(for new prototype of aio_read callback of file_operations structure)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ extern ssize_t my_aio_read(struct kiocb *, const struct iovec *, unsigned long, loff_t);
+ static struct file_operations fop = {
+ .aio_read = my_aio_read,
+ };
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_AIO_NEW_AIO_SIGNATURE, 1, Define if VFS AIO support in kernel has a new prototype),
+ AC_MSG_RESULT(no)
+ )
+ CFLAGS=$tmp_cflags
+
fi
- tmp_cflags=$CFLAGS
- dnl if this test passes, there is a struct dentry* argument
- CFLAGS="$CFLAGS -Werror"
- AC_MSG_CHECKING(if statfs callbacks' arguments in kernel has struct dentry argument)
- dnl if this test passes, the kernel has it
- dnl if this test fails, the kernel does not have it
+ AC_MSG_CHECKING(for dentry argument in kernel super_operations statfs)
+ dnl Rely on the fact that there is an external vfs_statfs that is
+ dnl of the same type as the .statfs in struct super_operations to
+ dnl verify the signature of that function pointer. There is a single
+ dnl commit in the git history where both changed at the same time
+ dnl from super_block to dentry.
+ dnl
+ dnl The alternative approach of trying to define a s_op.statfs is not
+ dnl as nice because that only throws a warning, requiring -Werror to
+ dnl catch it. This is a problem if the compiler happens to spit out
+ dnl other spurious warnings that have nothing to do with the test.
+ dnl
+ dnl If this test passes, the kernel uses a struct dentry argument.
+ dnl If this test fails, the kernel uses something else (old struct
+ dnl super_block perhaps).
AC_TRY_COMPILE([
#define __KERNEL__
#include <linux/fs.h>
- extern int pvfs_statfs(struct dentry *, struct kstatfs *);
- static struct super_operations s_op = {
- .statfs = pvfs_statfs,
- };
+ int vfs_statfs(struct dentry *de, struct kstatfs *kfs)
+ {
+ return 0;
+ }
], [],
AC_MSG_RESULT(yes)
- AC_DEFINE(HAVE_DENTRY_STATFS_SOP, 1, Define if statfs callback has struct dentry argument),
+ AC_DEFINE(HAVE_DENTRY_STATFS_SOP, 1, Define if super_operations statfs has dentry argument),
AC_MSG_RESULT(no)
)
- AC_MSG_CHECKING(if get_sb callbacks' in kernel has struct vfsmount argument)
- dnl if this test passes, the kernel has it
- dnl if this test fails, the kernel does not have it
+ AC_MSG_CHECKING(for vfsmount argument in kernel file_system_type get_sb)
+ dnl Same trick as above. A single commit changed mayn things at once:
+ dnl type and signature of file_system_type.get_sb, and signature of
+ dnl get_sb_bdev. This test is a bit more tenuous, as get_sb_bdev
+ dnl isn't used directly in a file_system_type, but is a popular helper
+ dnl for many FSes. And it has not exactly the same signature.
+ dnl
+ dnl If this test passes, the kernel has the most modern known form,
+ dnl which includes a stfuct vfsmount argument.
+ dnl If this test fails, the kernel uses something else.
AC_TRY_COMPILE([
#define __KERNEL__
#include <linux/fs.h>
- #include <linux/mount.h>
- extern int pvfs_get_sb(struct file_system_type *fst, int flags, const char *devname, void *data, struct vfsmount *);
- static struct file_system_type fst = {
- .get_sb = pvfs_get_sb,
- };
+ int get_sb_bdev(struct file_system_type *fs_type, int flags,
+ const char *dev_name, void *data,
+ int (*fill_super)(struct super_block *, void *,
+ int),
+ struct vfsmount *vfsm)
+ {
+ return 0;
+ }
], [],
AC_MSG_RESULT(yes)
- AC_DEFINE(HAVE_VFSMOUNT_GETSB, 1, Define if get_sb callback has struct vfsmount argument),
+ AC_DEFINE(HAVE_VFSMOUNT_GETSB, 1, Define if file_system_type get_sb has vfsmount argument),
AC_MSG_RESULT(no)
)
- CFLAGS=$tmp_cflags
AC_MSG_CHECKING(for xattr support in kernel)
dnl if this test passes, the kernel has it
@@ -191,23 +504,26 @@ AC_DEFUN([AX_KERNEL_FEATURES],
if test "x$have_xattr" = "xyes"; then
dnl Test to check if setxattr function has a const void * argument
AC_MSG_CHECKING(for const argument to setxattr function)
- tmp_cflags=$CFLAGS
dnl if this test passes, there is a const void* argument
- CFLAGS="$CFLAGS -Werror"
AC_TRY_COMPILE([
#define __KERNEL__
#include <linux/fs.h>
- int pvfs2_setxattr(struct dentry *dentry, const char *name,
- const void *value, size_t size, int flags) { return (0);};
- static struct inode_operations in_op = {
- .setxattr = pvfs2_setxattr
- };
- ], [],
+ ],
+ [
+ struct inode_operations inode_ops;
+ int ret;
+ struct dentry * dent = NULL;
+ const char * name = NULL;
+ const void * val = NULL;
+ size_t size = 0;
+ int flags = 0;
+
+ ret = inode_ops.setxattr(dent, name, val, size, flags);
+ ],
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_SETXATTR_CONST_ARG, 1, Define if kernel setxattr has const void* argument),
AC_MSG_RESULT(no)
)
- CFLAGS=$tmp_cflags
fi
dnl Test to see if sysctl proc handlers have a 6th argument
@@ -270,6 +586,29 @@ AC_DEFUN([AX_KERNEL_FEATURES],
[#define __KERNEL__
#include <asm/ioctl32.h>
] )
+ AC_CHECK_HEADERS([linux/exportfs.h], [],[],
+ [#define __KERNEL__
+ #include <linux/exportfs.h>
+ ])
+
+ AC_MSG_CHECKING(for generic_file_readv api in kernel)
+ dnl if this test passes, the kernel does not have it
+ dnl if this test fails, the kernel has it defined with a different
+ dnl signature! deliberately, the signature for this method has been
+ dnl changed for it to give a compiler error.
+
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ int generic_file_readv(struct inode *inode)
+ {
+ return 0;
+ }
+ ], [],
+ AC_MSG_RESULT(no),
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_GENERIC_FILE_READV, 1, Define if kernel has generic_file_readv),
+ )
AC_MSG_CHECKING(for generic_permission api in kernel)
dnl if this test passes, the kernel does not have it
@@ -320,6 +659,32 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_MSG_RESULT(no)
)
+ AC_MSG_CHECKING(for fh_to_dentry member in export_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/exportfs.h>
+ ], [
+ struct export_operations x;
+ x.fh_to_dentry = NULL;
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_FHTODENTRY_EXPORT_OPERATIONS, 1, Define if export_operations has an fh_to_dentry member),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(for encode_fh member in export_operations in kernel)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/exportfs.h>
+ ], [
+ struct export_operations x;
+ x.encode_fh = NULL;
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_ENCODEFH_EXPORT_OPERATIONS, 1, Define if export_operations has an encode_fh member),
+ AC_MSG_RESULT(no)
+ )
+
dnl Using -Werror is not an option, because some arches throw lots of
dnl warnings that would trigger false negatives. We know that the
dnl change to the releasepage() function signature was accompanied by
@@ -352,29 +717,56 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_MSG_RESULT(no)
)
+ dnl kmem_cache_destroy function may return int only on pre 2.6.19 kernels
+ dnl else it returns a void.
+ AC_MSG_CHECKING(for int return in kmem_cache_destroy)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/slab.h>
+ extern int kmem_cache_destroy(kmem_cache_t *);
+ ], [],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_INT_RETURN_KMEM_CACHE_DESTROY, 1, Define if return value from kmem_cache_destroy is type int),
+ AC_MSG_RESULT(no)
+ )
+
dnl more 2.6 api changes. return type for the invalidatepage
dnl address_space_operation is 'void' in new kernels but 'int' in old
dnl I had to turn on -Werror for this test because i'm not sure how
dnl else to make dnl "initialization from incompatible pointer type"
dnl fail.
- tmp_cflags=${CFLAGS}
- CFLAGS="${CFLAGS} -Werror"
AC_MSG_CHECKING(for older int return in invalidatepage)
AC_TRY_COMPILE([
#define __KERNEL__
#include <linux/fs.h>
- static int cfg_invalidate_page(struct page * page, unsigned long offset) {
- return 0;
- }
- struct address_space_operations aso =
- {
- .invalidatepage = cfg_invalidate_page,
- };
- ], [],
+ ],
+ [
+ struct address_space_operations aso;
+
+ int ret;
+ struct page * page = NULL;
+ unsigned long offset;
+
+ ret = aso.invalidatepage(page, offset);
+ ],
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_INT_RETURN_ADDRESS_SPACE_OPERATIONS_INVALIDATEPAGE, 1, Define if return type of invalidatepage should be int),
AC_MSG_RESULT(NO)
)
+
+ dnl In 2.6.18.1 and newer, including <linux/config.h> will throw off a
+ dnl warning
+ tmp_cflags=${CFLAGS}
+ CFLAGS="${CFLAGS} -Werror"
+ AC_MSG_CHECKING(for warnings when including linux/config.h)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/config.h>
+ ], [],
+ AC_MSG_RESULT(no)
+ AC_DEFINE(HAVE_NOWARNINGS_WHEN_INCLUDING_LINUX_CONFIG_H, 1, Define if including linux/config.h gives no warnings),
+ AC_MSG_RESULT(yes)
+ )
CFLAGS=$tmp_cflags
AC_MSG_CHECKING(for compat_ioctl member in file_operations structure)
@@ -391,6 +783,8 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_MSG_RESULT(no)
)
+ dnl Gives wrong answer if header is missing; don't try then.
+ if test x$ac_cv_header_linux_ioctl32_h = xyes ; then
AC_MSG_CHECKING(for register_ioctl32_conversion kernel exports)
dnl if this test passes, the kernel does not have it
dnl if this test fails, the kernel has it defined
@@ -406,6 +800,243 @@ AC_DEFUN([AX_KERNEL_FEATURES],
AC_MSG_RESULT(no),
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_REGISTER_IOCTL32_CONVERSION, 1, Define if kernel has register_ioctl32_conversion),
+ )
+ fi
+
+ AC_MSG_CHECKING(for int return value of kmem_cache_destroy)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/slab.h>
+ ], [
+ int i = kmem_cache_destroy(NULL);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_KMEM_CACHE_DESTROY_INT_RETURN, 1, Define if kmem_cache_destroy returns int),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl As of 2.6.19, combined readv/writev into aio_read and aio_write
+ dnl functions. Detect this by not finding a readv member.
+ AC_MSG_CHECKING(for combined file_operations readv and aio_read)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct file_operations filop = {
+ .readv = NULL
+ };
+ ],
+ AC_MSG_RESULT(no),
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_COMBINED_AIO_AND_VECTOR, 1, Define if struct file_operations has combined aio_read and readv functions),
+ )
+
+ dnl Check for kzalloc
+ AC_MSG_CHECKING(for kzalloc)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/slab.h>
+ ], [
+ void * a;
+ a = kzalloc(1024, GFP_KERNEL);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_KZALLOC, 1, Define if kzalloc exists),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl Check for two arg register_sysctl_table()
+ AC_MSG_CHECKING(for two arguments to register_sysctl_table)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/sysctl.h>
+ #include <linux/proc_fs.h>
+ ], [
+ register_sysctl_table(NULL, 0);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_TWO_ARG_REGISTER_SYSCTL_TABLE, 1, Define if register_sysctl_table takes two arguments),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl FS_IOC_GETFLAGS and FS_IOC_SETFLAGS appeared
+ dnl somewhere around 2.6.20.1 as generic versions of fs-specific flags
+ AC_MSG_CHECKING(for generic FS_IOC ioctl flags)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ int flags = FS_IOC_GETFLAGS;
+ ],
+ AC_MSG_RESULT(yes),
+ AC_DEFINE(HAVE_NO_FS_IOC_FLAGS, 1, Define if FS_IOC flags missing from fs.h)
+ AC_MSG_RESULT(no)
+ )
+
+ dnl old linux kernels define struct page with a 'count' member, whereas
+ dnl other kernels (since at least 2.6.20) define struct page with a
+ dnl '_count'
+ AC_MSG_CHECKING(for obsolete struct page count without underscore)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/mm.h>
+ ], [
+ struct page *p;
+ int foo;
+ foo = atomic_read(&(p)->count);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_OBSOLETE_STRUCT_PAGE_COUNT_NO_UNDERSCORE, 1, Define if struct page defines a count member without leading underscore),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl old linux kernels do not have class_create and related functions
+ dnl
+ dnl check for class_device_destroy() to weed out RHEL4 kernels that
+ dnl have some class functions but not others
+ AC_MSG_CHECKING(if kernel has device classes)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/device.h>
+ ], [
+ class_device_destroy(NULL, "pvfs2")
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_KERNEL_DEVICE_CLASSES, 1, Define if kernel has device classes),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl 2.6.23 removed the destructor parameter from kmem_cache_create
+ AC_MSG_CHECKING(for destructor param to kmem_cache_create)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/slab.h>
+ ], [
+ kmem_cache_create("config-test", 0, 0, 0, NULL, NULL);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_KMEM_CACHE_CREATE_DESTRUCTOR_PARAM, 1, [Define if kernel kmem_cache_create has destructor param]),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl 2.6.24 changed the constructor parameter signature of
+ dnl kmem_cache_create. Check for this newer two-param style and
+ dnl if not, assume it is old. Note we can get away with just
+ dnl struct kmem_cache (and not kmem_cache_t) as that change happened
+ dnl in older kernels. If they don't match, gcc complains about
+ dnl passing argument ... from incompatible pointer type, hence the
+ dnl need for the -Werror.
+ tmp_cflags=$CFLAGS
+ CFLAGS="$CFLAGS -Werror"
+ AC_MSG_CHECKING(for two-param kmem_cache_create constructor)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/kernel.h>
+ #include <linux/slab.h>
+ void ctor(struct kmem_cache *cachep, void *req)
+ {
+ }
+ ], [
+ kmem_cache_create("config-test", 0, 0, 0, ctor);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_KMEM_CACHE_CREATE_CTOR_TWO_PARAM, 1, [Define if kernel kmem_cache_create constructor has new-style two-parameter form]),
+ AC_MSG_RESULT(no)
+ )
+ CFLAGS=$tmp_cflags
+
+ AC_MSG_CHECKING(if kernel address_space struct has a spin_lock field named page_lock)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space as;
+ spin_lock(&as.page_lock);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_SPIN_LOCK_PAGE_ADDR_SPACE_STRUCT, 1, [Define if kernel address_space struct has a spin_lock member named page_lock instead of rw_lock]),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(if kernel address_space struct has a rwlock_t field named tree_lock)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space as;
+ read_lock(&as.tree_lock);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_SPIN_LOCK_TREE_ADDR_SPACE_STRUCT, 1, [Define if kernel address_space struct has a spin_lock member named tree_lock instead of rw_lock]),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(if kernel address_space struct has a priv_lock field - from RT linux)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space as;
+ spin_lock(&as.priv_lock);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_RT_PRIV_LOCK_ADDR_SPACE_STRUCT, 1, [Define if kernel address_space struct has a spin_lock for private data instead of rw_lock -- used by RT linux]),
+ AC_MSG_RESULT(no)
+ )
+
+ AC_MSG_CHECKING(if kernel defines mapping_nrpages macro - from RT linux)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct address_space idata;
+ int i = mapping_nrpages(&idata);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_MAPPING_NRPAGES_MACRO, 1, [Define if kernel defines mapping_nrpages macro -- defined by RT linux]),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl Starting with 2.6.25-rc1, .read_inode goes away.
+ AC_MSG_CHECKING(if kernel super_operations contains read_inode field)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/fs.h>
+ ], [
+ struct super_operations sops;
+ sops.read_inode(NULL);
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_READ_INODE, 1, [Define if kernel super_operations contains read_inode field]),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl older 2.6 kernels don't have MNT_NOATIME
+ AC_MSG_CHECKING(if mount.h defines MNT_NOATIME)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/mount.h>
+ ], [
+ int flag = MNT_NOATIME;
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_MNT_NOATIME, 1, [Define if mount.h contains
+ MNT_NOATIME flags]),
+ AC_MSG_RESULT(no)
+ )
+
+ dnl older 2.6 kernels don't have MNT_NODIRATIME
+ AC_MSG_CHECKING(if mount.h defines MNT_NODIRATIME)
+ AC_TRY_COMPILE([
+ #define __KERNEL__
+ #include <linux/mount.h>
+ ], [
+ int flag = MNT_NODIRATIME;
+ ],
+ AC_MSG_RESULT(yes)
+ AC_DEFINE(HAVE_MNT_NODIRATIME, 1, [Define if mount.h contains
+ MNT_NODIRATIME flags]),
+ AC_MSG_RESULT(no)
)
CFLAGS=$oldcflags
Index: openssl.m4
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/openssl.m4,v
diff -p -u -r1.2 -r1.2.4.1
--- openssl.m4 11 Sep 2006 00:38:43 -0000 1.2
+++ openssl.m4 21 Jul 2008 18:22:18 -0000 1.2.4.1
@@ -3,26 +3,59 @@ AC_DEFUN([AX_OPENSSL],
[
opensslpath=ifelse([$1], ,,$1)
- AC_MSG_CHECKING([for openssl library])
+ if test "x$1" != "xno"; then
+
+ AC_MSG_CHECKING([for openssl library])
+
+ if test "x${opensslpath}" != "x"; then
+ CFLAGS="${CFLAGS} -I${opensslpath}/include"
+ LDFLAGS="$LDFLAGS -L${opensslpath}/lib64 -L${opensslpath}/lib"
+ SERVER_LDFLAGS="$SERVER_LDFLAGS -L${opensslpath}/lib64 -L${opensslpath}/lib"
+ fi
+ LIBS="$LIBS -lcrypto -lssl"
+
+ AC_COMPILE_IFELSE(
+ [#include "openssl/bio.h"],
+ [],
+ [AC_MSG_ERROR(Invalid openssl path specified. No openssl/bio.h found.)])
+
+ AC_TRY_LINK(
+ [#include "openssl/bio.h"],
+ [BIO * b;],
+ [AC_MSG_RESULT(yes)],
+ [AC_MSG_ERROR(could not find openssl libs)])
+
+ AC_DEFINE(WITH_OPENSSL, 1, [Define if openssl exists])
+
+ AC_CHECK_HEADERS(openssl/evp.h)
+ AC_CHECK_HEADERS(openssl/crypto.h)
+ fi
+])
- if test "x${opensslpath}" != "x"; then
- CFLAGS="${CFLAGS} -I${opensslpath}/include"
- LDFLAGS="$LDFLAGS -L${opensslpath}/lib64 -L${opensslpath}/lib"
- SERVER_LDFLAGS="$SERVER_LDFLAGS -L${opensslpath}/lib64 -L${opensslpath}/lib"
- fi
- LIBS="$LIBS -lcrypt -lssl"
+AC_DEFUN([AX_OPENSSL_OPTIONAL],
+[
+ AC_MSG_CHECKING([for openssl library])
+ TMPLIBS=${LIBS}
+ LIBS="$LIBS -lcrypto -lssl"
AC_COMPILE_IFELSE(
- [#include "openssl/bio.h"],
- [],
- [AC_MSG_ERROR(Invalid openssl path specified. No openssl/evp.h found.)])
+ [#include "openssl/bio.h"],
+ [],
+ [AC_MSG_WARN(No openssl headers found.)])
AC_TRY_LINK(
- [#include "openssl/bio.h"],
- [BIO * b;],
- [AC_MSG_RESULT(yes)],
- [AC_MSG_ERROR(could not find openssl libs)])
+ [#include "openssl/bio.h"],
+ [BIO * b;],
+ [AC_MSG_RESULT(yes)
+ AC_DEFINE(WITH_OPENSSL, 1, [Define if openssl exists])
+ ],
+ [
+ AC_MSG_WARN(No openssl headers found.)
+ LIBS=${TMPLIBS}
+ ])
+
+ AC_CHECK_HEADERS(openssl/evp.h)
+ AC_CHECK_HEADERS(openssl/crypto.h)
- AC_DEFINE(WITH_OPENSSL, 1, [Define if openssl exists])
])
Index: rt.m4
===================================================================
RCS file: /projects/cvsroot/pvfs2-1/maint/config/rt.m4,v
diff -p -u -r1.1 -r1.1.56.1
--- rt.m4 10 Nov 2005 01:26:56 -0000 1.1
+++ rt.m4 21 Jul 2008 18:22:18 -0000 1.1.56.1
@@ -3,8 +3,6 @@ AC_DEFUN([AX_CHECK_NEEDS_LIBRT],
[
AC_MSG_CHECKING([if server lib needs -lrt])
-oldldflags=$LDFLAGS
-
AC_TRY_LINK(
[#include <stdlib.h>
#include <unistd.h>
@@ -12,7 +10,8 @@ AC_TRY_LINK(
[lio_listio(LIO_NOWAIT, NULL, 0, NULL);],
[AC_MSG_RESULT(no)],
[
- LDFLAGS="$LDFLAGS -lrt"
+ oldlibs=$LIBS
+ LIBS="$LIBS -lrt"
AC_TRY_LINK(
[#include <stdlib.h>
#include <unistd.h>
@@ -22,7 +21,6 @@ AC_TRY_LINK(
AC_SUBST(NEEDS_LIBRT)
AC_MSG_RESULT(yes)],
[AC_MSG_ERROR(failed attempting to link lio_listio)])
+ LIBS=$oldlibs
])
-
-LDFLAGS=$oldldflags
])
More information about the Pvfs2-cvs
mailing list