From 8190601aee6fc8af178e4b0400c5a2c75f917bf6 Mon Sep 17 00:00:00 2001 From: maier Date: Fri, 21 Sep 2012 14:08:33 +0000 Subject: [PATCH] Bugfix git-svn-id: https://svn.dealii.org/branches/branch_cmake@26595 0785d39b-7218-0410-832d-ea1e28bc413d --- deal.II/CMakeLists.txt | 17 +++++++-- .../macros/macro_expand_instantiations.cmake | 2 +- deal.II/cmake/setup_custom_targets.cmake | 36 +++++++++++++++++++ 3 files changed, 51 insertions(+), 4 deletions(-) create mode 100644 deal.II/cmake/setup_custom_targets.cmake diff --git a/deal.II/CMakeLists.txt b/deal.II/CMakeLists.txt index e6c7e6c1e8..b8f0645427 100644 --- a/deal.II/CMakeLists.txt +++ b/deal.II/CMakeLists.txt @@ -91,11 +91,16 @@ SET(VERSION "8.0.pre") # $ cmake -DCMAKE_CXX_FLAGS="-Wno-sign-compare" <...> # # -# Build optoins: TODO +# Build options: # -# - BUILD_SHARED_LIBS and DEAL_II_SETUP_DEFAULT_COMPILER_FLAGS +# - BUILD_SHARED_LIBS and +# - DEAL_II_SETUP_DEFAULT_COMPILER_FLAGS # -# Installation: TODO +# Installation: +# +# - DEAL_II_INSTALL_EXAMPLES +# - DEAL_II_INSTALL_COMPAT_FILES +# - DEAL_II_INSTALL_PROJECT_CONFIG # # - Explain Components and Options... # - Explain how to build and install only a specific component: @@ -233,6 +238,8 @@ OPTION(DEAL_II_INSTALL_PROJECT_CONFIG ON) + + ########################################################################### # # # Configuration: # @@ -397,3 +404,7 @@ ADD_SUBDIRECTORY(config) ADD_SUBDIRECTORY(doc) ADD_SUBDIRECTORY(examples) +# +# Define some convencience custom targets for easy use: +# +INCLUDE(setup_custom_targets) diff --git a/deal.II/cmake/macros/macro_expand_instantiations.cmake b/deal.II/cmake/macros/macro_expand_instantiations.cmake index d4084e5cb9..cb2f60e11e 100644 --- a/deal.II/cmake/macros/macro_expand_instantiations.cmake +++ b/deal.II/cmake/macros/macro_expand_instantiations.cmake @@ -25,7 +25,7 @@ MACRO(macro_expand_instantiations target inst_in_files) DEPENDS expand_instantiations ${CMAKE_CURRENT_SOURCE_DIR}/${inst_in_file} COMMAND expand_instantiations - ARGS ${CMAKE_BINARY_DIR}/contrib/config/template-arguments + ARGS ${CMAKE_BINARY_DIR}/config/template-arguments < ${CMAKE_CURRENT_SOURCE_DIR}/${inst_in_file} > ${CMAKE_CURRENT_BINARY_DIR}/${inst_file} ) diff --git a/deal.II/cmake/setup_custom_targets.cmake b/deal.II/cmake/setup_custom_targets.cmake new file mode 100644 index 0000000000..30fcba93e4 --- /dev/null +++ b/deal.II/cmake/setup_custom_targets.cmake @@ -0,0 +1,36 @@ + +# +# Setup some convenience custom targets for the build system: +# + +# +# Custom targets for building all targets necessary to install a specific +# component. (Too bad, we have to do this by hand. There is no cmake +# internal way to do this, yet...) +# + +ADD_CUSTOM_TARGET(library) +ADD_DEPENDENCIES(library deal_II) + + +IF(DEAL_II_WITH_DOXYGEN) + + ADD_CUSTOM_TARGET(documentation) + ADD_DEPENDENCIES(documentation doxygen) + +ENDIF() + + +IF(DEAL_II_INSTALL_COMPAT_FILES) + + ADD_CUSTOM_TARGET(compat_files) + +ENDIF() + + +IF(DEAL_II_INSTALL_PROJECT_CONFIG) + + ADD_CUSTOM_TARGET(project_config) + +ENDIF() + -- 2.39.5