From 6864ebdd6aeb44aa86193f7723b872dbf1ed26fa Mon Sep 17 00:00:00 2001 From: James Laird Date: Thu, 30 Mar 2006 18:08:50 -0500 Subject: [svn-r12183] Purpose: Configure cleanup Description: Removed unused macros, migrated to non-depreciated macros. Solution: The changes to use standard AC_TRY_LIB macros earlier this week seem not to have broken anything, so I deleted the local macros in acsite.m4 (with an eye to eventually deleting the rest of the file and using only autoconf-supported macros). Replaced the depreciated AC_TRY_LIB with AC_LIB_IFELSE to shut up warnings during reconfigure. Platforms tested: mir, copper (should be just cleanup) --- acsite.m4 | 232 ----------------------------------------------------------- configure | 4 -- configure.in | 4 +- 3 files changed, 2 insertions(+), 238 deletions(-) diff --git a/acsite.m4 b/acsite.m4 index 08693c6..0ed8781 100644 --- a/acsite.m4 +++ b/acsite.m4 @@ -102,235 +102,3 @@ rm -rf conftest* AC_LANG_POP(Fortran) ]) -dnl ------------------------------------------------------------------------- -dnl AC_TRY_FCOMPILE() -dnl -dnl Check if we can compile a simple Fortran 90 program. -dnl -dnl AC_TRY_FCOMPILE(FUNCTION-BODY, -dnl [ACTION-IF-SUCCESS], [ACTION-IF-NOT-SUCCESS]) -dnl -AC_DEFUN([AC_TRY_FCOMPILE], -[AC_LANG_PUSH(Fortran) - -test -d conftestdir || mkdir conftestdir -cd conftestdir -rm -rf * - -cat >conftest.$ac_ext <conftest.$ac_ext <conftest.$ac_ext <&6 -dnl cat >conftest.f90 <<'EOF' -dnl program conftest -dnl if (selected_real_kind(12) .eq. kind(0.0)) then -dnl print '(a)','YES' -dnl else -dnl print '(a)','NO' -dnl end if -dnl end program conftest -dnl EOF -dnl $ac_cv_prog_F90 $FCFLAGS -o conftest conftest.f90 > /dev/null 2>&1 -dnl if test "`./conftest | head -1`" = YES; then -dnl echo "yes" 1>&6 -dnl AC_DEFINE(HIPREC) -dnl else -dnl echo "no" 1>&6 -dnl fi - -dnl echo $ac_n "checking whether f90 precision of default real type""... $ac_c" 1>&6 -dnl cat >conftest.f90 <<'EOF' -dnl program conftest -dnl if (kind(0.0) .eq. selected_real_kind(12) .or.& -dnl &kind(0.0) .eq. selected_real_kind(6) ) then -dnl print '(a)','YES' -dnl else -dnl print '(a)','NO' -dnl end if -dnl end program conftest -dnl EOF -dnl $ac_cv_prog_F90 $FCFLAGS -o conftest conftest.f90 > /dev/null 2>&1 -dnl if test "`./conftest | head -1`" = YES; then -dnl echo "OK" 1>&6 -dnl AC_DEFINE(REALOK) -dnl else -dnl echo "no" 1>&6 -dnl fi - -dnl echo $ac_n "checking accuracy of arithmetic""... $ac_c" 1>&6 -dnl cat >conftest.f90 <<'EOF' -dnl program conftest -dnl integer, parameter :: double=selected_real_kind(12) -dnl real(double), parameter :: ulp=2.0_double**(-47) -dnl real(double), parameter :: ans=0.92699498904359955986_double -dnl real(double) :: x,y,z -dnl integer i -dnl x=0.0_double -dnl y=ulp -dnl do i=2,100 -dnl z=x+y -dnl x=y -dnl y=z-int(z) -dnl end do -dnl if (y-ans .lt. ulp/2.0_double) then -dnl print '(a)','YES' -dnl else -dnl print '(a)','NO' -dnl end if -dnl end program conftest -dnl EOF -dnl $ac_cv_prog_F90 $FCFLAGS -o conftest conftest.f90 > /dev/null 2>&1 -dnl if test "`./conftest | head -1`" = YES; then -dnl echo "OK" 1>&6 -dnl AC_DEFINE(ARITHOK) -dnl else -dnl echo "no" 1>&6 -dnl fi - -dnl echo $ac_n "checking whether int is the fastest way to truncate""... $ac_c" 1>&6 -dnl cat >conftest.f90 <<'EOF' -dnl program conftest -dnl integer, parameter :: double=selected_real_kind(12) -dnl real(double), parameter :: ulp=2.0_double**(-47) -dnl real(double) :: x,y,z,ya,yb -dnl integer :: t0,t1,i,timea,timeb -dnl -dnl x=0.0_double -dnl y=ulp -dnl call system_clock(t0) -dnl do i=2,1000000 -dnl z=x+y -dnl x=y -dnl y=z-int(z) -dnl end do -dnl ya=y -dnl call system_clock(t1) -dnl timea=t1-t0 -dnl -dnl x=0.0_double -dnl y=ulp -dnl call system_clock(t0) -dnl do i=2,1000000 -dnl z=x+y -dnl x=y -dnl if (z.ge.1.0_double) then -dnl y=z-1.0_double -dnl else -dnl y=z -dnl end if -dnl end do -dnl yb=y -dnl call system_clock(t1) -dnl timeb=t1-t0 -dnl -dnl if (timea.lt.timeb) then -dnl print '(a)','YES' -dnl else -dnl print '(a)','NO' -dnl end if -dnl print *,ya,yb -dnl end program conftest -dnl EOF -dnl $ac_cv_prog_F90 $FCFLAGS -o conftest conftest.f90 > /dev/null 2>&1 -dnl if test "`./conftest | head -1`" = YES; then -dnl echo "yes" 1>&6 -dnl AC_DEFINE(USEINT) -dnl else -dnl echo "no" 1>&6 -dnl fi -dnl -dnl ------------------------------------------------------------------------- -dnl ------------------------------------------------------------------------- diff --git a/configure b/configure index 0ce39ef..7328199 100755 --- a/configure +++ b/configure @@ -48491,12 +48491,10 @@ ac_compiler_gnu=$ac_cv_fc_compiler_gnu cat >conftest.$ac_ext <<_ACEOF - program main include 'mpif.h' integer:: ierr call mpi_file_open( ierr ) - end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 @@ -48599,12 +48597,10 @@ rm -f conftest.err conftest.$ac_objext \ if test "X$PARALLEL" = "Xyes"; then cat >conftest.$ac_ext <<_ACEOF - program main include 'mpif.h' integer:: ierr call mpi_file_open( ierr ) - end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 diff --git a/configure.in b/configure.in index 3f31a2e..8f32823 100644 --- a/configure.in +++ b/configure.in @@ -2160,7 +2160,7 @@ case "X-$enable_parallel" in AC_LANG_PUSH(Fortran) dnl Try link a simple MPI program. If fail, try again with -lmpi. - AC_TRY_LINK(, [ + AC_LINK_IFELSE([ include 'mpif.h' integer:: ierr call mpi_file_open( ierr )],, @@ -2172,7 +2172,7 @@ case "X-$enable_parallel" in dnl Then try link a simple MPI-IO program. If fail, try again with dnl -lmpio. if test "X$PARALLEL" = "Xyes"; then - AC_TRY_LINK(, [ + AC_LINK_IFELSE([ include 'mpif.h' integer:: ierr call mpi_file_open( ierr )],, -- cgit v0.12