Skip to content

Commit

Permalink
app-arch/unrar: bump to v5.6.8
Browse files Browse the repository at this point in the history
Package-Manager: Portage-2.3.50, Repoman-2.3.11
Signed-off-by: Thomas Deutschmann <[email protected]>
  • Loading branch information
Whissi committed Oct 12, 2018
1 parent c16b803 commit 38065ce
Show file tree
Hide file tree
Showing 2 changed files with 69 additions and 0 deletions.
1 change: 1 addition & 0 deletions app-arch/unrar/Manifest
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@ DIST unrar-5.5.8.tar.gz 222285 BLAKE2B ec6317fc95674a3f282f92762ee89d2fd21d162a9
DIST unrar-5.6.5.tar.gz 226296 BLAKE2B c35dfdc10976ee2a7827f9386021f79af6712ae3a6641e83934ef7223e1202c46c59e12d2b78abe230c3f929f2228fe8c0664f05275b905ea06806a02cd685aa SHA512 984340935671913b4d2a765db5c4edc0d08d859fc43f3ae0e97e681c4ea302a51808fefa8c11c3aeecad1c2681541f363c5051813d978b5b14959c2e55f71281
DIST unrar-5.6.6.tar.gz 226484 BLAKE2B f5facddd5c326c039c02b31ac28ba86d5417a51d00a463da1c6fbb714856ffb275defbe400a0d56a21850c754f06eda615fcab983a206f335422503d76f11427 SHA512 1e1e9dc2ed104ab7819d11ad2249780a4320cb30f3c427ea1669c3769fa3a8369841711a2d46d918049659bc67b2cd7dc7560a12127d810a57614293c24fe25a
DIST unrar-5.6.7.tar.gz 226579 BLAKE2B 32b6e70539e4ba0a09bac5eaf880ce555a1012516ba6f439060e6604b5274b17e3f5c8dfa721999243eda64fa9b1b53eda95f7b9df11320ade1873bf665ee3c0 SHA512 2c102fdc2f1a924a57c5492b966b0e1d0035bc3de2a78a46733f300d412ff9983fc5c717856faeb21e71c4bd090296e57e5b87888190867eb3c41f62550647e9
DIST unrar-5.6.8.tar.gz 226647 BLAKE2B a3f4f791d2527d13003b7d57506e61723312bb0537066c72fa5ea27e4e9de18644f5445b69e9f66ec479402f6d944ce76b17ad9192b3f835ff9781f0902e03c9 SHA512 5410308d7f462824bc10087cdc4515c58aaad776cc09eb6491864a338ae00ff35e3b54d1e7250c0a9576554ea382383155be718a0b95d7af00f27d5df04f4f56
68 changes: 68 additions & 0 deletions app-arch/unrar/unrar-5.6.8.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI="6"

inherit flag-o-matic multilib toolchain-funcs

MY_PN="${PN}src"

DESCRIPTION="Uncompress rar files"
HOMEPAGE="https://www.rarlab.com/rar_add.htm"
SRC_URI="https://www.rarlab.com/rar/${MY_PN}-${PV}.tar.gz -> ${P}.tar.gz"

LICENSE="unRAR"
# subslot = soname version
SLOT="0/5"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
IUSE=""

RDEPEND="!<=app-arch/unrar-gpl-0.0.1_p20080417"

S=${WORKDIR}/unrar

PATCHES=(
"${FILESDIR}"/${PN}-5.5.5-build.patch
"${FILESDIR}"/${PN}-5.5.5-honor-flags.patch
)

src_prepare() {
default

local sed_args=( -e "/libunrar/s:.so:$(get_libname ${PV%.*.*}):" )
if [[ ${CHOST} == *-darwin* ]] ; then
sed_args+=( -e "s:-shared:-dynamiclib -install_name ${EPREFIX}/usr/$(get_libdir)/libunrar$(get_libname ${PV%.*.*}):" )
else
sed_args+=( -e "s:-shared:& -Wl,-soname -Wl,libunrar$(get_libname ${PV%.*.*}):" )
fi
sed -i "${sed_args[@]}" makefile || die
}

src_configure() {
mkdir -p build-{lib,bin}
printf 'VPATH = ..\ninclude ../makefile' > build-lib/Makefile || die
cp build-{lib,bin}/Makefile || die
}

src_compile() {
unrar_make() {
emake CXX="$(tc-getCXX)" CXXFLAGS="${CXXFLAGS}" STRIP=true "$@"
}

unrar_make CXXFLAGS+=" -fPIC" -C build-lib lib
ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname) || die
ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname ${PV}) || die

unrar_make -C build-bin
}

src_install() {
dobin build-bin/unrar
dodoc readme.txt

dolib.so build-lib/libunrar*

insinto /usr/include/libunrar${PV%.*.*}
doins *.hpp
dosym libunrar${PV%.*.*} /usr/include/libunrar
}

0 comments on commit 38065ce

Please sign in to comment.