summaryrefslogtreecommitdiff
path: root/sci-libs/libsigrok
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2022-01-16 20:27:28 +0000
committerV3n3RiX <venerix@koprulu.sector>2022-01-16 20:27:28 +0000
commit2fd57282f0262ca084e05b0f2c63fbada395d02b (patch)
tree4e0f23cea9ce9fd972e70ebc5214bf36fed465cc /sci-libs/libsigrok
parentc3bc61051d7f12b4c682efa7a5460bbc8815649e (diff)
gentoo resync : 16.01.2021
Diffstat (limited to 'sci-libs/libsigrok')
-rw-r--r--sci-libs/libsigrok/Manifest5
-rw-r--r--sci-libs/libsigrok/libsigrok-0.5.2-r3.ebuild182
-rw-r--r--sci-libs/libsigrok/libsigrok-9999.ebuild12
-rw-r--r--sci-libs/libsigrok/metadata.xml4
4 files changed, 197 insertions, 6 deletions
diff --git a/sci-libs/libsigrok/Manifest b/sci-libs/libsigrok/Manifest
index 475be9d63a97..cf08fed50c63 100644
--- a/sci-libs/libsigrok/Manifest
+++ b/sci-libs/libsigrok/Manifest
@@ -3,5 +3,6 @@ AUX libsigrok-0.5.2-ruby-swig-docs.patch 3085 BLAKE2B 865f38a8230762f58620c06b91
AUX libsigrok-0.5.2-swig-4.patch 1484 BLAKE2B 94c9bbde14f3175252677dedd50a7f3ff17bcc734382d93fbe3c65c71989dc72d0568535343bcb7764053075a2bac9c9f2d4e480d582a5371ac0d4a12bcab4a2 SHA512 34e568351624aeada4c3894be8a60cc0111be7c20ebe8e5395a1f81b2fc453a6a8228f575b95faad5140162a9d4fc5fc570546f42673f7275cb3910c73ffc8de
DIST libsigrok-0.5.2.tar.gz 1779465 BLAKE2B fc6fdde1054e9ac50bc42249c34b3dbfff1e89d77f0db5a8762e52fcf2ea5ea69b2defcf1cde4ed7b1edd1e21770002ed661a470c8d666904daa48a84a2bbfc5 SHA512 cf673dad6280302d69050c29490621f66c6d6a73932d019a53ec3501316d3f2e23e7667a04f866dbe6ed73f86a63de73d2173e2b6cea563631d705e06f887092
EBUILD libsigrok-0.5.2-r2.ebuild 3912 BLAKE2B 402bef147d2b91b20934d43fdee761f07ae73c6973f06f6c37097beacc172cdc236bab38f7647fd25424a96364a7f8cdd0f847929bb70929e8724769cc1b15b1 SHA512 a80e0d58c2262204f879f38cdaa97e4cb862bbe1b3801f31bb675e69376f871cfafee3720ec56457c5340bd7f6b7c06e1e7511acfda4f970d52eeac305d3ae99
-EBUILD libsigrok-9999.ebuild 3676 BLAKE2B 66dc520e44e8315956b11fd188f636fe5f3d7a0396fac2b806d2272e518db52356e70a1584accecea29a015c93aaf68cd44bfdb8df660a98431b21a9ff0a5ade SHA512 fd11ed14b08f4e1f584c7bc56c1c256409d687d2c4a730b2715f31823028b7a33d24cbe6b2857bfa0f4a98a4fa3e5efa1140b68c719f04d8b13a56a3dee580a8
-MISC metadata.xml 702 BLAKE2B 14ee168c6f76641e8057b310fe70dbda5075963de77de02b2cbc503634de9cf8c5f30aa46efe31206fddb4821d499ad2a7e63529370f37b29d0d2d7892686fbb SHA512 3efde6829bcd822729b1eb21c64d216b79dadb79006d04f119bef32e315cafb6db885b051925df818cfdaead1299b0b25c94d40f9b1f04c58bea2c90d212dc81
+EBUILD libsigrok-0.5.2-r3.ebuild 4057 BLAKE2B a43f9b774de8cb3c6df5198b7f155d40a3c149396bfaa5346625c302f99ada5ae69440e5dfd29f11f1f8c3ac04b014920f8c7aa8dcc4a3370da078d00f9a1605 SHA512 ba85487744ada2c18c51ee97c9139eb62f9c93fdac05f1651864b3f1ac1ac7cbcfc0e57302b2f90ed04fc40fce0bc8cfa3b7687d1ecb7cefec70514d3ec49681
+EBUILD libsigrok-9999.ebuild 3931 BLAKE2B 498c6b13b08da5cb4eb54a3e1853555fd7b8741a48a6810f1436883c07aa5700ce5812d03397fa2cc803d3388f3a59584a4e8028d764f9e7c35081c5306b8529 SHA512 dc586a2ebc8cf5bef64e5458d0330573f5f5d3070aed60e1da0d3fd4fef5dae0a15d99a63b5a782ad7b6cddbb61fdfd21d36e02dedba089747d44535609e0b6f
+MISC metadata.xml 886 BLAKE2B cb7cece1f79a4affb612e55f147eb93895a805e43aed6bbabfed2e3b925b0714d64651c00294da2742f8c09ce9984a58888b89025d73712400c8bd026296b2cb SHA512 79c9697b3fe6954108cb60ae79c06cee280ef6d73bcd9e35ab148750a4fa55c8e5118c21cdb4e3ae009d4c160a26c98132448476ef90ac6d7a19a79138c3b2f6
diff --git a/sci-libs/libsigrok/libsigrok-0.5.2-r3.ebuild b/sci-libs/libsigrok/libsigrok-0.5.2-r3.ebuild
new file mode 100644
index 000000000000..8c206cfc5d79
--- /dev/null
+++ b/sci-libs/libsigrok/libsigrok-0.5.2-r3.ebuild
@@ -0,0 +1,182 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="7"
+
+PYTHON_COMPAT=( python3_{7,8,9,10} )
+USE_RUBY="ruby26 ruby25"
+RUBY_OPTIONAL="yes"
+
+inherit autotools python-r1 java-pkg-opt-2 ruby-ng udev xdg-utils
+
+if [[ ${PV} == *9999* ]]; then
+ EGIT_REPO_URI="git://sigrok.org/${PN}"
+ inherit git-r3
+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="bluetooth +cxx ftdi hidapi 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 )"
+
+# 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(+)]
+ bluetooth? ( >=net-wireless/bluez-4.0:= )
+ cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
+ ftdi? ( dev-embedded/libftdi:1[static-libs(+)] )
+ hidapi? ( >=dev-libs/hidapi-0.8.0 )
+ 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="
+ java? ( >=virtual/jre-1.8:* )
+ !static-libs? ( ${LIB_DEPEND//\[static-libs(+)]} )
+ static-libs? ( ${LIB_DEPEND} )
+"
+DEPEND="${LIB_DEPEND//\[static-libs(+)]}
+ cxx? ( app-doc/doxygen )
+ java? (
+ >=dev-lang/swig-3.0.6
+ >=virtual/jdk-1.8:*
+ )
+ python? (
+ >=dev-lang/swig-3.0.6
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ )
+ ruby? ( >=dev-lang/swig-3.0.8 )
+ 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
+ "${FILESDIR}/${P}-check-0.15.patch"
+)
+
+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
+}
+
+sigrok_src_prepare() {
+ eautoreconf
+}
+
+each_ruby_prepare() {
+ sigrok_src_prepare
+}
+
+src_prepare() {
+ if use ruby; then
+ cp -rl "${S}" "${WORKDIR}"/all || die
+ ruby-ng_src_prepare
+ fi
+ default
+ sigrok_src_prepare
+ use python && python_copy_sources
+}
+
+sigrok_src_configure() {
+ econf \
+ $(use_with bluetooth libbluez) \
+ $(use_with ftdi libftdi) \
+ $(use_with hidapi libhidapi) \
+ $(use_with parport libieee1284) \
+ $(use_with serial libserialport) \
+ $(use_with usb libusb) \
+ $(use_enable cxx) \
+ $(use_enable java) \
+ $(use_enable static-libs static) \
+ "${@}"
+}
+
+each_ruby_configure() {
+ RUBY="${RUBY}" sigrok_src_configure --enable-ruby --disable-python
+}
+
+each_python_configure() {
+ cd "${BUILD_DIR}"
+ sigrok_src_configure --disable-ruby --enable-python
+}
+
+src_configure() {
+ sigrok_src_configure --disable-ruby --disable-python
+ use ruby && ruby-ng_src_configure
+ use python && python_foreach_impl each_python_configure
+}
+
+each_ruby_compile() {
+ emake ruby-build
+}
+
+each_python_compile() {
+ cd "${BUILD_DIR}"
+ emake python-build
+}
+
+src_compile() {
+ default
+ use ruby && ruby-ng_src_compile
+ use python && python_foreach_impl each_python_compile
+}
+
+src_test() {
+ emake check
+}
+
+each_ruby_install() {
+ emake ruby-install DESTDIR="${D}"
+}
+
+each_python_install() {
+ cd "${BUILD_DIR}"
+ emake python-install DESTDIR="${D}"
+ python_optimize
+}
+
+src_install() {
+ default
+ use python && python_foreach_impl each_python_install
+ use ruby && ruby-ng_src_install
+ use udev && udev_dorules contrib/*.rules
+ find "${D}" -name '*.la' -type f -delete || die
+}
+
+pkg_postinst() {
+ xdg_icon_cache_update
+ xdg_mimeinfo_database_update
+}
+
+pkg_postrm() {
+ 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 02994b07b73a..126dd3c3d52f 100644
--- a/sci-libs/libsigrok/libsigrok-9999.ebuild
+++ b/sci-libs/libsigrok/libsigrok-9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="7"
-PYTHON_COMPAT=( python3_{7,8,9} )
+PYTHON_COMPAT=( python3_{7,8,9,10} )
USE_RUBY="ruby26 ruby25"
RUBY_OPTIONAL="yes"
@@ -22,7 +22,7 @@ HOMEPAGE="https://sigrok.org/wiki/Libsigrok"
LICENSE="GPL-3"
SLOT="0/9999"
-IUSE="+cxx ftdi java parport python ruby serial static-libs test +udev usb"
+IUSE="bluetooth +cxx ftdi hidapi java nettle parport python ruby serial static-libs test +udev usb"
REQUIRED_USE="java? ( cxx )
python? ( cxx ${PYTHON_REQUIRED_USE} )
ruby? ( cxx || ( $(ruby_get_use_targets) ) )"
@@ -33,8 +33,11 @@ RESTRICT="!test? ( test )"
LIB_DEPEND="
>=dev-libs/glib-2.32.0[static-libs(+)]
>=dev-libs/libzip-0.8:=[static-libs(+)]
+ bluetooth? ( >=net-wireless/bluez-4.0:= )
cxx? ( dev-cpp/glibmm:2[static-libs(+)] )
ftdi? ( dev-embedded/libftdi:1[static-libs(+)] )
+ hidapi? ( >=dev-libs/hidapi-0.8.0 )
+ nettle? ( dev-libs/nettle:=[static-libs(+)] )
parport? ( sys-libs/libieee1284[static-libs(+)] )
python? (
${PYTHON_DEPS}
@@ -97,7 +100,10 @@ src_prepare() {
sigrok_src_configure() {
econf \
+ $(use_with bluetooth libbluez) \
$(use_with ftdi libftdi) \
+ $(use_with hidapi libhidapi) \
+ $(use_with nettle libnettle) \
$(use_with parport libieee1284) \
$(use_with serial libserialport) \
$(use_with usb libusb) \
diff --git a/sci-libs/libsigrok/metadata.xml b/sci-libs/libsigrok/metadata.xml
index 125e899de100..d9f21398e7c8 100644
--- a/sci-libs/libsigrok/metadata.xml
+++ b/sci-libs/libsigrok/metadata.xml
@@ -11,7 +11,9 @@
as well as input/output file format support.
</longdescription>
<use>
- <flag name="ftdi">Enable drivers that need libftdi</flag>
+ <flag name="ftdi">Enable drivers that need <pkg>dev-embedded/libftdi</pkg></flag>
+ <flag name="hidapi">Enable drivers that need <pkg>dev-libs/hidapi</pkg></flag>
+ <flag name="nettle">Enable drivers that need <pkg>dev-libs/nettle</pkg></flag>
<flag name="parport">Enable drivers that are parallel (IEEE1284) based</flag>
<flag name="serial">Enable drivers that are serial (RS232) based</flag>
</use>