Magellan Linux

Contents of /smage/trunk/extras/drbd-utils/drbd-utils-9.8.0-r2.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 12967 - (show annotations) (download)
Tue Mar 12 13:45:08 2019 UTC (5 years, 1 month ago) by niro
File size: 1808 byte(s)
auto added: ver bump to 9.8.0-r2
1 # $Id$
2
3 PNAME="drbd-utils"
4 PVER="9.8.0"
5 PBUILD="r2"
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 sminclude mbuild udev systemd
24
25 SRC_URI=(
26 mirror://${PNAME}/${SRCFILE}
27 https://www.linbit.com/downloads/drbd/utils/${SRCFILE}
28 )
29
30 UP2DATE="updatecmd https://www.linbit.com/downloads/drbd/utils/ | highesttarball gz"
31
32 src_prepare()
33 {
34 munpack ${SRCFILE} || die
35 cd ${SRCDIR}
36
37 # from gentoo: respect multilib
38 sed -i -e "s:/lib/:/$(mlibdir)/:g" Makefile.in scripts/Makefile.in scripts/global_common.conf scripts/drbd.conf.example || die
39 sed -e "s:@prefix@/lib:@prefix@/$(mlibdir):" -e "s:(DESTDIR)/lib:(DESTDIR)/$(mlibdir):" -i user/*/Makefile.in || die
40 mautoreconf || die
41 }
42
43 src_compile()
44 {
45 cd ${SRCDIR}
46
47 mconfigure \
48 --localstatedir=/var \
49 --with-distro=generic \
50 --without-bashcompletion \
51 --with-initscripttype=systemd \
52 --with-systemdunitdir=$(mget-systemd-unit-dir) \
53 --with-tmpfilesdir=$(mget-systemd-tmpfilesdir) \
54 --with-udev \
55 --without-rgmanager \
56 --without-pacemaker \
57 --without-heartbeat \
58 --without-83support \
59 --without-xen \
60 --with-prebuiltman \
61 || die
62
63 mmake || die
64 }
65
66 src_install()
67 {
68 cd ${SRCDIR}
69
70 mmake DESTDIR=${BINDIR} install || die
71
72 # move hardcoded lib
73 mv ${BINDIR}/$(mlibdir)/drbd/* ${BINDIR}/usr/$(mlibdir)/drbd/ || die
74 rm -r ${BINDIR}/$(mlibdir) || die
75
76 # remove runtime created dirs
77 rm -r ${BINDIR}/var/lock || die
78 rm -r ${BINDIR}/var/run || die
79
80 minstalldocs COPYING ChangeLog README* scripts/drbd.conf.example || die
81 }