mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Add build scripts for incremental and clean builds
- build.sh: incremental build with auto Data symlink creation - rebuild.sh: clean rebuild (rm -rf build) for troubleshooting Both scripts use all available CPU cores and ensure Data symlink exists in bin directory for runtime asset access.
This commit is contained in:
parent
a764eea2ec
commit
bf03044a63
2 changed files with 70 additions and 0 deletions
31
build.sh
Executable file
31
build.sh
Executable file
|
|
@ -0,0 +1,31 @@
|
|||
#!/bin/bash
|
||||
# Wowee Build Script - Ensures no stale binaries
|
||||
|
||||
set -e # Exit on error
|
||||
|
||||
cd "$(dirname "$0")"
|
||||
|
||||
echo "Building wowee..."
|
||||
|
||||
# Create build directory if it doesn't exist
|
||||
mkdir -p build
|
||||
cd build
|
||||
|
||||
# Configure with cmake
|
||||
echo "Configuring with CMake..."
|
||||
cmake .. -DCMAKE_BUILD_TYPE=Release
|
||||
|
||||
# Build with all cores
|
||||
echo "Building with $(nproc) cores..."
|
||||
cmake --build . --parallel $(nproc)
|
||||
|
||||
# Ensure Data symlink exists in bin directory
|
||||
cd bin
|
||||
if [ ! -e Data ]; then
|
||||
ln -s ../../Data Data
|
||||
fi
|
||||
cd ..
|
||||
|
||||
echo ""
|
||||
echo "Build complete! Binary: build/bin/wowee"
|
||||
echo "Run with: cd build/bin && ./wowee"
|
||||
Loading…
Add table
Add a link
Reference in a new issue