1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
7 MY_P=${PV}_MegaCLI_Linux
9 DESCRIPTION="LSI Logic MegaRAID Command Line Interface management tool"
10 HOMEPAGE="http://www.lsi.com/"
11 SRC_URI="http://www.lsi.com/downloads/Public/RAID%20Controllers/RAID%20Controllers%20Common%20Files/${MY_P}.zip"
15 # This package can never enter stable, it can't be mirrored and upstream
16 # can remove the distfiles from their mirror anytime.
20 DEPEND="app-arch/unzip
22 RDEPEND="sys-libs/ncurses-compat:5"
26 RESTRICT="mirror fetch"
27 QA_PREBUILT="/opt/${PN}/${PN}
31 einfo "Upstream has implement a mandatory clickthrough EULA for distfile download"
32 einfo "Please visit $SRC_URI"
33 einfo "And place $A into your DISTDIR directory"
39 rpm_unpack ./"Linux MegaCLI ${PV}"/MegaCli-${PV}-1.noarch.rpm
43 newdoc "Linux MegaCLI ${PV}.txt" RELEASE.txt
46 libsysfs=libstorelibir-2.so.14.07-0
48 amd64) MegaCli=MegaCli64;;
49 x86) MegaCli=MegaCli;;
50 *) die "invalid ARCH";;
52 newexe opt/MegaRAID/MegaCli/${MegaCli} ${PN}
54 exeinto /opt/${PN}/lib
55 doexe opt/MegaRAID/MegaCli/${libsysfs}
58 newbin "${FILESDIR}"/${PN}-wrapper ${PN}
59 dosym ${PN} /opt/bin/MegaCli
62 chrpath -d "${D}"/opt/${PN}/${PN}
67 einfo "See /usr/share/doc/${PF}/RELEASE.txt for a list of supported controllers"
68 einfo "(contains LSI model names only, not those sold by 3rd parties"
69 einfo "under custom names like Dell PERC etc)."
71 einfo "As there's no dedicated manual, you might want to have"
72 einfo "a look at the following cheat sheet (originally written"
73 einfo "for Dell PowerEdge Expandable RAID Controllers):"
74 einfo "http://tools.rapidsoft.de/perc/perc-cheat-sheet.html"
76 einfo "For more information about working with Dell PERCs see:"
77 einfo "http://tools.rapidsoft.de/perc/"