]>
Commit | Line | Data |
---|---|---|
f76a2828 DM |
1 | PACKAGE=pve-container |
2 | ||
3 | PREFIX=${DESTDIR}/usr | |
4 | BINDIR=${PREFIX}/bin | |
5 | SBINDIR=${PREFIX}/sbin | |
6 | MANDIR=${PREFIX}/share/man | |
7 | DOCDIR=${PREFIX}/share/doc/${PACKAGE} | |
bf9f492f DM |
8 | LXC_SCRIPT_DIR=${PREFIX}/share/lxc |
9 | LXC_TMPL_DIR=${LXC_SCRIPT_DIR}/templates | |
10 | LXC_HOOK_DIR=${LXC_SCRIPT_DIR}/hooks | |
11 | LXC_COMMON_CONFIG_DIR=${LXC_SCRIPT_DIR}/config/common.conf.d | |
f76a2828 DM |
12 | PODDIR=${DOCDIR}/pod |
13 | MAN1DIR=${MANDIR}/man1/ | |
81bee809 | 14 | MAN5DIR=${MANDIR}/man5/ |
f76a2828 DM |
15 | export PERLDIR=${PREFIX}/share/perl5 |
16 | ||
17 | all: | |
18 | ||
19 | %.1.gz: %.1.pod | |
20 | rm -f $@ | |
21 | cat $<|pod2man -n $* -s 1 -r ${VERSION} -c "Proxmox Documentation"|gzip -c9 >$@ | |
22 | ||
81bee809 DM |
23 | %.5.gz: %.5.pod |
24 | rm -f $@ | |
25 | cat $<|pod2man -n $* -s 5 -r ${VERSION} -c "Proxmox Documentation"|gzip -c9 >$@ | |
26 | ||
f76a2828 | 27 | pct.1.pod: pct |
1c7f4f65 | 28 | perl -I. -T ./pct printmanpod >$@ |
f76a2828 | 29 | |
81bee809 DM |
30 | pct.conf.5.pod: gen-pct-conf-pod.pl PVE/LXC.pm |
31 | perl -I. ./gen-pct-conf-pod.pl >$@ | |
32 | ||
93285df8 DM |
33 | lxc-pve-mount-hook.1.pod: lxc-pve-mount-hook |
34 | perl -I. -T ./lxc-pve-mount-hook printmanpod >$@ | |
35 | ||
32e6d659 AD |
36 | lxc-pve-poststop-hook.1.pod: lxc-pve-poststop-hook |
37 | perl -I. -T ./lxc-pve-poststop-hook printmanpod >$@ | |
38 | ||
f76a2828 | 39 | .PHONY: install |
32e6d659 | 40 | install: pct lxc-pve.conf lxc-pve-mount-hook lxc-pve-poststop-hook lxcnetaddbr lxc-pve-mount-hook.1.pod lxc-pve-mount-hook.1.gz lxc-pve-poststop-hook.1.pod lxc-pve-poststop-hook.1.gz pct.1.pod pct.1.gz pct.conf.5.pod pct.conf.5.gz pve-update-lxc-config |
f76a2828 | 41 | perl -T -I. ./pct verifyapi |
f76a2828 DM |
42 | install -d ${SBINDIR} |
43 | install -m 0755 pct ${SBINDIR} | |
4968d0f7 | 44 | install -m 0755 pve-update-lxc-config ${SBINDIR} |
bf9f492f DM |
45 | install -d ${LXC_SCRIPT_DIR} |
46 | install -m 0755 lxcnetaddbr ${LXC_SCRIPT_DIR} | |
47 | install -d ${LXC_HOOK_DIR} | |
48 | install -m 0755 lxc-pve-mount-hook ${LXC_HOOK_DIR} | |
32e6d659 | 49 | install -m 0755 lxc-pve-poststop-hook ${LXC_HOOK_DIR} |
bf9f492f DM |
50 | install -d ${LXC_COMMON_CONFIG_DIR} |
51 | install -m 0644 lxc-pve.conf ${LXC_COMMON_CONFIG_DIR}/01-pve.conf | |
f76a2828 DM |
52 | make -C PVE install |
53 | install -d ${MAN1DIR} | |
81bee809 | 54 | install -d ${MAN5DIR} |
f76a2828 DM |
55 | install -d ${PODDIR} |
56 | install -m 0644 pct.1.gz ${MAN1DIR} | |
f76a2828 | 57 | install -m 0644 pct.1.pod ${PODDIR} |
81bee809 DM |
58 | install -m 0644 pct.conf.5.pod ${PODDIR} |
59 | install -m 0644 pct.conf.5.gz ${MAN5DIR} | |
f76a2828 | 60 | |
1e180f97 DM |
61 | .PHONY: test |
62 | test: | |
63 | make -C test test | |
64 | ||
f76a2828 DM |
65 | .PHONY: clean |
66 | clean: | |
1e180f97 | 67 | make -C test clean |
f76a2828 DM |
68 | rm -rf *.1.pod *.1.gz |
69 | find . -name '*~' -exec rm {} ';' | |
70 | ||
71 | .PHONY: distclean | |
72 | distclean: clean | |
73 |