1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118
|
# This file is part of autopkgtest
# autopkgtest is a tool for testing Debian binary packages
#
# autopkgtest is Copyright (C) 2006 Canonical Ltd.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
# See the file CREDITS for a full list of credits information (often
# installed as /usr/share/doc/autopkgtest/CREDITS).
prefix = /usr
share = $(DESTDIR)$(prefix)/share
bindir = $(DESTDIR)$(prefix)/bin
man1dir = $(share)/man/man1
pkgname = autopkgtest
docdir = $(share)/doc/$(pkgname)
datadir = $(share)/$(pkgname)
pythondir = $(datadir)/lib
INSTALL = install
INSTALL_DIRS = $(INSTALL) -d
INSTALL_PROG = $(INSTALL) -m 0755
INSTALL_DATA = $(INSTALL) -m 0644
virts = chroot \
docker \
lxc \
lxd \
null \
qemu \
schroot \
ssh \
unshare \
$(NULL)
programs = tools/autopkgtest-buildvm-ubuntu-cloud \
tools/autopkgtest-build-docker \
tools/autopkgtest-build-lxc \
tools/autopkgtest-build-lxd \
tools/autopkgtest-build-qemu \
runner/autopkgtest \
$(NULL)
pythonfiles = lib/VirtSubproc.py \
lib/adtlog.py \
lib/autopkgtest_args.py \
lib/autopkgtest_deps.py \
lib/autopkgtest_qemu.py \
lib/adt_testbed.py \
lib/adt_binaries.py \
lib/testdesc.py \
$(NULL)
rstfiles = $(wildcard doc/*.rst)
htmlfiles = $(patsubst %.rst,%.html,$(rstfiles))
%.html: %.rst
rst2html -v $< > $@
all: $(htmlfiles)
check:
./tests/run-parallel
install:
$(INSTALL_DIRS) \
$(bindir) \
$(docdir) \
$(man1dir) \
$(pythondir) \
$(datadir)/lib/in-testbed \
$(datadir)/setup-commands \
$(datadir)/ssh-setup \
$(NULL)
set -e; for f in $(programs); do \
$(INSTALL_PROG) $$f $(bindir); \
test ! -f $$f.1 || $(INSTALL_DATA) $$f.1 $(man1dir); \
done
set -e; for f in $(virts); do \
$(INSTALL_PROG) virt/autopkgtest-virt-$$f $(bindir); \
$(INSTALL_DATA) virt/autopkgtest-virt-$${f}.1 $(man1dir); \
done
$(INSTALL_DATA) $(pythonfiles) $(pythondir)
$(INSTALL_DATA) CREDITS $(docdir)
$(INSTALL_DATA) $(rstfiles) $(htmlfiles) $(docdir)
$(INSTALL_PROG) lib/*.sh $(datadir)/lib/
$(INSTALL_PROG) lib/in-testbed/*.sh $(datadir)/lib/in-testbed/
$(INSTALL_PROG) lib/arch-is-concerned.pl $(datadir)/lib/
$(INSTALL_PROG) lib/parse-deps.pl $(datadir)/lib/
$(INSTALL_PROG) lib/unshare-helper $(datadir)/lib/
$(INSTALL_PROG) setup-commands/*[!~] $(datadir)/setup-commands
$(INSTALL_PROG) ssh-setup/[a-z]*[!~] $(datadir)/ssh-setup
$(INSTALL_DATA) ssh-setup/SKELETON $(datadir)/ssh-setup
ln -fns autopkgtest-virt-docker $(bindir)/autopkgtest-virt-podman
ln -fns autopkgtest-virt-docker.1 $(man1dir)/autopkgtest-virt-podman.1
ln -fns autopkgtest-build-docker $(bindir)/autopkgtest-build-podman
ln -fns autopkgtest-build-docker.1 $(man1dir)/autopkgtest-build-podman.1
ln -fns autopkgtest-virt-lxd $(bindir)/autopkgtest-virt-incus
ln -fns autopkgtest-virt-lxd.1 $(man1dir)/autopkgtest-virt-incus.1
ln -fns autopkgtest-build-lxd $(bindir)/autopkgtest-build-incus
ln -fns autopkgtest-build-lxd.1 $(man1dir)/autopkgtest-build-incus.1
clean:
rm -rf */__pycache__/
rm -rf .mypy_cache/
rm -f $(htmlfiles)
|