public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Sam James" <sam@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-sound/liblc3/
Date: Wed, 22 Nov 2023 18:29:02 +0000 (UTC)	[thread overview]
Message-ID: <1700677715.e1b8a96cfc24d46b49c58e3c9e2eb597fdf47574.sam@gentoo> (raw)

commit:     e1b8a96cfc24d46b49c58e3c9e2eb597fdf47574
Author:     Matoro Mahri <matoro_gentoo <AT> matoro <DOT> tk>
AuthorDate: Wed Nov 22 03:56:49 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Nov 22 18:28:35 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e1b8a96c

media-sound/liblc3: wire up tests

The test/arm and test/neon suites actually run on non-ARM platforms, but
the generic implementations are not endian-safe, and since they're
supposed to test ARM assembly, there's not much point in running them on
other platforms.

Most of the tricks stolen from Debian: deps and rules.

Tested on arm and arm64, as well as other 64-bit BE and LE platforms.

Bug: https://bugs.gentoo.org/896130
Signed-off-by: Matoro Mahri <matoro_gentoo <AT> matoro.tk>
Closes: https://github.com/gentoo/gentoo/pull/33934
Signed-off-by: Sam James <sam <AT> gentoo.org>

 media-sound/liblc3/liblc3-1.0.4-r1.ebuild | 52 +++++++++++++++++++++++++++++++
 1 file changed, 52 insertions(+)

diff --git a/media-sound/liblc3/liblc3-1.0.4-r1.ebuild b/media-sound/liblc3/liblc3-1.0.4-r1.ebuild
new file mode 100644
index 000000000000..13bee49ab7af
--- /dev/null
+++ b/media-sound/liblc3/liblc3-1.0.4-r1.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10,11,12} pypy3 )
+inherit meson python-any-r1
+
+DESCRIPTION="LC3 is an efficient low latency audio codec"
+HOMEPAGE="https://github.com/google/liblc3"
+SRC_URI="https://github.com/google/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="test tools"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86"
+RESTRICT="!test? ( test )"
+
+DEPEND="test? (
+	$(python_gen_any_dep '
+		dev-python/numpy[${PYTHON_USEDEP}]
+		dev-python/scipy[${PYTHON_USEDEP}]
+	')
+)"
+
+python_check_deps() {
+	python_has_version -d "dev-python/numpy[${PYTHON_USEDEP}]" &&
+	python_has_version -d "dev-python/scipy[${PYTHON_USEDEP}]"
+}
+
+pkg_setup() {
+	use test && python-any-r1_pkg_setup
+}
+
+src_prepare() {
+	use arm || rm -rf "test/arm" || die
+	use arm64 || rm -rf "test/neon" || die
+	default
+}
+
+src_configure() {
+	local emesonargs=(
+		# We let users choose to enable LTO
+		-Db_lto=false
+		$(meson_use tools)
+	)
+	meson_src_configure
+}
+
+src_test() {
+	V= emake test CFLAGS:="${CPPFLAGS} ${CFLAGS} -I"$("${EPYTHON}" -c "import numpy;print(numpy.get_include())")""
+}


             reply	other threads:[~2023-11-22 18:29 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-22 18:29 Sam James [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-04-24 23:51 [gentoo-commits] repo/gentoo:master commit in: media-sound/liblc3/ Sam James
2025-04-23 15:52 Sam James
2025-04-22  0:36 Sam James
2025-04-21  6:22 Sam James
2025-04-20  2:10 Sam James
2025-04-20  2:01 Sam James
2025-04-14  2:42 Ionen Wolkens
2025-02-23 18:38 Sam James
2025-02-23  5:11 Sam James
2024-07-17  6:14 Sam James
2024-06-20 17:16 Sam James
2024-06-20 17:16 Sam James
2024-04-29  1:01 Sam James
2023-11-24  9:31 Sam James
2023-11-22 18:29 Sam James
2023-09-27  7:21 Sam James
2023-09-27  6:34 Sam James
2023-09-27  5:09 Sam James
2023-09-27  4:49 Sam James
2023-09-27  4:46 Sam James
2023-08-13  6:49 Sam James
2023-07-28 12:02 Arthur Zamarin
2023-07-28 12:02 Arthur Zamarin
2023-07-28 12:01 Arthur Zamarin
2023-07-28  9:37 Sam James
2023-07-28  7:56 Sam James
2023-07-04  5:46 WANG Xuerui
2023-06-27  5:20 Jakov Smolić
2023-06-26 18:39 Arthur Zamarin
2023-06-26 18:39 Arthur Zamarin
2023-06-26 18:39 Arthur Zamarin
2023-06-26 18:39 Arthur Zamarin
2023-06-26 18:26 Arthur Zamarin
2023-06-26 16:47 Sam James

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=1700677715.e1b8a96cfc24d46b49c58e3c9e2eb597fdf47574.sam@gentoo \
    --to=sam@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