blob: a0fd6aa0e5f12675b7c92706daf4f0f2dae475eb (
plain)
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="5"
inherit autotools epatch
DESCRIPTION="Serviceability for SCSI Disks and Arrays"
HOMEPAGE="http://scsirastools.sourceforge.net/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE=""
RDEPEND=">=sys-apps/sg3_utils-1.44"
DEPEND="${RDEPEND}"
src_prepare() {
epatch "${FILESDIR}"/${PN}-1.5.7-sysmacros.patch #580214
# this builds a really old mdadm
sed -i \
-e '/RPMB/d' \
-e '/^SUBDIRS/s,mdadm.d,,' \
-e '/^SUBDIRS/s,files,,' \
Makefile.am || die "sed Makefile.am failed"
eautoreconf
# i386 ELF binaries in tarball = bad
rm "${S}"/files/ialarms* || die
# Fix up /sbin instances to be /usr/sbin instead
for i in src/sgraidmon.c src/sgdiskmon.c ; do
sed -i "${S}"/${i} \
-e '/evtcmd\[\].*\"\/sbin\//s,/sbin/,/usr/sbin/,' \
|| die "Failed to set /sbin in sources"
done
}
src_configure() {
econf --sbindir=/usr/sbin
}
src_install() {
local docdir="/usr/share/doc/${PF}"
emake install DESTDIR="${D}" datato="${ED}${docdir}"
dosbin files/sgevt files/mdevt
rm -f "${ED}${docdir}"/{SCSIRAS,COPYING}
# install modepage files
insinto /usr/share/${PN}
doins files/*.mdf
dodoc ChangeLog AUTHORS TODO
}
|