-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathauto-build.sh
More file actions
executable file
·43 lines (33 loc) · 1.25 KB
/
auto-build.sh
File metadata and controls
executable file
·43 lines (33 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
set -e
export BUILD_ROOT="/media/ankit/133f8f70-3409-4fdf-9112-2ef66d30e298/mlfs-build"
export MLFS_TARGET="x86_64-mlfs-linux-musl"
export MLFS_ARCH="x86_64"
export PATH="/tools/bin:/cross-tools/bin:$PATH"
cd "$BUILD_ROOT"
# Download remaining sources
echo "Downloading sources..."
cd sources && wget -i sources.list -P packages/ --continue -q &
WGET_PID=$!
# Start cross-tools build
echo "Starting cross-tools build..."
cd /home/ankit/Documents/Code/LinuxFork/Musl-LFS
sudo mkdir -p /cross-tools /tools
sudo chown -R $USER:$USER /cross-tools /tools
# Build cross-tools
./build-scripts/build-cross-tools.sh 2>&1 | tee "$BUILD_ROOT/cross-tools-build.log" &
BUILD_PID=$!
# Monitor and commit progress
while kill -0 $BUILD_PID 2>/dev/null; do
sleep 300
git add -A && git commit -m "Build progress: $(date)" --author="MilkywayRides <milkywayrides@github.com>" || true
git push origin main || true
done
wait $BUILD_PID
echo "Cross-tools build completed"
# Build tools
echo "Starting tools build..."
./build-scripts/build-toolchain.sh 2>&1 | tee "$BUILD_ROOT/tools-build.log"
git add -A && git commit -m "MLFS build completed successfully" --author="MilkywayRides <milkywayrides@github.com>"
git push origin main
echo "Build completed successfully!"