consolidate linux install script
This commit is contained in:
@@ -8,6 +8,26 @@ RTAUDIO_ROOT=${LIB_ROOT}/rtaudio
|
||||
RTMIDI_ROOT=${LIB_ROOT}/rtmidi
|
||||
YAMLCPP_ROOT=${LIB_ROOT}/yaml-cpp
|
||||
|
||||
# detect dependencies
|
||||
libraries=("rtaudio" "rtmidi" "yaml-cpp")
|
||||
dependencies_found=0
|
||||
|
||||
for lib in "${libraries[@]}"; do
|
||||
if [[ -e "./build/lib/$lib" ]]; then
|
||||
echo "found $lib"
|
||||
((dependencies_found++))
|
||||
else
|
||||
echo "did not find $lib"
|
||||
fi
|
||||
done
|
||||
|
||||
# run the install script if dependencies not found
|
||||
if [[ "$dependencies_found" -ne "${#libraries[@]}" ]]; then
|
||||
./scripts/install_dependencies.sh
|
||||
else
|
||||
echo "All dependencies detected, skipping dependency install step..."
|
||||
fi
|
||||
|
||||
cmake -S . -B ${BUILD_DIR} -G Ninja \
|
||||
-DRtAudio_DIR="${RTAUDIO_ROOT}/share/rtaudio" \
|
||||
-DRtMidi_DIR="${RTMIDI_ROOT}/share/rtmidi" \
|
||||
|
||||
Reference in New Issue
Block a user