Files
SubWave/build.sh
T
rattatwinko 1a00e98661 rather large commit, it now handles memory and threading properly.
---

more thorough commit message which was generated by the wonderful copilot AI tool:

Refactor and enhance audio encoding and decoding pipelines

- Introduced CodecUtils.h for utility functions related to audio codec selection, including sample format and bitrate clamping.
- Added DecoderPipeline.h to manage audio decoding, including opening files and retrieving audio stream information.
- Implemented EncoderPipeline.h to handle audio encoding, including encoder setup, resampling, and writing output files.
- Created OutputPathBuilder.h to generate output file paths based on reencode job specifications.
- Refactored SpectrogramWidget to improve OpenGL handling and ensure safe context usage.
- Updated ReencodeDialog.h to enhance code readability and maintainability.
- Improved error handling and logging throughout the audio processing components.
2026-07-01 09:56:37 +02:00

76 lines
1.3 KiB
Bash
Executable File

#!/usr/bin/env bash
set -e
clean() {
echo "cleaning build dir"
rm -rf build
}
incremental_build() {
mkdir -p ../build
cd build
cmake ..
make -j"$(nproc)"
}
clean_build() {
clean
mkdir build
cd build
echo "doing a clean build"
cmake ..
make -j"$(nproc)"
}
release_build() {
if [ -d "build" ]; then
rm -rf "build"
echo "removing build directory"
fi
mkdir "build"
cd build
echo "starting cmake and make processes"
cmake -DCMAKE_BUILD_TYPE=Release ..
make -j"$(nproc)"
}
run_executable() {
./build/SubWave
}
clean_appimage() {
if [ -e "SubWave-x86_64.AppImage" ]; then
rm -rf SubWave-x86_64.AppImage
echo "Removed AppImage"
fi
echo "No AppImage found, aborting"
}
case "${1:-build}" in
clean|c)
clean
;;
build|incremental|ib)
incremental_build
;;
cleanbuild|cb)
clean_build
;;
run|exec|r)
run_executable
;;
release|rb)
release_build
;;
cai|clean_appimage|cleanimg)
clean_appimage
;;
cbr|clean_build_run)
clean_build && run_executable
;;
*)
echo "Usage: $0 {build|clean|cleanbuild|cb}"
exit 1
;;
esac