summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorgy Yakovlev <gyakovlev@gentoo.org>2020-09-19 12:31:23 -0700
committerGeorgy Yakovlev <gyakovlev@gentoo.org>2020-09-19 12:32:39 -0700
commit2feaf6caf827123788b3e1d1eacac2a6001f2d00 (patch)
treeca6776296bad89dbdba5fdac861988a1ef3972ba /dev-java/openjfx
parentgnome-base/gnome-keyring: Port to python3 (diff)
downloadgentoo-2feaf6caf827123788b3e1d1eacac2a6001f2d00.tar.gz
gentoo-2feaf6caf827123788b3e1d1eacac2a6001f2d00.tar.bz2
gentoo-2feaf6caf827123788b3e1d1eacac2a6001f2d00.zip
dev-java/openjfx: add 8.999 version
it's last tip version of publicly available openjfx-8 with security and reliability patches backported. it's possible to toggle avplugin build independently of media now, but it's still behind media useflag for now. also switched to gradle-4.10.3 patches taken from https://github.com/jschwartzenberg/openjfx8 Bug: https://bugs.gentoo.org/547918 Package-Manager: Portage-3.0.7, Repoman-3.0.1 Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'dev-java/openjfx')
-rw-r--r--dev-java/openjfx/Manifest3
-rw-r--r--dev-java/openjfx/files/8/don-t-force-msse.patch51
-rw-r--r--dev-java/openjfx/openjfx-8.999.ebuild198
3 files changed, 252 insertions, 0 deletions
diff --git a/dev-java/openjfx/Manifest b/dev-java/openjfx/Manifest
index 28cb9dbe6dac..82c29bc5bef8 100644
--- a/dev-java/openjfx/Manifest
+++ b/dev-java/openjfx/Manifest
@@ -1,5 +1,6 @@
DIST ST4-4.0.8.jar 239543 BLAKE2B 72d257c6d0f1b3bde0afce805128dd38d8520b2073377bbb995fed3b4e18a3ea69d508d6d7554755ec68bf50940082b896ed89998a5178272d24376404b389c5 SHA512 9877289297cd5b15ad464a19467699387f57c510fe8a476e07e9d2334bd11933f9bdb9c6caa4972d4d4c84b56740c6d885cd39300dd7ce35b7c5bde536238086
DIST antlr4-4.7.2-complete.jar 2079769 BLAKE2B 9407e5096b5943702a1375f568957f35486a80f122bc59c5ec8e899f59214c43ee4ece551d9078de14b7707d85f9306ae99953981c755a1e1205d83412010738 SHA512 e788d28796c8925a158f0a09048590bdcf6730d46dcb8a12b362cbcc80a7ceb76374b2675987c953faecd3cf4a847b1571485a71081a84684170d25d05176a11
+DIST gradle-4.10.3-bin.zip 78422006 BLAKE2B f565e591751acb5b05c261b3d8dbc8e07f76b48c73516f6cb1b2846ebf0bbf38000b9a61790e9b3055bddd9f9846d61979d187f4a30c317a1de98546891d9d2d SHA512 fd3f4cfbd5262cc8514b7fb3e303ef46b9ca4b22901f1fe848ec4679f8d6bc283bde12ec584437624f0acf5486e5663966ad0736bf8ab341ac3e2667f514ceec
DIST gradle-4.8-bin.zip 75885015 BLAKE2B eb6592afe122690f5e013abec2821beabac070563556ceec67ce02506582d4d9ac9c5d9f97ad2c464e442446f26ff90e9ead2c04e462a564411259564e3332c6 SHA512 4b351c9c5b0970bafb3b2b9b9e2ec9f37ff681cc3ac30004852d712cf8bb83061211a58e5b1f101813cde6a0aec914badf4ef0a806eec603418b851b64a06882
DIST gunit-3.5.2.jar 287425 BLAKE2B 86e759c5bb164758b689d93bef4b6a0bcb39eb9fee28d2a8dc113a4c97e5e8516b55ada87c27738ffa0fc512805caa338d8649f6f5c9ba36490c4c3ebed86fdd SHA512 c9f14dacec2f22f62b7d3849d1c0e9d626b3dc20eb74a85b32f1901f6279b7b84af095107128bcbe80c49ac05448a713309b60d0c3d2f88e0bca8a14690292b2
DIST lucene-core-7.1.0.jar 2779248 BLAKE2B 9edea1cfdeca2f2ec9e5c014e575774dc32fa5cf12ba02fd419fc252da10c03cd9f6cda989203211de4bc2ffcd2e79e8b97914e9792951bb0877a203760f07ad SHA512 0cd96016de2bc7ad94779e30348c443cf6028119fdae42c6f29e33d84495876a7519640f20680762324ea40c42e21b595f79cd606a6142b9875501f1e9179678
@@ -9,3 +10,5 @@ DIST lucene-queryparser-7.1.0.jar 384680 BLAKE2B adce2572de9f534323eead31dd30f97
DIST lucene-sandbox-7.1.0.jar 182914 BLAKE2B 70c795f84d8f0908abe47db77f632eeb6571a77e1445b8ab04a75080cea40e3b8171071965ff7fd9f6d39a450dd33144e922d19c1f07c605de54b45e3e881323 SHA512 6faf9fd9c7c082bf062adb6a28d89447e6e27152eb3f0a325081e5f791196e5440334632ccbf9c458940220676f7e73390a174889d9b7a656d088b3dade5d500
DIST openjfx-11.0.9_p0.tar.bz2 64148934 BLAKE2B 317fb1c9ea99816ecbd8ab64ed3a6ad0aaa319bedd17bf71ee192c5e610fea14611f3938302f1caf666980bcc7d4787f770e36aec1884a73dac3ddba8e1a878f SHA512 8b6d339131f096b4490d7a8c4a20c15362b4f6c6aa4ddd74f610f3b5a8b8c7aac3ab123dcdd5488cc37dc38f1536ce1db95286f4233ee4db1845d1bd560b2236
DIST openjfx-8.202.tar.bz2 62024068 BLAKE2B 006d9a3922812b58a80b6c8e2c80d758b7e18375da5667141cd266b5ce6ae4859d95d7a6701031926db1ce12b5638dfc6ff710cbe8e6c0bc74f347dc0c5f167c SHA512 6759c6422bfc18f78877b13ac664da23c820e8c37f31f3b470760e344b2b6a18936c5a70e3a495addf2129c2548375dc5588147eb0cefbf41dae258ef0d8896c
+DIST openjfx-8.999-backports.tar.xz 2794912 BLAKE2B cdcef2e443dce274b90ce5d0d148e7d10e73eebd9a62ec1514bc13017defa624ce6486f00de80f03d055d2294c9656de9bd3965bb07393d4397a201023a52a69 SHA512 eabbce2f230ef37d392d564d272a95d0f5225cfad0441268b020200e63fbb15b1883df3f21b5f75e34e8b2cf61bc3d843451315a51f1ec2cd487abaae3ee7893
+DIST openjfx-8.999.tar.bz2 62286455 BLAKE2B c9a714a618d9ae02768dae6128756d64b2b6299a36a6ad9828bf2213dc641cbbcaa2d3f3e0b4913bb60893419a2d5c730ca2db88f759bbd94b3e83112199278c SHA512 6049730b72e569939fed3d62b46a409e949b4c2309f4355253c8c891799c7fb5138e20aa217454fbbd78b1dd99c254b34b3fe6c9cbb35854bd8656993655bf32
diff --git a/dev-java/openjfx/files/8/don-t-force-msse.patch b/dev-java/openjfx/files/8/don-t-force-msse.patch
new file mode 100644
index 000000000000..2f5d56718cca
--- /dev/null
+++ b/dev-java/openjfx/files/8/don-t-force-msse.patch
@@ -0,0 +1,51 @@
+From 6483d73551590e8036cd5ec6d317e8114b403f36 Mon Sep 17 00:00:00 2001
+From: Georgy Yakovlev <gyakovlev@gentoo.org>
+Date: Sun, 26 Apr 2020 20:57:39 -0700
+Subject: [PATCH] don't force msse
+
+---
+ .../main/native/gstreamer/projects/linux/avplugin/Makefile | 1 -
+ .../native/gstreamer/projects/linux/fxplugins/Makefile | 1 -
+ .../media/src/main/native/jfxmedia/projects/linux/Makefile | 1 -
+ modules/web/src/main/native/Tools/Scripts/webkitdirs.pm | 7 -------
+ 4 files changed, 10 deletions(-)
+
+diff --git a/modules/media/src/main/native/gstreamer/projects/linux/avplugin/Makefile b/modules/media/src/main/native/gstreamer/projects/linux/avplugin/Makefile
+index df9f7f21..f82f0537 100644
+--- a/modules/media/src/main/native/gstreamer/projects/linux/avplugin/Makefile
++++ b/modules/media/src/main/native/gstreamer/projects/linux/avplugin/Makefile
+@@ -28,7 +28,6 @@ CFLAGS = -fPIC \
+ -Wformat-security \
+ -Werror=implicit-function-declaration \
+ -fstack-protector \
+- -msse2 \
+ -fbuiltin \
+ -DHAVE_STDINT_H \
+ -DLINUX \
+diff --git a/modules/media/src/main/native/gstreamer/projects/linux/fxplugins/Makefile b/modules/media/src/main/native/gstreamer/projects/linux/fxplugins/Makefile
+index fd3847d0..3887ac6d 100644
+--- a/modules/media/src/main/native/gstreamer/projects/linux/fxplugins/Makefile
++++ b/modules/media/src/main/native/gstreamer/projects/linux/fxplugins/Makefile
+@@ -25,7 +25,6 @@ CFLAGS = -fPIC \
+ -Wformat-security \
+ -Werror=implicit-function-declaration \
+ -fstack-protector \
+- -msse2 \
+ -fbuiltin \
+ -DHAVE_STDINT_H \
+ -DLINUX \
+diff --git a/modules/media/src/main/native/jfxmedia/projects/linux/Makefile b/modules/media/src/main/native/jfxmedia/projects/linux/Makefile
+index 3d089501..10fad68f 100644
+--- a/modules/media/src/main/native/jfxmedia/projects/linux/Makefile
++++ b/modules/media/src/main/native/jfxmedia/projects/linux/Makefile
+@@ -44,7 +44,6 @@ ifdef HOST_COMPILE
+ -Wformat-security \
+ -fstack-protector \
+ -Werror=implicit-function-declaration \
+- -msse2 \
+ -DGSTREAMER_LITE
+
+ INCLUDES = $(BASE_INCLUDES) \
+--
+2.26.2
+
diff --git a/dev-java/openjfx/openjfx-8.999.ebuild b/dev-java/openjfx/openjfx-8.999.ebuild
new file mode 100644
index 000000000000..71f180d6d92c
--- /dev/null
+++ b/dev-java/openjfx/openjfx-8.999.ebuild
@@ -0,0 +1,198 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+JAVA_PKG_IUSE="doc source"
+
+inherit java-pkg-2 java-pkg-simple multiprocessing toolchain-funcs
+
+EGRADLE_VER="4.10.3"
+EHG_COMMIT="9f49e3b6147f"
+
+DESCRIPTION="Java OpenJFX 8 client application platform"
+HOMEPAGE="https://openjfx.io"
+SRC_URI="
+ https://hg.openjdk.java.net/${PN}/8u-dev/rt/archive/${EHG_COMMIT}.tar.bz2 -> ${P}.tar.bz2
+ https://dev.gentoo.org/~gyakovlev/distfiles/${P}-backports.tar.xz
+ https://services.gradle.org/distributions/gradle-${EGRADLE_VER}-bin.zip
+"
+
+LICENSE="GPL-2-with-classpath-exception"
+SLOT="$(ver_cut 1)"
+KEYWORDS="~amd64 ~ppc64"
+
+IUSE="debug doc media cpu_flags_x86_sse2"
+
+DEPEND="
+ app-arch/unzip
+ >=dev-java/ant-core-1.8.2:0
+ >=dev-java/antlr-2.7.7-r7:0
+ dev-java/antlr:3
+ dev-java/stringtemplate:0
+ dev-java/swt:4.10[cairo,opengl]
+ sys-devel/bison
+ sys-devel/flex
+ virtual/jdk:1.8
+ virtual/pkgconfig
+"
+
+RDEPEND="
+ dev-java/swt:4.10[cairo,opengl]
+ virtual/jre:1.8
+"
+
+REQUIRED_USE="amd64? ( cpu_flags_x86_sse2 )"
+
+RESTRICT="test" # needs junit version we don't have, fragile
+
+# eclass overrides it, set back to normal
+S="${WORKDIR}/${P}"
+
+# FIXME: majority of flags are honored, needs a bit more patching
+QA_FLAGS_IGNORED=".*"
+
+JAVA_PKG_WANT_BUILD_VM="openjdk-8"
+JAVA_PKG_WANT_SOURCE="1.8"
+JAVA_PKG_WANT_TARGET="1.8"
+
+PATCHES=(
+ "${FILESDIR}"/8/99-sysdeps.patch
+ "${FILESDIR}"/8/disable-online-repos.patch
+ "${FILESDIR}"/8/respect_flags.patch
+ "${FILESDIR}"/8/0000-Fix-wait-call-in-PosixPlatform.patch
+ "${FILESDIR}"/8/0001-Change-Lucene.patch
+ "${FILESDIR}"/8/0003-fix-cast-between-incompatible-function-types.patch
+ "${FILESDIR}"/8/0004-Fix-Compilation-Flags.patch
+ "${FILESDIR}"/8/0005-don-t-include-xlocale.h.patch
+ "${FILESDIR}"/8/06-disable-architecture-verification.patch
+ "${FILESDIR}"/8/07-disable-assembler-on-unsupported-archs.patch
+ "${FILESDIR}"/8/10-javadoc-locale.patch
+ "${FILESDIR}"/8/Wno-error.patch
+ "${FILESDIR}"/8/don-t-force-msse.patch
+ "${FILESDIR}"/8/fxpackager-don-t-include-obsolete-sys-sysctl.h.patch
+)
+
+egradle() {
+ local GRADLE_HOME="${WORKDIR}/gradle-${EGRADLE_VER}"
+ local gradle="${GRADLE_HOME}/bin/gradle"
+ local gradle_args=(
+ --info
+ --stacktrace
+ --no-build-cache
+ --no-daemon
+ --offline
+ --gradle-user-home "${T}/gradle_user_home"
+ --project-cache-dir "${T}/gradle_project_cache"
+ )
+
+ export GRADLE_HOME
+
+ # FIXME: build.gradle believes $ANT_HOME/bin/ant shoud exist
+ unset ANT_HOME
+
+ einfo "gradle "${gradle_args[@]}" ${@}"
+ # TERM needed, otherwise gradle may fail on terms it does not know about
+ TERM="xterm" "${gradle}" "${gradle_args[@]}" ${@} || die "gradle failed"
+}
+
+src_unpack() {
+ default
+ mv -v "rt-${EHG_COMMIT}" "${P}" || die
+}
+
+src_prepare() {
+ eapply "${WORKDIR}/${P}-backports"
+ default
+
+ # this will create local jar storage to be used as ivy repo
+ local d="${T}/jars"
+ mkdir "${d}" || die
+
+ # we need jars subdir in every prokect so gradle can find them
+ # only system jars, no bundling
+ local target targets
+ targets=(
+ jars
+ buildSrc/jars
+ modules/{base,builders,controls,extensions,fxml}/jars
+ modules/{graphics,jmx,media,swing,swt,web,fxpackager}/jars
+ )
+ einfo "Copying system jars"
+ for target in ${targets[@]}; do
+ ln -vs "${T}/jars" "${target}" || die
+ done
+
+ local swt_file_name="$(java-pkg_getjars swt-4.10)"
+ java-pkg_jar-from --build-only --into "${d}" ant-core ant.jar ant-1.8.2.jar
+ java-pkg_jar-from --build-only --into "${d}" ant-core ant-launcher.jar ant-launcher-1.8.2.jar
+ java-pkg_jar-from --build-only --into "${d}" antlr antlr.jar antlr-2.7.7.jar
+ java-pkg_jar-from --build-only --into "${d}" antlr-3 antlr-tool.jar antlr-3.1.3.jar
+ java-pkg_jar-from --build-only --into "${d}" antlr-3 antlr-runtime.jar antlr-runtime-3.1.3.jar
+ java-pkg_jar-from --build-only --into "${d}" stringtemplate stringtemplate.jar stringtemplate-3.2.jar
+ sed -i "s#compile name: SWT_FILE_NAME#compile files(\"${swt_file_name#/}\")#" "${S}"/build.gradle || die
+
+ sed -i 's/-rpath/-rpath-link/g' modules/media/src/main/native/jfxmedia/projects/linux/Makefile || die
+}
+
+src_configure() {
+ # see gradle.properties.template in ${S}
+ cat <<- _EOF_ > "${S}"/gradle.properties
+ COMPILE_TARGETS = linux
+ GRADLE_VERSION_CHECK = false
+ COMPILE_AVPLUGIN = $(usex media true false)
+ COMPILE_MEDIA = $(usex media true false)
+ COMPILE_WEBKIT = false
+ BUILD_JAVADOC = $(usex doc true false)
+ BUILD_SRC_ZIP = $(usex source true false)
+ FULL_TEST = false
+ CONF = $(usex debug DebugNative Release)
+ NUM_COMPILE_THREADS = $(makeopts_jobs)
+ _EOF_
+
+ local repostring='
+ repositories {
+ ivy {
+ url file("${projectDir}/jars")
+ layout "pattern", {
+ artifact "[artifact]-[revision].[ext]"
+ artifact "[artifact].[ext]"
+ }
+ }
+ mavenLocal()
+ }'
+
+ cat <<- _EOF_ > "${S}"/buildSrc/gentoo.gradle
+ ${repostring}
+ _EOF_
+
+ cat <<- _EOF_ > "${S}"/gentoo.gradle
+ ${repostring}
+ allprojects {
+ ${repostring}
+ }
+ _EOF_
+
+ echo "apply from: 'gentoo.gradle'" >> build.gradle || die
+ echo "apply from: 'gentoo.gradle'" >> buildSrc/build.gradle || die
+ sed -i 's/mavenCentral/mavenLocal/g' build.gradle || die
+ sed -i 's/mavenCentral/mavenLocal/g' buildSrc/build.gradle || die
+ einfo "Configured with the following settings:"
+ cat gradle.properties || die
+
+}
+
+src_compile() {
+ tc-export_build_env CC CXX PKG_CONFIG
+ rm -r tests buildSrc/src/test || die
+ egradle openExportLinux
+}
+
+src_install() {
+ local dest="/usr/$(get_libdir)/openjdk-${SLOT}"
+ local ddest="${ED%/}/${dest#/}"
+ dodir "${dest}"
+ pushd build/export/sdk > /dev/null || die
+ cp -pPRv * "${ddest}" || die
+ popd > /dev/null || die
+}