forked from darktable-org/darktable
-
Notifications
You must be signed in to change notification settings - Fork 0
394 lines (382 loc) · 14.2 KB
/
nightly.yml
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
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
name: Nightly PKG
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
permissions:
contents: read
actions: write # We need this to be able to cancel workflow if job fails
jobs:
AppImage:
if: github.repository == 'darktable-org/darktable' || github.event_name == 'workflow_dispatch'
name: Nightly darktable AppImage
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
compiler:
- { compiler: GNU12, CC: gcc-12, CXX: g++-12, packages: gcc-12 g++-12 }
branch:
- { code: master, label: gitmaster }
env:
CC: ${{ matrix.compiler.CC }}
CXX: ${{ matrix.compiler.CXX }}
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/build
INSTALL_PREFIX: ${{ github.workspace }}/AppDir/usr
CMAKE_BUILD_TYPE: ${{ matrix.btype }}
GENERATOR: ${{ matrix.generator }}
TARGET: ${{ matrix.target }}
DARKTABLE_CLI: ${{ github.workspace }}/AppDir/usr/bin/darktable-cli
BRANCH: ${{ matrix.branch.code }}
BUILD_NAME: ${{ matrix.branch.label }}
steps:
- name: Install compiler ${{ matrix.compiler.compiler }}
run: |
# Remove azure mirror because it is unreliable and sometimes unpredictably leads to failed CI
sudo sed -i 's/azure\.//' /etc/apt/sources.list
sudo apt-get update
sudo apt-get -y install \
${{ matrix.compiler.packages }}
- name: Install Base Dependencies
run: |
sudo apt-get -y install \
build-essential \
appstream-util \
desktop-file-utils \
gettext \
git \
gdb \
intltool \
libatk1.0-dev \
libcairo2-dev \
libcolord-dev \
libcolord-gtk-dev \
libcups2-dev \
libcurl4-gnutls-dev \
libimage-exiftool-perl \
libfuse2 \
libgdk-pixbuf2.0-dev \
libglib2.0-dev \
libgraphicsmagick1-dev \
libgtk-3-dev \
libinih-dev \
libjpeg-dev \
libjson-glib-dev \
liblcms2-dev \
liblensfun-dev \
liblensfun-bin \
liblensfun-data-v1 \
liblensfun1 \
libopenjp2-7-dev \
libosmgpsmap-1.0-dev \
libpango1.0-dev \
libpng-dev \
libportmidi-dev \
libpugixml-dev \
librsvg2-dev \
libsaxon-java \
libsdl2-dev \
libsecret-1-dev \
libsqlite3-dev \
libtiff5-dev \
libwebp-dev \
libx11-dev \
libxml2-dev \
libxml2-utils \
ninja-build \
perl \
po4a \
python3-jsonschema \
xsltproc \
zlib1g-dev \
appstream;
sudo add-apt-repository -y ppa:savoury1/graphics
sudo add-apt-repository -y ppa:savoury1/ffmpeg4
sudo add-apt-repository -y ppa:savoury1/display
sudo apt-get update
sudo apt-get -y install \
libavif-dev \
libgmic-dev \
libgphoto2-dev \
libheif-dev \
libimath-dev \
libopenexr-dev \
libjxl-dev \
x11proto-dev \
libxfixes-dev;
- name: Build and install a more recent version of exiv2
run: |
git clone --branch v0.28.3 --depth 1 https://github.com/Exiv2/exiv2 src-exiv2
cd src-exiv2
cmake -S . -B build -G Ninja \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=ON \
-DEXIV2_ENABLE_NLS=ON \
-DEXIV2_ENABLE_VIDEO=OFF \
-DCMAKE_INSTALL_PREFIX=/usr
cmake --build build
sudo cmake --install build
cd ..
- name: Cancel workflow if job fails
if: ${{ failure() }}
uses: andymckay/cancel-action@0.5
- name: Checkout darktable master branch
run: |
# Note that we can't make a shallow clone to reduce clone traffic and time, as we have to
# fetch the entire history to correctly generate the version for the AppImage filename
git clone https://github.com/darktable-org/darktable src
pushd src
git submodule init
git config submodule.src/tests/integration.update none
git submodule update
popd
- name: Update lensfun data
continue-on-error: true
run: |
sudo lensfun-update-data
- name: Build and Install
run: |
cd src
bash tools/appimage-build-script.sh
- name: Package upload
if: ${{ success() }}
uses: actions/upload-artifact@v4
with:
path: ${{ github.workspace }}/src/build/Darktable-*.AppImage*
name: artifact-appimage
retention-days: 1
Windows:
if: github.repository == 'darktable-org/darktable' || github.event_name == 'workflow_dispatch'
name: Nightly darktable Windows
runs-on: windows-latest
strategy:
fail-fast: true
matrix:
btype:
- Release
msystem:
- UCRT64
target:
- skiptest
generator:
- Ninja
eco: [-DBINARY_PACKAGE_BUILD=ON]
defaults:
run:
shell: msys2 {0}
env:
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/build
INSTALL_PREFIX: ${{ github.workspace }}/install
ECO: ${{ matrix.eco }}
CMAKE_BUILD_TYPE: ${{ matrix.btype }}
TARGET: ${{ matrix.target }}
GENERATOR: ${{ matrix.generator }}
steps:
- uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.msystem }}
install: >-
git
intltool
po4a
pacboy: >-
cc:p
cmake:p
libxslt:p
ninja:p
nsis:p
python-jsonschema:p
curl:p
drmingw:p
gcc-libs:p
gettext:p
gmic:p
graphicsmagick:p
gtk3:p
icu:p
imath:p
iso-codes:p
lcms2:p
lensfun:p
libavif:p
libgphoto2:p
libheif:p
libjpeg-turbo:p
libjxl:p
libpng:p
librsvg:p
libsecret:p
libtiff:p
libwebp:p
libxml2:p
lua:p
omp:p
openexr:p
openjpeg2:p
osm-gps-map:p
portmidi:p
pugixml:p
SDL2:p
sqlite3:p
webp-pixbuf-loader:p
zlib:p
update: false
- name: Install the latest not yet broken version of exiv2
run: |
# It's a temporary fix, to be removed when the issue will be resolved
pacman -U --noconfirm https://repo.msys2.org/mingw/ucrt64/mingw-w64-ucrt-x86_64-exiv2-0.27.7-1-any.pkg.tar.zst
- name: Cancel workflow if job fails
if: ${{ failure() }}
uses: andymckay/cancel-action@0.5
- run: git config --global core.autocrlf input
shell: bash
- name: Checkout darktable master branch
run: |
# Note that we can't make a shallow clone to reduce clone traffic and time, as we have to
# fetch the entire history to correctly generate the version for the installation package filename
git clone https://github.com/darktable-org/darktable src
pushd src
git submodule init
git config submodule.src/tests/integration.update none
git submodule update
popd
- name: Update lensfun data
if: ${{ success() && matrix.btype == 'Release' && matrix.target == 'skiptest' }}
continue-on-error: true
run: |
lensfun-update-data
- name: Build and Install
run: |
cmake -E make_directory "${BUILD_DIR}"
cmake -E make_directory "${INSTALL_PREFIX}"
$(cygpath ${SRC_DIR})/.ci/ci-script.sh
- name: Package
if: ${{ success() && matrix.btype == 'Release' && matrix.target == 'skiptest' }}
run: |
cd "${BUILD_DIR}"
cmake --build "${BUILD_DIR}" --target package
- name: Get version info
run: |
cd ${SRC_DIR}
echo "VERSION=$(git describe --tags --match release-* | sed 's/^release-//;s/-/+/;s/-/~/;s/rc/~rc/')" >> $GITHUB_ENV
([[ ${MSYSTEM_CARCH} == x86_64 ]] && echo "SYSTEM=win64" || echo "SYSTEM=woa64") >> $GITHUB_ENV
- name: Package upload
if: ${{ success() }}
uses: actions/upload-artifact@v4
with:
path: ${{ env.BUILD_DIR }}/darktable-${{ env.VERSION }}-${{ env.SYSTEM }}.exe
name: artifact-windows
retention-days: 2
macOS:
if: github.repository == 'darktable-org/darktable' || github.event_name == 'workflow_dispatch'
name: Nightly darktable macOS
runs-on: ${{ matrix.build.os }}
strategy:
fail-fast: true
matrix:
build:
- { os: macos-13, xcode: 15.2, deployment: 13.5 } # LLVM16, x86_64
- { os: macos-14, xcode: 15.4, deployment: 14.0 } # LLVM16, arm64
compiler:
- { compiler: XCode, CC: cc, CXX: c++ }
btype: [ Release ]
eco: [-DBINARY_PACKAGE_BUILD=ON -DBUILD_CURVE_TOOLS=ON -DBUILD_NOISE_TOOLS=ON -DUSE_GRAPHICSMAGICK=OFF -DUSE_IMAGEMAGICK=ON]
target:
- skiptest
generator:
- Ninja
env:
DEVELOPER_DIR: /Applications/Xcode_${{ matrix.build.xcode }}.app/Contents/Developer
CC: ${{ matrix.compiler.CC }}
CXX: ${{ matrix.compiler.CXX }}
MACOSX_DEPLOYMENT_TARGET: ${{ matrix.build.deployment }}
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/src/build
INSTALL_PREFIX: ${{ github.workspace }}/src/build/macosx
ECO: ${{ matrix.eco }}
CMAKE_BUILD_TYPE: ${{ matrix.btype }}
GENERATOR: ${{ matrix.generator }}
TARGET: ${{ matrix.target }}
steps:
- name: Checkout darktable master branch
run: |
# Note that we can't make a shallow clone to reduce clone traffic and time, as we have to
# fetch the entire history to correctly generate the version for the disk image filename
git clone https://github.com/darktable-org/darktable src
pushd src
git submodule init
git config submodule.src/tests/integration.update none
git submodule update
popd
- name: Install Base Dependencies
run: |
brew update > /dev/null || true
# brew upgrade || true # No need for a very time-consuming upgrade of ALL packages
brew install --force gd # See https://github.com/Homebrew/homebrew-core/issues/141766
brew tap Homebrew/bundle
cd src/.ci
export HOMEBREW_NO_INSTALL_UPGRADE=1
brew bundle --verbose || true
# handle keg-only libs
brew link --force libomp
brew link --force libsoup@2
- name: Cancel workflow if job fails
if: ${{ failure() }}
uses: andymckay/cancel-action@0.5
- name: Build and Install
run: |
cmake -E make_directory "${BUILD_DIR}";
cmake -E make_directory "${INSTALL_PREFIX}";
./src/.ci/ci-script.sh;
- name: Build macOS package
run: |
./src/packaging/macosx/3_make_hb_darktable_package.sh
- name: Create DMG file
run: |
./src/packaging/macosx/4_make_hb_darktable_dmg.sh
- name: Get architecture
run: |
echo "ARCHITECTURE=$(uname -m)" >> $GITHUB_ENV
- name: Get version info
run: |
cd ${{ env.SRC_DIR }}
echo "VERSION=$(git describe --tags --match release-* | sed 's/^release-//;s/-/+/;s/-/~/;s/rc/~rc/')-${{ env.ARCHITECTURE }}" >> $GITHUB_ENV
- name: Package upload
if: ${{ success() }}
uses: actions/upload-artifact@v4
with:
path: ${{ env.INSTALL_PREFIX }}/darktable-${{ env.VERSION }}.dmg
name: artifact-macos-${{ env.ARCHITECTURE }}
retention-days: 2
upload_to_release:
permissions:
# We need write permission to update the nightly tag
contents: write
runs-on: ubuntu-latest
needs: [AppImage, Windows, macOS]
steps:
- name: Download artifacts
uses: actions/download-artifact@v4
- name: Update nightly release
uses: andelf/nightly-release@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: nightly
prerelease: true
name: 'Darktable nightly build $$'
# Please do not modify the body text by adding line breaks in paragraphs, as this text should display well on screens of different widths
body: |
This is a nightly build of Darktable.
You can use this if you want to try new features without waiting for releases. From time to time, in development builds, old difficult-to-reproduce bugs are fixed, but it is also true that in the development process with the introduction of new complex code, the stability of the program may suffer compared to official releases, so **use it with caution**!
Also, new versions can make changes to the database schema, so it's best to run them with a separate library.
The AppImage package is compatible with distribution releases that have glibc version 2.35 or higher. For example, if we consider some popular distributions, Ubuntu 22.04, Debian 12, Fedora 36 and newer releases are compatible.
The `*.AppImage.zsync` file is not intended to be downloaded and used locally. Just ignore it. This file contains technical information required by AppImage auto-updaters such as [AppImageUpdate](https://appimage.github.io/AppImageUpdate/).
The macOS `*-x86_64.dmg` package requires at least macOS 13.5 (Ventura), the `*-arm64.dmg` package requires at least macOS 14.0 (Sonoma).
__Please help us improve Darktable by reporting any issues you encounter!__ :wink:
files: |
artifact-appimage/*
artifact-windows/*
artifact-macos-*/*