summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRepository mirror & CI <repomirrorci@gentoo.org>2020-07-06 18:37:48 +0000
committerRepository mirror & CI <repomirrorci@gentoo.org>2020-07-06 18:37:48 +0000
commit4917214f077254cecd27bdc98edebafd68eb298f (patch)
tree282a7f1693068bdac6b624c2cbdd8b6ef8635976
parent2020-07-06 18:05:25 UTC (diff)
parentnet-libs/libnsl: Bump to version 1.3.0 (diff)
downloadgentoo-4917214f077254cecd27bdc98edebafd68eb298f.tar.gz
gentoo-4917214f077254cecd27bdc98edebafd68eb298f.tar.bz2
gentoo-4917214f077254cecd27bdc98edebafd68eb298f.zip
Merge updates from master
-rw-r--r--app-crypt/qca/Manifest1
-rw-r--r--app-crypt/qca/qca-2.3.1.ebuild84
-rw-r--r--dev-ruby/did_you_mean/did_you_mean-1.4.0.ebuild3
-rw-r--r--dev-ruby/net-sftp/files/net-sftp-2.1.2-net-ssh-4.patch42
-rw-r--r--eclass/ruby-fakegem.eclass6
-rw-r--r--net-libs/libnsl/Manifest1
-rw-r--r--net-libs/libnsl/libnsl-1.3.0.ebuild43
-rw-r--r--sci-electronics/pulseview/Manifest2
-rw-r--r--sci-electronics/pulseview/files/pulseview-0.4.2-qt-5.15.patch142
-rw-r--r--sci-electronics/pulseview/pulseview-0.4.2.ebuild (renamed from sci-electronics/pulseview/pulseview-0.4.1-r1.ebuild)43
-rw-r--r--sci-electronics/pulseview/pulseview-9999.ebuild41
-rw-r--r--sci-libs/libsigrok/Manifest2
-rw-r--r--sci-libs/libsigrok/files/libsigrok-0.5.2-ruby-swig-docs.patch63
-rw-r--r--sci-libs/libsigrok/files/libsigrok-0.5.2-swig-4.patch37
-rw-r--r--sci-libs/libsigrok/libsigrok-0.4.0.ebuild90
-rw-r--r--sci-libs/libsigrok/libsigrok-0.5.1.ebuild101
-rw-r--r--sci-libs/libsigrok/libsigrok-0.5.2.ebuild71
-rw-r--r--sci-libs/libsigrok/libsigrok-9999.ebuild64
-rw-r--r--sci-libs/libsigrokdecode/Manifest2
-rw-r--r--sci-libs/libsigrokdecode/libsigrokdecode-0.4.1.ebuild54
-rw-r--r--sci-libs/libsigrokdecode/libsigrokdecode-0.5.2.ebuild54
-rw-r--r--sci-libs/libsigrokdecode/libsigrokdecode-0.5.3.ebuild28
-rw-r--r--sci-libs/libsigrokdecode/libsigrokdecode-9999.ebuild28
-rw-r--r--sys-libs/libcap/Manifest1
-rw-r--r--sys-libs/libcap/files/libcap-2.37-build-system-fixes.patch3
-rw-r--r--sys-libs/libcap/files/libcap-2.38-no_perl.patch71
-rw-r--r--sys-libs/libcap/libcap-2.38.ebuild87
27 files changed, 708 insertions, 456 deletions
diff --git a/app-crypt/qca/Manifest b/app-crypt/qca/Manifest
index 73f8c879420b..df985aee2126 100644
--- a/app-crypt/qca/Manifest
+++ b/app-crypt/qca/Manifest
@@ -1 +1,2 @@
DIST qca-2.3.0.tar.xz 729504 BLAKE2B 71cf9dfae00066c14e1055da1fa1a8e1210f538b1addfde1b99a9b26b1e8f7dd61e289d0f505b5ec04d5f4745216d4fd0f8be8f8de9e9cbf74123907ba703d0e SHA512 ca9251868e073834562fa62ffc64b3e7817c9ddadc6bc3fb99cf8b5c8d859969562170a98874be9590c617b2dd8e5590d2c83792554f54bb880c677902db22fe
+DIST qca-2.3.1.tar.xz 725984 BLAKE2B a99121dd95822ef5e1057dc9ad9250bb14486f42b0571936453644bc7c5649f16cbc918fa04d4a5af2c62bc35cc672159a84e27a86e685cfe320518a42076052 SHA512 092704a8d7c5973f05c82584ea55b4f8f874965aea943277e50fde873913a9bdad6a51ea74fc0036bbb632a13141cb4c030504229c06779890286205929f6021
diff --git a/app-crypt/qca/qca-2.3.1.ebuild b/app-crypt/qca/qca-2.3.1.ebuild
new file mode 100644
index 000000000000..adf2da003f33
--- /dev/null
+++ b/app-crypt/qca/qca-2.3.1.ebuild
@@ -0,0 +1,84 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit kde.org cmake qmake-utils
+
+DESCRIPTION="Qt Cryptographic Architecture (QCA)"
+HOMEPAGE="https://userbase.kde.org/QCA"
+SRC_URI="mirror://kde/stable/${PN}/${PV}/${P}.tar.xz"
+
+LICENSE="LGPL-2.1"
+SLOT="2"
+KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris"
+IUSE="botan debug doc examples gcrypt gpg logger nss pkcs11 sasl softstore +ssl test"
+
+RESTRICT="!test? ( test )"
+
+BDEPEND="
+ doc? ( app-doc/doxygen )
+"
+RDEPEND="
+ dev-qt/qtcore:5
+ botan? ( dev-libs/botan:= )
+ gcrypt? ( dev-libs/libgcrypt:= )
+ gpg? ( app-crypt/gnupg )
+ nss? ( dev-libs/nss )
+ pkcs11? (
+ >=dev-libs/openssl-1.1
+ dev-libs/pkcs11-helper
+ )
+ sasl? ( dev-libs/cyrus-sasl:2 )
+ ssl? ( >=dev-libs/openssl-1.1:0= )
+"
+DEPEND="${RDEPEND}
+ test? (
+ dev-qt/qtnetwork:5
+ dev-qt/qttest:5
+ )
+"
+
+PATCHES=( "${FILESDIR}/${PN}-disable-pgp-test.patch" )
+
+qca_plugin_use() {
+ echo -DWITH_${2:-$1}_PLUGIN=$(usex "$1")
+}
+
+src_configure() {
+ local mycmakeargs=(
+ -DQCA_FEATURE_INSTALL_DIR="${EPREFIX}$(qt5_get_mkspecsdir)/features"
+ -DQCA_PLUGINS_INSTALL_DIR="${EPREFIX}$(qt5_get_plugindir)"
+ $(qca_plugin_use botan)
+ $(qca_plugin_use gcrypt)
+ $(qca_plugin_use gpg gnupg)
+ $(qca_plugin_use logger)
+ $(qca_plugin_use nss)
+ $(qca_plugin_use pkcs11)
+ $(qca_plugin_use sasl cyrus-sasl)
+ $(qca_plugin_use softstore)
+ $(qca_plugin_use ssl ossl)
+ -DBUILD_TESTS=$(usex test)
+ )
+ cmake_src_configure
+}
+
+src_test() {
+ local -x QCA_PLUGIN_PATH="${BUILD_DIR}/lib/qca"
+ cmake_src_test
+}
+
+src_install() {
+ cmake_src_install
+
+ if use doc; then
+ pushd "${BUILD_DIR}" >/dev/null || die
+ doxygen Doxyfile || die
+ dodoc -r apidocs/html
+ popd >/dev/null || die
+ fi
+
+ if use examples; then
+ dodoc -r "${S}"/examples
+ fi
+}
diff --git a/dev-ruby/did_you_mean/did_you_mean-1.4.0.ebuild b/dev-ruby/did_you_mean/did_you_mean-1.4.0.ebuild
index 37ef1514da15..aaf321bf8d8a 100644
--- a/dev-ruby/did_you_mean/did_you_mean-1.4.0.ebuild
+++ b/dev-ruby/did_you_mean/did_you_mean-1.4.0.ebuild
@@ -16,9 +16,6 @@ LICENSE="MIT"
SLOT="2.6"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE=""
-# Old dev-ruby/psych is removed from the tree, but must be uninstalled before
-# did_you_mean will build.
-DEPEND="${DEPEND} !!dev-ruby/psych"
all_ruby_prepare() {
sed -i -e '/bundler/ s:^:#:' Rakefile || die
diff --git a/dev-ruby/net-sftp/files/net-sftp-2.1.2-net-ssh-4.patch b/dev-ruby/net-sftp/files/net-sftp-2.1.2-net-ssh-4.patch
deleted file mode 100644
index d510153ba8d5..000000000000
--- a/dev-ruby/net-sftp/files/net-sftp-2.1.2-net-ssh-4.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 9870b32d31bbe5cddceead54c64f71e4fd91779e Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?V=C3=ADt=20Ondruch?= <vondruch@redhat.com>
-Date: Mon, 27 Feb 2017 15:00:30 +0100
-Subject: [PATCH] Fix compatiblity with net-ssh 4.0+
-
----
- test/test_download.rb | 4 +++-
- test/test_session.rb | 6 ++++--
- 2 files changed, 7 insertions(+), 3 deletions(-)
-
-diff --git a/test/test_download.rb b/test/test_download.rb
-index d4a5f0b..d9582b6 100644
---- a/test/test_download.rb
-+++ b/test/test_download.rb
-@@ -139,7 +139,9 @@ def test_download_file_should_transfer_remote_to_local_buffer
-
- def test_download_directory_to_buffer_should_fail
- expect_sftp_session :server_version => 3
-- assert_raises(ArgumentError) { sftp.download("/path/to/remote", StringIO.new, :recursive => true) }
-+ Net::SSH::Test::Extensions::IO.with_test_extension do
-+ assert_raises(ArgumentError) { sftp.download("/path/to/remote", StringIO.new, :recursive => true) }
-+ end
- end
-
- private
-diff --git a/test/test_session.rb b/test/test_session.rb
-index a59058a..c398436 100644
---- a/test/test_session.rb
-+++ b/test/test_session.rb
-@@ -660,8 +660,10 @@ def test_unblock_bang_should_block_and_return_response
-
- def assert_not_implemented(server_version, command, *args)
- expect_sftp_session :server_version => 1
-- sftp.connect!
-- assert_raises(NotImplementedError) { sftp.send(command, *args) }
-+ Net::SSH::Test::Extensions::IO.with_test_extension do
-+ sftp.connect!
-+ assert_raises(NotImplementedError) { sftp.send(command, *args) }
-+ end
- end
-
- def assert_command_with_callback(command, *args)
diff --git a/eclass/ruby-fakegem.eclass b/eclass/ruby-fakegem.eclass
index d0956082f816..8ab448765946 100644
--- a/eclass/ruby-fakegem.eclass
+++ b/eclass/ruby-fakegem.eclass
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# @ECLASS: ruby-fakegem.eclass
@@ -182,7 +182,9 @@ esac
SRC_URI="https://rubygems.org/gems/${RUBY_FAKEGEM_NAME}-${RUBY_FAKEGEM_VERSION}${RUBY_FAKEGEM_SUFFIX:+-${RUBY_FAKEGEM_SUFFIX}}.gem"
-ruby_add_bdepend virtual/rubygems
+# dev-ruby/psych is no longer installed and is incompatible with modern
+# ruby versions.
+ruby_add_bdepend "virtual/rubygems !!dev-ruby/psych"
ruby_add_rdepend virtual/rubygems
case ${EAPI} in
4|5|6)
diff --git a/net-libs/libnsl/Manifest b/net-libs/libnsl/Manifest
index f6db6f19194a..0adf5f26e283 100644
--- a/net-libs/libnsl/Manifest
+++ b/net-libs/libnsl/Manifest
@@ -1 +1,2 @@
DIST libnsl-1.2.0.tar.gz 209188 BLAKE2B 4249cfbf0b5391790f5e5f81e4eb0be963e5fdc0c32a9400d4128e717d93da49f8751caf8de3bb4ba1a23b8670a0e4f8e750f38f4612dd0cc97db4c157421a06 SHA512 30115aa679a04ad01f55cff9dd1890b4c41c730a9bac2adab5add9ae03a0b4687c5f4b6e3b8652ecbb074eefac8faee3f1f13ea60d42cf4432db8a575ca72cd8
+DIST libnsl-1.3.0.tar.gz 95645 BLAKE2B d5116c2837a7ed5d5916d571d2e5deaf733b2e3e4401c2ebb0ec253d2755c2dc169139ea64756bd4ab28e3107f9ff1dcdd5ef6657828862a95ca18f2f145e3b3 SHA512 ce75ee9e54f1bdd2b31886e8157ff5f654511c3da017e0d9f8d0da6a2a9f9a78ff2e5f72cfb7ce3a23065f57337db51e3c8842a7e990350a62612018f4960342
diff --git a/net-libs/libnsl/libnsl-1.3.0.ebuild b/net-libs/libnsl/libnsl-1.3.0.ebuild
new file mode 100644
index 000000000000..1c8cb717c768
--- /dev/null
+++ b/net-libs/libnsl/libnsl-1.3.0.ebuild
@@ -0,0 +1,43 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools multilib-minimal
+
+DESCRIPTION="Public client interface for NIS(YP) and NIS+ in a IPv6 ready version"
+HOMEPAGE="https://github.com/thkukuk/libnsl"
+SRC_URI="https://github.com/thkukuk/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+SLOT="0/2"
+LICENSE="LGPL-2.1+"
+
+# Stabilize together with glibc-2.26!
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+
+IUSE=""
+
+DEPEND="
+ >=net-libs/libtirpc-1.0.2-r1[${MULTILIB_USEDEP}]
+"
+RDEPEND="${DEPEND}
+ !<sys-libs/glibc-2.26
+"
+
+src_prepare() {
+ default
+ eautoreconf
+}
+
+multilib_src_configure() {
+ local myconf=(
+ --enable-shared
+ --disable-static
+ )
+ ECONF_SOURCE=${S} econf "${myconf[@]}"
+}
+
+multilib_src_install_all() {
+ einstalldocs
+ find "${ED}" -type f -name '*.la' -delete || die
+}
diff --git a/sci-electronics/pulseview/Manifest b/sci-electronics/pulseview/Manifest
index 48cd9f5d045f..1088db19d10a 100644
--- a/sci-electronics/pulseview/Manifest
+++ b/sci-electronics/pulseview/Manifest
@@ -1 +1 @@
-DIST pulseview-0.4.1.tar.gz 1342532 BLAKE2B 759779d4024df8f972fbed515764f17557014972abcb39d3942b411bfa78c6f97a89ee98b706adb51d240bdb738925546cec073f98ba829f1e325acaac892c01 SHA512 0bae4357be312bf6e997885270887a5bcc0a8dfb6914e63bb0d5abb35389b6681748e0e4667556ad432c5432c861185bcdd8da7815fb570fc8a2fbbf5eed3801
+DIST pulseview-0.4.2.tar.gz 1399718 BLAKE2B ebbefefa55bb7ce9d1bbdfa8ea44d9536fa4f9ca9f6f13175a5bb6122dcb431ddad7c668e631128ca57fd2231021f8ce1c686fac9fa746ace24cf69ef3d71e71 SHA512 79f653c9faad021c03b59b4a519b594190d5558dfb9be60cabcc2a35e991e66b733b337fec58a9248699e7aef0df3be1472c81f93274b25cec1fc6b73f8f033b
diff --git a/sci-electronics/pulseview/files/pulseview-0.4.2-qt-5.15.patch b/sci-electronics/pulseview/files/pulseview-0.4.2-qt-5.15.patch
new file mode 100644
index 000000000000..df55954f3c8c
--- /dev/null
+++ b/sci-electronics/pulseview/files/pulseview-0.4.2-qt-5.15.patch
@@ -0,0 +1,142 @@
+From ae726b70a7ada9a4be5808e00f0c951318479684 Mon Sep 17 00:00:00 2001
+From: Valentin Ochs <a@0au.de>
+Date: Sat, 20 Jun 2020 16:01:27 +0200
+Subject: [PATCH] Replace obsolete/deprecated Qt methods
+
+---
+ pv/subwindows/decoder_selector/subwindow.cpp | 2 +-
+ pv/util.cpp | 21 ++++++++++++++++++--
+ pv/util.hpp | 10 ++++++++++
+ pv/views/trace/decodetrace.cpp | 3 ++-
+ pv/views/trace/ruler.cpp | 2 +-
+ pv/widgets/timestampspinbox.cpp | 2 +-
+ 6 files changed, 34 insertions(+), 6 deletions(-)
+
+diff --git a/pv/subwindows/decoder_selector/subwindow.cpp b/pv/subwindows/decoder_selector/subwindow.cpp
+index 94ed6f4b..2c65dcf2 100644
+--- a/pv/subwindows/decoder_selector/subwindow.cpp
++++ b/pv/subwindows/decoder_selector/subwindow.cpp
+@@ -185,7 +185,7 @@ QToolBar* SubWindow::create_toolbar(QWidget *parent) const
+ int SubWindow::minimum_width() const
+ {
+ QFontMetrics m(info_label_body_->font());
+- const int label_width = m.width(QString(tr(initial_notice)));
++ const int label_width = util::text_width(m, tr(initial_notice));
+
+ return label_width + min_width_margin;
+ }
+diff --git a/pv/util.cpp b/pv/util.cpp
+index 897254e1..dfb8c72b 100644
+--- a/pv/util.cpp
++++ b/pv/util.cpp
+@@ -143,7 +143,7 @@ QString format_time_si(const Timestamp& v, SIPrefix prefix,
+ QString s;
+ QTextStream ts(&s);
+ if (sign && !v.is_zero())
+- ts << forcesign;
++ ts.setNumberFlags(ts.numberFlags() | QTextStream::ForceSign);
+ ts << qSetRealNumberPrecision(precision) << (v * multiplier);
+ ts << ' ' << prefix << unit;
+
+@@ -169,7 +169,7 @@ QString format_value_si(double v, SIPrefix prefix, unsigned precision,
+ QString s;
+ QTextStream ts(&s);
+ if (sign && (v != 0))
+- ts << forcesign;
++ ts.setNumberFlags(ts.numberFlags() | QTextStream::ForceSign);
+ ts.setRealNumberNotation(QTextStream::FixedNotation);
+ ts.setRealNumberPrecision(precision);
+ ts << (v * multiplier) << ' ' << prefix << unit;
+@@ -279,5 +279,22 @@ vector<string> split_string(string text, string separator)
+ return result;
+ }
+
++/**
++ * Return the width of a string in a given font.
++ *
++ * @param[in] metric metrics of the font
++ * @param[in] string the string whose width should be determined
++ *
++ * @return width of the string in pixels
++ */
++std::streamsize text_width(const QFontMetrics &metric, const QString &string)
++{
++#if QT_VERSION >= QT_VERSION_CHECK(5, 11, 0)
++ return metric.horizontalAdvance(string);
++#else
++ return metric.width(string);
++#endif
++}
++
+ } // namespace util
+ } // namespace pv
+diff --git a/pv/util.hpp b/pv/util.hpp
+index fab29a14..49ae04b2 100644
+--- a/pv/util.hpp
++++ b/pv/util.hpp
+@@ -30,6 +30,7 @@
+
+ #include <QMetaType>
+ #include <QString>
++#include <QFontMetrics>
+
+ using std::string;
+ using std::vector;
+@@ -143,6 +144,15 @@ QString format_time_minutes(const Timestamp& t, signed precision = 0,
+
+ vector<string> split_string(string text, string separator);
+
++/**
++ * Return the width of a string in a given font.
++ * @param[in] metric metrics of the font
++ * @param[in] string the string whose width should be determined
++ *
++ * @return width of the string in pixels
++ */
++std::streamsize text_width(const QFontMetrics &metric, const QString &string);
++
+ } // namespace util
+ } // namespace pv
+
+diff --git a/pv/views/trace/decodetrace.cpp b/pv/views/trace/decodetrace.cpp
+index 67c9b1c4..93c7c5a9 100644
+--- a/pv/views/trace/decodetrace.cpp
++++ b/pv/views/trace/decodetrace.cpp
+@@ -161,7 +161,8 @@ DecodeTrace::DecodeTrace(pv::Session &session,
+
+ // Determine shortest string we want to see displayed in full
+ QFontMetrics m(QApplication::font());
+- min_useful_label_width_ = m.width("XX"); // e.g. two hex characters
++ // e.g. two hex characters
++ min_useful_label_width_ = util::text_width(m, "XX");
+
+ default_row_height_ = (ViewItemPaintParams::text_height() * 6) / 4;
+ annotation_height_ = (ViewItemPaintParams::text_height() * 5) / 4;
+diff --git a/pv/views/trace/ruler.cpp b/pv/views/trace/ruler.cpp
+index 555794fc..83ffed28 100644
+--- a/pv/views/trace/ruler.cpp
++++ b/pv/views/trace/ruler.cpp
+@@ -283,7 +283,7 @@ void Ruler::paintEvent(QPaintEvent*)
+ const int rightedge = width();
+ const int x_tick = tick.first;
+ if ((x_tick > leftedge) && (x_tick < rightedge)) {
+- const int x_left_bound = QFontMetrics(font()).width(tick.second) / 2;
++ const int x_left_bound = util::text_width(QFontMetrics(font()), tick.second) / 2;
+ const int x_right_bound = rightedge - x_left_bound;
+ const int x_legend = min(max(x_tick, x_left_bound), x_right_bound);
+ p.drawText(x_legend, ValueMargin, 0, text_height,
+diff --git a/pv/widgets/timestampspinbox.cpp b/pv/widgets/timestampspinbox.cpp
+index fea8175e..01424a5b 100644
+--- a/pv/widgets/timestampspinbox.cpp
++++ b/pv/widgets/timestampspinbox.cpp
+@@ -76,7 +76,7 @@ QSize TimestampSpinBox::minimumSizeHint() const
+ {
+ const QFontMetrics fm(fontMetrics());
+ const int l = round(value_).str().size() + precision_ + 10;
+- const int w = fm.width(QString(l, '0'));
++ const int w = util::text_width(fm, QString(l, '0'));
+ const int h = lineEdit()->minimumSizeHint().height();
+ return QSize(w, h);
+ }
+--
+2.24.0.rc2
diff --git a/sci-electronics/pulseview/pulseview-0.4.1-r1.ebuild b/sci-electronics/pulseview/pulseview-0.4.2.ebuild
index 909877319c9b..b4e924d82834 100644
--- a/sci-electronics/pulseview/pulseview-0.4.1-r1.ebuild
+++ b/sci-electronics/pulseview/pulseview-0.4.2.ebuild
@@ -1,13 +1,13 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=7
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6,7,8,9} )
-inherit cmake-utils gnome2-utils python-single-r1 xdg-utils
+inherit cmake python-single-r1 xdg-utils
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3
else
@@ -23,39 +23,54 @@ SLOT="0"
IUSE="+decode static"
REQUIRED_USE="decode? ( ${PYTHON_REQUIRED_USE} )"
+BDEPEND="
+ dev-qt/linguist-tools:5
+ virtual/pkgconfig
+"
RDEPEND="
+ >=dev-cpp/glibmm-2.28.0:2
>=dev-libs/boost-1.55:=
>=dev-libs/glib-2.28.0:2
- >=dev-cpp/glibmm-2.28.0:2
- >=sci-libs/libsigrok-0.5.1:=[cxx]
dev-qt/qtcore:5
dev-qt/qtgui:5
- dev-qt/qtwidgets:5
dev-qt/qtsvg:5
+ dev-qt/qtwidgets:5
+ >=sci-libs/libsigrok-0.5.1:=[cxx]
decode? (
- >=sci-libs/libsigrokdecode-0.5.2:=[${PYTHON_SINGLE_USEDEP}]
${PYTHON_DEPS}
- )"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
+ >=sci-libs/libsigrokdecode-0.5.2:=[${PYTHON_SINGLE_USEDEP}]
+ )
+"
+DEPEND="${RDEPEND}"
DOCS=( HACKING NEWS README )
+PATCHES=( "${FILESDIR}/${P}-qt-5.15.patch" )
+
+pkg_setup() {
+ use decode && python_setup
+}
+
+src_prepare() {
+ cmake_src_prepare
+ cmake_comment_add_subdirectory manual
+}
+
src_configure() {
local mycmakeargs=(
-DDISABLE_WERROR=TRUE
-DENABLE_DECODE=$(usex decode)
-DSTATIC_PKGDEPS_LIBS=$(usex static)
)
- cmake-utils_src_configure
+ cmake_src_configure
}
pkg_postinst() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_desktop_database_update
}
pkg_postrm() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_desktop_database_update
}
diff --git a/sci-electronics/pulseview/pulseview-9999.ebuild b/sci-electronics/pulseview/pulseview-9999.ebuild
index 570474071f06..e67387d52ebe 100644
--- a/sci-electronics/pulseview/pulseview-9999.ebuild
+++ b/sci-electronics/pulseview/pulseview-9999.ebuild
@@ -1,13 +1,13 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=7
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6,7,8,9} )
-inherit cmake-utils gnome2-utils python-single-r1 xdg-utils
+inherit cmake python-single-r1 xdg-utils
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3
else
@@ -23,39 +23,52 @@ SLOT="0"
IUSE="+decode static"
REQUIRED_USE="decode? ( ${PYTHON_REQUIRED_USE} )"
+BDEPEND="
+ dev-qt/linguist-tools:5
+ virtual/pkgconfig
+"
RDEPEND="
+ >=dev-cpp/glibmm-2.28.0:2
>=dev-libs/boost-1.55:=
>=dev-libs/glib-2.28.0:2
- >=dev-cpp/glibmm-2.28.0:2
- >=sci-libs/libsigrok-0.6.0:=[cxx]
dev-qt/qtcore:5
dev-qt/qtgui:5
- dev-qt/qtwidgets:5
dev-qt/qtsvg:5
+ dev-qt/qtwidgets:5
+ >=sci-libs/libsigrok-0.6.0:=[cxx]
decode? (
- >=sci-libs/libsigrokdecode-0.6.0:=[${PYTHON_SINGLE_USEDEP}]
${PYTHON_DEPS}
- )"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
+ >=sci-libs/libsigrokdecode-0.6.0:=[${PYTHON_SINGLE_USEDEP}]
+ )
+"
+DEPEND="${RDEPEND}"
DOCS=( HACKING NEWS README )
+pkg_setup() {
+ use decode && python_setup
+}
+
+src_prepare() {
+ cmake_src_prepare
+ cmake_comment_add_subdirectory manual
+}
+
src_configure() {
local mycmakeargs=(
-DDISABLE_WERROR=TRUE
-DENABLE_DECODE=$(usex decode)
-DSTATIC_PKGDEPS_LIBS=$(usex static)
)
- cmake-utils_src_configure
+ cmake_src_configure
}
pkg_postinst() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_desktop_database_update
}
pkg_postrm() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_desktop_database_update
}
diff --git a/sci-libs/libsigrok/Manifest b/sci-libs/libsigrok/Manifest
index 5bd8440632e5..a25f3c7b87d3 100644
--- a/sci-libs/libsigrok/Manifest
+++ b/sci-libs/libsigrok/Manifest
@@ -1,4 +1,2 @@
DIST libsigrok-0.3.0.tar.gz 924503 BLAKE2B 132cc952b7314e11034100973f1086d17515fb7b1eb3792506569211fe05e9f35b113fceaff7c0468ad9be0bbcac0251ae63ae856f1393c51e743983e60886df SHA512 b94e8a8da1346f9ab267fd693975411243f2cb016e48ec05f4ad88a8a1dfe5ed6f5ad4ac4bf0e94dc551dc92cd70d2719983e21abaa4811693fb28a27bf74550
-DIST libsigrok-0.4.0.tar.gz 1387329 BLAKE2B 8d1578c1f84c84af54f0e6c97bcdcec6d183a80170d0b19aa44c4015dac3c418e1a1e304b42b12be3f905a3887f95d2ecc9644aeb2a81a961e09438e380ec70b SHA512 5963c1a44cf351a38d9434f89a15b20d36c7196a78464c302c65ab262bcdb2f26274c7fabf01174757e1f9a367497b9721578ebf802f75ef97ee71ff3dade1e0
-DIST libsigrok-0.5.1.tar.gz 1664813 BLAKE2B b5765e1057ee4411ef2f83fa73473429bc8f84653f1c7761af3c1280decc2fcb1d3c68d8f92f7e77b85f1fcda74cf6066e5bf56c0da2de4b28148b920b94e0da SHA512 48337fc4625dc0abc162ae54e04ce091047835aa1e49ba1ab84542805008d1ff5646b143fde57e317f3b34514c0e6d4dcb7b1c5944f3f16bdef1a7169edc3517
DIST libsigrok-0.5.2.tar.gz 1779465 BLAKE2B fc6fdde1054e9ac50bc42249c34b3dbfff1e89d77f0db5a8762e52fcf2ea5ea69b2defcf1cde4ed7b1edd1e21770002ed661a470c8d666904daa48a84a2bbfc5 SHA512 cf673dad6280302d69050c29490621f66c6d6a73932d019a53ec3501316d3f2e23e7667a04f866dbe6ed73f86a63de73d2173e2b6cea563631d705e06f887092
diff --git a/sci-libs/libsigrok/files/libsigrok-0.5.2-ruby-swig-docs.patch b/sci-libs/libsigrok/files/libsigrok-0.5.2-ruby-swig-docs.patch
new file mode 100644
index 000000000000..808227a2fffb
--- /dev/null
+++ b/sci-libs/libsigrok/files/libsigrok-0.5.2-ruby-swig-docs.patch
@@ -0,0 +1,63 @@
+From bae9308ec157378bd22ce4f4a0226f1e7ef23594 Mon Sep 17 00:00:00 2001
+From: Anatol Pomozov <anatol.pomozov@gmail.com>
+Date: Mon, 8 Jun 2020 20:46:44 -0700
+Subject: [PATCH] Fix ruby SWIG bindings generation
+
+bindings/swig/doc.py generates a swig interface file for ruby bindings
+that includes docstrings with comments braces ( /* and */ ) like this:
+
+ %feature("docstring") sigrok::Channel::type "/* Type of this channel. */\n";
+ %feature("docstring") sigrok::Channel::enabled "/* Enabled status of this channel. */\n";
+
+SWIG generates *.cxx and adds its own braces to the docstring:
+
+/*/* Document-class: Sigrok::Error
+Exception thrown when an error code is returned by any libsigrok call. */
+*/
+
+this causes compilation error for Ruby bindings.
+
+To fix the error we should not add extra braces to the docstring.
+With this patch libsigrok compiles fine with with ruby 2.7 and swig 4.0.2.
+
+Fixes bug #1526
+
+Signed-off-by: Anatol Pomozov <anatol.pomozov@gmail.com>
+---
+ bindings/swig/doc.py | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/bindings/swig/doc.py b/bindings/swig/doc.py
+index e8767af8..182f5477 100644
+--- a/bindings/swig/doc.py
++++ b/bindings/swig/doc.py
+@@ -46,7 +46,7 @@ for compound in index.findall('compound'):
+ if language == 'python':
+ print('%%feature("docstring") %s "%s";' % (class_name, brief))
+ elif language == 'ruby':
+- print('%%feature("docstring") %s "/* Document-class: %s\\n%s */\\n";' % (class_name, class_name.replace("sigrok", "Sigrok", 1), brief))
++ print('%%feature("docstring") %s "Document-class: %s\\n%s\\n";' % (class_name, class_name.replace("sigrok", "Sigrok", 1), brief))
+ elif language == 'java':
+ print('%%typemap(javaclassmodifiers) %s "/** %s */\npublic class"' % (
+ class_name, brief))
+@@ -77,10 +77,10 @@ for compound in index.findall('compound'):
+ for name, desc in parameters.items()]) + '";')
+ if language == 'ruby' and kind == 'public-func':
+ print(str.join('\n', [
+- '%%feature("docstring") %s::%s "/* %s' % (
++ '%%feature("docstring") %s::%s "%s' % (
+ class_name, member_name, brief)] + [
+ '@param %s %s' % (name, desc)
+- for name, desc in parameters.items()]) + ' */\\n";')
++ for name, desc in parameters.items()]) + '\\n";')
+ elif language == 'java' and kind == 'public-func':
+ print(str.join('\n', [
+ '%%javamethodmodifiers %s::%s "/** %s' % (
+@@ -111,4 +111,4 @@ for compound in index.findall('compound'):
+ print('%}')
+ elif language == 'ruby' and constants:
+ for member_name, brief in constants:
+- print('%%feature("docstring") %s::%s "/* %s */\\n";' % (class_name, member_name, brief))
++ print('%%feature("docstring") %s::%s "%s\\n";' % (class_name, member_name, brief))
+--
+2.27.0
diff --git a/sci-libs/libsigrok/files/libsigrok-0.5.2-swig-4.patch b/sci-libs/libsigrok/files/libsigrok-0.5.2-swig-4.patch
new file mode 100644
index 000000000000..3c5dd85a5100
--- /dev/null
+++ b/sci-libs/libsigrok/files/libsigrok-0.5.2-swig-4.patch
@@ -0,0 +1,37 @@
+From e803574173bdac8a7f33085a648c29eaf248a394 Mon Sep 17 00:00:00 2001
+From: Uwe Hermann <uwe@hermann-uwe.de>
+Date: Sat, 4 Apr 2020 21:54:13 +0200
+Subject: [PATCH 1/1] bindings/java: Fix build issue with SWIG 4.x.
+
+Tested with SWIG 3.x and SWIG 4.x.
+
+This fixes bug #1527.
+---
+ bindings/java/org/sigrok/core/classes/classes.i | 8 ++++++++
+ 1 file changed, 8 insertions(+)
+
+diff --git a/bindings/java/org/sigrok/core/classes/classes.i b/bindings/java/org/sigrok/core/classes/classes.i
+index 75793b25..e953fe5d 100644
+--- a/bindings/java/org/sigrok/core/classes/classes.i
++++ b/bindings/java/org/sigrok/core/classes/classes.i
+@@ -94,10 +94,18 @@ VECTOR(std::shared_ptr<sigrok::HardwareDevice>, HardwareDevice)
+ "java.util.Map<JKey, JValue>"
+
+ %typemap(javain,
++/* SWIG 4.0.0 changed the std::map wrappers in an incompatible way. */
++#if SWIG_VERSION >= 0x040000
++ pre=" $javaclassname temp$javainput = new $javaclassname();
++ for (java.util.Map.Entry<JKey, JValue> entry : $javainput.entrySet())
++ temp$javainput.put(entry.getKey(), entry.getValue());",
++ pgcppname="temp$javainput")
++#else
+ pre=" $javaclassname temp$javainput = new $javaclassname();
+ for (java.util.Map.Entry<JKey, JValue> entry : $javainput.entrySet())
+ temp$javainput.set(entry.getKey(), entry.getValue());",
+ pgcppname="temp$javainput")
++#endif
+ std::map< CKey, CValue > "$javaclassname.getCPtr(temp$javainput)"
+
+ %typemap(javaout) std::map< CKey, CValue > {
+--
+2.24.0.rc2
diff --git a/sci-libs/libsigrok/libsigrok-0.4.0.ebuild b/sci-libs/libsigrok/libsigrok-0.4.0.ebuild
deleted file mode 100644
index df9318757a57..000000000000
--- a/sci-libs/libsigrok/libsigrok-0.4.0.ebuild
+++ /dev/null
@@ -1,90 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-PYTHON_COMPAT=( python3_6 )
-
-inherit eutils python-single-r1 java-pkg-opt-2 ltprune
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="git://sigrok.org/${PN}"
- inherit git-r3 autotools
-else
- SRC_URI="https://sigrok.org/download/source/${PN}/${P}.tar.gz"
- KEYWORDS="~amd64 ~x86"
-fi
-
-DESCRIPTION="basic hardware drivers for logic analyzers and input/output file format support"
-HOMEPAGE="https://sigrok.org/wiki/Libsigrok"
-
-LICENSE="GPL-3"
-SLOT="0/3"
-IUSE="cxx ftdi java parport python serial static-libs test usb"
-RESTRICT="!test? ( test )"
-REQUIRED_USE="java? ( cxx ) python? ( cxx ${PYTHON_REQUIRED_USE} )"
-
-# We also support librevisa, but that isn't in the tree ...
-LIB_DEPEND=">=dev-libs/glib-2.32.0[static-libs(+)]
- >=dev-libs/libzip-0.8:=[static-libs(+)]
- cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
- python? (
- ${PYTHON_DEPS}
- $(python_gen_cond_dep '
- >=dev-python/pygobject-3.0.0[${PYTHON_MULTI_USEDEP}]
- ')
- )
- ftdi? ( >=dev-embedded/libftdi-0.16:=[static-libs(+)] )
- parport? ( sys-libs/libieee1284[static-libs(+)] )
- serial? ( >=dev-libs/libserialport-0.1.1[static-libs(+)] )
- usb? ( virtual/libusb:1[static-libs(+)] )"
-RDEPEND="!static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
- static-libs? ( ${LIB_DEPEND} )
- java? ( >=virtual/jre-1.4 )"
-DEPEND="${LIB_DEPEND//\[static-libs(+)]}
- test? ( >=dev-libs/check-0.9.4 )
- cxx? ( app-doc/doxygen )
- java? (
- >=dev-lang/swig-3.0.6
- >=virtual/jdk-1.4
- )
- python? (
- $(python_gen_cond_dep '
- dev-python/setuptools[${PYTHON_MULTI_USEDEP}]
- dev-python/numpy[${PYTHON_MULTI_USEDEP}]
- ')
- >=dev-lang/swig-3.0.6
- )
- virtual/pkgconfig"
-
-pkg_setup() {
- use python && python-single-r1_pkg_setup
- java-pkg-opt-2_pkg_setup
-}
-
-src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
- eapply_user
-}
-
-src_configure() {
- econf \
- $(use_with ftdi libftdi) \
- $(use_with parport libieee1284) \
- $(use_with serial libserialport) \
- $(use_with usb libusb) \
- $(use_enable cxx) \
- $(use_enable java) \
- $(use_enable python) \
- --disable-ruby \
- $(use_enable static-libs static)
-}
-
-src_test() {
- emake check
-}
-
-src_install() {
- default
- prune_libtool_files
-}
diff --git a/sci-libs/libsigrok/libsigrok-0.5.1.ebuild b/sci-libs/libsigrok/libsigrok-0.5.1.ebuild
deleted file mode 100644
index 078e9f5d9ab5..000000000000
--- a/sci-libs/libsigrok/libsigrok-0.5.1.ebuild
+++ /dev/null
@@ -1,101 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-PYTHON_COMPAT=( python3_{6,7} )
-
-inherit eutils gnome2-utils python-single-r1 java-pkg-opt-2 ltprune udev xdg-utils
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="git://sigrok.org/${PN}"
- inherit git-r3 autotools
-else
- SRC_URI="https://sigrok.org/download/source/${PN}/${P}.tar.gz"
- KEYWORDS="~amd64 ~x86"
-fi
-
-DESCRIPTION="basic hardware drivers for logic analyzers and input/output file format support"
-HOMEPAGE="https://sigrok.org/wiki/Libsigrok"
-
-LICENSE="GPL-3"
-SLOT="0/4"
-IUSE="cxx ftdi java parport python serial static-libs test +udev usb"
-RESTRICT="!test? ( test )"
-REQUIRED_USE="java? ( cxx ) python? ( cxx ${PYTHON_REQUIRED_USE} )"
-
-# We also support librevisa, but that isn't in the tree ...
-LIB_DEPEND=">=dev-libs/glib-2.32.0[static-libs(+)]
- >=dev-libs/libzip-0.8:=[static-libs(+)]
- cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
- python? (
- ${PYTHON_DEPS}
- $(python_gen_cond_dep '
- >=dev-python/pygobject-3.0.0[${PYTHON_MULTI_USEDEP}]
- ')
- )
- ftdi? ( >=dev-embedded/libftdi-0.16:=[static-libs(+)] )
- parport? ( sys-libs/libieee1284[static-libs(+)] )
- serial? ( >=dev-libs/libserialport-0.1.1[static-libs(+)] )
- usb? ( virtual/libusb:1[static-libs(+)] )"
-RDEPEND="!static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
- static-libs? ( ${LIB_DEPEND} )
- java? ( >=virtual/jre-1.4 )"
-DEPEND="${LIB_DEPEND//\[static-libs(+)]}
- test? ( >=dev-libs/check-0.9.4 )
- cxx? ( app-doc/doxygen )
- java? (
- >=dev-lang/swig-3.0.6
- >=virtual/jdk-1.4
- )
- python? (
- $(python_gen_cond_dep '
- dev-python/setuptools[${PYTHON_MULTI_USEDEP}]
- dev-python/numpy[${PYTHON_MULTI_USEDEP}]
- ')
- >=dev-lang/swig-3.0.6
- )
- virtual/pkgconfig"
-
-pkg_setup() {
- use python && python-single-r1_pkg_setup
- java-pkg-opt-2_pkg_setup
-}
-
-src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
- eapply_user
-}
-
-src_configure() {
- econf \
- $(use_with ftdi libftdi) \
- $(use_with parport libieee1284) \
- $(use_with serial libserialport) \
- $(use_with usb libusb) \
- $(use_enable cxx) \
- $(use_enable java) \
- $(use_enable python) \
- --disable-ruby \
- $(use_enable static-libs static)
-}
-
-src_test() {
- emake check
-}
-
-src_install() {
- default
- use udev && udev_dorules contrib/*.rules
- prune_libtool_files
-}
-
-pkg_postinst() {
- gnome2_icon_cache_update
- xdg_mimeinfo_database_update
-}
-
-pkg_postrm() {
- gnome2_icon_cache_update
- xdg_mimeinfo_database_update
-}
diff --git a/sci-libs/libsigrok/libsigrok-0.5.2.ebuild b/sci-libs/libsigrok/libsigrok-0.5.2.ebuild
index 49ca96068ac4..7e3111fc54d1 100644
--- a/sci-libs/libsigrok/libsigrok-0.5.2.ebuild
+++ b/sci-libs/libsigrok/libsigrok-0.5.2.ebuild
@@ -3,13 +3,13 @@
EAPI="6"
-PYTHON_COMPAT=( python3_{6,7} )
-USE_RUBY="ruby26 ruby25 ruby24"
+PYTHON_COMPAT=( python3_{6,7,8} )
+USE_RUBY="ruby26 ruby25"
RUBY_OPTIONAL="yes"
-inherit eutils gnome2-utils python-r1 java-pkg-opt-2 ltprune ruby-ng udev xdg-utils
+inherit python-r1 java-pkg-opt-2 ruby-ng udev xdg-utils
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3 autotools
else
@@ -17,56 +17,75 @@ else
KEYWORDS="~amd64 ~x86"
fi
-DESCRIPTION="basic hardware drivers for logic analyzers and input/output file format support"
+DESCRIPTION="Basic hardware drivers for logic analyzers and input/output file format support"
HOMEPAGE="https://sigrok.org/wiki/Libsigrok"
LICENSE="GPL-3"
SLOT="0/4"
-IUSE="cxx ftdi java parport python ruby serial static-libs +udev test usb"
+IUSE="+cxx ftdi java parport python ruby serial static-libs test +udev usb"
+REQUIRED_USE="java? ( cxx )
+ python? ( cxx ${PYTHON_REQUIRED_USE} )
+ ruby? ( cxx || ( $(ruby_get_use_targets) ) )"
+
RESTRICT="!test? ( test )"
-REQUIRED_USE="java? ( cxx ) python? ( cxx ${PYTHON_REQUIRED_USE} ) ruby? ( cxx || ( $(ruby_get_use_targets) ) )"
# We also support librevisa, but that isn't in the tree ...
-LIB_DEPEND=">=dev-libs/glib-2.32.0[static-libs(+)]
+LIB_DEPEND="
+ >=dev-libs/glib-2.32.0[static-libs(+)]
>=dev-libs/libzip-0.8:=[static-libs(+)]
cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
- python? ( ${PYTHON_DEPS} >=dev-python/pygobject-3.0.0[${PYTHON_USEDEP}] )
- ruby? ( $(ruby_implementations_depend) )
ftdi? ( >=dev-embedded/libftdi-0.16:=[static-libs(+)] )
parport? ( sys-libs/libieee1284[static-libs(+)] )
+ python? (
+ ${PYTHON_DEPS}
+ >=dev-python/pygobject-3.0.0[${PYTHON_USEDEP}]
+ )
+ ruby? ( $(ruby_implementations_depend) )
serial? ( >=dev-libs/libserialport-0.1.1[static-libs(+)] )
- usb? ( virtual/libusb:1[static-libs(+)] )"
-RDEPEND="!static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
+ usb? ( virtual/libusb:1[static-libs(+)] )
+"
+RDEPEND="
+ java? ( >=virtual/jre-1.4 )
+ !static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
static-libs? ( ${LIB_DEPEND} )
- java? ( >=virtual/jre-1.4 )"
+"
DEPEND="${LIB_DEPEND//\[static-libs(+)]}
- test? ( >=dev-libs/check-0.9.4 )
cxx? ( app-doc/doxygen )
java? (
>=dev-lang/swig-3.0.6
>=virtual/jdk-1.4
)
python? (
- dev-python/setuptools[${PYTHON_USEDEP}]
- dev-python/numpy[${PYTHON_USEDEP}]
>=dev-lang/swig-3.0.6
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
)
ruby? ( >=dev-lang/swig-3.0.8 )
- virtual/pkgconfig"
+ test? ( >=dev-libs/check-0.9.4 )
+ virtual/pkgconfig
+"
S="${WORKDIR}"/${P}
+PATCHES=(
+ # https://sigrok.org/bugzilla/show_bug.cgi?id=1527
+ "${FILESDIR}/${P}-swig-4.patch"
+ # https://sigrok.org/bugzilla/show_bug.cgi?id=1526
+ "${FILESDIR}/${P}-ruby-swig-docs.patch" # bug 705074
+)
+
pkg_setup() {
+ use python && python_setup
use ruby && ruby-ng_pkg_setup
java-pkg-opt-2_pkg_setup
}
src_unpack() {
- [[ ${PV} == "9999" ]] && git-r3_src_unpack || default
+ [[ ${PV} == *9999* ]] && git-r3_src_unpack || default
}
sigrok_src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
+ [[ ${PV} == *9999* ]] && eautoreconf
}
each_ruby_prepare() {
@@ -74,9 +93,12 @@ each_ruby_prepare() {
}
src_prepare() {
- use ruby && cp -rl "${S}" "${WORKDIR}"/all && ruby-ng_src_prepare
+ if use ruby; then
+ cp -rl "${S}" "${WORKDIR}"/all || die
+ ruby-ng_src_prepare
+ fi
+ default
sigrok_src_prepare
- eapply_user
use python && python_copy_sources
}
@@ -102,7 +124,6 @@ each_python_configure() {
}
src_configure() {
- python_setup
sigrok_src_configure --disable-ruby --disable-python
use ruby && ruby-ng_src_configure
use python && python_foreach_impl each_python_configure
@@ -142,15 +163,15 @@ src_install() {
use python && python_foreach_impl each_python_install
use ruby && ruby-ng_src_install
use udev && udev_dorules contrib/*.rules
- prune_libtool_files
+ find "${D}" -name '*.la' -type f -delete || die
}
pkg_postinst() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_mimeinfo_database_update
}
pkg_postrm() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_mimeinfo_database_update
}
diff --git a/sci-libs/libsigrok/libsigrok-9999.ebuild b/sci-libs/libsigrok/libsigrok-9999.ebuild
index d4e9bf2291f2..1449357471e6 100644
--- a/sci-libs/libsigrok/libsigrok-9999.ebuild
+++ b/sci-libs/libsigrok/libsigrok-9999.ebuild
@@ -3,13 +3,13 @@
EAPI="6"
-PYTHON_COMPAT=( python3_{6,7} )
-USE_RUBY="ruby26 ruby25 ruby24"
+PYTHON_COMPAT=( python3_{6,7,8} )
+USE_RUBY="ruby26 ruby25"
RUBY_OPTIONAL="yes"
-inherit eutils gnome2-utils python-r1 java-pkg-opt-2 ltprune ruby-ng udev xdg-utils
+inherit python-r1 java-pkg-opt-2 ruby-ng udev xdg-utils
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3 autotools
else
@@ -17,56 +17,68 @@ else
KEYWORDS="~amd64 ~x86"
fi
-DESCRIPTION="basic hardware drivers for logic analyzers and input/output file format support"
+DESCRIPTION="Basic hardware drivers for logic analyzers and input/output file format support"
HOMEPAGE="https://sigrok.org/wiki/Libsigrok"
LICENSE="GPL-3"
SLOT="0/9999"
-IUSE="cxx ftdi java parport python ruby serial static-libs +udev test usb"
+IUSE="+cxx ftdi java parport python ruby serial static-libs test +udev usb"
+REQUIRED_USE="java? ( cxx )
+ python? ( cxx ${PYTHON_REQUIRED_USE} )
+ ruby? ( cxx || ( $(ruby_get_use_targets) ) )"
+
RESTRICT="!test? ( test )"
-REQUIRED_USE="java? ( cxx ) python? ( cxx ${PYTHON_REQUIRED_USE} ) ruby? ( cxx || ( $(ruby_get_use_targets) ) )"
# We also support librevisa, but that isn't in the tree ...
-LIB_DEPEND=">=dev-libs/glib-2.32.0[static-libs(+)]
+LIB_DEPEND="
+ >=dev-libs/glib-2.32.0[static-libs(+)]
>=dev-libs/libzip-0.8:=[static-libs(+)]
cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
- python? ( ${PYTHON_DEPS} >=dev-python/pygobject-3.0.0[${PYTHON_USEDEP}] )
- ruby? ( $(ruby_implementations_depend) )
ftdi? ( >=dev-embedded/libftdi-0.16:=[static-libs(+)] )
parport? ( sys-libs/libieee1284[static-libs(+)] )
+ python? (
+ ${PYTHON_DEPS}
+ >=dev-python/pygobject-3.0.0[${PYTHON_USEDEP}]
+ )
+ ruby? ( $(ruby_implementations_depend) )
serial? ( >=dev-libs/libserialport-0.1.1[static-libs(+)] )
- usb? ( virtual/libusb:1[static-libs(+)] )"
-RDEPEND="!static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
+ usb? ( virtual/libusb:1[static-libs(+)] )
+"
+RDEPEND="
+ java? ( >=virtual/jre-1.4 )
+ !static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
static-libs? ( ${LIB_DEPEND} )
- java? ( >=virtual/jre-1.4 )"
+"
DEPEND="${LIB_DEPEND//\[static-libs(+)]}
- test? ( >=dev-libs/check-0.9.4 )
cxx? ( app-doc/doxygen )
java? (
>=dev-lang/swig-3.0.6
>=virtual/jdk-1.4
)
python? (
- dev-python/setuptools[${PYTHON_USEDEP}]
- dev-python/numpy[${PYTHON_USEDEP}]
>=dev-lang/swig-3.0.6
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
)
ruby? ( >=dev-lang/swig-3.0.8 )
- virtual/pkgconfig"
+ test? ( >=dev-libs/check-0.9.4 )
+ virtual/pkgconfig
+"
S="${WORKDIR}"/${P}
pkg_setup() {
+ use python && python_setup
use ruby && ruby-ng_pkg_setup
java-pkg-opt-2_pkg_setup
}
src_unpack() {
- [[ ${PV} == "9999" ]] && git-r3_src_unpack || default
+ [[ ${PV} == *9999* ]] && git-r3_src_unpack || default
}
sigrok_src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
+ [[ ${PV} == *9999* ]] && eautoreconf
}
each_ruby_prepare() {
@@ -74,9 +86,12 @@ each_ruby_prepare() {
}
src_prepare() {
- use ruby && cp -rl "${S}" "${WORKDIR}"/all && ruby-ng_src_prepare
+ if use ruby; then
+ cp -rl "${S}" "${WORKDIR}"/all || die
+ ruby-ng_src_prepare
+ fi
+ default
sigrok_src_prepare
- eapply_user
use python && python_copy_sources
}
@@ -102,7 +117,6 @@ each_python_configure() {
}
src_configure() {
- python_setup
sigrok_src_configure --disable-ruby --disable-python
use ruby && ruby-ng_src_configure
use python && python_foreach_impl each_python_configure
@@ -142,15 +156,15 @@ src_install() {
use python && python_foreach_impl each_python_install
use ruby && ruby-ng_src_install
use udev && udev_dorules contrib/*.rules
- prune_libtool_files
+ find "${D}" -name '*.la' -type f -delete || die
}
pkg_postinst() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_mimeinfo_database_update
}
pkg_postrm() {
- gnome2_icon_cache_update
+ xdg_icon_cache_update
xdg_mimeinfo_database_update
}
diff --git a/sci-libs/libsigrokdecode/Manifest b/sci-libs/libsigrokdecode/Manifest
index ec940a54b30c..f549ae22ea40 100644
--- a/sci-libs/libsigrokdecode/Manifest
+++ b/sci-libs/libsigrokdecode/Manifest
@@ -1,3 +1 @@
-DIST libsigrokdecode-0.4.1.tar.gz 751546 BLAKE2B b1625714a75e481d94956bd64af264c87b440c0a236f19ff02d18cc16964b701de8799a81943f4e9ec1181b1906c5e62deca98fbbbc30dfbdf8bff2208f86bc6 SHA512 b072001190e80a194986524fd4de4d32f4559d618b151a3dbfa2c63b292c8a490535cb7479cfa665c4e8d3798251a5d6f5ecfa456ca669237237ffced3e88272
-DIST libsigrokdecode-0.5.2.tar.gz 852133 BLAKE2B 7a73c3766582d6fd33e597ca286b0125ece3e5e9f5f3b70dcd79dd42693b9688df674dd5d1876ddef798a5b3aee97f47df4d40b52c5a24b9b8c09a347cda96ad SHA512 49d0cba3a5fe17593165c3669dc8530e4e68497369b461f39b63c903f41a3060766c23d44c4112c9b9a5e740ae1e2c03a735494ac798dc631f3913079be04e22
DIST libsigrokdecode-0.5.3.tar.gz 892783 BLAKE2B 45bae2488e4872be3bb891813083ed540617ac88558bb6c2d971fbb0c05585d3fcb74192fc83ce7d67ee466bc04c61fbccf6f475e549b80c86fe5f0cc191c7c1 SHA512 23393504b68135ed4ae8e8a654df024620af02e84fa3955956c61899388812229108155b4ae8d946e61f33dc8a8807db090d608350548a7a717d966442b07b9e
diff --git a/sci-libs/libsigrokdecode/libsigrokdecode-0.4.1.ebuild b/sci-libs/libsigrokdecode/libsigrokdecode-0.4.1.ebuild
deleted file mode 100644
index d8561c945b2f..000000000000
--- a/sci-libs/libsigrokdecode/libsigrokdecode-0.4.1.ebuild
+++ /dev/null
@@ -1,54 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-PYTHON_COMPAT=( python3_6 )
-
-inherit eutils ltprune python-single-r1
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="git://sigrok.org/${PN}"
- inherit git-r3 autotools
-else
- SRC_URI="https://sigrok.org/download/source/${PN}/${P}.tar.gz"
- KEYWORDS="~amd64 ~x86"
-fi
-
-DESCRIPTION="provide (streaming) protocol decoding functionality"
-HOMEPAGE="https://sigrok.org/wiki/Libsigrokdecode"
-
-LICENSE="GPL-3"
-SLOT="0/3"
-IUSE="static-libs"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-RDEPEND=">=dev-libs/glib-2.28.0
- ${PYTHON_DEPS}"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
-
-src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
-
- # Only a test program (not installed, and not used by src_test)
- # is used by libsigrok, so disable it to avoid the compile.
- sed -i \
- -e '/build_runtc=/s:yes:no:' \
- configure || die
-
- eapply_user
-}
-
-src_configure() {
- econf $(use_enable static-libs static)
-}
-
-src_test() {
- emake check
-}
-
-src_install() {
- default
- prune_libtool_files
-}
diff --git a/sci-libs/libsigrokdecode/libsigrokdecode-0.5.2.ebuild b/sci-libs/libsigrokdecode/libsigrokdecode-0.5.2.ebuild
deleted file mode 100644
index 1b1d6710e99f..000000000000
--- a/sci-libs/libsigrokdecode/libsigrokdecode-0.5.2.ebuild
+++ /dev/null
@@ -1,54 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI="6"
-
-PYTHON_COMPAT=( python3_{6,7} )
-
-inherit eutils ltprune python-single-r1
-
-if [[ ${PV} == "9999" ]]; then
- EGIT_REPO_URI="git://sigrok.org/${PN}"
- inherit git-r3 autotools
-else
- SRC_URI="https://sigrok.org/download/source/${PN}/${P}.tar.gz"
- KEYWORDS="~amd64 ~x86"
-fi
-
-DESCRIPTION="provide (streaming) protocol decoding functionality"
-HOMEPAGE="https://sigrok.org/wiki/Libsigrokdecode"
-
-LICENSE="GPL-3"
-SLOT="0/4"
-IUSE="static-libs"
-REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-
-RDEPEND=">=dev-libs/glib-2.34.0
- ${PYTHON_DEPS}"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
-
-src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
-
- # Only a test program (not installed, and not used by src_test)
- # is used by libsigrok, so disable it to avoid the compile.
- sed -i \
- -e '/build_runtc=/s:yes:no:' \
- configure || die
-
- eapply_user
-}
-
-src_configure() {
- econf $(use_enable static-libs static)
-}
-
-src_test() {
- emake check
-}
-
-src_install() {
- default
- prune_libtool_files
-}
diff --git a/sci-libs/libsigrokdecode/libsigrokdecode-0.5.3.ebuild b/sci-libs/libsigrokdecode/libsigrokdecode-0.5.3.ebuild
index 1b1d6710e99f..6b0e3b267c37 100644
--- a/sci-libs/libsigrokdecode/libsigrokdecode-0.5.3.ebuild
+++ b/sci-libs/libsigrokdecode/libsigrokdecode-0.5.3.ebuild
@@ -1,13 +1,12 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=7
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6,7,8,9} )
+inherit python-single-r1
-inherit eutils ltprune python-single-r1
-
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3 autotools
else
@@ -15,7 +14,7 @@ else
KEYWORDS="~amd64 ~x86"
fi
-DESCRIPTION="provide (streaming) protocol decoding functionality"
+DESCRIPTION="Provide (streaming) protocol decoding functionality"
HOMEPAGE="https://sigrok.org/wiki/Libsigrokdecode"
LICENSE="GPL-3"
@@ -23,13 +22,16 @@ SLOT="0/4"
IUSE="static-libs"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-RDEPEND=">=dev-libs/glib-2.34.0
- ${PYTHON_DEPS}"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
+RDEPEND="${PYTHON_DEPS}
+ >=dev-libs/glib-2.34.0
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ virtual/pkgconfig
+"
src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
+ default
# Only a test program (not installed, and not used by src_test)
# is used by libsigrok, so disable it to avoid the compile.
@@ -37,7 +39,7 @@ src_prepare() {
-e '/build_runtc=/s:yes:no:' \
configure || die
- eapply_user
+ [[ ${PV} == *9999* ]] && eautoreconf
}
src_configure() {
@@ -50,5 +52,5 @@ src_test() {
src_install() {
default
- prune_libtool_files
+ find "${D}" -name '*.la' -type f -delete || die
}
diff --git a/sci-libs/libsigrokdecode/libsigrokdecode-9999.ebuild b/sci-libs/libsigrokdecode/libsigrokdecode-9999.ebuild
index d4b8425482e3..d9212117c961 100644
--- a/sci-libs/libsigrokdecode/libsigrokdecode-9999.ebuild
+++ b/sci-libs/libsigrokdecode/libsigrokdecode-9999.ebuild
@@ -1,13 +1,12 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI="6"
+EAPI=7
-PYTHON_COMPAT=( python3_{6,7} )
+PYTHON_COMPAT=( python3_{6,7,8,9} )
+inherit python-single-r1
-inherit eutils ltprune python-single-r1
-
-if [[ ${PV} == "9999" ]]; then
+if [[ ${PV} == *9999* ]]; then
EGIT_REPO_URI="git://sigrok.org/${PN}"
inherit git-r3 autotools
else
@@ -15,7 +14,7 @@ else
KEYWORDS="~amd64 ~x86"
fi
-DESCRIPTION="provide (streaming) protocol decoding functionality"
+DESCRIPTION="Provide (streaming) protocol decoding functionality"
HOMEPAGE="https://sigrok.org/wiki/Libsigrokdecode"
LICENSE="GPL-3"
@@ -23,13 +22,16 @@ SLOT="0/9999"
IUSE="static-libs"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
-RDEPEND=">=dev-libs/glib-2.34.0
- ${PYTHON_DEPS}"
-DEPEND="${RDEPEND}
- virtual/pkgconfig"
+RDEPEND="${PYTHON_DEPS}
+ >=dev-libs/glib-2.34.0
+"
+DEPEND="${RDEPEND}"
+BDEPEND="
+ virtual/pkgconfig
+"
src_prepare() {
- [[ ${PV} == "9999" ]] && eautoreconf
+ default
# Only a test program (not installed, and not used by src_test)
# is used by libsigrok, so disable it to avoid the compile.
@@ -37,7 +39,7 @@ src_prepare() {
-e '/build_runtc=/s:yes:no:' \
configure || die
- eapply_user
+ [[ ${PV} == *9999* ]] && eautoreconf
}
src_configure() {
@@ -50,5 +52,5 @@ src_test() {
src_install() {
default
- prune_libtool_files
+ find "${D}" -name '*.la' -type f -delete || die
}
diff --git a/sys-libs/libcap/Manifest b/sys-libs/libcap/Manifest
index a31123b59580..4970055027de 100644
--- a/sys-libs/libcap/Manifest
+++ b/sys-libs/libcap/Manifest
@@ -2,3 +2,4 @@ DIST libcap-2.26.tar.xz 67172 BLAKE2B 9d1952bd03e1bba5ffa225a5088b8d841c2007219b
DIST libcap-2.27.tar.xz 67780 BLAKE2B 7b58d7afdd90281771a302cd9554f067b9e3636b0c052935973d8a0d890490c3933b3513874b788a8c10e37ab5ad9cfa766408c9629b7c8562cb17bfdef87747 SHA512 e32335fd3e0d1564574acc73df7030b5b0fd98875217bffabd76f2765f1a7a6f1369f03df2ee22a1782776838784e342378c10613ea1163d53ae5055ab6a62b6
DIST libcap-2.36.tar.xz 112612 BLAKE2B fec0997eba7af6e9df83ce91235bdd96e98d7284268f0e3d3f4ef41e7b5e0621649a90069f2a162bcecf387c156ff481be379012fc57bbbc59309b850fe879ae SHA512 0193bd1b1b6223260a629458a37db581a0ff61f1d23f439fd2bdd0e6f3acb30ce996fb0f4f86c59670183d9f42932ae1e817e44e6b64f4ff49d61ea3a4a10aa5
DIST libcap-2.37.tar.xz 114800 BLAKE2B 96f9d12510266da3ca49b26859b29cbd2ea45ae676eaf54b6e3b732c0a8ab22ff8a8a4b5b2de68a7094b7d7df5d2d1664d0b5060cd25a3da05ea86ac9cdd0e75 SHA512 72d75165f78299411baa22a358dcee8169753d0a96ba97c31f24e3a25cf99fa818a00f980a99e8bc2c996a433533ae09d0401f1f3dfb03017bdc4b21d71ba848
+DIST libcap-2.38.tar.xz 115752 BLAKE2B e096a54f44aac3411035a6365b74c423e1a4bdd8d1f99e53af1e2a825687a46e428f42718b485a8f40bfa59bdf7c0872d5a60599253ae774d3289677fc161890 SHA512 df92c77f29d9a92b9356f9422a55ba56855e89875b24db57f42f247a8ee0891a2e50f235805aa848c2564de33c1ecd5d68e4a9e8ea6896542cf7585ccbf677d1
diff --git a/sys-libs/libcap/files/libcap-2.37-build-system-fixes.patch b/sys-libs/libcap/files/libcap-2.37-build-system-fixes.patch
index 797ac62dd1f1..3d0a771aa5f3 100644
--- a/sys-libs/libcap/files/libcap-2.37-build-system-fixes.patch
+++ b/sys-libs/libcap/files/libcap-2.37-build-system-fixes.patch
@@ -1,4 +1,4 @@
-From 16bca4a0f45a712867992dbe30aa51558c78d424 Mon Sep 17 00:00:00 2001
+From 33c8c4ebf725aa9950689d4dc72d2f5da30beab5 Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vapier@gentoo.org>
Date: Tue, 5 May 2020 09:52:40 +0200
Subject: [PATCH] build system fixes
@@ -19,6 +19,7 @@ Forward ported from libcap-2.25 to libcap-2.28
Forward ported from libcap-2.28 to libcap-2.29
Forward ported from libcap-2.29 to libcap-2.33
Forward ported from libcap-2.33 to libcap-2.34
+Forward ported from libcap-2.34 to libcap-2.37
Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
---
diff --git a/sys-libs/libcap/files/libcap-2.38-no_perl.patch b/sys-libs/libcap/files/libcap-2.38-no_perl.patch
new file mode 100644
index 000000000000..f3e0c468c869
--- /dev/null
+++ b/sys-libs/libcap/files/libcap-2.38-no_perl.patch
@@ -0,0 +1,71 @@
+From 3f76418eaf73896489129c529fac021e4f3a03c0 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Wed, 21 Nov 2018 11:00:54 +0100
+Subject: [PATCH] use awk/sed instead of perl for creating header files
+
+More systems should have awk/sed than perl.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+
+Forward ported from libcap-2.22 to libcap-2.26
+and incorporated the gperf-3.1 fix provided by Mike Gilbert
+<floppym@gentoo.org>
+Forward ported from libcap-2.26 to libcap-2.28
+Forward ported from libcap-2.28 to libcap-2.38
+
+Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
+---
+ libcap/Makefile | 26 +++++++++++++++++++-------
+ 1 file changed, 19 insertions(+), 7 deletions(-)
+
+diff --git a/libcap/Makefile b/libcap/Makefile
+index 3d6463d..df2526c 100644
+--- a/libcap/Makefile
++++ b/libcap/Makefile
+@@ -22,6 +22,8 @@ MAJLIBNAME=$(LIBNAME).$(VERSION)
+ MINLIBNAME=$(MAJLIBNAME).$(MINOR)
+ GPERF_OUTPUT = _caps_output.gperf
+ CFLAGS += -fPIC
++AWK = awk
++SED = sed
+
+ all: $(MINLIBNAME) $(STACAPLIBNAME) libcap.pc libpsx.pc $(STAPSXLIBNAME)
+
+@@ -55,17 +57,27 @@ cap_names.h: _makenames
+ ./_makenames > cap_names.h
+
+ $(GPERF_OUTPUT): cap_names.list.h
+- perl -e 'print "struct __cap_token_s { const char *name; int index; };\n%{\nconst struct __cap_token_s *__cap_lookup_name(const char *, size_t);\n%}\n%%\n"; while ($$l = <>) { $$l =~ s/[\{\"]//g; $$l =~ s/\}.*// ; print $$l; }' < $< | gperf --ignore-case --language=ANSI-C --readonly --null-strings --global-table --hash-function-name=__cap_hash_name --lookup-function-name="__cap_lookup_name" -c -t -m20 $(INDENT) > $@
+- sed -e 's/unsigned int len/size_t len/' -i $@
++ (printf "%b" "struct __cap_token_s { const char *name; int index; };\n%%\n"; \
++ $(SED) -e 's:["{}]::g' -e 's:,$$::' $<) | \
++ gperf \
++ --ignore-case \
++ --language=ANSI-C \
++ --includes \
++ --readonly \
++ --null-strings \
++ --global-table \
++ --hash-function-name=__cap_hash_name \
++ --lookup-function-name="__cap_lookup_name" \
++ -c -t -m20 $(INDENT) > $@
+
+-# Intention is that libcap keeps up with torvalds' tree, as reflected
+-# by this maintained version of the kernel header. libcap dynamically
+-# trims the meaning of "all" capabilities down to that of the running
+-# kernel as of 2.30.
+ UAPI_HEADER := $(topdir)/libcap/include/uapi/linux/capability.h
+ cap_names.list.h: Makefile $(UAPI_HEADER)
+ @echo "=> making $@ from $(UAPI_HEADER)"
+- perl -e 'while ($$l=<>) { if ($$l =~ /^\#define[ \t](CAP[_A-Z]+)[ \t]+([0-9]+)\s+$$/) { $$tok=$$1; $$val=$$2; $$tok =~ tr/A-Z/a-z/; print "{\"$$tok\",$$val},\n"; } }' $(UAPI_HEADER) | fgrep -v 0x > $@
++ $(AWK) '($$0 ~ /^#define[[:space:]]+CAP[_A-Z]+[[:space:]]+[0-9]+[[:space:]]*$$/) { printf "{\"%s\",%s},\n", tolower($$2), $$3 }' $(UAPI_HEADER) > $@
++
++cap_names.list.h: $(KERNEL_HEADERS)/linux/capability.h Makefile
++ @echo "=> making $@ from $<"
++ $(AWK) '($$0 ~ /^#define[[:space:]]+CAP[_A-Z]+[[:space:]]+[0-9]+[[:space:]]*$$/) { printf "{\"%s\",%s},\n", tolower($$2), $$3 }' $< > $@
+
+ $(STACAPLIBNAME): $(CAPOBJS)
+ $(AR) rcs $@ $^
+--
+2.27.0
+
diff --git a/sys-libs/libcap/libcap-2.38.ebuild b/sys-libs/libcap/libcap-2.38.ebuild
new file mode 100644
index 000000000000..3f680c7722ff
--- /dev/null
+++ b/sys-libs/libcap/libcap-2.38.ebuild
@@ -0,0 +1,87 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit multilib multilib-minimal toolchain-funcs pam usr-ldscript
+
+DESCRIPTION="POSIX 1003.1e capabilities"
+HOMEPAGE="https://sites.google.com/site/fullycapable/"
+SRC_URI="https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/${P}.tar.xz"
+
+# it's available under either of the licenses
+LICENSE="|| ( GPL-2 BSD )"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="pam static-libs"
+
+# While the build system optionally uses gperf, we don't DEPEND on it because
+# the build automatically falls back when it's unavailable. #604802
+RDEPEND=">=sys-apps/attr-2.4.47-r1[${MULTILIB_USEDEP}]"
+PDEPEND="pam? ( sys-libs/pam[${MULTILIB_USEDEP}] )"
+DEPEND="${RDEPEND}
+ ${PDEPEND}
+ sys-kernel/linux-headers"
+
+# Requires test suite being run as root (via sudo)
+RESTRICT="test"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-2.37-build-system-fixes.patch
+ "${FILESDIR}"/${PN}-2.38-no_perl.patch
+ "${FILESDIR}"/${PN}-2.25-ignore-RAISE_SETFCAP-install-failures.patch
+ "${FILESDIR}"/${PN}-2.21-include.patch
+)
+
+src_prepare() {
+ default
+ multilib_copy_sources
+}
+
+run_emake() {
+ local args=(
+ exec_prefix="${EPREFIX}"
+ lib_prefix="${EPREFIX}/usr"
+ lib="$(get_libdir)"
+ prefix="${EPREFIX}/usr"
+ PAM_CAP="$(usex pam yes no)"
+ DYNAMIC=yes
+ GOLANG=no
+ )
+ emake "${args[@]}" "$@"
+}
+
+src_configure() {
+ tc-export AR CC RANLIB
+ tc-export_build_env BUILD_CC
+ multilib-minimal_src_configure
+}
+
+multilib_src_compile() {
+ run_emake
+}
+
+multilib_src_install() {
+ # no configure, needs explicit install line #444724#c3
+ run_emake DESTDIR="${D}" install
+
+ gen_usr_ldscript -a cap
+ if ! use static-libs ; then
+ # Don't remove libpsx.a!
+ # See https://bugs.gentoo.org/703912
+ rm "${ED}"/usr/$(get_libdir)/libcap.a || die
+ fi
+
+ if [[ -d "${ED}"/usr/$(get_libdir)/security ]] ; then
+ rm -r "${ED}"/usr/$(get_libdir)/security || die
+ fi
+
+ if use pam; then
+ dopammod pam_cap/pam_cap.so
+ dopamsecurity '' pam_cap/capability.conf
+ fi
+}
+
+multilib_src_install_all() {
+ dodoc CHANGELOG README doc/capability.notes
+}