Contents of /smage/trunk/extras/drbd-utils/drbd-utils-9.25.0-r1.smage2
Parent Directory | Revision Log
Revision 17146 -
(show annotations)
(download)
Tue Oct 24 11:09:39 2023 UTC (7 months, 1 week ago) by niro
File size: 2478 byte(s)
Tue Oct 24 11:09:39 2023 UTC (7 months, 1 week ago) by niro
File size: 2478 byte(s)
-ver bump 9.25.0-r1
1 | # $Id$ |
2 | |
3 | PNAME="drbd-utils" |
4 | PVER="9.25.0" |
5 | PBUILD="r1" |
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://pkg.linbit.com//downloads/drbd/utils/${SRCFILE} |
34 | mirror://${PNAME}/${SRCFILE} |
35 | mirror://${PNAME}/${PNAME}-${PVER}-fix-missing-includes.patch |
36 | ) |
37 | |
38 | UP2SEPERATOR="v" |
39 | UP2DATE="updatecmd https://github.com/LINBIT/drbd-utils/tags | grep -v -- '-rc' | highesttarball gz" |
40 | |
41 | src_prepare() |
42 | { |
43 | munpack ${SRCFILE} || die |
44 | cd ${SRCDIR} |
45 | |
46 | # upstream: fix missing includes |
47 | # see: https://github.com/LINBIT/drbd-utils/commit/feebd378195cf18b06f9fa209586af0c6d32ddb8 |
48 | mpatch ${PNAME}-${PVER}-fix-missing-includes.patch || die |
49 | |
50 | # from gentoo: respect multilib |
51 | sed -i -e "s:/lib/:/$(mlibdir)/:g" Makefile.in scripts/Makefile.in scripts/global_common.conf scripts/drbd.conf.example || die |
52 | sed -e "s:@prefix@/lib:@prefix@/$(mlibdir):" -e "s:(DESTDIR)/lib:(DESTDIR)/$(mlibdir):" -i user/*/Makefile.in || die |
53 | |
54 | # from gentoo: disable the survey participation |
55 | sed -i '/usage-count/ s/yes/no/' scripts/global_common.conf || die |
56 | |
57 | mautoreconf || die |
58 | } |
59 | |
60 | src_compile() |
61 | { |
62 | cd ${SRCDIR} |
63 | |
64 | mconfigure \ |
65 | --localstatedir=/var \ |
66 | --with-distro=generic \ |
67 | --without-bashcompletion \ |
68 | --with-initscripttype=systemd \ |
69 | --with-systemdunitdir=$(mget-systemd-unit-dir) \ |
70 | --with-tmpfilesdir=$(mget-systemd-tmpfilesdir) \ |
71 | --with-udev \ |
72 | --without-rgmanager \ |
73 | --without-pacemaker \ |
74 | --without-heartbeat \ |
75 | --without-83support \ |
76 | --without-xen \ |
77 | --with-prebuiltman \ |
78 | || die |
79 | |
80 | mmake || die |
81 | } |
82 | |
83 | alx_generic_src_install() |
84 | { |
85 | cd ${SRCDIR} |
86 | |
87 | mmake DESTDIR=${BINDIR} install || die |
88 | |
89 | # move hardcoded lib |
90 | mv ${BINDIR}/$(mlibdir)/drbd/* ${BINDIR}/usr/$(mlibdir)/drbd/ || die |
91 | rm -r ${BINDIR}/$(mlibdir) || die |
92 | |
93 | # remove runtime created dirs |
94 | rm -r ${BINDIR}/var/lock || die |
95 | rm -r ${BINDIR}/var/run || die |
96 | |
97 | minstalldocs COPYING ChangeLog README* scripts/drbd.conf.example || die |
98 | } |
99 | |
100 | preinstall_drbd-utils() |
101 | { |
102 | # always keep this files even if the user edited them |
103 | add_conf_prot_ignore /etc/drbd.d/global_common.conf |
104 | } |