-
Notifications
You must be signed in to change notification settings - Fork 6
58 lines (50 loc) · 1.8 KB
/
build-linux.yml
File metadata and controls
58 lines (50 loc) · 1.8 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
name: Reusable Linux & Debian Build
on:
workflow_call:
inputs:
prepared_source_artifact_name:
description: 'The name of the prepared source code artifact to download'
required: true
type: string
lin_filename:
description: 'The final, desired filename for the .tar.gz package'
required: true
type: string
deb_filename:
description: 'The final, desired filename for the .deb package'
required: true
type: string
jobs:
build_lin:
runs-on: ubuntu-latest
steps:
- name: Download prepared source code
uses: actions/download-artifact@v4
with:
name: ${{ inputs.prepared_source_artifact_name }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install System & Python Dependencies
run: |
sudo apt-get update
sudo apt-get install -y make build-essential fakeroot devscripts dh-python python3-all debhelper-compat=13
python -m pip install pyinstaller Pillow numpy scipy platformdirs tqdm
- name: Build Linux binary and Debian package using Makefile
run: make all deb LIN_TGZ=${{ inputs.lin_filename }}
- name: Find and rename Debian package
shell: bash
run: |
DEB_FILE=$(find .. -maxdepth 1 -name "*.deb")
mv "$DEB_FILE" "dist/${{ inputs.deb_filename }}"
- name: Upload Linux tar.gz artifact
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.lin_filename }}
path: dist/${{ inputs.lin_filename }}
- name: Upload Debian package artifact
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.deb_filename }}
path: dist/${{ inputs.deb_filename }}