CI: whitelist firmware-asus-me176c-acpi in devpkg (!699)

Without this, the device will simply run the broken ACPI DSDT table, so
we might as well update it. If we had put it into a subpackage, it
would not be possible to use the fixed DSDT without any other firmware
packages.
This commit is contained in:
Oliver Smith 2019-10-30 22:16:33 +01:00
parent 4098ca9638
commit b407687761
No known key found for this signature in database
GPG key ID: 5AE7F5513E0885CB

View file

@ -76,6 +76,26 @@ def test_deviceinfo(args):
raise last_exception
def device_dependency_check(apkbuild, path):
""" Raise an error if a device package has a dependency that is not allowed
(e.g. because it should be in a subpackage instead). """
# asus-me176c: without this, the device will simply run the broken ACPI
# DSDT table, so we might as well update it. See pmaports!699.
firmware_ok = {"device-asus-me176c": ["firmware-asus-me176c-acpi"]}
pkgname = apkbuild["pkgname"]
for depend in apkbuild["depends"]:
if (depend.startswith("firmware-") or
depend.startswith("linux-firmware")):
if pkgname in firmware_ok and depend in firmware_ok[pkgname]:
continue
raise RuntimeError("Firmware package '" + depend + "' found in"
" depends of " + path + ". These go into"
" subpackages now, see"
" <https://postmarketos.org/devicepkg>.")
def test_aports_device(args):
"""
Various tests performed on the /device/device-* aports.
@ -90,12 +110,7 @@ def test_aports_device(args):
# Depends: Must not have firmware packages
for depend in apkbuild["depends"]:
if (depend.startswith("firmware-") or
depend.startswith("linux-firmware")):
raise RuntimeError("Firmware package '" + depend + "' found in"
" depends of " + path + ". These go into"
" subpackages now, see"
" <https://postmarketos.org/devicepkg>.")
device_dependency_check(apkbuild, path)
# Architecture
device = apkbuild["pkgname"][len("device-"):]