-
-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathwine-stable.yml
208 lines (181 loc) · 10.7 KB
/
wine-stable.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
version: 1
script:
# Remove any previous build cache data
- rm -rf AppDir || true
- mkdir -p appimage-build/prime AppDir/winedata && cp wrapper AppDir
# Add winetricks
- wget -q "https://raw.githubusercontent.com/Winetricks/winetricks/master/src/winetricks" -P ./AppDir/bin && chmod +x ./AppDir/bin/winetricks
# Copy App icon to AppDir/usr/share/icons needed prior to appimage-builder ver 1.x.x
- mkdir -p AppDir/usr/share/icons AppDir/usr/lib64 ; cp wine.svg AppDir/usr/share/icons
# Add static appimage runtime
- cp runtime/runtime-x86_64 appimage-build/prime/runtime-x86_64
# Add config
- cp -R config AppDir/winedata
AppDir:
path: ./AppDir
app_info:
id: org.winehq.wine
name: wine
icon: wine
version: !ENV ${WINE_VER}
exec: bin/bash
exec_args: $APPDIR/wrapper $@
apt:
arch: [amd64]
sources:
- sourceline: 'deb http://archive.ubuntu.com/ubuntu/ focal main restricted universe multiverse'
- sourceline: 'deb http://archive.ubuntu.com/ubuntu/ focal-updates main restricted universe multiverse'
- sourceline: 'deb http://archive.ubuntu.com/ubuntu/ focal-backports main restricted universe multiverse'
key_url: 'http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x871920D1991BC93C'
- sourceline: 'deb https://dl.winehq.org/wine-builds/ubuntu/ focal main'
key_url: 'https://dl.winehq.org/wine-builds/winehq.key'
# - sourceline: 'deb http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu/ jammy main'
# key_url: 'http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xFCAE110B1118213C'
- sourceline: 'deb https://ppa.launchpadcontent.net/kisak/kisak-mesa/ubuntu focal main'
key_url: 'https://keyserver.ubuntu.com/pks/lookup?op=get&search=0xf63f0f2b90935439'
include:
- bash
- cabextract
- dash
- coreutils
- mesa-utils
- unionfs-fuse
- vulkan-tools
- libmspack0
files:
exclude:
- sbin
- var
- etc/alternatives
- etc/apt
- etc/cron.daily
- etc/dpkg
- etc/mysql
- etc/sane.d
- etc/sensors.d
- etc/skel
- etc/snmp
- etc/udev
- etc/gss
- etc/init.d
- etc/logrotate.d
- lib/modprobe.d
- lib/systemd
- lib/udev
- usr/lib/mime
- usr/lib/sasl2
- usr/lib/tmpfiles.d
- usr/sbin
- usr/share/apps
- usr/share/man
- usr/share/doc
- usr/share/adduser
- usr/share/apport
- usr/share/bash-completion
- usr/share/bug
- usr/share/debconf
- usr/share/doc
- usr/share/doc-base
- usr/share/dpkg
- usr/share/glib-2.0
- usr/share/gst-plugins-base
- usr/share/hal
- usr/share/info
- usr/share/initramfs-tools
- usr/share/kde4
- usr/share/libgphoto2
- usr/share/lintian
- usr/share/menu
- usr/share/metainfo
- usr/share/mesa-demos
- usr/share/mime
- usr/share/misc
- usr/share/mysql-common
- usr/share/pixmaps
- usr/share/pkgconfig
- usr/share/polkit-1
- usr/share/snmp
- usr/share/zoneinfo
- usr/share/zoneinfo-icu
- usr/share/zsh
- opt/wine-staging
- opt/wine-stable/share/man
- opt/wine-stable/share/applications
- opt/wine-stable/lib/wine/i386-windows/*.a
- opt/wine-stable/lib64/wine/x86_64-unix/*.a
- opt/wine-stable/lib64/wine/x86_64-windows/*.a
after_bundle:
# this is executed after the packages and files are added
- |
# Patch wrapper script
sed -i 's|wine-appimage|wine-appimage-stable|' AppDir/wrapper
WINE_VER="$(wget -qO- https://github.com/mmtrt/Wine-Builds/releases/expanded_assets/stable | grep -Eo '/wine-[0-9].*xz"' | cut -d'-' -f2 | head -1)"
wget -q "https://github.com/mmtrt/Wine-Builds/releases/download/stable/wine-${WINE_VER}-amd64.tar.xz"
mkdir -p AppDir/opt ; (cd AppDir/opt ; tar -xf ../../*.tar.xz ; mv wine-* wine-stable)
(cd AppDir/usr/bin; ln -s "../../opt/wine-stable/bin/"* .)
# Cleanup
rm -rf AppDir/usr/share/{applications,man,doc}
rm -rf AppDir/opt/wine-stable/share/{applications,man,doc}
rm -rf AppDir/opt/wine-stable/lib/wine/i386-windows/*.a
rm -rf AppDir/opt/wine-stable/lib64/wine/x86_64-unix/*.a
rm -rf AppDir/opt/wine-stable/lib64/wine/x86_64-windows/*.a
# Disable FileOpenAssociations
sed -i 's| LicenseInformation| LicenseInformation,\\\n FileOpenAssociations|g;$a \\n[FileOpenAssociations]\nHKCU,Software\\Wine\\FileOpenAssociations,"Enable",,"N"' AppDir/opt/wine-stable/share/wine/wine.inf
# Disable winemenubuilder
sed -i 's| FileOpenAssociations| FileOpenAssociations,\\\n DllOverrides|;$a \\n[DllOverrides]\nHKCU,Software\\Wine\\DllOverrides,"*winemenubuilder.exe",,""' AppDir/opt/wine-stable/share/wine/wine.inf
sed -i '/\%11\%\\winemenubuilder.exe -a -r/d' AppDir/opt/wine-stable/share/wine/wine.inf
# Pre patch CJK font replacement with Noto Sans CJK by defualt
sed -i 's| DllOverrides| DllOverrides,\\\n FontReplacement|g;$a \\n[FontReplacement]\nHKCU,Software\\Wine\\Fonts\\Replacements,"Batang",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"BatangChe",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Dotum",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"DotumChe",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Gulim",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"GulimChe",,"Noto Sans CJK KR"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei Light",,"Noto Sans CJK TC Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei Bold",,"Noto Sans CJK TC Black"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei UI",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei UI Light",,"Noto Sans CJK TC Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft JhengHei UI Bold",,"Noto Sans CJK TC Black"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei Light",,"Noto Sans CJK SC Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei Bold",,"Noto Sans CJK SC Black"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei UI",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei UI Light",,"Noto Sans CJK SC Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Microsoft YaHei UI Bold",,"Noto Sans CJK SC Black"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MingLiU",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MingLiU-ExtB",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MingLiU_HKSCS",,"Noto Sans CJK HK"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MingLiU_HKSCS-ExtB",,"Noto Sans CJK HK"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MS Gothic",,"Noto Sans CJK JP"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MS PGothic",,"Noto Sans CJK JP"\nHKCU,Software\\Wine\\Fonts\\Replacements,"MS UI Gothic",,"Noto Sans CJK JP"\nHKCU,Software\\Wine\\Fonts\\Replacements,"NSimSun",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"PMingLiU",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"PMingLiU-ExtB",,"Noto Sans CJK TC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"SimHei",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"SimSun",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"SimSun-ExtB",,"Noto Sans CJK SC"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic Regular",,"Noto Sans CJK JP"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic Medium",,"Noto Sans CJK JP Medium"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic Light",,"Noto Sans CJK JP Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic Bold",,"Noto Sans CJK JP Black"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic UI Regular",,"Noto Sans CJK JP"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic UI Medium",,"Noto Sans CJK JP Medium"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic UI Semilight",,"Noto Sans CJK JP DemiLight"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic UI Light",,"Noto Sans CJK JP Light"\nHKCU,Software\\Wine\\Fonts\\Replacements,"Yu Gothic UI Bold",,"Noto Sans CJK JP Black"' AppDir/opt/wine-stable/share/wine/wine.inf
# Deploy wine-mono wine-gecko
# For future reference setting of MONO_VER see https://github.com/wine-mirror/wine/tree/stable of wine-stable
MONO_VER=$(wget "https://raw.githubusercontent.com/wine-mirror/wine/$(wget -qO- https://github.com/wine-mirror/wine/releases/tag/wine-${WINE_VER} | grep 'commit/' | sed -r 's|/wine-mirror/wine/commit/||g' | cut -d'"' -f2 | head -1)/dlls/appwiz.cpl/addons.c" -qO- | grep -Po 'MONO_VERSION.*[0-9]"' | cut -d'"' -f2)
GECKO_VER=$(wget "https://raw.githubusercontent.com/wine-mirror/wine/$(wget -qO- https://github.com/wine-mirror/wine/releases/tag/wine-${WINE_VER} | grep 'commit/' | sed -r 's|/wine-mirror/wine/commit/||g' | cut -d'"' -f2 | head -1)/dlls/appwiz.cpl/addons.c" -qO- | grep -Po 'GECKO_VERSION.*[0-9]"' | cut -d'"' -f2)
case "$WINE_VER" in
3.0.1|3.0.2|3.0.3|3.0.4|3.0.5)
GECKO_VER="2.47"
MONO_VER="4.7.1"
;;
4.0.1|4.0.2|4.0.3|4.0.4)
GECKO_VER="2.47"
MONO_VER="4.7.5"
;;
5.0.1|5.0.2|5.0.3|5.0.4|5.0.5)
GECKO_VER="2.47.1"
MONO_VER="4.9.4"
;;
6.0.1|6.0.2|6.0.3|6.0.4)
GECKO_VER="2.47.2"
MONO_VER="5.1.1"
;;
7.0.1|7.0.2|7.0.3|7.0.4)
GECKO_VER="2.47.2"
MONO_VER="7.0.0-x86"
;;
*)
MONO_VER="$MONO_VER-x86"
;;
esac
# if [[ $(echo $GECKO_VER |sed -e 's/\.//g') -le 247 ]]; then
# GECKO=wine_gecko-${GECKO_VER}
# else
# GECKO=wine-gecko-${GECKO_VER}
# fi
MONO_URL="https://dl.winehq.org/wine/wine-mono/$(cut -d'-' -f1 <<< ${MONO_VER})/wine-mono-${MONO_VER}.msi"
# GECKO_URL_x86="https://dl.winehq.org/wine/wine-gecko/$GECKO_VER/${GECKO}-x86.msi"
# GECKO_URL_x86_64="https://dl.winehq.org/wine/wine-gecko/$GECKO_VER/${GECKO}-x86_64.msi"
wget -q "$MONO_URL" -O AppDir/winedata/wine-mono-${MONO_VER}.msi
# wget -q "$GECKO_URL_x86" -O AppDir/winedata/${GECKO}-x86.msi
# wget -q "$GECKO_URL_x86_64" -O AppDir/winedata/${GECKO}-x86_64.msi
after_runtime:
# this is executed after the runtime is added
- |
# Remove runtime info
sed -i '/modules_dir/d' AppDir/AppRun.config
runtime:
version: v3.0.0-devel-2
path_mappings:
- /opt/wine-stable:$APPDIR/opt/wine-stable
AppImage:
update-information: gh-releases-zsync|mmtrt|WINE_AppImage|continuous-stable|wine-stable*.AppImage.zsync
#sign-key: None
arch: x86_64