google-chrome: don't manually extract deb
also clean up the template a bit
This commit is contained in:
parent
01e33b3053
commit
76bac84c9b
@ -4,32 +4,34 @@ version=107.0.5304.110
|
||||
revision=1
|
||||
_channel=stable
|
||||
archs="x86_64"
|
||||
hostmakedepends="tar xz python3 python3-html2text python3-setuptools"
|
||||
hostmakedepends="python3-html2text python3-setuptools"
|
||||
depends="gtk+3"
|
||||
short_desc="Attempt at creating a safer, faster, and more stable browser"
|
||||
maintainer="Michael Aldridge <maldridge@voidlinux.org>"
|
||||
license="custom:chrome"
|
||||
homepage="https://www.google.com/chrome/"
|
||||
nostrip=yes
|
||||
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"
|
||||
distfiles="https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-${_channel}_${version}-1_amd64.deb"
|
||||
checksum=52e6d1be974c36cb40469f03b128cf21b36359a05fdadbb2e0379fbb17ef341b
|
||||
_license_checksum=8023b18fb5118ef65d586363e53909861bd1a9676e5eb83c20fd3ac6e33ea0be
|
||||
|
||||
do_extract() {
|
||||
mkdir -p ${DESTDIR}
|
||||
ar x ${XBPS_SRCDISTDIR}/google-chrome-${version}/${_filename}
|
||||
skiprdeps="/opt/google/chrome/libqt5_shim.so"
|
||||
repository=nonfree
|
||||
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() {
|
||||
tar xf data.tar.xz -C ${DESTDIR}
|
||||
vcopy etc /
|
||||
vcopy opt /
|
||||
vcopy usr /
|
||||
|
||||
# Install the icons
|
||||
for size in 16 24 32 48 64 128 256; do
|
||||
@ -47,10 +49,6 @@ do_install() {
|
||||
# Remove the Debian/Ubuntu crontab
|
||||
rm -rf ${DESTDIR}/etc
|
||||
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
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user