From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 2DEE51582EF for ; Mon, 17 Feb 2025 20:19:02 +0000 (UTC) Received: from lists.gentoo.org (bobolink.gentoo.org [140.211.166.189]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) (Authenticated sender: relay-lists.gentoo.org@gentoo.org) by smtp.gentoo.org (Postfix) with ESMTPSA id 0E07C34318A for ; Mon, 17 Feb 2025 20:19:02 +0000 (UTC) Received: from bobolink.gentoo.org (localhost [127.0.0.1]) by bobolink.gentoo.org (Postfix) with ESMTP id 45BF7110471; Mon, 17 Feb 2025 20:18:58 +0000 (UTC) Received: from smtp.gentoo.org (mail.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by bobolink.gentoo.org (Postfix) with ESMTPS id 387C5110470 for ; Mon, 17 Feb 2025 20:18:58 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id D99E134312A for ; Mon, 17 Feb 2025 20:18:57 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 3C0652637 for ; Mon, 17 Feb 2025 20:18:56 +0000 (UTC) From: "Sam James" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sam James" Message-ID: <1739823504.d5c62bd26e15d585d1516010cdbde0d809fd5ae8.sam@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: media-libs/zxing-cpp/ X-VCS-Repository: repo/gentoo X-VCS-Files: media-libs/zxing-cpp/Manifest media-libs/zxing-cpp/zxing-cpp-2.2.1-r1.ebuild X-VCS-Directories: media-libs/zxing-cpp/ X-VCS-Committer: sam X-VCS-Committer-Name: Sam James X-VCS-Revision: d5c62bd26e15d585d1516010cdbde0d809fd5ae8 X-VCS-Branch: master Date: Mon, 17 Feb 2025 20:18:56 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 8a53eda6-cc56-4740-b2c6-691be0e6f5f2 X-Archives-Hash: ce6d92f6f4dac41f35824e81bcf62a26 commit: d5c62bd26e15d585d1516010cdbde0d809fd5ae8 Author: Sam James gentoo org> AuthorDate: Mon Feb 17 20:10:43 2025 +0000 Commit: Sam James gentoo org> CommitDate: Mon Feb 17 20:18:24 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d5c62bd2 media-libs/zxing-cpp: wire up tests Fortunately, the situation has improved since bug #793173. Wire up the tests accordingly. Note that upstream do say that the unit tests option "shouldn't be used in production builds". My assumption is that this is because of it setting ZXING_BUILD_FOR_TEST, but when looking at use of that, I can't see anything harmful. Bug: https://bugs.gentoo.org/793173 Signed-off-by: Sam James gentoo.org> media-libs/zxing-cpp/Manifest | 1 + media-libs/zxing-cpp/zxing-cpp-2.2.1-r1.ebuild | 48 ++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) diff --git a/media-libs/zxing-cpp/Manifest b/media-libs/zxing-cpp/Manifest index 34cf06914feb..e5d66734f685 100644 --- a/media-libs/zxing-cpp/Manifest +++ b/media-libs/zxing-cpp/Manifest @@ -1 +1,2 @@ +DIST zxing-cpp-2.2.1-test-samples.tar.gz 97082308 BLAKE2B bcea839f766e5696bcaab58d1483e43ef3d4b504979ea4db3114236853db92c64f7079ed91977a158cda745d8a08c0c249bf1b10382daf5a9816bf4280b95092 SHA512 4de268d36a337d233a60eed477e8421294d42f357534f21aba9574ec929809a4666fe7a55e3b3ac1518460aedfbb0d615659cc0a170e3685790745066339b064 DIST zxing-cpp-2.2.1.tar.gz 891055 BLAKE2B c6a3343cd0389d930e83dd9db4d6aeca6d4dda715c22c0b10dd76460e9d55bdd8e994c2ac24ba5d5a4f5e2069fcb035b2e4651a380b6b39bcce4b90d0c754df8 SHA512 f1de8df783061a152a18cd9102ac0c579c40c76ab4a5ba9f30bcb8ddb532f3fac08736840a631adbf7c30a7fa00ce8d65625c8cd695288620601708e8f256a53 diff --git a/media-libs/zxing-cpp/zxing-cpp-2.2.1-r1.ebuild b/media-libs/zxing-cpp/zxing-cpp-2.2.1-r1.ebuild new file mode 100644 index 000000000000..659cf14edc25 --- /dev/null +++ b/media-libs/zxing-cpp/zxing-cpp-2.2.1-r1.ebuild @@ -0,0 +1,48 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +DESCRIPTION="C++ Multi-format 1D/2D barcode image processing library" +HOMEPAGE="https://github.com/zxing-cpp/zxing-cpp" +SRC_URI=" + https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz + test? ( https://github.com/zxing-cpp/zxing-cpp/releases/download/v${PV}/test_samples.tar.gz -> ${P}-test-samples.tar.gz ) +" + +LICENSE="Apache-2.0" +SLOT="0/3" +KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc64 ~riscv ~x86" +IUSE="test" +RESTRICT="!test? ( test )" + +DEPEND=" + test? ( + dev-cpp/gtest + dev-libs/stb + ) +" + +PATCHES=( + "${FILESDIR}/${P}-cmake.patch" + "${FILESDIR}/${P}-cxx20.patch" # bug 939897 +) + +src_prepare() { + if use test ; then + ln -s "${WORKDIR}"/test/samples "${S}"/test/samples || die + fi + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DBUILD_EXAMPLES=OFF # nothing is installed + -DBUILD_BLACKBOX_TESTS=$(usex test) + -DBUILD_UNIT_TESTS=$(usex test) + ) + cmake_src_configure +}