Contents of /smage/trunk/extras/drbd-utils/drbd-utils-9.10.0-r3.smage2
Parent Directory | Revision Log
Revision 13714 -
(show annotations)
(download)
Wed Jul 31 11:42:57 2019 UTC (5 years, 1 month ago) by niro
File size: 2194 byte(s)
Wed Jul 31 11:42:57 2019 UTC (5 years, 1 month ago) by niro
File size: 2194 byte(s)
-added conf_prot_ignore
1 | # $Id$ |
2 | |
3 | PNAME="drbd-utils" |
4 | PVER="9.10.0" |
5 | PBUILD="r3" |
6 | |
7 | PCAT="sys-fs" |
8 | |
9 | DESCRIPTION="Userland tools for Distributed Replicated Block Device." |
10 | HOMEPAGE="https://www.drbd.org/" |
11 | |
12 | DEPEND=">= app-shells/bash-4 |
13 | >= dev-lang/perl-5" |
14 | |
15 | SDEPEND=">= dev-libs/libxslt-1.1 |
16 | >= app-text/docbook-xsl-stylesheets-1.76 |
17 | >= virtual/sed |
18 | >= dev-libs/libxslt-dev-1.1" |
19 | |
20 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
21 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
22 | |
23 | ALX_PKG_KEEP="etc |
24 | usr/$(mlibdir)/drbd |
25 | usr/lib/systemd |
26 | usr/lib/tmpfiles.d |
27 | usr/lib/udev |
28 | usr/sbin |
29 | var/lib/drbd" |
30 | sminclude udev systemd alx-split |
31 | |
32 | SRC_URI=( |
33 | https://www.linbit.com/downloads/drbd/utils/${SRCFILE} |
34 | mirror://${PNAME}/${SRCFILE} |
35 | ) |
36 | |
37 | UP2DATE="updatecmd https://www.linbit.com/downloads/drbd/utils/ | highesttarball gz" |
38 | |
39 | src_prepare() |
40 | { |
41 | munpack ${SRCFILE} || die |
42 | cd ${SRCDIR} |
43 | |
44 | # from gentoo: respect multilib |
45 | sed -i -e "s:/lib/:/$(mlibdir)/:g" Makefile.in scripts/Makefile.in scripts/global_common.conf scripts/drbd.conf.example || die |
46 | sed -e "s:@prefix@/lib:@prefix@/$(mlibdir):" -e "s:(DESTDIR)/lib:(DESTDIR)/$(mlibdir):" -i user/*/Makefile.in || die |
47 | |
48 | # from gentoo: disable the survey participation |
49 | sed -i '/usage-count/ s/yes/no/' scripts/global_common.conf || die |
50 | |
51 | mautoreconf || die |
52 | } |
53 | |
54 | src_compile() |
55 | { |
56 | cd ${SRCDIR} |
57 | |
58 | mconfigure \ |
59 | --localstatedir=/var \ |
60 | --with-distro=generic \ |
61 | --without-bashcompletion \ |
62 | --with-initscripttype=systemd \ |
63 | --with-systemdunitdir=$(mget-systemd-unit-dir) \ |
64 | --with-tmpfilesdir=$(mget-systemd-tmpfilesdir) \ |
65 | --with-udev \ |
66 | --without-rgmanager \ |
67 | --without-pacemaker \ |
68 | --without-heartbeat \ |
69 | --without-83support \ |
70 | --without-xen \ |
71 | --with-prebuiltman \ |
72 | || die |
73 | |
74 | mmake || die |
75 | } |
76 | |
77 | alx_generic_src_install() |
78 | { |
79 | cd ${SRCDIR} |
80 | |
81 | mmake DESTDIR=${BINDIR} install || die |
82 | |
83 | # move hardcoded lib |
84 | mv ${BINDIR}/$(mlibdir)/drbd/* ${BINDIR}/usr/$(mlibdir)/drbd/ || die |
85 | rm -r ${BINDIR}/$(mlibdir) || die |
86 | |
87 | # remove runtime created dirs |
88 | rm -r ${BINDIR}/var/lock || die |
89 | rm -r ${BINDIR}/var/run || die |
90 | |
91 | minstalldocs COPYING ChangeLog README* scripts/drbd.conf.example || die |
92 | } |
93 | |
94 | preinstall_drbd-utils() |
95 | { |
96 | # always keep this files even if the user edited them |
97 | add_conf_prot_ignore /etc/drbd.d/global_common.conf |
98 | } |