"Fossies" - the Fresh Open Source Software Archive

Member "dune-grid-howto-2.7.0/CMakeLists.txt" (20 Dec 2019, 2845 Bytes) of package /linux/misc/dune/dune-grid-howto-2.7.0.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the latest Fossies "Diffs" side-by-side code changes report for "CMakeLists.txt": 2.6.0_vs_2.7.0.

    1 # set up project
    2 project(dune-grid-howto C CXX)
    3 
    4 # general stuff
    5 cmake_minimum_required(VERSION 3.1)
    6 
    7 if(NOT (dune-common_DIR OR dune-common_ROOT OR
    8         "${CMAKE_PREFIX_PATH}" MATCHES ".*dune-common.*"))
    9     string(REPLACE  ${CMAKE_PROJECT_NAME} dune-common dune-common_DIR
   10       ${PROJECT_BINARY_DIR})
   11 endif()
   12 
   13 #find dune-common and set the module path
   14 find_package(dune-common REQUIRED)
   15 list(APPEND CMAKE_MODULE_PATH ${dune-common_MODULE_PATH})
   16 
   17 option(DUNE_GRID_GRIDTYPE_SELECTOR "" ON)
   18 
   19 #include the dune macros
   20 include(DuneMacros)
   21 
   22 # start a dune project with information from dune.module
   23 dune_project()
   24 
   25 # The directory where the example grid files used for the examples are located
   26 set_property(DIRECTORY APPEND PROPERTY
   27   COMPILE_DEFINITIONS "DUNE_GRID_HOWTO_EXAMPLE_GRIDS_PATH=\"${PROJECT_SOURCE_DIR}/grids/\"")
   28 
   29 # force that all tests are built
   30 set(DUNE_BUILD_TESTS_ON_MAKE_ALL TRUE)
   31 
   32 # enable the flags for all third party features found
   33 dune_enable_all_packages()
   34 
   35 dune_add_test(SOURCES adaptivefinitevolume.cc
   36   COMPILE_DEFINITIONS "GRIDDIM=2" "WORLDDIM=2" "YASPGRID")
   37 add_dune_alberta_flags(adaptivefinitevolume WORLDDIM 2)
   38 
   39 dune_add_test(SOURCES adaptiveintegration.cc
   40   COMPILE_DEFINITIONS "GRIDDIM=2" "WORLDDIM=2" "YASPGRID")
   41 
   42 dune_add_test(SOURCES finiteelements.cc)
   43 add_dune_alberta_flags(finiteelements WORLDDIM 2)
   44 
   45 dune_add_test(SOURCES finitevolume.cc
   46   COMPILE_DEFINITIONS "GRIDDIM=2" "WORLDDIM=2" "YASPGRID")
   47 
   48 dune_add_test(SOURCES integration.cc
   49   COMPILE_DEFINITIONS "GRIDDIM=2" "WORLDDIM=2" "YASPGRID")
   50 
   51 dune_add_test(SOURCES gettingstarted.cc)
   52 
   53 dune_add_test(SOURCES othergrids.cc)
   54 add_dune_ug_flags(othergrids)
   55 
   56 dune_add_test(SOURCES parfinitevolume.cc)
   57 
   58 dune_add_test(SOURCES traversal.cc)
   59 
   60 dune_add_test(SOURCES visualization.cc
   61   COMPILE_DEFINITIONS "GRIDDIM=2" "WORLDDIM=2" "YASPGRID")
   62 
   63 add_subdirectory(doc)
   64 add_subdirectory(grids)
   65 
   66 # install headers, cc files and executables
   67 install(FILES
   68   basicunitcube.hh
   69   elementdata.hh
   70   evolve.hh
   71   finitevolumeadapt.hh transportproblem.hh
   72   functors.hh unitcube_albertagrid.hh
   73   initialize.hh
   74   integrateentity.hh
   75   parfvdatahandle.hh
   76   parevolve.hh
   77   shapefunctions.hh
   78   transportproblem2.hh
   79   unitcube.hh
   80   unitcube_alugrid.hh
   81   unitcube_yaspgrid.hh
   82   vertexdata.hh
   83   vtkout.hh
   84   adaptivefinitevolume.cc
   85   adaptiveintegration.cc
   86   gettingstarted.cc
   87   integration.cc
   88   othergrids.cc
   89   finiteelements.cc
   90   finitevolume.cc
   91   parfinitevolume.cc
   92   traversal.cc
   93   visualization.cc
   94   DESTINATION ${CMAKE_INSTALL_DOCDIR}/examples)
   95 
   96 install(TARGETS
   97   adaptivefinitevolume
   98   adaptiveintegration
   99   gettingstarted
  100   integration
  101   othergrids
  102   finiteelements
  103   finitevolume
  104   parfinitevolume
  105   traversal
  106   visualization
  107   DESTINATION ${CMAKE_INSTALL_DOCDIR}/examples)
  108 
  109 # finalize the dune project, e.g. generating config.h etc.
  110 finalize_dune_project(GENERATE_CONFIG_H_CMAKE)