public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Florian Schmaus" <flow@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-text/pdftk/
Date: Tue, 16 May 2023 14:02:18 +0000 (UTC)	[thread overview]
Message-ID: <1684245441.2c89bec539b30353c485318fcbbda9f1b5c09c94.flow@gentoo> (raw)

commit:     2c89bec539b30353c485318fcbbda9f1b5c09c94
Author:     Volkmar W. Pogatzki <gentoo <AT> pogatzki <DOT> net>
AuthorDate: Fri May 12 13:57:48 2023 +0000
Commit:     Florian Schmaus <flow <AT> gentoo <DOT> org>
CommitDate: Tue May 16 13:57:21 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2c89bec5

app-text/pdftk: update live ebuild

Signed-off-by: Volkmar W. Pogatzki <gentoo <AT> pogatzki.net>
Signed-off-by: Florian Schmaus <flow <AT> gentoo.org>

 app-text/pdftk/pdftk-9999.ebuild | 80 +++++++++++++++++++++++++++++++---------
 1 file changed, 63 insertions(+), 17 deletions(-)

diff --git a/app-text/pdftk/pdftk-9999.ebuild b/app-text/pdftk/pdftk-9999.ebuild
index 01bda985c416..f76cb2d086b7 100644
--- a/app-text/pdftk/pdftk-9999.ebuild
+++ b/app-text/pdftk/pdftk-9999.ebuild
@@ -1,9 +1,13 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
-EAPI=7
+EAPI=8
 
-inherit java-pkg-2 java-ant-2
+JAVA_PKG_IUSE="doc source test"
+MAVEN_ID="com.gitlab.pdftk-java:pdftk-java:3.3.3"
+JAVA_TESTING_FRAMEWORKS="junit-4"
+
+inherit java-pkg-2 java-pkg-simple
 
 DESCRIPTION="gcj-free version of pdftk written in Java"
 HOMEPAGE="https://gitlab.com/pdftk-java/pdftk"
@@ -11,6 +15,7 @@ HOMEPAGE="https://gitlab.com/pdftk-java/pdftk"
 if [[ ${PV} == 9999 ]] ; then
 	inherit git-r3
 	EGIT_REPO_URI="https://gitlab.com/pdftk-java/pdftk/"
+	S="${WORKDIR}/pdftk-${PV}"
 else
 	SRC_URI="https://gitlab.com/pdftk-java/pdftk/-/archive/v${PV}/pdftk-v${PV}.tar.bz2"
 	KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
@@ -20,23 +25,64 @@ fi
 LICENSE="GPL-2"
 SLOT="0"
 
-JAVA_PKG_STRICT="yes"
-EANT_GENTOO_CLASSPATH="bcprov,commons-lang-3.6"
-JAVA_ANT_REWRITE_CLASSPATH="true"
-
-CDEPEND="
+CP_DEPEND="
 	dev-java/bcprov:0
-	dev-java/commons-lang:3.6"
+	dev-java/commons-lang:3.6
+"
 
-RDEPEND="
-	${CDEPEND}
-	>=virtual/jre-1.8:*"
+# Compile dependencies
+# POM: pom.xml
+# test? com.github.stefanbirkner:system-rules:1.19.0 -> !!!groupId-not-found!!!
+# test? junit:junit:4.12 -> >=dev-java/junit-4.13.2:4
 
 DEPEND="
-	${CDEPEND}
-	>=virtual/jdk-1.8:*"
+	>=virtual/jdk-1.8:*
+	${CP_DEPEND}
+	test? (
+		app-text/poppler[cairo]
+		dev-java/system-rules:0
+	)
+"
+
+RDEPEND="
+	>=virtual/jre-1.8:*
+	${CP_DEPEND}"
+
+DOCS=( CHANGELOG.md README.md )
+
+JAVA_LAUNCHER_FILENAME="${PN}"
+JAVA_MAIN_CLASS="com.gitlab.pdftk_java.pdftk"
+JAVA_SRC_DIR="java"
+JAVA_RESOURCE_DIRS="resources/java"
+
+JAVA_TEST_GENTOO_CLASSPATH="junit-4,system-rules"
+JAVA_TEST_SRC_DIR="test"
+
+src_prepare() {
+	default
+	mkdir resources || die
+	cp -r {,resources/}java || die
+	rm -r resources/java/com/gitlab/pdftk_java/com/lowagie/text/pdf/codec || die
+	find resources/java -type f \( -name '*.java' -o -name '*.sh' \) -exec rm -rf {} + || die
+}
 
-src_install() {
-	java-pkg_newjar "build/jar/pdftk.jar"
-	java-pkg_dolauncher ${PN} --main com.gitlab.pdftk_java.pdftk
+src_test() {
+	# some tests seem to need special treatment
+	einfo "Runnig first test"
+	JAVA_TEST_RUN_ONLY=(
+		com.gitlab.pdftk_java.CatTest
+		com.gitlab.pdftk_java.DataTest
+		com.gitlab.pdftk_java.FormTest
+		com.gitlab.pdftk_java.MultipleTest
+	)
+	java-pkg-simple_src_test
+	einfo "Running second test"
+	JAVA_TEST_RUN_ONLY=()
+	JAVA_TEST_EXCLUDES=(
+		com.gitlab.pdftk_java.CatTest
+		com.gitlab.pdftk_java.DataTest
+		com.gitlab.pdftk_java.FormTest
+		com.gitlab.pdftk_java.MultipleTest
+	)
+	java-pkg-simple_src_test
 }


             reply	other threads:[~2023-05-16 14:02 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-16 14:02 Florian Schmaus [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-07-02  6:58 [gentoo-commits] repo/gentoo:master commit in: app-text/pdftk/ Miroslav Šulc
2024-07-01 21:14 Jakov Smolić
2024-07-01 21:14 Jakov Smolić
2024-06-12  7:06 Florian Schmaus
2024-06-02 11:15 Florian Schmaus
2024-06-02 11:15 Florian Schmaus
2023-10-22  7:14 Miroslav Šulc
2023-10-20 20:18 Arthur Zamarin
2023-10-19 12:17 Sam James
2023-10-01  7:32 Miroslav Šulc
2023-10-01  7:32 Miroslav Šulc
2023-09-19 14:10 Miroslav Šulc
2023-05-16 14:02 Florian Schmaus
2023-01-24  9:08 Florian Schmaus
2022-10-28  6:13 Miroslav Šulc
2022-10-27 23:46 Sam James
2022-10-25 11:12 Sam James
2022-10-11 13:02 Miroslav Šulc
2022-10-11  6:48 Agostino Sarubbo
2022-10-10 11:49 Sam James
2022-09-23  9:58 Florian Schmaus
2022-09-10 17:30 Florian Schmaus
2022-09-09  6:43 Florian Schmaus
2022-01-24  9:14 Miroslav Šulc
2022-01-23 13:09 Jakov Smolić
2022-01-23 13:09 Jakov Smolić
2021-12-24  8:16 Miroslav Šulc
2021-12-24  8:16 Miroslav Šulc
2021-07-25  1:10 Sam James
2021-07-18  6:35 Agostino Sarubbo
2021-03-26  7:51 Miroslav Šulc
2021-03-25 21:29 Sam James
2021-02-24 10:58 Miroslav Šulc
2021-02-18 20:11 Sergei Trofimovich
2019-12-02 20:55 Andreas K. Hüttel
2019-05-14 20:40 Patrice Clement
2018-11-24  8:56 Mikle Kolyada
2018-09-05 12:33 Andreas Hüttel
2018-09-05 12:16 Andreas Hüttel
2018-09-05 11:51 Andreas Hüttel
2018-09-02 20:13 Andreas Hüttel
2018-04-08 22:42 Patrice Clement
2017-11-27 17:45 Andreas Hüttel

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=1684245441.2c89bec539b30353c485318fcbbda9f1b5c09c94.flow@gentoo \
    --to=flow@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