Commit 63a4702c authored by Julien Muchembled's avatar Julien Muchembled

When installing, try 'python2' first, fall back on 'python'

parent 4fe44ea3
...@@ -2,6 +2,7 @@ DESTDIR = / ...@@ -2,6 +2,7 @@ DESTDIR = /
PREFIX = /usr/local PREFIX = /usr/local
MANDIR = $(PREFIX)/share/man MANDIR = $(PREFIX)/share/man
UNITDIR = /lib/systemd/system UNITDIR = /lib/systemd/system
PYTHON = $(or $(shell command -v python2),python)
MANPAGELIST := $(patsubst %,docs/%,re6st-conf.1 re6st-registry.1 re6stnet.8) MANPAGELIST := $(patsubst %,docs/%,re6st-conf.1 re6st-registry.1 re6stnet.8)
...@@ -17,8 +18,7 @@ install: install-noinit ...@@ -17,8 +18,7 @@ install: install-noinit
install-noinit: install-man install-noinit: install-man
set -e $(DESTDIR)$(PREFIX) /bin/re6stnet; [ -x $$1$$2 ] || \ set -e $(DESTDIR)$(PREFIX) /bin/re6stnet; [ -x $$1$$2 ] || \
$(or $(PYTHON),python2) setup.py install \ $(PYTHON) setup.py install --prefix=$(PREFIX) --root=$(DESTDIR); \
--prefix=$(PREFIX) --root=$(DESTDIR); \
install -d $$1/sbin; mv $$1$$2 $$1/sbin install -d $$1/sbin; mv $$1$$2 $$1/sbin
install -Dpm 0644 daemon/README.conf $(DESTDIR)/etc/re6stnet/README install -Dpm 0644 daemon/README.conf $(DESTDIR)/etc/re6stnet/README
install -Dpm 0644 daemon/logrotate.conf $(DESTDIR)/etc/logrotate.d/re6stnet install -Dpm 0644 daemon/logrotate.conf $(DESTDIR)/etc/logrotate.d/re6stnet
......
...@@ -16,7 +16,7 @@ debian/changelog: ...@@ -16,7 +16,7 @@ debian/changelog:
endif endif
override_dh_install: override_dh_install:
make DESTDIR=$(TMP) PREFIX=/usr PYTHON=/usr/bin/python install make DESTDIR=$(TMP) PREFIX=/usr install
# BBB: compat < 10 ; https://bugs.debian.org/879727 # BBB: compat < 10 ; https://bugs.debian.org/879727
override_dh_systemd_start: override_dh_systemd_start:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment