google-chrome: don't manually extract deb
also clean up the template a bit
This commit is contained in:
parent
01e33b3053
commit
76bac84c9b
1 changed files with 18 additions and 20 deletions
|
@ -4,32 +4,34 @@ version=107.0.5304.110
|
||||||
revision=1
|
revision=1
|
||||||
_channel=stable
|
_channel=stable
|
||||||
archs="x86_64"
|
archs="x86_64"
|
||||||
hostmakedepends="tar xz python3 python3-html2text python3-setuptools"
|
hostmakedepends="python3-html2text python3-setuptools"
|
||||||
depends="gtk+3"
|
depends="gtk+3"
|
||||||
short_desc="Attempt at creating a safer, faster, and more stable browser"
|
short_desc="Attempt at creating a safer, faster, and more stable browser"
|
||||||
maintainer="Michael Aldridge <maldridge@voidlinux.org>"
|
maintainer="Michael Aldridge <maldridge@voidlinux.org>"
|
||||||
license="custom:chrome"
|
license="custom:chrome"
|
||||||
homepage="https://www.google.com/chrome/"
|
homepage="https://www.google.com/chrome/"
|
||||||
nostrip=yes
|
distfiles="https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-${_channel}_${version}-1_amd64.deb"
|
||||||
restricted=yes
|
|
||||||
repository=nonfree
|
|
||||||
skiprdeps="/opt/google/chrome/libqt5_shim.so"
|
|
||||||
|
|
||||||
_baseUrl="https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable"
|
|
||||||
_filename="google-chrome-${_channel}_${version}-1_amd64.deb"
|
|
||||||
_chromeUrl="${_baseUrl}/${_filename}"
|
|
||||||
_licenseUrl="https://www.google.com/intl/en/chrome/terms/"
|
|
||||||
|
|
||||||
distfiles="$_chromeUrl"
|
|
||||||
checksum=52e6d1be974c36cb40469f03b128cf21b36359a05fdadbb2e0379fbb17ef341b
|
checksum=52e6d1be974c36cb40469f03b128cf21b36359a05fdadbb2e0379fbb17ef341b
|
||||||
|
_license_checksum=8023b18fb5118ef65d586363e53909861bd1a9676e5eb83c20fd3ac6e33ea0be
|
||||||
|
|
||||||
do_extract() {
|
skiprdeps="/opt/google/chrome/libqt5_shim.so"
|
||||||
mkdir -p ${DESTDIR}
|
repository=nonfree
|
||||||
ar x ${XBPS_SRCDISTDIR}/google-chrome-${version}/${_filename}
|
restricted=yes
|
||||||
|
nostrip=yes
|
||||||
|
|
||||||
|
post_extract() {
|
||||||
|
$XBPS_FETCH_CMD 'https://www.google.com/intl/en/chrome/terms/' -o google-chrome-eula.html
|
||||||
|
html2text google-chrome-eula.html | sed -n '/^#/,/^SEE/p' > google-chrome-eula.md
|
||||||
|
filesum="$(xbps-digest google-chrome-eula.md)"
|
||||||
|
if [ "$filesum" != "$_license_checksum" ]; then
|
||||||
|
msg_error "SHA256 mismatch for EULA:\n$filesum\n"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
do_install() {
|
do_install() {
|
||||||
tar xf data.tar.xz -C ${DESTDIR}
|
vcopy etc /
|
||||||
|
vcopy opt /
|
||||||
|
vcopy usr /
|
||||||
|
|
||||||
# Install the icons
|
# Install the icons
|
||||||
for size in 16 24 32 48 64 128 256; do
|
for size in 16 24 32 48 64 128 256; do
|
||||||
|
@ -47,10 +49,6 @@ do_install() {
|
||||||
# Remove the Debian/Ubuntu crontab
|
# Remove the Debian/Ubuntu crontab
|
||||||
rm -rf ${DESTDIR}/etc
|
rm -rf ${DESTDIR}/etc
|
||||||
rm -rf ${DESTDIR}/opt/google/chrome/cron
|
rm -rf ${DESTDIR}/opt/google/chrome/cron
|
||||||
}
|
|
||||||
|
|
||||||
post_install() {
|
|
||||||
xbps-fetch ${_licenseUrl} -o google-chrome-eula.html
|
|
||||||
cat google-chrome-eula.html | html2text >> google-chrome-eula.md
|
|
||||||
vlicense google-chrome-eula.md
|
vlicense google-chrome-eula.md
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue