-
Notifications
You must be signed in to change notification settings - Fork 2
72 lines (62 loc) · 2.44 KB
/
linux-debug-build-test.yml
File metadata and controls
72 lines (62 loc) · 2.44 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: gkit-linux-build-test
on:
push:
branches-ignore: [ "main" ]
pull_request:
branches-ignore: [ "main" ]
jobs:
build-and-test:
name: Build and Test on Ubuntu-latest
runs-on: ubuntu-latest
strategy:
matrix:
preset: [ "linux-x86_64-gcc-debug", "linux-x86_64-gcc-noabi-debug",
"linux-x86_64-llvm-debug", "linux-x86_64-llvm-noabi-debug" ]
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Show build information
run: |
echo "🚀 Starting build for gkit project"
echo "Platform: ${{ runner.os }}"
echo "Workflow: ${{ github.workflow }}"
echo "Repository: ${{ github.repository }}"
echo "Commit SHA: ${{ github.sha }}"
- name: Install dependencies
run: |
echo "📦 Installing Ubuntu dependencies..."
sudo apt-get update
sudo apt-get install -y \
build-essential clang cmake ninja-build \
libasound2-dev libpulse-dev libx11-dev libxext-dev \
libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev \
libxss-dev libxtst-dev libxkbcommon-dev libdrm-dev \
libgbm-dev libgl1-mesa-dev libgles2-mesa-dev libegl1-mesa-dev \
libdbus-1-dev libibus-1.0-dev libudev-dev
echo "✅ Ubuntu dependencies installed successfully"
- name: Configure CMake
run: |
echo "⚙️ Configuring CMake for Linux..."
echo "Using preset: ${{matrix.preset}}"
cmake --preset ${{matrix.preset}}
echo "✅ CMake configuration completed"
- name: Configure and build project
run: |
echo "🔨 Building project on Linux..."
BUILD_DIR="${{ github.workspace }}/build/${{matrix.preset}}"
echo "Build directory: $BUILD_DIR"
cmake --build $BUILD_DIR
echo "✅ Linux build completed successfully"
- name: Show build results
run: |
echo "🎉 Build process completed!"
echo "Platform: Linux(Ubuntu-latest)"
echo "Job status: ${{ job.status }}"
# List built files
echo "📁 Built files:"
find ${{ github.workspace }}/build -name "*.so" -o -name "*.dll" -o -name "*.a" -o -name "*.lib" 2>/dev/null || echo "No library files found"
# Show disk usage
echo "💾 Disk usage:"
du -sh ${{ github.workspace }}/build 2>/dev/null || echo "Build directory size info not available"