forked from LINBIT/linstor-proxmox
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
39 lines (34 loc) · 1.08 KB
/
Makefile
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
DESTDIR=
PREFIX=/usr
REL=linstor-proxmox-$(VERSION)
export PERLDIR=${PREFIX}/share/perl5
all:
@echo "The only useful target is 'deb'"
deb:
dh_clean
debuild -us -uc -i -b
install:
install -D -m 0644 ./DRBDPlugin.pm.divert ${DESTDIR}$(PERLDIR)/PVE/Storage/DRBDPlugin.pm
install -D -m 0644 ./LINSTORPlugin.pm ${DESTDIR}$(PERLDIR)/PVE/Storage/Custom/LINSTORPlugin.pm
install -D -m 0644 ./LINBIT/Linstor.pm ${DESTDIR}$(PERLDIR)/LINBIT/Linstor.pm
install -D -m 0644 ./LINBIT/PluginHelper.pm ${DESTDIR}$(PERLDIR)/LINBIT/PluginHelper.pm
ifndef VERSION
debrelease:
$(error environment variable VERSION is not set)
else
debrelease:
grep -q "$$( echo '$(VERSION)' | sed -e 's/-rc/~rc/' )" debian/changelog
grep 'PLUGIN_VERSION' LINSTORPlugin.pm | grep -q '$(VERSION)'
dh_clean
ln -s . $(REL) || true
tar --owner=0 --group=0 -czvf $(REL).tar.gz \
$(REL)/Makefile \
$(REL)/README.md \
$(REL)/CHANGELOG.md \
$(REL)/DRBDPlugin.pm.divert \
$(REL)/LINSTORPlugin.pm \
$(REL)/LINBIT/Linstor.pm \
$(REL)/LINBIT/PluginHelper.pm \
$(REL)/debian
if test -L "$(REL)"; then rm $(REL); fi
endif