diff options
-rw-r--r-- | games-puzzle/pauker/files/pauker-1.8-r3-project.properties.patch | 24 | ||||
-rw-r--r-- | games-puzzle/pauker/pauker-1.8-r3.ebuild | 70 |
2 files changed, 94 insertions, 0 deletions
diff --git a/games-puzzle/pauker/files/pauker-1.8-r3-project.properties.patch b/games-puzzle/pauker/files/pauker-1.8-r3-project.properties.patch new file mode 100644 index 000000000000..b063b1055621 --- /dev/null +++ b/games-puzzle/pauker/files/pauker-1.8-r3-project.properties.patch @@ -0,0 +1,24 @@ +diff --git a/nbproject/project.properties b/nbproject/project.properties +index 02aef46..edca271 100644 +--- a/nbproject/project.properties ++++ b/nbproject/project.properties +@@ -37,8 +37,8 @@ javac.classpath=\ + # Space-separated list of extra javac options + javac.compilerargs=-Xlint:all,-serial + javac.deprecation=true +-javac.source=1.5 +-javac.target=1.5 ++javac.source=1.8 ++javac.target=1.8 + javac.test.classpath=\ + ${javac.classpath}:\ + ${build.classes.dir}:\ +@@ -64,7 +64,7 @@ jnlp.signed=false + main.class=pauker.program.gui.swing.PaukerFrame + manifest.file=manifest.mf + meta.inf.dir=${src.dir}/META-INF +-platform.active=JDK_1.5 ++platform.active=JDK_1.8 + run.classpath=\ + ${javac.classpath}:\ + ${build.classes.dir} diff --git a/games-puzzle/pauker/pauker-1.8-r3.ebuild b/games-puzzle/pauker/pauker-1.8-r3.ebuild new file mode 100644 index 000000000000..c41b5e3153e2 --- /dev/null +++ b/games-puzzle/pauker/pauker-1.8-r3.ebuild @@ -0,0 +1,70 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +JAVA_PKG_IUSE="doc source" + +inherit desktop java-pkg-2 java-ant-2 + +DESCRIPTION="A java based flashcard program" +HOMEPAGE="https://pauker.sourceforge.net/" +SRC_URI="mirror://sourceforge/project/pauker/pauker/${PV}/${P}.src.jar" +S="${WORKDIR}" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +BDEPEND="app-arch/unzip" +COMMON_DEP=" + dev-java/browserlauncher2:1.0 + dev-java/javahelp + dev-java/lucene:2.4 + dev-java/swing-layout:1 +" +RDEPEND="${COMMON_DEP} + >=virtual/jre-1.8:*" +DEPEND="${COMMON_DEP} + >=virtual/jdk-1.8:*" +BDEPEND="app-arch/unzip" + +PATCHES=( + "${FILESDIR}/${PN}_bundledjars.patch" + "${FILESDIR}/pauker-1.8-r3-project.properties.patch" +) + +src_prepare() { + default + find . -iname '*.jar' -delete || die + + java-pkg_jar-from --into libs browserlauncher2-1.0 browserlauncher2.jar BrowserLauncher2-1_3.jar + java-pkg_jar-from --into libs javahelp jhall.jar + java-pkg_jar-from --into libs lucene-2.4 lucene-core.jar lucene-core-2.4.0.jar + java-pkg_jar-from --into libs swing-layout-1 swing-layout.jar +} + +src_compile() { + eant -Dfile.reference.BrowserLauncher2-1_3.jar="libs/BrowserLauncher2-1_3.jar" \ + -Dlibs.swing-layout.classpath="libs/swing-layout.jar" \ + -Dplatforms.JDK_1.8.home="${JAVA_HOME}" jar $(use_doc javadoc) +} + +#test depend on jemmy, a netbeans module. so unless it is packaged separately +#tests cannot be build. + +src_install() { + java-pkg_jarinto "/usr/share/${PN}" + java-pkg_newjar "dist/${P}.jar" + + java-pkg_dolauncher ${PN} \ + -into "/usr" \ + --pwd /usr/share/${PN} \ + --main pauker.program.gui.swing.PaukerFrame + + use doc && java-pkg_dojavadoc dist/javadoc + use source && java-pkg_dosrc src + + newicon src/pauker/icons/repeat.png ${PN}.png + make_desktop_entry pauker Pauker +} |