build: add make dev name=<profile-name>.

This commit is contained in:
Alexandre Pujol 2024-10-02 19:49:21 +01:00
parent c5505dee8b
commit 7ba556b15c
Failed to generate hash of commit

View file

@ -9,7 +9,7 @@ PKGDEST := /tmp/pkg
PKGNAME := apparmor.d PKGNAME := apparmor.d
P = $(filter-out dpkg,$(notdir $(wildcard ${BUILD}/apparmor.d/*))) P = $(filter-out dpkg,$(notdir $(wildcard ${BUILD}/apparmor.d/*)))
.PHONY: all build enforce full install local $(P) pkg dpkg rpm tests lint man docs serve clean .PHONY: all build enforce full install local $(P) dev package pkg dpkg rpm tests lint man docs serve clean
all: build all: build
@./${BUILD}/prebuild --complain @./${BUILD}/prebuild --complain
@ -71,6 +71,12 @@ $(P):
done; done;
@systemctl restart apparmor || systemctl status apparmor @systemctl restart apparmor || systemctl status apparmor
name ?=
dev:
@go run ./cmd/prebuild --complain --file $(shell find apparmor.d -iname ${name})
@sudo install -Dm644 ${BUILD}/${name} /etc/apparmor.d/${name}
@sudo systemctl restart apparmor || systemctl status apparmor
dist ?= archlinux dist ?= archlinux
package: package:
@bash dists/docker.sh ${dist} @bash dists/docker.sh ${dist}