thorium-browser-beta-avx512-bin
LOW
maintainer RubenKelevra
0 votes
scanned 2026-10-19 13:25:12.486194
Why flagged
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
Triggered rules
Low
Few votes, recently uploaded
zero_votes_recent
Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.
PKGBUILD
1
# Maintainer: @RubenKelevra <rubenkelevra@gmail.com>
2
# Contributor: xiota <aur@mentalfossa.com>
3
# Contributor: JPratama7 <josepratama080@gmail.com>
4
# Contributor: Dominik Adrian Grzywak <starterx4 at gmail dot com>
5
6
_pkgname='thorium-browser'
7
pkgname="${_pkgname}-beta-avx512-bin"
8
pkgbase="${pkgname}"
9
pkgver=156.0.8078.28
10
pkgrel=1
11
pkgdesc='AVX-512 beta build of the Chromium fork focused on performance'
12
url='https://github.com/gz83/thorium'
13
license=(
14
'BSD-3-Clause'
15
'LicenseRef-Google-Widevine-CDM'
16
)
17
arch=('x86_64')
18
makedepends=('libarchive')
19
depends=(
20
'alsa-lib'
21
'at-spi2-core'
22
'cairo'
23
'dbus'
24
'expat'
25
'glib2'
26
'gtk3'
27
'hicolor-icon-theme'
28
'libcups'
29
'libgcc'
30
'libnotify'
31
'libx11'
32
'libxcb'
33
'libxcomposite'
34
'libxdamage'
35
'libxext'
36
'libxfixes'
37
'libxkbcommon'
38
'libxrandr'
39
'mesa'
40
'nspr'
41
'nss'
42
'pango'
43
'systemd-libs'
44
'ttf-liberation'
45
'xdg-utils'
46
)
47
optdepends=(
48
'gtk4: GTK4 UI support'
49
'kdialog: native dialogs on Plasma'
50
'libsecret: password storage client integration'
51
'org.freedesktop.secrets: Secret Service backend for password storage'
52
'pipewire: WebRTC desktop sharing under Wayland'
53
'qt5-base: Qt5 UI support'
54
'qt6-base: Qt6 UI support'
55
'upower: Battery Status API support'
56
)
57
provides=(
58
"${_pkgname}=${pkgver}"
59
"${_pkgname}-beta=${pkgver}"
60
)
61
conflicts=(
62
"${_pkgname}"
63
"${_pkgname}-bin"
64
"${_pkgname}-sse3-bin"
65
"${_pkgname}-sse4-bin"
66
"${_pkgname}-avx-bin"
67
"${_pkgname}-avx2-bin"
68
'thorium-browser-beta-bin'
69
'thorium-browser-beta-sse4-bin'
70
'thorium-browser-beta-avx-bin'
71
'thorium-browser-beta-avx2-bin'
72
)
73
options=(
74
'!emptydirs'
75
'!strip'
76
'!debug'
77
)
78
79
_dl_url="${url}/releases/download/M${pkgver}"
80
_dl_filename_x86_64="${_pkgname}_${pkgver}_AVX512.deb"
81
_license_filename="${_pkgname}-${pkgver}-LICENSE.md"
82
_data_archive='data.tar.xz'
83
noextract=("${_dl_filename_x86_64}")
84
85
source=(
86
"${_pkgname}.sh"
87
'thorium-cpu-check.sh'
88
'thorium-shell.sh'
89
"${_license_filename}::${url}/raw/M${pkgver}/LICENSE.md"
90
)
91
source_x86_64=("${_dl_url}/${_dl_filename_x86_64}")
92
b2sums=(
93
'038ce007f34bc9c519bcc1918ca472cf6596a1dade80b9b150021762a51cf28bc331bb82299110023593f569b9cf285c9ed60d695cfd2abf82d0bf9073ceeee5'
94
'e705119e48127f4c8583bb36b489451ef287cb5a1af3f1b4440ddeeb9e59851e6bfe0f1988449b40323f32734d05fdbc1cdc6aee0910be54cb02af688f957a15'
95
'867bc169f526a530a79d1eef5cc463d1c386d380bb574228a46492c9c85fc5dcdaa8768e08282dbe5ed660458613b67da8e3f822a3c9d93866e2252f3332b672'
96
'fe17f16ad6a8911dc9c49de3e45fa450a2a3ef59ec2f5400daed74b4401cfe2426e5b52e8e2e519bbc9f2b110112e616578eaf57705605a75cc5e8fa9d820060'
97
)
98
sha256sums_x86_64=('f8a8228d4a33cd7f6ba7c1e40872e9c0ff0203c937ae12e7a91db02b3b4b6027')
99
100
prepare() {
101
CARCH="${CARCH}" bash "${srcdir}/thorium-cpu-check.sh" build
102
}
103
104
package() {
105
printf ' -> Extracting the archive...\n'
106
rm -f -- "${srcdir}/${_data_archive}"
107
bsdtar -C "${srcdir}" -xf "${srcdir}/${_dl_filename_x86_64}" "${_data_archive}"
108
bsdtar -C "${pkgdir}/" -xJf "${srcdir}/${_data_archive}"
109
rm -f -- "${srcdir}/${_data_archive}"
110
111
printf ' -> Moving files in place...\n'
112
mv -- "${pkgdir}/opt/chromium.org/thorium" "${pkgdir}/opt/${_pkgname}"
113
unlink -- "${pkgdir}/usr/bin/thorium-browser"
114
unlink -- "${pkgdir}/usr/bin/pak"
115
116
# Upstream labels its beta packages as stable in the version dialog.
117
# Correct the channel without changing the CPU variant annotation.
118
local upstream_launcher="${pkgdir}/opt/${_pkgname}/${_pkgname}"
119
sed -E \
120
-e 's@^([[:space:]]*export CHROME_VERSION_EXTRA=")stable@\1beta@' \
121
-i -- "${upstream_launcher}"
122
if ! grep -Eq '^[[:space:]]*export CHROME_VERSION_EXTRA="beta' "${upstream_launcher}" ||
123
grep -Eq '^[[:space:]]*export CHROME_VERSION_EXTRA="stable' "${upstream_launcher}"; then
124
printf 'Unexpected upstream release channel marker: %s\n' "${upstream_launcher}" >&2
125
return 1
126
fi
127
128
# thorium-browser
129
install -Dm755 -- "${srcdir}/${_pkgname}.sh" "${pkgdir}/usr/bin/${_pkgname}"
130
install -Dm755 -- "${srcdir}/thorium-cpu-check.sh" \
131
"${pkgdir}/usr/lib/${_pkgname}/check-cpu-support"
132
chmod 4755 -- "${pkgdir}/opt/${_pkgname}/chrome-sandbox"
133
134
local widevine_dir="${pkgdir}/opt/${_pkgname}/WidevineCdm"
135
if [[ ! -f ${widevine_dir}/_platform_specific/linux_x64/libwidevinecdm.so || ! -f ${widevine_dir}/LICENSE ]]; then
136
printf 'Missing bundled x86_64 Widevine CDM or license\n' >&2
137
return 1
138
fi
139
install -Dm644 -- "${widevine_dir}/LICENSE" \
140
"${pkgdir}/usr/share/licenses/${pkgname}/Widevine-LICENSE"
141
142
# Fix upstream paths after moving Thorium out of /opt/chromium.org.
143
if [[ -f ${pkgdir}/opt/${_pkgname}/default-app-block ]]; then
144
sed -E \
145
-e "s@/opt/chromium.org/thorium/@/opt/${_pkgname}/@g" \
146
-i -- "${pkgdir}/opt/${_pkgname}/default-app-block"
147
fi
148
149
# Bring upstream AppStream metadata up to the current schema and path.
150
local metainfo_source="${pkgdir}/usr/share/appdata/thorium-browser.appdata.xml"
151
local metainfo_file="${pkgdir}/usr/share/metainfo/org.chromium.Thorium.metainfo.xml"
152
if [[ ! -f ${metainfo_source} ]]; then
153
printf 'Missing Thorium AppStream metadata: %s\n' "${metainfo_source}" >&2
154
return 1
155
fi
156
install -Dm644 -- "${metainfo_source}" "${metainfo_file}"
157
rm -f -- "${metainfo_source}"
158
rmdir --ignore-fail-on-non-empty -- "${pkgdir}/usr/share/appdata"
159
sed -E \
160
-e 's@<id>thorium-browser[.]desktop</id>@<id>org.chromium.Thorium</id>@' \
161
-e '/<translation\/>/d' \
162
-e 's@<developer_name>([^<]+)</developer_name>@<developer id="io.github.alex313031"><name>\1</name></developer>@' \
163
-i -- "${metainfo_file}"
164
if ! grep -q '<launchable type="desktop-id">' "${metainfo_file}"; then
165
sed -i '/<url type="bugtracker">/i\ <launchable type="desktop-id">thorium-browser.desktop</launchable>' \
166
"${metainfo_file}"
167
fi
168
if ! grep -q '<content_rating type="oars-1.1"' "${metainfo_file}"; then
169
sed -i '/<url type="bugtracker">/i\ <content_rating type="oars-1.1"/>' \
170
"${metainfo_file}"
171
fi
172
173
# thorium-shell
174
install -Dm755 -- "${srcdir}/thorium-shell.sh" "${pkgdir}/usr/bin/thorium-shell"
175
sed -E \
176
-e 's@^Icon=.*@Icon=thorium-shell@' \
177
-i -- "${pkgdir}/usr/share/applications/thorium-shell.desktop"
178
179
# thorium-browser.xml
180
sed -E \
181
-e "s@/opt/chromium.org/thorium/@/opt/${_pkgname}/@" \
182
-i -- "${pkgdir}/usr/share/gnome-control-center/default-apps/thorium-browser.xml"
183
184
# Icons
185
install -Dm644 -- "${pkgdir}/opt/${_pkgname}/product_logo_256.png" \
186
"${pkgdir}/usr/share/icons/hicolor/256x256/apps/${_pkgname}.png"
187
install -Dm644 -- "${pkgdir}/opt/${_pkgname}/thorium_shell.png" \
188
"${pkgdir}/usr/share/icons/hicolor/256x256/apps/thorium-shell.png"
189
190
# Clean up upstream Debian packaging files.
191
rm -rf -- \
192
"${pkgdir}/opt/chromium.org" \
193
"${pkgdir}/etc/cron.daily/" \
194
"${pkgdir}/usr/share/doc/" \
195
"${pkgdir}/opt/${_pkgname}/cron/" \
196
"${pkgdir}/opt/${_pkgname}"/product_logo_*.{png,xpm} \
197
"${pkgdir}/usr/share/menu/"
198
199
install -Dm644 -- "${srcdir}/${_license_filename}" \
200
"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.md"
201
}
202
Scan history
| Scanned at (UTC) | Severity | Rules |
|---|---|---|
| 2026-10-19 13:25:12 | Low | 1 |