Home | History | Annotate | Download | only in semanage
      1 PYTHON ?= python
      2 
      3 # Installation directories.
      4 PREFIX ?= $(DESTDIR)/usr
      5 LIBDIR ?= $(PREFIX)/lib
      6 SBINDIR ?= $(PREFIX)/sbin
      7 MANDIR = $(PREFIX)/share/man
      8 PYLIBVER ?= $(shell $(PYTHON) -c 'import sys;print("python%d.%d" % sys.version_info[0:2])')
      9 PYTHONLIBDIR ?= $(LIBDIR)/$(PYLIBVER)
     10 BASHCOMPLETIONDIR ?= $(DESTDIR)/usr/share/bash-completion/completions
     11 
     12 TARGETS=semanage
     13 
     14 BASHCOMPLETIONS=semanage-bash-completion.sh 
     15 
     16 all: $(TARGETS)
     17 
     18 install: all
     19 	[ -d $(MANDIR)/man8 ] || mkdir -p $(MANDIR)/man8
     20 	-mkdir -p $(SBINDIR)
     21 	install -m 755 semanage $(SBINDIR)
     22 	install -m 644 *.8 $(MANDIR)/man8
     23 	test -d $(PYTHONLIBDIR)/site-packages || install -m 755 -d $(PYTHONLIBDIR)/site-packages
     24 	install -m 755 seobject.py $(PYTHONLIBDIR)/site-packages
     25 	-mkdir -p $(BASHCOMPLETIONDIR)
     26 	install -m 644 $(BASHCOMPLETIONS) $(BASHCOMPLETIONDIR)/semanage
     27 
     28 test:
     29 	@$(PYTHON) test-semanage.py -a
     30 clean:
     31 
     32 indent:
     33 
     34 relabel:
     35