public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Viorel Munteanu" <ceamac@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-embedded/urjtag/
Date: Sun,  6 Aug 2023 10:05:37 +0000 (UTC)	[thread overview]
Message-ID: <1691316312.fcd645b0be20fa53aa6f58f959e1771a4696ca12.ceamac@gentoo> (raw)

commit:     fcd645b0be20fa53aa6f58f959e1771a4696ca12
Author:     Huang Rui <vowstar <AT> gmail <DOT> com>
AuthorDate: Sun Aug  6 04:44:18 2023 +0000
Commit:     Viorel Munteanu <ceamac <AT> gentoo <DOT> org>
CommitDate: Sun Aug  6 10:05:12 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fcd645b0

dev-embedded/urjtag: fix the live ebuild

Signed-off-by: Huang Rui <vowstar <AT> gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/32077
Signed-off-by: Viorel Munteanu <ceamac <AT> gentoo.org>

 dev-embedded/urjtag/urjtag-9999.ebuild | 48 ++++++++++++++++++++++++++++------
 1 file changed, 40 insertions(+), 8 deletions(-)

diff --git a/dev-embedded/urjtag/urjtag-9999.ebuild b/dev-embedded/urjtag/urjtag-9999.ebuild
index 290a76a683c9..031c9e8c7232 100644
--- a/dev-embedded/urjtag/urjtag-9999.ebuild
+++ b/dev-embedded/urjtag/urjtag-9999.ebuild
@@ -1,7 +1,11 @@
 # Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=7
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+
+inherit python-r1
 
 if [[ ${PV} == "9999" ]] ; then
 	EGIT_REPO_URI="git://git.code.sf.net/p/urjtag/git"
@@ -17,14 +21,23 @@ HOMEPAGE="https://urjtag.sourceforge.net/"
 
 LICENSE="GPL-2"
 SLOT="0"
-# TODO: Figure out if anyone wants the Python bindings
-IUSE="ftdi readline usb"
+
+IUSE="ftdi ftd2xx python readline usb"
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
 
 DEPEND="ftdi? ( dev-embedded/libftdi:1 )
+	ftd2xx? ( dev-embedded/libftd2xx )
+	python? ( ${PYTHON_DEPS} )
 	readline? ( sys-libs/readline:= )
 	usb? ( virtual/libusb:1 )"
-RDEPEND="${DEPEND}
-	!dev-embedded/jtag"
+RDEPEND="${DEPEND}"
+BDEPEND="
+	python? ( dev-python/setuptools[${PYTHON_USEDEP}] )
+"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-2021.03-fix-python-setup.patch"
+)
 
 src_prepare() {
 	default
@@ -37,16 +50,35 @@ src_prepare() {
 }
 
 src_configure() {
-	use readline || export vl_cv_lib_readline=no
-
 	econf \
 		--disable-werror \
 		--disable-python \
+		$(use_with readline) \
 		$(use_with ftdi libftdi) \
-		$(use_with usb libusb)
+		$(use_with ftd2xx) \
+		$(use_with usb libusb 1.0)
+}
+
+src_compile() {
+	use python && python_copy_sources
+
+	emake
 }
 
 src_install() {
 	default
+
+	if use python; then
+		installation() {
+			cd bindings/python || die
+			ln -s "${S}"/src/.libs ../../src/.libs || die
+			"${EPYTHON}" setup.py install \
+				--root="${D}" \
+				--prefix="${EPREFIX}/usr" || die
+		}
+		python_foreach_impl run_in_build_dir installation
+		python_foreach_impl python_optimize
+	fi
+
 	find "${ED}" -name '*.la' -delete || die
 }


             reply	other threads:[~2023-08-06 10:05 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-06 10:05 Viorel Munteanu [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-08-24 18:37 [gentoo-commits] repo/gentoo:master commit in: dev-embedded/urjtag/ Joonas Niilola
2023-09-15  4:52 Viorel Munteanu
2023-09-15  4:52 Viorel Munteanu
2023-09-07 17:02 Sam James
2023-09-07 14:41 Sam James
2023-09-07 14:41 Sam James
2023-06-08 11:23 Viorel Munteanu
2021-04-18 22:22 Andreas Sturmlechner
2021-02-18  8:37 Sam James
2021-02-16 12:30 Sam James
2021-02-12  9:57 Sam James
2021-02-11  7:55 Sam James
2020-12-27 20:19 Sam James
2019-11-23 18:19 Michał Górny
2019-11-23 18:19 Michał Górny
2017-03-23 20:53 David Seifert
2016-10-30 20:05 Sven Wegener
2016-01-10 11:17 Sven Wegener
2015-12-31 16:23 Sven Wegener
2015-12-31 13:29 Sven Wegener
2015-12-31 13:27 Sven Wegener
2015-12-31 13:11 Sven Wegener
2015-12-31 13:11 Sven Wegener

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1691316312.fcd645b0be20fa53aa6f58f959e1771a4696ca12.ceamac@gentoo \
    --to=ceamac@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox