mirror of
https://gitlab.com/apparmor/apparmor.git
synced 2025-03-04 08:24:42 +01:00
move the DISTRO variable definition from common/Make.rules to
parser/Makefile (which is the only Makefile that uses the DISTRO variable) Acked-by: Steve Beattie <steve@nxnw.org>
This commit is contained in:
parent
70efe0cb53
commit
3e74935279
2 changed files with 21 additions and 20 deletions
|
@ -45,26 +45,6 @@ define nl
|
|||
|
||||
endef
|
||||
|
||||
ifndef DISTRO
|
||||
DISTRO=$(shell if [ -f /etc/slackware-version ] ; then \
|
||||
echo slackware ; \
|
||||
elif [ -f /etc/debian_version ] ; then \
|
||||
echo debian ;\
|
||||
elif which rpm > /dev/null ; then \
|
||||
if [ "$(rpm --eval '0%{?suse_version}')" != "0" ] ; then \
|
||||
echo suse ;\
|
||||
elif [ "$(rpm --eval '%{_host_vendor}')" = redhat ] ; then \
|
||||
echo rhel4 ;\
|
||||
elif [ "$(rpm --eval '0%{?fedora}')" != "0" ] ; then \
|
||||
echo rhel4 ;\
|
||||
else \
|
||||
echo unknown ;\
|
||||
fi ;\
|
||||
else \
|
||||
echo unknown ;\
|
||||
fi)
|
||||
endif
|
||||
|
||||
REPO_VERSION_CMD=([ -x /usr/bin/bzr ] && /usr/bin/bzr version-info . 2> /dev/null || awk '{ print "revno: "$2 }' common/.stamp_rev) | awk '/^revno:/ { print $2 }'
|
||||
|
||||
ifndef PYTHON_VERSIONS
|
||||
|
|
|
@ -328,6 +328,27 @@ install-debian:
|
|||
install-unknown:
|
||||
|
||||
INSTALLDEPS=arch
|
||||
|
||||
ifndef DISTRO
|
||||
DISTRO=$(shell if [ -f /etc/slackware-version ] ; then \
|
||||
echo slackware ; \
|
||||
elif [ -f /etc/debian_version ] ; then \
|
||||
echo debian ;\
|
||||
elif which rpm > /dev/null ; then \
|
||||
if [ "$(rpm --eval '0%{?suse_version}')" != "0" ] ; then \
|
||||
echo suse ;\
|
||||
elif [ "$(rpm --eval '%{_host_vendor}')" = redhat ] ; then \
|
||||
echo rhel4 ;\
|
||||
elif [ "$(rpm --eval '0%{?fedora}')" != "0" ] ; then \
|
||||
echo rhel4 ;\
|
||||
else \
|
||||
echo unknown ;\
|
||||
fi ;\
|
||||
else \
|
||||
echo unknown ;\
|
||||
fi)
|
||||
endif
|
||||
|
||||
ifdef DISTRO
|
||||
INSTALLDEPS+=install-$(DISTRO)
|
||||
endif
|
||||
|
|
Loading…
Add table
Reference in a new issue