Gentoo Archives: gentoo-commits

From: Thomas Beierlein <tomjbe@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/hamlib/
Date: Sat, 18 Sep 2021 14:51:36
Message-Id: 1631976684.99564dc2827a0d81627edb88dd68306391ce06c4.tomjbe@gentoo
1 commit: 99564dc2827a0d81627edb88dd68306391ce06c4
2 Author: Thomas Beierlein <tomjbe <AT> gentoo <DOT> org>
3 AuthorDate: Sat Sep 18 14:51:24 2021 +0000
4 Commit: Thomas Beierlein <tomjbe <AT> gentoo <DOT> org>
5 CommitDate: Sat Sep 18 14:51:24 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=99564dc2
7
8 media-libs/hamlib: Version bump
9
10 * Bump to EAPI8
11 * Fix HOMEPAGE (https:// is not supported)
12
13 Package-Manager: Portage-3.0.23, Repoman-3.0.3
14 Signed-off-by: Thomas Beierlein <tomjbe <AT> gentoo.org>
15
16 media-libs/hamlib/Manifest | 1 +
17 media-libs/hamlib/hamlib-4.3.1.ebuild | 94 +++++++++++++++++++++++++++++++++++
18 2 files changed, 95 insertions(+)
19
20 diff --git a/media-libs/hamlib/Manifest b/media-libs/hamlib/Manifest
21 index feb6931a589..625133f7cba 100644
22 --- a/media-libs/hamlib/Manifest
23 +++ b/media-libs/hamlib/Manifest
24 @@ -1 +1,2 @@
25 DIST hamlib-4.2.tar.gz 2311775 BLAKE2B 4fe8d3e6d489369aede1a4cd59f01be44a7787ca71c21c5b92d436666c67de68013f488834d0f57238e6a947c24cd5b4c6c667397dec30392f1cccd695df252e SHA512 08ccf4e592fbae938ae1aaa5afede7e2e6ec7d23b449a65b00e093502f4aeb36930624f055d9802349f77df9dd2b7b983aa44d83f8c62a6de5789e7df627f804
26 +DIST hamlib-4.3.1.tar.gz 2356944 BLAKE2B c803d253c867303cbde98b6f2e10f610aac111b7bd81fd343e1396cb86384b1c26942e5ccb8e395e073f9aa3d48e6f9edc1b64da14b2ec5ca09f98fbd3dee667 SHA512 8dee4676a19de7ac1ef733a4285b76e918f11aad6594d0557d36df295faf04c615e0993edb2f9ed5e7aea718c184603fec831caf28b75026c705f0b2e4b9eca7
27
28 diff --git a/media-libs/hamlib/hamlib-4.3.1.ebuild b/media-libs/hamlib/hamlib-4.3.1.ebuild
29 new file mode 100644
30 index 00000000000..f7d9f12e8a3
31 --- /dev/null
32 +++ b/media-libs/hamlib/hamlib-4.3.1.ebuild
33 @@ -0,0 +1,94 @@
34 +# Copyright 1999-2021 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=8
38 +
39 +PYTHON_COMPAT=( python3_{7..10} )
40 +MY_P=${P/_rc2/~rc2}
41 +
42 +inherit autotools python-single-r1
43 +
44 +DESCRIPTION="Ham radio backend rig control libraries"
45 +HOMEPAGE="http://www.hamlib.org"
46 +SRC_URI="mirror://sourceforge/hamlib/${MY_P}.tar.gz"
47 +
48 +LICENSE="LGPL-2 GPL-2"
49 +SLOT="0/4.2"
50 +KEYWORDS="~amd64 ~x86"
51 +IUSE="doc perl python tcl"
52 +
53 +RESTRICT="test"
54 +
55 +RDEPEND="
56 + =virtual/libusb-0*
57 + dev-libs/libxml2
58 + sys-libs/readline:0=
59 + perl? ( dev-lang/perl )
60 + python? ( ${PYTHON_DEPS} )
61 + tcl? ( dev-lang/tcl:0= )"
62 +
63 +DEPEND=" ${RDEPEND}
64 + virtual/pkgconfig
65 + dev-lang/swig
66 + >=sys-devel/libtool-2.2
67 + doc? ( app-doc/doxygen )"
68 +
69 +REQUIRED_USE="${PYTHON_REQUIRED_USE}"
70 +
71 +DOCS=(AUTHORS NEWS PLAN README README.betatester README.developer)
72 +
73 +S="${WORKDIR}/${MY_P}"
74 +
75 +pkg_setup() {
76 + use python && python-single-r1_pkg_setup
77 +}
78 +
79 +src_prepare() {
80 + # fix hardcoded libdir paths
81 + sed -i -e "s#fix}/lib#fix}/$(get_libdir)/hamlib#" \
82 + -e "s#fix}/include#fix}/include/hamlib#" \
83 + hamlib.pc.in || die "sed failed"
84 +
85 + # Correct install target to whatever INSTALLDIRS says and use vendor
86 + # installdirs everywhere (bug #611550)
87 + sed -i -e "s#install_site#install#" \
88 + -e 's#MAKEFILE="Hamlib-pl.mk"#MAKEFILE="Hamlib-pl.mk" INSTALLDIRS=vendor#' \
89 + bindings/Makefile.am || die "sed failed patching for perl"
90 +
91 + # make building of documentation compatible with autotools-utils
92 + sed -i -e "s/doc:/html:/g" doc/Makefile.am || die "sed failed"
93 +
94 + eautoreconf
95 +
96 + eapply_user
97 +}
98 +
99 +src_configure() {
100 + econf \
101 + --libdir=/usr/$(get_libdir)/hamlib \
102 + --disable-static \
103 + --with-xml-support \
104 + $(use_with perl perl-binding) \
105 + $(use_with python python-binding) \
106 + $(use_with tcl tcl-binding)
107 +}
108 +
109 +src_compile() {
110 + emake
111 + use doc && emake html
112 +}
113 +
114 +src_install() {
115 + emake DESTDIR="${D}" install
116 +
117 + use python && python_optimize
118 +
119 + use doc && HTML_DOCS=( doc/html/ )
120 + einstalldocs
121 +
122 + insinto /usr/$(get_libdir)/pkgconfig
123 + doins hamlib.pc
124 +
125 + echo "LDPATH=/usr/$(get_libdir)/hamlib" > "${T}"/73hamlib
126 + doenvd "${T}"/73hamlib
127 +}