Skip to content
Snippets Groups Projects

WIP: new cmake build system

Closed Simon Praetorius requested to merge feature/new_build_system into master
Compare and
51 files
+ 857
828
Compare changes
  • Side-by-side
  • Inline
Files
51
+ 6
6
@@ -336,6 +336,8 @@ NAME=`echo $PROJECT | sed -e 's/dune[_-]//'`
NAME_=`echo $NAME | tr '-' '_'`
# module name in uppercase with _ instead of -
UNAME=`echo $PROJECT | tr '-' '_' | sed 's/\(.*\)/\U\1/'`
# $PROJECT with all non-alphanumeric characters removed
LIBNAME=`echo $NAME | sed 's/[^a-zA-Z0-9]//'`
################## README ##################
echo "- $PROJECT/README"
@@ -373,9 +375,9 @@ An example options file might look like this:
#use this options to configure and make if no other options are given
CMAKE_FLAGS=" \\
-DCMAKE_CXX_COMPILER=g++-5 \\
-DCMAKE_CXX_COMPILER=g++-7 \\
-DCMAKE_CXX_FLAGS='-Wall -pedantic' \\
-DCMAKE_INSTALL_PREFIX=/install/path" #Force g++-5 and set compiler flags
-DCMAKE_INSTALL_PREFIX=/install/path" #Force g++-7 and set compiler flags
If you save this information into example.opts you can pass the opts file to
dunecontrol via the --opts option, e. g.
@@ -416,9 +418,7 @@ list(APPEND CMAKE_MODULE_PATH "\${PROJECT_SOURCE_DIR}/cmake/modules"
include(DuneMacros)
# start a dune project with information from dune.module
dune_project()
dune_enable_all_packages()
dune_project($LIBNAME)
add_subdirectory(src)
add_subdirectory(dune)
@@ -648,7 +648,7 @@ CC_DELIM
echo "- $PROJECT/doc/doxygen/CMakeLists.txt"
cat> "$PROJECT/doc/doxygen/CMakeLists.txt" << CC_DELIM
# shortcut for creating the Doxyfile.in and Doxyfile
add_doxygen_target()
dune_add_doxygen_target()
CC_DELIM
#########################################################
Loading