summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSören Tempel <soeren+git@soeren-tempel.net>2018-03-11 16:17:30 +0100
committerSören Tempel <soeren+git@soeren-tempel.net>2018-03-11 16:29:00 +0100
commitf5eb69a5bd0c2bcf5af32277f0e3dc1bff86d836 (patch)
treef95be21330a97bbfd4f5ac9f8c18fbd277a0bfc3
parent45529e54d254ce1a14ccc028d76328d384a3757f (diff)
downloadabuild-f5eb69a5bd0c2bcf5af32277f0e3dc1bff86d836.tar.gz
abuild-f5eb69a5bd0c2bcf5af32277f0e3dc1bff86d836.tar.bz2
abuild-f5eb69a5bd0c2bcf5af32277f0e3dc1bff86d836.tar.xz
abuild-f5eb69a5bd0c2bcf5af32277f0e3dc1bff86d836.zip
abuild: add postcheck for -openrc subpackage
-rw-r--r--abuild.in10
1 files changed, 10 insertions, 0 deletions
diff --git a/abuild.in b/abuild.in
index 4a10362..8d09fc4 100644
--- a/abuild.in
+++ b/abuild.in
@@ -671,6 +671,11 @@ postcheck() {
error "Found /usr/lib/charset.alias"
return 1
fi
+ # look for /etc/init.d and /etc/conf.d
+ if [ -e "$dir"/etc/init.d -o -e "$dir"/etc/conf.d ] \
+ && ! is_openrc_pkg "$name"; then
+ warning "Found OpenRC directory (/etc/conf.d or /etc/init.d) but name doesn't end with -openrc"
+ fi
# look for /usr/share/doc
if [ -e "$dir"/usr/share/doc ] \
&& ! is_doc_pkg "$name"; then
@@ -1072,6 +1077,11 @@ is_doc_pkg() {
test "${1%-doc}" != "$1"
}
+# returns true if this is the -openrc package
+is_openrc_pkg() {
+ test "${1%-openrc}" != "$1"
+}
+
# check that noarch is set if needed
archcheck() {
options_has "!archcheck" && return 0