diff options
Diffstat (limited to 'dev-java')
-rw-r--r-- | dev-java/Manifest.gz | bin | 58146 -> 58487 bytes | |||
-rw-r--r-- | dev-java/jmc/Manifest | 3 | ||||
-rw-r--r-- | dev-java/jmc/jmc-8.3.0.ebuild | 74 | ||||
-rw-r--r-- | dev-java/jmc/metadata.xml | 10 | ||||
-rw-r--r-- | dev-java/owasp-java-encoder/Manifest | 4 | ||||
-rw-r--r-- | dev-java/owasp-java-encoder/files/owasp-java-encoder-1.2.3-BenchmarkTest.patch | 46 | ||||
-rw-r--r-- | dev-java/owasp-java-encoder/metadata.xml | 10 | ||||
-rw-r--r-- | dev-java/owasp-java-encoder/owasp-java-encoder-1.2.3.ebuild | 34 |
8 files changed, 181 insertions, 0 deletions
diff --git a/dev-java/Manifest.gz b/dev-java/Manifest.gz Binary files differindex 1fde1bce5282..bd415d6fb90f 100644 --- a/dev-java/Manifest.gz +++ b/dev-java/Manifest.gz diff --git a/dev-java/jmc/Manifest b/dev-java/jmc/Manifest new file mode 100644 index 000000000000..ef6b049b26ed --- /dev/null +++ b/dev-java/jmc/Manifest @@ -0,0 +1,3 @@ +DIST jmc-8.3.0.ga.tar.gz 40714977 BLAKE2B 7ec59a23a62ede30844cee71bd1c859974ee3112bb5cc1b31b65f63f0bbf1b2689a94180d0fba687858353d05b3d1046a7b98688f01312606332bfd9d99ac9e8 SHA512 e4fb9fe8fa0ebfd3dd550dfa3412a4a7f88cb46eedaba329c4fd1a693047377b5c57db8ef8751f5966bce7621d6d2eff52a8d1921c089e7b1c3104684918fde9 +EBUILD jmc-8.3.0.ebuild 1952 BLAKE2B 2375b10a7fdb7a87384133ac3f1e3ba7333f436e3ba69717fb52f2aea401d8d6b557ca68a8225af3797110ebde07fd38b2594ca54339de99db13ebf969c3bada SHA512 e18a071f1d77cb04601c6f1fea174ebc85c813943078fe78667e2e2487e85e9493ecc7efc4ea1165cad1bf98e4cdcc2cf0740cc78505d1805e0c5489b8c350f3 +MISC metadata.xml 293 BLAKE2B 4bc56b086092dcd5406674f25f67455b30a2d9fe8360c7cd6b65db33310c677a19889fe97896cb4822f6e9b245b9fecb9049dc586198e905e693943bcf8a93b7 SHA512 5c21de269ab7431db4316d7059f612ee6caf3ab2cb62bd9ff00d56d8bdcc30cd21f5775b35236e1caf7c0eb0ee86f4bfcd468e8d6b200922ce76fbd44a9d62b3 diff --git a/dev-java/jmc/jmc-8.3.0.ebuild b/dev-java/jmc/jmc-8.3.0.ebuild new file mode 100644 index 000000000000..9db8fbfc2388 --- /dev/null +++ b/dev-java/jmc/jmc-8.3.0.ebuild @@ -0,0 +1,74 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +JAVA_PKG_IUSE="doc source" +MAVEN_PROVIDES=" + org.openjdk.jmc:common:${PV} + org.openjdk.jmc:flightrecorder:${PV} +" + +inherit java-pkg-2 java-pkg-simple + +DESCRIPTION="JDK Mission Control" +HOMEPAGE="https://openjdk.org/projects/jmc/" +SRC_URI="https://github.com/openjdk/jmc/archive/${PV}-ga.tar.gz -> ${P}.ga.tar.gz" +S="${WORKDIR}/${P}-ga" + +LICENSE="UPL-1.0" +SLOT="0" +KEYWORDS="~amd64" + +DEPEND=" + dev-java/lz4-java:0 + dev-java/owasp-java-encoder:0 + >=virtual/jdk-1.8:* +" +RDEPEND=">=virtual/jre-1.8:*" + +src_compile() { + einfo "Compiling jmc-common.jar" + JAVA_AUTOMATIC_MODULE_NAME="org.openjdk.jmc.common" + JAVA_CLASSPATH_EXTRA=" + lz4-java + owasp-java-encoder + " + JAVA_JAR_FILENAME="jmc-common.jar" + JAVA_RESOURCE_DIRS="core/org.openjdk.jmc.common/src/main/resources" + JAVA_SRC_DIR="core/org.openjdk.jmc.common/src/main/java" + java-pkg-simple_src_compile + JAVA_GENTOO_CLASSPATH_EXTRA+=":jmc-common.jar" + rm -r target || die + + einfo "Compiling jmc-flightrecorder.jar" + JAVA_AUTOMATIC_MODULE_NAME="org.openjdk.jmc.flightrecorder" + JAVA_JAR_FILENAME="jmc-flightrecorder.jar" + JAVA_RESOURCE_DIRS="core/org.openjdk.jmc.flightrecorder/src/main/resources" + JAVA_SRC_DIR="core/org.openjdk.jmc.flightrecorder/src/main/java" + java-pkg-simple_src_compile + JAVA_GENTOO_CLASSPATH_EXTRA+=":jmc-flightrecorder.jar" + rm -r target || die + + if use doc; then + JAVA_SRC_DIR=() + JAVA_SRC_DIR=( + "core/org.openjdk.jmc.common/src/main/java" + "core/org.openjdk.jmc.flightrecorder/src/main/java" + ) + JAVA_JAR_FILENAME="ignoreme.jar" + java-pkg-simple_src_compile + fi +} + +src_install() { + default + java-pkg_dojar jmc-common.jar jmc-flightrecorder.jar + if use doc; then + java-pkg_dojavadoc target/api + fi + if use source; then + java-pkg_dosrc "core/org.openjdk.jmc.common/src/main/java/*" + java-pkg_dosrc "core/org.openjdk.jmc.flightrecorder/src/main/java/*" + fi +} diff --git a/dev-java/jmc/metadata.xml b/dev-java/jmc/metadata.xml new file mode 100644 index 000000000000..13df86c0e8a8 --- /dev/null +++ b/dev-java/jmc/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>java@gentoo.org</email> + </maintainer> + <upstream> + <remote-id type="github">openjdk/jmc</remote-id> + </upstream> +</pkgmetadata> diff --git a/dev-java/owasp-java-encoder/Manifest b/dev-java/owasp-java-encoder/Manifest new file mode 100644 index 000000000000..12fc30747a35 --- /dev/null +++ b/dev-java/owasp-java-encoder/Manifest @@ -0,0 +1,4 @@ +AUX owasp-java-encoder-1.2.3-BenchmarkTest.patch 1971 BLAKE2B 1a4d60fb1b16b98878f1c9bd056d1600327768613a9df9017395f40f8d249b7034bb44b5573638307398ab5296c01f618f0e5348023e84aa526ca0d76ab41113 SHA512 376c5cad6e7cb4ebc3fe6998d90155c71bdfa793ecb132ea49e018169f6fe150485cd0b79984e5f88c96afb3ceb80cfdb68f49fe9aea4cabffc29ec3a7fc40e0 +DIST owasp-java-encoder-1.2.3.tar.gz 134303 BLAKE2B 76b9652863fcdfdce82bd26062fa500bb92b21ba6edff7b3f409a1375e135176f826dca4bb02b4dd48905112ae20a0af0a1f09cb4e21ea41c672a44c52fea209 SHA512 19c13894ce68325553bdbee41190cb113d698c79ec74885604fd9db4f083efe0fcdc4313b7191014bfd972d0ee52f0fbe0621d7bb407745bd1feeb2ac9e49783 +EBUILD owasp-java-encoder-1.2.3.ebuild 838 BLAKE2B b3894fa1e53146bcb4f384dbc316413c8d59e0e0d0898c9347edd9d0dee23bc01db4178514a07c61d5339ee8fec0f87c6b8f22a68040349ea0c17e590551e337 SHA512 31bcf6e488822edecf2e2c1175da97ddf6e03c7d4622daf6e26849dd82d1bc7cd4c139d7e844c7338c659d4386ae3a107aa17f64cff3fee066487c0e7cc023a3 +MISC metadata.xml 306 BLAKE2B 8dfe8c2f01f21e1e865973e9865f3a9439a7a378d2acc52a6e148dcf70e3ef0f0fcce4efff20d89c0e2872e5d23fb0795b2d669eb18c278abf3ae6406db8f84a SHA512 c696a3c2763ff1868b3b80ee7c4b47fc697679a0539c2b9b300f0a969ad3bcd168e75f5d0275c10bac5b1ba7052e2e498c2c7daf3290f593cd0be8c9f35940fd diff --git a/dev-java/owasp-java-encoder/files/owasp-java-encoder-1.2.3-BenchmarkTest.patch b/dev-java/owasp-java-encoder/files/owasp-java-encoder-1.2.3-BenchmarkTest.patch new file mode 100644 index 000000000000..de988462ede7 --- /dev/null +++ b/dev-java/owasp-java-encoder/files/owasp-java-encoder-1.2.3-BenchmarkTest.patch @@ -0,0 +1,46 @@ +There were 2 failures: +1) Encode.forHtmlUnquotedAttribute(org.owasp.encoder.BenchmarkTest$1$3) +junit.framework.AssertionFailedError + at junit.framework.Assert.fail(Assert.java:55) + at junit.framework.Assert.assertTrue(Assert.java:22) + at junit.framework.Assert.assertTrue(Assert.java:31) + at junit.framework.TestCase.assertTrue(TestCase.java:200) + at org.owasp.encoder.BenchmarkTest$1$3.runTest(BenchmarkTest.java:115) +2) Encode.forUriComponent(org.owasp.encoder.BenchmarkTest$1$3) +junit.framework.AssertionFailedError + at junit.framework.Assert.fail(Assert.java:55) + at junit.framework.Assert.assertTrue(Assert.java:22) + at junit.framework.Assert.assertTrue(Assert.java:31) + at junit.framework.TestCase.assertTrue(TestCase.java:200) + at org.owasp.encoder.BenchmarkTest$1$3.runTest(BenchmarkTest.java:115) + +FAILURES!!! +Tests run: 962, Failures: 2 +--- a/src/test/java/org/owasp/encoder/BenchmarkTest.java ++++ b/src/test/java/org/owasp/encoder/BenchmarkTest.java +@@ -209,12 +209,6 @@ public class BenchmarkTest extends TestCase { + return Encode.forXml(input); + } + }, +- new Bench("Encode.forHtmlUnquotedAttribute") { +- @Override +- public String encode(String input) { +- return Encode.forHtmlUnquotedAttribute(input); +- } +- }, + new Bench("Encode.forJavaScript") { + @Override + public String encode(String input) { +@@ -227,12 +221,6 @@ public class BenchmarkTest extends TestCase { + return Encode.forCssString(input); + } + }, +- new Bench("Encode.forUriComponent") { +- @Override +- public String encode(String input) { +- return Encode.forUriComponent(input); +- } +- }, + new Bench("Encode.forCDATA") { + @Override + public String encode(String input) { diff --git a/dev-java/owasp-java-encoder/metadata.xml b/dev-java/owasp-java-encoder/metadata.xml new file mode 100644 index 000000000000..caf58d352146 --- /dev/null +++ b/dev-java/owasp-java-encoder/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>java@gentoo.org</email> + </maintainer> + <upstream> + <remote-id type="github">OWASP/owasp-java-encoder</remote-id> + </upstream> +</pkgmetadata> diff --git a/dev-java/owasp-java-encoder/owasp-java-encoder-1.2.3.ebuild b/dev-java/owasp-java-encoder/owasp-java-encoder-1.2.3.ebuild new file mode 100644 index 000000000000..57b4175762d7 --- /dev/null +++ b/dev-java/owasp-java-encoder/owasp-java-encoder-1.2.3.ebuild @@ -0,0 +1,34 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +JAVA_PKG_IUSE="doc source test" +MAVEN_ID="org.owasp.encoder:encoder:${PV}" +JAVA_TESTING_FRAMEWORKS="junit-4" + +inherit java-pkg-2 java-pkg-simple + +DESCRIPTION="OWASP Java Encoder" +HOMEPAGE="https://owasp.org/www-project-java-encoder/" +SRC_URI="https://github.com/OWASP/owasp-java-encoder/archive/v${PV}.tar.gz -> ${P}.tar.gz" +S="${WORKDIR}/${P}/core" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~amd64" + +RDEPEND=">=virtual/jre-1.8:*" +DEPEND=">=virtual/jdk-1.8:*" + +PATCHES=( "${FILESDIR}/owasp-java-encoder-1.2.3-BenchmarkTest.patch" ) + +JAVA_SRC_DIR="src/main/java" +JAVA_TEST_GENTOO_CLASSPATH="junit-4" +JAVA_TEST_RESOURCE_DIRS="src/test/resources" +JAVA_TEST_SRC_DIR="src/test/java" + +src_prepare() { + default #780585 + java-pkg-2_src_prepare +} |