pkglint: forbid files generated by mimedb trigger

This commit is contained in:
Đoàn Trần Công Danh 2020-03-08 14:08:24 +07:00 committed by Toyam Cox
parent cef3871d48
commit 7c8ab37d36

View file

@ -80,6 +80,15 @@ hook() {
error=1
fi
# Forbid files would be generated by mimedb trigger
for f in XMLnamespaces aliases generic-icons globs globs2 icons \
magic mime.cache subclasses treemagic types version ; do
if [ -f "${PKGDESTDIR}/usr/share/mime/$f" ]; then
msg_red "${pkgver}: /usr/share/mime/$f is forbidden. Delete it.\n"
error=1
fi
done
# Forbid empty packages unless build_style=meta
if [ "$build_style" != "meta" ]; then
if [ "$(find $PKGDESTDIR/* -maxdepth 1 -type d 2>/dev/null)" = "" ]; then