To build this project on macOS, follow the steps below.
-
Install Xcode
Xcode is required for compiling code on macOS. -
Install Homebrew
Homebrew is a package manager for macOS that simplifies the installation of software.ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" brew doctor
-
Install Micromamba
Micromamba is used to manage environments for this project. Follow the Micromamba installation guide for detailed instructions on macOS.Alternatively, install it with Homebrew:
brew install micromamba
-
Navigate to the root directory of the project:
cd /path/to/nelson/
-
Create and activate the environment:
micromamba env create -f environment-macos-dev.yml micromamba activate nelson
-
Create a build directory and run CMake with the following options:
mkdir -p build cd build cmake .. \ -DCMAKE_BUILD_TYPE=Release \ -DFORCE_LIBGFORTRAN_LINK=ON \ -DWITHOUT_SLICOT_MODULE=ON \ -DCMAKE_PREFIX_PATH=$CONDA_PREFIX \ -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX \ -DCMAKE_INSTALL_LIBDIR=lib
-
Build the project:
cmake --build . cmake --build . --target buildhelp cmake --build . --target install
-
Run the application:
nelson
- See ccpp.yml for an up-to-date list of dependencies and build instructions across platforms.
- Refer to Building with Linux for further information on compilation options.