提交 a504e52d 编写于 作者: C Cleber Rosa

Makefile: move Debian package related rules to contrib

The support for Debian packages have already been moved to a contrib
dir, their Makefile rules were kept but not even updated.  Let's
move those to the contrib dir.

Notice: the status of these rules are equal to the other Debian package
files, that is, they're unsupported and we do not guarantee they're
actually working.
Signed-off-by: NCleber Rosa <crosa@redhat.com>
上级 6b224a9e
...@@ -14,13 +14,10 @@ PYTHON=$(shell which python) ...@@ -14,13 +14,10 @@ PYTHON=$(shell which python)
PYTHON26=$(shell $(PYTHON) -V 2>&1 | grep 2.6 -q && echo true || echo false) PYTHON26=$(shell $(PYTHON) -V 2>&1 | grep 2.6 -q && echo true || echo false)
VERSION=$(shell $(PYTHON) setup.py --version 2>/dev/null) VERSION=$(shell $(PYTHON) setup.py --version 2>/dev/null)
DESTDIR=/ DESTDIR=/
BUILDIR=$(CURDIR)/debian/avocado
PROJECT=avocado
AVOCADO_DIRNAME=$(shell echo $${PWD\#\#*/}) AVOCADO_DIRNAME=$(shell echo $${PWD\#\#*/})
AVOCADO_PLUGINS=$(filter-out ../$(AVOCADO_DIRNAME), $(wildcard ../*)) AVOCADO_PLUGINS=$(filter-out ../$(AVOCADO_DIRNAME), $(wildcard ../*))
RELEASE_COMMIT=$(shell git log --pretty=format:'%H' -n 1 $(VERSION)) RELEASE_COMMIT=$(shell git log --pretty=format:'%H' -n 1 $(VERSION))
RELEASE_SHORT_COMMIT=$(shell git log --pretty=format:'%h' -n 1 $(VERSION)) RELEASE_SHORT_COMMIT=$(shell git log --pretty=format:'%h' -n 1 $(VERSION))
COMMIT=$(shell git log --pretty=format:'%H' -n 1) COMMIT=$(shell git log --pretty=format:'%H' -n 1)
SHORT_COMMIT=$(shell git log --pretty=format:'%h' -n 1) SHORT_COMMIT=$(shell git log --pretty=format:'%h' -n 1)
...@@ -49,11 +46,6 @@ all: ...@@ -49,11 +46,6 @@ all:
@echo "srpm: Generate a source RPM package (.srpm)" @echo "srpm: Generate a source RPM package (.srpm)"
@echo "rpm: Generate binary RPMs" @echo "rpm: Generate binary RPMs"
@echo @echo
@echo "Debian related targets:"
@echo "deb: Generate both source and binary debian packages"
@echo "deb-src: Generate a source debian package"
@echo "deb-bin: Generate a binary debian package"
@echo
@echo "Release related targets:" @echo "Release related targets:"
@echo "source-release: Create source package for the latest tagged release" @echo "source-release: Create source package for the latest tagged release"
@echo "srpm-release: Generate a source RPM package (.srpm) for the latest tagged release" @echo "srpm-release: Generate a source RPM package (.srpm) for the latest tagged release"
...@@ -83,25 +75,6 @@ pypi: source-pypi develop ...@@ -83,25 +75,6 @@ pypi: source-pypi develop
install: install:
$(PYTHON) setup.py install --root $(DESTDIR) $(COMPILE) $(PYTHON) setup.py install --root $(DESTDIR) $(COMPILE)
deb-prepare-source:
# build the source package in the parent directory
# then rename it to project_version.orig.tar.gz
dch -D "vivid" -M -v "$(VERSION)" "Automated (make builddeb) build."
$(PYTHON) setup.py sdist $(COMPILE) --dist-dir=../
rename -f 's/$(PROJECT)-(.*)\.tar\.gz/$(PROJECT)_$$1\.orig\.tar\.gz/' ../*
deb-src: deb-prepare-source
# build the source package
dpkg-buildpackage -S -elookkas@gmail.com -rfakeroot
deb-bin: deb-prepare-source
# build binary package
dpkg-buildpackage -b -rfakeroot
deb: deb-prepare-source
# build both source and binary packages
dpkg-buildpackage -i -I -rfakeroot
srpm: source srpm: source
if test ! -d BUILD/SRPM; then mkdir -p BUILD/SRPM; fi if test ! -d BUILD/SRPM; then mkdir -p BUILD/SRPM; fi
mock --resultdir BUILD/SRPM -D "commit $(COMMIT)" --buildsrpm --spec avocado.spec --sources SOURCES mock --resultdir BUILD/SRPM -D "commit $(COMMIT)" --buildsrpm --spec avocado.spec --sources SOURCES
......
BUILDIR=$(CURDIR)/debian/avocado
PROJECT=avocado
all:
@echo
@echo "Debian related targets:"
@echo "deb: Generate both source and binary debian packages"
@echo "deb-src: Generate a source debian package"
@echo "deb-bin: Generate a binary debian package"
@echo
deb-prepare-source:
# build the source package in the parent directory
# then rename it to project_version.orig.tar.gz
dch -D "vivid" -M -v "$(VERSION)" "Automated (make builddeb) build."
$(PYTHON) setup.py sdist $(COMPILE) --dist-dir=../
rename -f 's/$(PROJECT)-(.*)\.tar\.gz/$(PROJECT)_$$1\.orig\.tar\.gz/' ../*
deb-src: deb-prepare-source
# build the source package
dpkg-buildpackage -S -elookkas@gmail.com -rfakeroot
deb-bin: deb-prepare-source
# build binary package
dpkg-buildpackage -b -rfakeroot
deb: deb-prepare-source
# build both source and binary packages
dpkg-buildpackage -i -I -rfakeroot
This is a collection of files that are useful to generate packages for
Debian(-like) systems. Their "contrib" status mean that they should
work, but there's no support for them.
If there are users out there interested in keeping Debian(-like)
packages update, please step up.
The basic usage is to run the various targets defined in the Makefile,
such as running `make deb` to have both source and binary packages
generated.
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册