-
Notifications
You must be signed in to change notification settings - Fork 36
138 lines (134 loc) · 4.01 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
name: nightly packages
# based on the same for darktable-org/darktable
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
permissions:
contents: read
jobs:
AppImage:
if: github.repository == 'hanatos/vkdt' && false
name: nightly vkdt 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 }}
VKDT_CLI: ${{ github.workspace }}/AppDir/usr/bin/vkdt-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 \
git \
vulkan-tools \
libvulkan-dev \
libjpeg-dev \
libpugixml-dev \
libglfw3-dev \
zlib1g-dev \
appstream;
- uses: actions/checkout@v4
with:
ref: ${{ env.BRANCH }}
submodules: true
# We have to fetch the entire history to correctly generate the version for the AppImage filename
fetch-depth: 0
- name: build and install
run: |
bash bin/mkappimg.sh
- name: check if it runs
run: |
${INSTALL_PREFIX}/bin/vkdt --version
- name: package upload
if: ${{ success() }}
uses: actions/upload-artifact@v4
with:
path: ${{ env.BUILD_DIR }}/vkdt-*.AppImage*
name: artifact-appimage
retention-days: 1
Windows:
if: github.repository == 'hanatos/vkdt'
name: nightly vkdt windows
runs-on: windows-latest
strategy:
fail-fast: true
matrix:
msystem:
- UCRT64
defaults:
run:
shell: msys2 {0}
env:
SRC_DIR: ${{ github.workspace }}/vkdt
INSTALL_PREFIX: ${{ github.workspace }}/install
steps:
- uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.msystem }}
install: >-
git
pacboy: >-
cc:p
gcc-libs:p
dlfcn:p
rsync
make
glfw:p
vulkan-devel:p
glslang:p
libjpeg-turbo:p
zlib:p
exiv2:p
omp:p
cmake:p
pugixml:p
update: false
- uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: true
path: src
- name: build and install
run: |
make -C $(cygpath ${SRC_DIR})
make DESTDIR=$(cygpath ${INSTALL_PREFIX}) -C $(cygpath ${SRC_DIR}) install
- name: check if it runs
run: |
$(cygpath ${INSTALL_PREFIX})/bin/vkdt.exe --version
- name: get version info
run: |
cd ${SRC_DIR}
echo "VERSION=$(git describe --tags)" >> $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 }}/vkdt-${{ env.VERSION }}-${{ env.SYSTEM }}.exe
name: artifact-windows
retention-days: 1