mirror of
https://github.com/SELinuxProject/selinux
synced 2025-01-11 07:59:26 +00:00
57ac60769c
PYTHONLIBDIR is currently also used in sepolgen but has a different behaviour regarding DESTDIR. Let's try to make this consistant. Signed-off-by: Laurent Bigonville <bigon@bigon.be>
35 lines
861 B
Makefile
35 lines
861 B
Makefile
PYTHON ?= python
|
|
|
|
# Installation directories.
|
|
PREFIX ?= $(DESTDIR)/usr
|
|
LIBDIR ?= $(PREFIX)/lib
|
|
SBINDIR ?= $(PREFIX)/sbin
|
|
MANDIR = $(PREFIX)/share/man
|
|
PYTHONLIBDIR ?= $(shell $(PYTHON) -c "from distutils.sysconfig import *; print(get_python_lib(1))")
|
|
PACKAGEDIR ?= $(DESTDIR)/$(PYTHONLIBDIR)
|
|
BASHCOMPLETIONDIR ?= $(DESTDIR)/usr/share/bash-completion/completions
|
|
|
|
TARGETS=semanage
|
|
|
|
BASHCOMPLETIONS=semanage-bash-completion.sh
|
|
|
|
all: $(TARGETS)
|
|
|
|
install: all
|
|
[ -d $(MANDIR)/man8 ] || mkdir -p $(MANDIR)/man8
|
|
-mkdir -p $(SBINDIR)
|
|
install -m 755 semanage $(SBINDIR)
|
|
install -m 644 *.8 $(MANDIR)/man8
|
|
test -d $(PACKAGEDIR) || install -m 755 -d $(PACKAGEDIR)
|
|
install -m 755 seobject.py $(PACKAGEDIR)
|
|
-mkdir -p $(BASHCOMPLETIONDIR)
|
|
install -m 644 $(BASHCOMPLETIONS) $(BASHCOMPLETIONDIR)/semanage
|
|
|
|
test:
|
|
@$(PYTHON) test-semanage.py -a
|
|
clean:
|
|
|
|
indent:
|
|
|
|
relabel:
|