← Back to team overview

dolfin team mailing list archive

Re: [Branch ~dolfin-core/dolfin/main] Rev 4931: Some work at harmonizing output from configure scripts. Perhaps we need to revert since

 

On Tue, Aug 10, 2010 at 4:25 PM,  <noreply@xxxxxxxxxxxxx> wrote:
> ------------------------------------------------------------
> revno: 4931
> committer: Anders Logg <logg@xxxxxxxxx>
> branch nick: dolfin-dev
> timestamp: Tue 2010-08-10 16:20:41 +0200
> message:
>  Some work at harmonizing output from configure scripts. Perhaps we need to revert since
>  some of the builtin tests (like in the UFC script) don't capitalize (while others do)
>  and don't nest their output (but prefix all lines with "- ").
> modified:
>  cmake/FindArmadillo.dolfin.cmake
>  cmake/FindCGAL.dolfin.cmake
>  cmake/FindMTL4.dolfin.cmake
>  cmake/FindUMFPACK.dolfin.cmake
>
>
> --
> lp:dolfin
> https://code.launchpad.net/~dolfin-core/dolfin/main
>
> Your team DOLFIN Core Team is subscribed to branch lp:dolfin.
> To unsubscribe from this branch go to https://code.launchpad.net/~dolfin-core/dolfin/main/+edit-subscription
>
> === modified file 'cmake/FindArmadillo.dolfin.cmake'
> --- cmake/FindArmadillo.dolfin.cmake    2010-08-10 11:32:46 +0000
> +++ cmake/FindArmadillo.dolfin.cmake    2010-08-10 14:20:41 +0000
> @@ -10,7 +10,7 @@
>  # ARMADILLO_DIR - directory in which Armadillo resides
>
>  if(NOT ARMADILLO_FOUND)
> -  message(STATUS "checking for package 'Armadillo'")
> +  message(STATUS "Checking for package 'Armadillo'")
>
>   find_path(ARMADILLO_INCLUDE_DIR
>     NAMES armadillo
> @@ -20,7 +20,7 @@
>     DOC "Directory where the Armadillo header file is located"
>     )
>   mark_as_advanced(ARMADILLO_INCLUDE_DIR)
> -
> +
>   find_library(ARMADILLO_LIBRARY
>     NAMES armadillo
>     HINTS $ENV{ARMADILLO_DIR}
> @@ -32,7 +32,7 @@
>
>   if(ARMADILLO_INCLUDE_DIR AND ARMADILLO_LIBRARY)
>     include(CheckCXXSourceRuns)
> -
> +
>     # These are needed for the try_run and check_cxx_source_runs commands below
>     set(CMAKE_REQUIRED_INCLUDES ${ARMADILLO_INCLUDE_DIR})
>     set(CMAKE_REQUIRED_LIBRARIES ${ARMADILLO_LIBRARY})
> @@ -52,7 +52,7 @@
>  }
>  "
>       )
> -
> +
>     try_run(
>       ARMADILLO_CONFIG_TEST_VERSION_EXITCODE
>       ARMADILLO_CONFIG_TEST_VERSION_COMPILED
> @@ -60,35 +60,35 @@
>       ${ARMADILLO_CONFIG_TEST_VERSION_CPP}
>       RUN_OUTPUT_VARIABLE OUTPUT
>       )
> -
> +
>     if(ARMADILLO_CONFIG_TEST_VERSION_EXITCODE EQUAL 0)
>       set(ARMADILLO_VERSION ${OUTPUT} CACHE TYPE STRING)
>     endif(ARMADILLO_CONFIG_TEST_VERSION_EXITCODE EQUAL 0)
> -
> +
>     check_cxx_source_runs("
>  #include <armadillo>
> -
> +
>  int main()
>  {
>  arma::mat A = arma::rand(4, 4);
>  arma::vec b = arma::rand(4);
>  arma::vec x = arma::solve(A, b);
> -
> +
>  return 0;
>  }
>  "
>       ARMADILLO_TEST_RUNS)
> -
> +
>     if(NOT ARMADILLO_TEST_RUNS)
> -      message(FATAL_ERROR "Unable to compile and run Armadillo test program.")
> +      message("   Unable to compile and run Armadillo test program.")

Since Armadillo is a required dependency I think that an error should
be given when it cant be found.

Johannes

>     endif(NOT ARMADILLO_TEST_RUNS)
> -
> +
>     set(ARMADILLO_FOUND 1 CACHE TYPE BOOL)
>   endif(ARMADILLO_INCLUDE_DIR AND ARMADILLO_LIBRARY)
> -
> +
>   if(ARMADILLO_FOUND)
> -    message(STATUS "  found Armadillo, version ${ARMADILLO_VERSION}")
> +    message(STATUS "   Found package Armadillo, version ${ARMADILLO_VERSION}")
>   else(ARMADILLO_FOUND)
> -    message(STATUS "  package 'Armadillo' not found")
> +    message("   Unable to configure package 'Armadillo'")
>   endif(ARMADILLO_FOUND)
>  endif(NOT ARMADILLO_FOUND)
>
> === modified file 'cmake/FindCGAL.dolfin.cmake'
> --- cmake/FindCGAL.dolfin.cmake 2010-08-10 11:37:46 +0000
> +++ cmake/FindCGAL.dolfin.cmake 2010-08-10 14:20:41 +0000
> @@ -1,6 +1,6 @@
>  set(DOLFIN_CGAL_FOUND 0)
>
> -message(STATUS "checking for package 'CGAL'")
> +message(STATUS "Checking for package 'CGAL'")
>
>  find_path(DOLFIN_CGAL_INCLUDE_DIR CGAL
>   /usr/include
> @@ -19,6 +19,7 @@
>   )
>  mark_as_advanced(DOLFIN_MPFR_LIBRARY)
>
> +# FIXME: Why is GMP in this file???
>  find_library(DOLFIN_GMP_LIBRARY gmp
>   DOC "The GMP library"
>   )
> @@ -29,7 +30,7 @@
>  endif(DOLFIN_CGAL_INCLUDE_DIR AND DOLFIN_CGAL_LIBRARY AND DOLFIN_MPFR_LIBRARY AND DOLFIN_GMP_LIBRARY)
>
>  if(DOLFIN_CGAL_FOUND)
> -  message("   found package 'CGAL', version ${CGAL_VERSION}")
> +  message("   Found package 'CGAL', version ${CGAL_VERSION}")
>  else(DOLFIN_CGAL_FOUND)
> -  message("   unable to configure package 'CGAL'")
> +  message("   Unable to configure package 'CGAL'")
>  endif(DOLFIN_CGAL_FOUND)
>
> === modified file 'cmake/FindMTL4.dolfin.cmake'
> --- cmake/FindMTL4.dolfin.cmake 2010-08-10 11:37:46 +0000
> +++ cmake/FindMTL4.dolfin.cmake 2010-08-10 14:20:41 +0000
> @@ -1,6 +1,6 @@
>  set(MTL4_FOUND 0)
>
> -message(STATUS "checking for package 'MTL4'")
> +message(STATUS "Checking for package 'MTL4'")
>
>  # Check for header file
>  find_path(MTL4_INCLUDE_DIR boost/numeric/mtl/mtl.hpp
> @@ -12,9 +12,12 @@
>
>  # Try compiling and running test program
>  if(MTL4_INCLUDE_DIR)
> -  message("   found package 'MTL4'")
> +
> +  # Set flags for building test program
> +  set(CMAKE_REQUIRED_INCLUDES ${MTL4_INCLUDE_DIR})
> +
> +  # Build and run test program
>   include(CheckCXXSourceRuns)
> -  set(CMAKE_REQUIRED_INCLUDES ${MTL4_INCLUDE_DIR})
>   check_cxx_source_runs("
>  #include <iostream>
>  #include <boost/numeric/mtl/mtl.hpp>
> @@ -27,18 +30,18 @@
>  " MTL4_TEST_RUNS)
>
>   if(NOT MTL4_TEST_RUNS)
> -    message("   unable to run test program for package 'MTL4'")
> +    message("   Unable to run test program for package 'MTL4'")
>   endif(NOT MTL4_TEST_RUNS)
>
>  endif(MTL4_INCLUDE_DIR)
>
> -# Report results of tests
> +# Report results of test
>  if(MTL4_TEST_RUNS)
> -  message("   found package 'MTL4'")
> +  message("   Found package 'MTL4'")
>   set(MTL4_FOUND 1)
>   include_directories(${MTL4_INCLUDE_DIR})
>   add_definitions(-DHAS_MTL4)
>  else(MTL4_TEST_RUNS)
> -  message("   unable to configure package 'MTL4'")
> +  message("   Unable to configure package 'MTL4'")
>  endif(MTL4_TEST_RUNS)
>
>
> === modified file 'cmake/FindUMFPACK.dolfin.cmake'
> --- cmake/FindUMFPACK.dolfin.cmake      2010-08-10 14:10:00 +0000
> +++ cmake/FindUMFPACK.dolfin.cmake      2010-08-10 14:20:41 +0000
> @@ -1,6 +1,6 @@
>  set(UMFPACK_FOUND 0)
>
> -message(STATUS "checking for package 'UMFPACK'")
> +message(STATUS "Checking for package 'UMFPACK'")
>
>  # Check for header file
>  find_path(UMFPACK_INCLUDE_DIR umfpack.h
> @@ -59,17 +59,17 @@
>  " UMFPACK_TEST_RUNS)
>
>   if(NOT UMFPACK_TEST_RUNS)
> -    message("   unable to run test program for package 'UMFPACK'")
> +    message("   Unable to run test program for package 'UMFPACK'")
>   endif(NOT UMFPACK_TEST_RUNS)
>
>  endif(UMFPACK_INCLUDE_DIR AND UMFPACK_LIBRARY)
>
>  # Report results of tests
>  if(UMFPACK_TEST_RUNS)
> -  message("   found package 'UMFPACK'")
> +  message("   Found package 'UMFPACK'")
>   set(UMFPACK_FOUND 1)
>   include_directories(${UMFPACK_INCLUDE_DIR})
>   add_definitions(-DHAS_UMFPACK)
>  else(UMFPACK_TEST_RUNS)
> -  message("   unable to configure package 'UMFPACK'")
> +  message("   Unable to configure package 'UMFPACK'")
>  endif(UMFPACK_TEST_RUNS)
>
>
>



Follow ups