build: simplify detection of the target platform

It can be done within the container, rather than having to compute it in
the Makefile and then pass it as an argument.
This commit is contained in:
Saúl Ibarra Corretgé
2024-01-15 11:48:36 +01:00
parent 21f04ead6e
commit d31e164656
4 changed files with 15 additions and 32 deletions

View File

@@ -2,7 +2,9 @@
set -o pipefail -xeu
if [ "${USE_CHROMIUM}" = 1 -o "${TARGETPLATFORM}" = "linux/arm64" ]; then
dpkgArch="$(dpkg --print-architecture)"
if [ "${USE_CHROMIUM}" = 1 -o "${dpkgArch##*-}" = "arm64" ]; then
echo "Using Debian's Chromium"
apt-dpkg-wrap apt-get install -y chromium chromium-driver chromium-sandbox
chromium --version