Browse Source

version is now written into a seperate header file to prevent recompile of many files after a commit

Former-commit-id: a287aacefa
tempestpy_adaptions
sjunges 11 years ago
parent
commit
a528610d98
  1. 7
      CMakeLists.txt
  2. 1
      src/storm.cpp
  3. 7
      storm-config.h.in
  4. 12
      storm-version.h.in

7
CMakeLists.txt

@ -216,6 +216,13 @@ configure_file (
"${PROJECT_SOURCE_DIR}/storm-config.h.in"
"${PROJECT_BINARY_DIR}/include/storm-config.h"
)
# Configure a header file to pass the storm version to the source code
configure_file (
"${PROJECT_SOURCE_DIR}/storm-version.h.in"
"${PROJECT_BINARY_DIR}/include/storm-version.h"
)
# Add the binary dir include directory for storm-config.h
include_directories("${PROJECT_BINARY_DIR}/include")

1
src/storm.cpp

@ -21,6 +21,7 @@
#include <vector>
#include "storm-config.h"
#include "storm-version.h"
#include "src/models/Dtmc.h"
#include "src/models/MarkovAutomaton.h"
#include "src/storage/SparseMatrix.h"

7
storm-config.h.in

@ -8,13 +8,6 @@
#ifndef STORM_GENERATED_STORMCONFIG_H_
#define STORM_GENERATED_STORMCONFIG_H_
// Version Information
#define STORM_CPP_VERSION_MAJOR @STORM_CPP_VERSION_MAJOR@ // The major version of StoRM
#define STORM_CPP_VERSION_MINOR @STORM_CPP_VERSION_MINOR@ // The minor version of StoRM
#define STORM_CPP_VERSION_PATCH @STORM_CPP_VERSION_PATCH@ // The patch version of StoRM
#define STORM_CPP_VERSION_COMMITS_AHEAD @STORM_CPP_VERSION_COMMITS_AHEAD@ // How many commits passed since the tag was last set
#define STORM_CPP_VERSION_HASH "@STORM_CPP_VERSION_HASH@" // The short hash of the git commit this build is bases on
#define STORM_CPP_VERSION_DIRTY @STORM_CPP_VERSION_DIRTY@ // 0 iff there no files were modified in the checkout, 1 else
// The path of the sources from which StoRM will be/was build
#define STORM_CPP_BASE_PATH "@PROJECT_SOURCE_DIR@"

12
storm-version.h.in

@ -0,0 +1,12 @@
#ifndef STORM_GENERATED_VERSION_H_
#define STORM_GENERATED_VERSION_H_
// Version Information
#define STORM_CPP_VERSION_MAJOR @STORM_CPP_VERSION_MAJOR@ // The major version of StoRM
#define STORM_CPP_VERSION_MINOR @STORM_CPP_VERSION_MINOR@ // The minor version of StoRM
#define STORM_CPP_VERSION_PATCH @STORM_CPP_VERSION_PATCH@ // The patch version of StoRM
#define STORM_CPP_VERSION_COMMITS_AHEAD @STORM_CPP_VERSION_COMMITS_AHEAD@ // How many commits passed since the tag was last set
#define STORM_CPP_VERSION_HASH "@STORM_CPP_VERSION_HASH@" // The short hash of the git commit this build is bases on
#define STORM_CPP_VERSION_DIRTY @STORM_CPP_VERSION_DIRTY@ // 0 iff there no files were modified in the checkout, 1 else
#endif
Loading…
Cancel
Save