Gentoo Archives: gentoo-commits

From: Lars Wendler <polynomial-c@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-arch/unrar/
Date: Mon, 29 Jun 2020 14:27:11
Message-Id: 1593440805.878436e264d856317f7ba79832be8ca9e9d3b242.polynomial-c@gentoo
1 commit: 878436e264d856317f7ba79832be8ca9e9d3b242
2 Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jun 29 14:26:45 2020 +0000
4 Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
5 CommitDate: Mon Jun 29 14:26:45 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=878436e2
7
8 app-arch/unrar: Bump to version 5.9.4
9
10 Package-Manager: Portage-2.3.103, Repoman-2.3.23
11 Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
12
13 app-arch/unrar/Manifest | 1 +
14 app-arch/unrar/unrar-5.9.4.ebuild | 70 +++++++++++++++++++++++++++++++++++++++
15 2 files changed, 71 insertions(+)
16
17 diff --git a/app-arch/unrar/Manifest b/app-arch/unrar/Manifest
18 index 072a840adf0..57e0194c4ab 100644
19 --- a/app-arch/unrar/Manifest
20 +++ b/app-arch/unrar/Manifest
21 @@ -1,2 +1,3 @@
22 DIST unrar-5.9.2.tar.gz 229900 BLAKE2B a941ef6566a5b58990d88e6e99cc23c169fd7d99fe2c8ef1313db860f9f220510ea002990740c4b3a3f980c037f9b3be4cdad84624a9a6f5094b1074721800d4 SHA512 e48dd3327d57522aa676e8fd6e29b7133ee9921eb1525d90ddedc61716ecfeefb51a7eb3a667f4f81f21a5ce8654727617d33463a5b6a40a7bc32252fa9f25df
23 DIST unrar-5.9.3.tar.gz 229917 BLAKE2B 6ab2141970535753197d3ed74521f80d3b20ecc2a0f620932c31bd1b5ce4c70bc3e2671fed0a9a77ceb4f42f6423d315f3eac0a00dac334ee2c3dd60a569c78a SHA512 38b2e2e527a4d2df627072acb4c205f46c96771969db4558be04adf9166502b3b9c3d1cc60fe290b6c4ce56db68bb5e0b0ac3bf0698d9820d4840d56cc5f3e2f
24 +DIST unrar-5.9.4.tar.gz 229921 BLAKE2B d87189a6b6b3566a0efac7f72e40732ff673cdcac6f4fdaa96b5a771025f02779d74e2822053681477b3490f45817196673aa5707846767c4061ca95718557a1 SHA512 4c026bc12c38314c7df6e1b2f296be681fffa4ba525e378809063519cb5d51889fe8d3cbce16e802023354f02b45b1bcc672b79a6fa81b4baa13a374ce22c8f1
25
26 diff --git a/app-arch/unrar/unrar-5.9.4.ebuild b/app-arch/unrar/unrar-5.9.4.ebuild
27 new file mode 100644
28 index 00000000000..7a4b90b3f3b
29 --- /dev/null
30 +++ b/app-arch/unrar/unrar-5.9.4.ebuild
31 @@ -0,0 +1,70 @@
32 +# Copyright 1999-2020 Gentoo Authors
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI=7
36 +
37 +inherit flag-o-matic multilib toolchain-funcs
38 +
39 +MY_PN="${PN}src"
40 +
41 +DESCRIPTION="Uncompress rar files"
42 +HOMEPAGE="https://www.rarlab.com/rar_add.htm"
43 +SRC_URI="https://www.rarlab.com/rar/${MY_PN}-${PV}.tar.gz -> ${P}.tar.gz"
44 +
45 +LICENSE="unRAR"
46 +# subslot = soname version
47 +SLOT="0/5"
48 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris"
49 +IUSE=""
50 +
51 +RDEPEND="!<=app-arch/unrar-gpl-0.0.1_p20080417"
52 +
53 +S="${WORKDIR}/unrar"
54 +
55 +PATCHES=(
56 + "${FILESDIR}"/${PN}-5.9.3-build.patch
57 + "${FILESDIR}"/${PN}-5.5.5-honor-flags.patch
58 +)
59 +
60 +src_prepare() {
61 + default
62 +
63 + local sed_args=( -e "/libunrar/s:.so:$(get_libname ${PV%.*.*}):" )
64 + if [[ ${CHOST} == *-darwin* ]] ; then
65 + sed_args+=( -e "s:-shared:-dynamiclib -install_name ${EPREFIX}/usr/$(get_libdir)/libunrar$(get_libname ${PV%.*.*}):" )
66 + else
67 + sed_args+=( -e "s:-shared:& -Wl,-soname -Wl,libunrar$(get_libname ${PV%.*.*}):" )
68 + fi
69 + sed -i "${sed_args[@]}" makefile || die
70 +}
71 +
72 +src_configure() {
73 + mkdir -p build-{lib,bin}
74 + printf 'VPATH = ..\ninclude ../makefile' > build-lib/Makefile || die
75 + cp build-{lib,bin}/Makefile || die
76 +}
77 +
78 +src_compile() {
79 + unrar_make() {
80 + emake AR="$(tc-getAR)" CXX="$(tc-getCXX)" CXXFLAGS="${CXXFLAGS}" STRIP=true "$@"
81 + }
82 +
83 + unrar_make CXXFLAGS+=" -fPIC" -C build-lib lib
84 + ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname) || die
85 + ln -s libunrar$(get_libname ${PV%.*.*}) build-lib/libunrar$(get_libname ${PV}) || die
86 +
87 + unrar_make -C build-bin
88 +}
89 +
90 +src_install() {
91 + dobin build-bin/unrar
92 + dodoc readme.txt
93 +
94 + dolib.so build-lib/libunrar*
95 +
96 + insinto /usr/include/libunrar${PV%.*.*}
97 + doins *.hpp
98 + dosym libunrar${PV%.*.*} /usr/include/libunrar
99 +
100 + find "${ED}" -type f -name "*.a" -delete || die
101 +}