forked from HeidiSQL/HeidiSQL
-
Notifications
You must be signed in to change notification settings - Fork 0
183 lines (148 loc) · 5.73 KB
/
lazarus.yaml
File metadata and controls
183 lines (148 loc) · 5.73 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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
name: Lazarus
defaults:
run:
shell: bash
permissions:
contents: write
on:
push:
branches: [ lazarus ]
tags: [ "*" ]
paths-ignore: [ "README.md", "LICENSE", "CHANGELOG.md", ".github/cliff.toml" ]
pull_request:
branches: [ lazarus ]
jobs:
build:
runs-on: ${{ matrix.operating-system }}
env:
GITHUB: 1
strategy:
fail-fast: false
matrix:
operating-system: [ubuntu-latest, macos-latest]
lazarus-versions: ["stable"]
steps:
- name: Checkout source code
uses: actions/checkout@v4
- name: Install Lazarus
uses: D3SOX/setup-lazarus@support-new-versions
with:
lazarus-version: ${{ matrix.lazarus-versions }}
with-cache: false
- name: Build HeidiSQL (Ubuntu GTK)
if: ${{ matrix.operating-system == 'ubuntu-latest' }}
run: |
echo Building with GTK2
make build-gtk2
- name: Upload binaries GTK
if: ${{ matrix.operating-system == 'ubuntu-latest' && matrix.lazarus-versions == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.operating-system }}-GTK
path: out/gtk2/heidisql
- name: Getting libqt5pas-dev, libqt6pas-dev
if: ${{ matrix.operating-system == 'ubuntu-latest' }}
run: |
sudo apt update
sudo apt install -y libqt5pas-dev wget qt6-base-dev
LIBQT6PAS_VERSION="6.2.10"
wget -q "https://github.com/davidbannon/libqt6pas/releases/download/v${LIBQT6PAS_VERSION}/libqt6pas6_${LIBQT6PAS_VERSION}-1_amd64.deb" -O /tmp/libqt6pas6.deb
sudo dpkg -i /tmp/libqt6pas6.deb || sudo apt-get install -f -y
wget -q "https://github.com/davidbannon/libqt6pas/releases/download/v${LIBQT6PAS_VERSION}/libqt6pas6-dev_${LIBQT6PAS_VERSION}-1_amd64.deb" -O /tmp/libqt6pas6-dev.deb
sudo dpkg -i /tmp/libqt6pas6-dev.deb || sudo apt-get install -f -y
rm -f /tmp/libqt6pas6.deb /tmp/libqt6pas6-dev.deb
- name: Build HeidiSQL (Ubuntu QT5)
if: ${{ matrix.operating-system == 'ubuntu-latest' }}
run: |
echo Building with QT5
make build-qt5
- name: Upload binaries QT5
if: ${{ matrix.operating-system == 'ubuntu-latest' && matrix.lazarus-versions == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.operating-system }}-QT5
path: out/qt5/heidisql
- name: Build HeidiSQL (Ubuntu QT6)
if: ${{ matrix.operating-system == 'ubuntu-latest' }}
run: |
echo Building with QT6
make build-qt6
- name: Upload binaries QT6
if: ${{ matrix.operating-system == 'ubuntu-latest' && matrix.lazarus-versions == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.operating-system }}-QT6
path: out/qt6/heidisql
- name: Build HeidiSQL (macOS)
if: ${{ matrix.operating-system == 'macos-latest' }}
run: |
echo Building for macOS
lazbuild -B --bm=Release heidisql.lpi
mkdir -p ./out/macos
mv -v ./out/heidisql ./out/macos/heidisql
- name: Upload binaries macOS
if: ${{ matrix.operating-system == 'macos-latest' && matrix.lazarus-versions == 'stable' }}
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.operating-system }}
path: out/macos/heidisql
release:
if: contains(github.ref_type, 'tag')
env:
GITHUB: 1
name: Create GitHub Release
runs-on: [ubuntu-latest]
needs: [build]
steps:
- name: Checkout source code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set env
run: echo "tag=${{ github.ref_name }}" >> "$GITHUB_ENV"
- name: Download Ubuntu GTK
uses: actions/download-artifact@v4
with:
name: ubuntu-latest-GTK
path: out/gtk2
- name: Download Ubuntu QT5
uses: actions/download-artifact@v4
with:
name: ubuntu-latest-QT5
path: out/qt5
- name: Download Ubuntu QT6
uses: actions/download-artifact@v4
with:
name: ubuntu-latest-QT6
path: out/qt6
- name: List files
run: |
ls -alF out/gtk2
ls -alF out/qt5
ls -alF out/qt6
- name: Install gettext
run: sudo apt install -y gettext
- name: Install FPM
run: sudo gem install --no-document fpm
- name: Create release archives (Linux GTK)
run: make tar-gtk2
- name: Create debian package
run: make deb-package
- name: Create release archives (Linux QT5)
run: make tar-qt5
- name: Create release archives (Linux QT6)
run: make tar-qt6
- name: Generate Release Notes
id: git-cliff
uses: orhun/git-cliff-action@v4
with:
config: .github/cliff.toml
args: --latest --strip header
- name: Create GitHub release
uses: softprops/action-gh-release@v2
with:
name: HeidiSQL Linux ${{ env.tag }}
body: ${{ steps.git-cliff.outputs.content }}
files: dist/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}