[NeXus-code-svn] r835 - in trunk: . test

apache at nexusformat.org apache at nexusformat.org
Sun Nov 26 19:48:26 GMT 2006


Author: Freddie Akeroyd
Date: Sun Nov 26 19:48:24 2006
New Revision: 835

Modified:
   trunk/autogen.sh
   trunk/configure.ac
   trunk/test/Makefile.am
   trunk/test/napif4_test.f
   trunk/test/napif5_test.f

Log:
Correct problem with --with-* being ignored in configure.ac
Add allow autoconf 2.60
Remove STOP from FORTRAN statement (message varies with compiler)
Add in check for F90 path and see if this is Absoft

refs #4



Modified: trunk/autogen.sh
Url: http://svn.nexusformat.org/viewvc/NeXusCode/trunk/autogen.sh?r1=834&r2=835
==============================================================================
--- trunk/autogen.sh	(original)
+++ trunk/autogen.sh	Sun Nov 26 19:48:24 2006
@@ -28,6 +28,10 @@
 case $autoconfversion in
     *2.5[2-79])
 	;;
+    *2.6*)
+	;;
+    *2.7*)
+	;;
     *)
 	echo "This autoconf version is not supported by NeXus."
 	echo "NeXus only supports autoconf 2.5[2-79]."

Modified: trunk/configure.ac
Url: http://svn.nexusformat.org/viewvc/NeXusCode/trunk/configure.ac?r1=834&r2=835
==============================================================================
--- trunk/configure.ac	(original)
+++ trunk/configure.ac	Sun Nov 26 19:48:24 2006
@@ -55,7 +55,7 @@
 AM_CONFIG_HEADER(include/nxconfig.h:include/nxconfig_h.in)
 dnl Checks for programs.
 AC_ARG_WITH([cc], AC_HELP_STRING([--with-cc=c compiler], [Specify name of C compiler]),
-	[], [with_cc=yes])
+	[with_cc=$withval], [with_cc=yes])
 if test x"$with_cc" != x"no" ; then
 	if test x"$with_cc" != x"yes" ; then CC="$with_cc"; fi
 	AC_PROG_CC
@@ -65,7 +65,7 @@
 	AC_MSG_ERROR([You need a C compiler to compile this package])
 fi
 
-AC_ARG_WITH([cxx], AC_HELP_STRING([--with-cxx=c++ compiler], [Specify name of C++ compiler]), [], [with_cxx=yes])
+AC_ARG_WITH([cxx], AC_HELP_STRING([--with-cxx=c++ compiler], [Specify name of C++ compiler]), [with_cxx=$withval], [with_cxx=yes])
 if test x"$with_cxx" != x"no" ; then
 	if test x"$with_cxx" != x"yes" ; then CXX="$with_cxx"; fi
 	AC_PROG_CXX
@@ -74,12 +74,12 @@
 fi
 
 AC_ARG_WITH([f90], AC_HELP_STRING([--with-f90=f90 compiler], [Specify name of FORTRAN 90 compiler]),
-	[], [with_f90=no])
+	[with_f90=$withval], [with_f90=no])
 if test x"$with_f90" != x"no" ; then
 	if test x"$with_f90" = x"yes" ; then
 		AC_CHECK_PROGS(FC, [g95 f90 f95 ifort])
 	else
-		AC_CHECK_PROGS(FC, ["$with_f90"])
+		AC_CHECK_PROGS(FC, [$with_f90])
 	fi
 	dnl f90 has a "module path" option - hard to get as you really need a
 	dnl ready compiled module to point the option at so for now we are just
@@ -97,7 +97,7 @@
 fi
 
 AC_ARG_WITH([f77], AC_HELP_STRING([--with-f77=f77 compiler], [Specify name of FORTRAN 77 compiler]),
-	[], [with_f77=no])
+	[with_f77=$withval], [with_f77=no])
 if test x"$with_f77" != x"no" ; then
 	if test x"$with_f77" != x"yes" ; then F77="$with_f77"; fi
 	AC_PROG_F77
@@ -112,7 +112,7 @@
 	F77=
 fi
 
-AC_ARG_WITH([swig], AC_HELP_STRING([--with-swig=swig compiler], [Specify name of swig compiler]), [], [with_swig=no])
+AC_ARG_WITH([swig], AC_HELP_STRING([--with-swig=swig compiler], [Specify name of swig compiler]), [with_swig=$withval], [with_swig=no])
 if test x$with_swig != xno; then
     if test x$with_swig != xyes; then
 	SWIG=$with_swig
@@ -233,6 +233,17 @@
 AC_CHECK_PROGS(MS_LIB, [LIB])
 AM_CONDITIONAL(HAVE_MS_LIB, [test ! -z "$MS_LIB"])
 
+dnl extra FCFLAGS
+if ! test -z "$FC"; then
+    fcpathlc=`which $FC 2>/dev/null | tr 'A-Z' 'a-z'`
+    case "$fcpathlc" in
+	*absort*)
+	    echo "Absoft compiler detected - adjusting FCFLAGS"
+	    FCFLAGS="$FCFLAGS -g -cons -YEXT_NAMES=LCS -YEXT_SFX=_"
+	    ;;
+    esac
+fi
+
 HDF_EXT=a # library file extent to look for with HDF libraries
 case $host in
     alpha*-dec-osf*)
@@ -271,7 +282,7 @@
 	chmod +x libtool
 	JAVAINCLUDE="-I/System/Library/Frameworks/JavaVM.framework/Headers"
 dnl	F90FLAGS="$F90FLAGS -g -cons -YEXT_NAMES=LCS -YEXT_SFX=_"
-	FCFLAGS="$FCFLAGS -qextname"
+dnl	FCFLAGS="$FCFLAGS -qextname"
 	SHARED_LDFLAGS="-Wl,-single_module"
 #	LTF90COMPILETAG="--tag=F77"
 #	LTF90LINKTAG="--tag=CC"

Modified: trunk/test/Makefile.am
Url: http://svn.nexusformat.org/viewvc/NeXusCode/trunk/test/Makefile.am?r1=834&r2=835
==============================================================================
--- trunk/test/Makefile.am	(original)
+++ trunk/test/Makefile.am	Sun Nov 26 19:48:24 2006
@@ -154,6 +154,7 @@
 NXtest_SOURCES = NXtest.f90
 NXtest_LDADD = $(LIBNEXUS90)
 NXtest_LINK = $(FCLINK)
+NXtest_LDFLAGS = -static $(LDFLAGS)
 else
 NXtest_SOURCES = dummy.c
 NXtest_LINK = $(LINK)

Modified: trunk/test/napif4_test.f
Url: http://svn.nexusformat.org/viewvc/NeXusCode/trunk/test/napif4_test.f?r1=834&r2=835
==============================================================================
--- trunk/test/napif4_test.f	(original)
+++ trunk/test/napif4_test.f	Sun Nov 26 19:48:24 2006
@@ -305,7 +305,6 @@
          ENDIF
       IF (NXCLOSEGROUP(FILEID) .NE. NX_OK) STOP
       IF (NXCLOSE(FILEID) .NE. NX_OK) STOP
-      STOP
       END
 C----------------------------------------------------------------------
 C     LEN_TRIM trims remaining blanks and tabs from the end of "string"

Modified: trunk/test/napif5_test.f
Url: http://svn.nexusformat.org/viewvc/NeXusCode/trunk/test/napif5_test.f?r1=834&r2=835
==============================================================================
--- trunk/test/napif5_test.f	(original)
+++ trunk/test/napif5_test.f	Sun Nov 26 19:48:24 2006
@@ -305,7 +305,6 @@
          ENDIF
       IF (NXCLOSEGROUP(FILEID) .NE. NX_OK) STOP
       IF (NXCLOSE(FILEID) .NE. NX_OK) STOP
-      STOP
       END
 C----------------------------------------------------------------------
 C     LEN_TRIM trims remaining blanks and tabs from the end of "string"


More information about the NeXus-code-svn mailing list