Added openRC daemon

This commit is contained in:
Pascal Jäger
2021-10-24 02:20:26 +02:00
committed by Antynea
parent 63c3493504
commit fbc33391cb

View File

@@ -6,7 +6,6 @@ INITCPIO ?= false
SHARE_DIR = $(DESTDIR)$(PREFIX)/share
LIB_DIR = $(DESTDIR)$(PREFIX)/lib
BIN_DIR = $(DESTDIR)$(PREFIX)/bin
SYSCONFDIR=$(DESTDIR)/etc
OPENRC = $(shell strings /sbin/init | grep -q "sysvinit" && echo true || echo false)
SYSTEMD = $(shell test -d /run/systemd/system && echo true || echo false)
@@ -27,7 +26,7 @@ install:
@# OpenRC detected on system, install OpenRC daemon
@if [[ $(OPENRC) = true ]]; then \
install -Dm744 -t "$(BIN_DIR)/" grub-btrfs-openrc; \
install -Dm744 -t "$(SYSCONFDIR)/init.d/" grub-btrfsd; \
install -Dm744 -t "$(DESTDIR)/init.d/" grub-btrfsd; \
fi
@# Arch Linux like distros only :
@if test "$(INITCPIO)" = true; then \
@@ -54,7 +53,7 @@ uninstall:
@# OpenRC detected on system, install OpenRC daemon
@if [[ $(OPENRC) = true ]]; then \
rm -f "$(BIN_DIR)/grub-btrfs.openrcbin; \
rm -f "$(SYSCONFDIR)/init.d/grub-btrfs.openrc; \
rm -f "$(DESTDIR)/init.d/grub-btrfs.openrc; \
fi
@rm -f "$(LIB_DIR)/initcpio/install/grub-btrfs-overlayfs"
@rm -f "$(LIB_DIR)/initcpio/hooks/grub-btrfs-overlayfs"