sys-block/storcli: Bump to v007.0504.0000.0000
authorThomas Deutschmann <whissi@gentoo.org>
Sat, 26 May 2018 18:55:46 +0000 (20:55 +0200)
committerThomas Deutschmann <whissi@gentoo.org>
Sat, 26 May 2018 18:56:02 +0000 (20:56 +0200)
Package-Manager: Portage-2.3.40, Repoman-2.3.9

sys-block/storcli/Manifest
sys-block/storcli/storcli-7.0504.ebuild [new file with mode: 0644]

index 56b7d988f3b060b9defc4733e0dd06319e97a1b6..312a67d834be21b9df9dca473a4ed58b8aa0c148 100644 (file)
@@ -4,3 +4,4 @@ DIST storcli-1.21.06.zip 48578520 BLAKE2B e7bdfacbe7eba21b314a7aa4a61224c3363c95
 DIST storcli-1.21.06_readme.txt 199925 BLAKE2B 08b7ddc9d6a0ee176e91938d00ef12b39c764d0248f82d0d037050058088ea20f0356a7efc4d9de50c57fa685b32036d18c1eb8dcf4e7ffb85cd0b02b21c8abb SHA512 78524212b5d95bd62ef692bb715f6ae977811fd5522498915a4dbbd74a5d783d176fe318c0a0b7aad1b23419c78d205267f19b55790519dcc6d7e1d873498bad
 DIST storcli-1.23.02.zip 48778476 BLAKE2B 9eded7793e822785dfbd15b6a6fa70e70dc1f4e32df9e6e1e213420a4e6ae01705096ce8f0ea468a6dc8d5d22097c87e06e54be6fcccb9eaf6cc321c26b69b0a SHA512 2018c8b40d7371077f01bbe586ed1135d683823b9d243fde14d45404c8bab8328f36e19ac91eb876666a174a7cce7e95a2a75485f70681460cda4c9b65d4d579
 DIST storcli-1.23.02_readme.txt 201906 BLAKE2B 6dde1f7609d51f3d0b2feec9301a57472e92086fc7f1aecad3b455b03b571fb75e23de75d508c40b78ebab357340d8c14f5529fce3ce9ee6b513f5e80d82ad99 SHA512 9eefe69aee1a65339d2360759ba574f632a21bd3d13ba9d4cb0a86980e652addf5f7d2b650588f659caaa8ee302c48bc27b9f3ad7455e65d34dbcff0a8188e03
+DIST storcli-7.0504.zip 40558670 BLAKE2B 3cd54b47b42e5bb8329ccd4b09a6c0863347a04b276fa5dc11acf10ac1124c25b5f60e4171de96c1b8975bfae4cc7408554de933ba8fd5547fbd6e9395710ce8 SHA512 1c5c248a1c19eda5974415a7e1cc10c83bfad0d6e37adbd01ae624316fc1d60628503655c4dd0005a14c79c570177664ea9cdb7330b97daf19808a9513b1311a
diff --git a/sys-block/storcli/storcli-7.0504.ebuild b/sys-block/storcli/storcli-7.0504.ebuild
new file mode 100644 (file)
index 0000000..8201ffd
--- /dev/null
@@ -0,0 +1,77 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+
+inherit pax-utils
+
+# Upstream is still using strange version numbers
+MY_PV="007.0504.0000.0000"
+
+DESCRIPTION="MegaRAID StorCLI (successor of the MegaCLI)"
+HOMEPAGE="https://www.broadcom.com/support/download-search?dk=storcli"
+SRC_URI="https://docs.broadcom.com/docs-and-downloads/docs-and-downloads/raid-controllers/raid-controllers-common-files/${MY_PV}_Unified_StorCLI.zip -> ${P}.zip"
+
+LICENSE="Avago LSI BSD"
+SLOT="0/7.5"
+KEYWORDS="-* ~amd64 ~x86"
+IUSE=""
+
+RDEPEND=""
+DEPEND=""
+
+DOCS=( readme.txt license.txt )
+
+MY_STORCLI_BASEDIR="/opt/lsi/storcli"
+
+QA_PRESTRIPPED="${MY_STORCLI_BASEDIR:1}/storcli"
+
+src_unpack() {
+       local _src_file
+
+       for _src_file in ${A}; do
+               if [[ ${_src_file} == *.txt ]]; then
+                       cp "${DISTDIR}/${_src_file}" "${WORKDIR}" || die "Failed to copy '${_src_file}' to '${WORKDIR}'!"
+               else
+                       unpack ${_src_file}
+               fi
+       done
+
+       unpack "${WORKDIR}"/Unified_storcli_all_os.zip
+
+       mv Unified_storcli_all_os/Ubuntu/storcli_*.deb "${WORKDIR}" || die "Failed to move storcli_*.deb"
+
+       # Unpack Ubuntu package which will be our $S content
+       unpack "${WORKDIR}"/storcli_*.deb
+       rm -f storcli_*.deb || die "Failed to cleanup storcli_*.deb package"
+       unpack "${WORKDIR}"/data.tar.gz
+
+       mkdir "${S}" || die "Failed to create '${S}'"
+}
+
+src_prepare() {
+       default
+
+       # Create clean $S
+       mv "${WORKDIR}"/*_StorCLI.txt "${S}"/readme.txt || die "Failed to move *StorCLI.txt to readme.txt"
+       mv "${WORKDIR}"/Unified_storcli_all_os/Linux/license.txt "${S}"/license.txt || die "Failed to move Linux/license.txt"
+       rm -rf "${WORKDIR}"/Unified_stor* || die "Failed to cleanup Unified_storcli* dirs/files"
+       mv "${WORKDIR}"/opt/Mega*/storcli/* "${S}" || die "Failed to move storcli_.deb content to '${S}'"
+       rm -rf "${WORKDIR}"/{opt,control.tar.gz,data.tar.gz,debian-binary} || die "Failed to cleanup no longer needed files"
+}
+
+src_install() {
+       exeinto "${MY_STORCLI_BASEDIR}"
+
+       if use x86; then
+               doexe storcli
+       elif use amd64; then
+               newexe storcli64 storcli
+       fi
+
+       dosym "${MY_STORCLI_BASEDIR}"/storcli /usr/sbin/storcli
+
+       dodoc "${DOCS[@]}"
+
+       pax-mark m "${D%/}${MY_STORCLI_BASEDIR}"/storcli
+}