|
BashSpark
|
The CMake file defines the following targets:
doc: Generates documentation.deb: Generate .deb file of the library.rpm: Generate .rpm file of the library (currently unavailable).headers: Generates a zip file containing the library headers.abashspark: Generates a static library.fbashspark: Generates a static library with position-independent code.sbashspark: Generates a dynamic library.tbashspark: Generates the test executable.Exposed targets include:
BashSpark::ABashSpark: static library.BashSpark::FBashSpark: static library with position-independent code.BashSpark::SBashSpark: dynamic library.BashSpark::BashSpark: default dynamic library.BASH_SPARK_HEADER_DIR with the include path.The installation process consists of the following steps:
Set the project directory with:
Then configure CMake:
On POSIX systems, the library headers are stored at /usr/include. Execute the following commands:
Windows users: Extract the file ${BASH_SPARK}/build/BashSpark.tar.gz in the appropriate location.
Choose a library version to build:
abashspark: Static library.fbashspark: Static library with position-independent code.sbashspark: Dynamic library.Execute the appropriate command:
On POSIX systems, copy the library to /usr/lib:
Then move the libraries:
After these steps, the BashSpark library will be properly integrated into your system.
If the command debuild is missing, install the necessary tools with:
Use the following commands based on your Linux distribution to install CMake:
| Linux Distribution | Command |
|---|---|
| Debian-based | sudo apt install -y cmake |
| Red Hat-based | sudo yum install -y cmake |
| Fedora | sudo dnf install -y cmake |
| Arch Linux | sudo pacman -S --noconfirm cmake |
| Windows | Download CMake |
| MAC OS X | brew install cmake |