C and Python interface for the OpenSMOKE++ library
The library relies on the following external dependencies:
OpenSMOKE++ and Eigen are headers-only, while the others must be compiled or installed using your preferred package manager.
To speed up mathematical operations, one of the following libraries must also be installed:
Create the following environment variables to store the paths to the OpenSMOKE++ library and the OpenSMOKEppInterface repository. For example:
export OPENSMOKE_LATEST=${HOME}/OpenSMOKE/OpenSMOKEppMinimal4Basilisk/source
export OPENSMOKE_INTERFACE=${HOME}/OpenSMOKE/OpenSMOKEppInterface
If you use this repository with Basilisk and with My Basilisk Sandbox I suggest you the following directories structure:
├── OpenSMOKE
│ ├── OpenSMOKEppMinimal4Basilisk
│ └── OpenSMOKEppInterface
└── basilisk
├── basilisk
│ ├── _darcs
│ └── src
└── basilisk-sandbox-ecipriano
├── README.md
├── dev
├── doc
├── run
├── src
└── test
The default installation tool for this library is CMake, which attempts to automatically find the dependency libraries if they are installed in standard locations. Assuming you are using OpenBLAS, compile the project with the following commands:
mkdir build
cd build
cmake -DOPENSMOKE_USE_OPENBLAS=1 ..
make
If any errors occur during compilation, make sure that CMake is detecting the correct paths. Below is an example of the CMake output
...
-- Found Boost: /opt/homebrew/lib/cmake/Boost-1.85.0/BoostConfig.cmake (found version "1.85.0") found components: date_time filesystem program_options system regex timer chrono
-- Boost_INCLUDE_DIRS = /opt/homebrew/include
-- Boost_LIBRARIES = Boost::date_time;Boost::filesystem;Boost::program_options;Boost::system;Boost::regex;Boost::timer;Boost::chrono
-- Found Eigen3: /opt/homebrew/include/eigen3 (Required is at least version "2.91.0")
-- Eigen_LIBRARIES = /opt/homebrew/include/eigen3
-- OpenSmoke++ = /Users/ecipriano/OpenSMOKE/OpenSMOKEppMinimal4Basilisk/source
-- CONFIG++_INCLUDE_DIR = /Users/ecipriano/Local/libconfig/build/include
-- CONFIG++_LIBRARY = /Users/ecipriano/Local/libconfig/build/lib/libconfig++.dylib
-- OpenBLAS_INCLUDE_DIRS = /opt/homebrew/Cellar/openblas/0.3.27/include
-- BLAS_LIBRARIES = /opt/homebrew/Cellar/openblas/0.3.27/lib/libopenblas.dylib
...
If a library is not found automatically by CMake (e.g., if it was installed in a non-standard location), you can manually specify the path in the cmake command. For example, to specify the OpenBLAS library path:
cmake -DOPENSMOKE_USE_OPENBLAS=1 -DOpenBLAS_ROOT=/opt/homebrew/Cellar/openblas/0.3.27 ..
After compilation, you can test that everything is correctly installed by running a small suite of tests:
ctest