Package Details: java8-openjfx-src 8.u202-10

Git Clone URL: https://aur.archlinux.org/java8-openjfx.git (read-only, click to copy)
Package Base: java8-openjfx
Description: Java OpenJFX 8 client application platform (open-source implementation of JavaFX)
Upstream URL: https://wiki.openjdk.java.net/display/OpenJFX/Main
Keywords: java8-openjfx openjfx
Licenses: GPL
Submitter: freswa
Maintainer: Rogach
Last Packager: Rogach
Votes: 13
Popularity: 0.70
First Submitted: 2022-03-09 18:41 (UTC)
Last Updated: 2024-05-25 07:41 (UTC)

Latest Comments

1 2 3 4 5 6 .. 14 Next › Last »

danwood76 commented on 2025-01-08 12:29 (UTC) (edited on 2025-01-08 12:33 (UTC) by danwood76)

Thanks for all the input from various users on here.

I have managed to create a PKGBUILD which incorporates the required changes and works without modifying anything on the system (so using the stock LDFLAGS in makepkg.conf).

Hopefully @Rogach can incorporate these changes into the AUR package.

One issue I didn't encounter was problems with the .bz2 package, so maybe there was a temporary issue with the download server at some point?

PKGBUILD diff:

diff --git a/PKGBUILD b/PKGBUILD
index 45443fe..783fb8f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -40,6 +40,7 @@ makedepends=(
   python2
   qt5-base
   ruby
+  ruby-erb
   unzip
   webkit2gtk
 )
@@ -56,6 +57,7 @@ source=(
   java8-openjfx-include-iterator.patch
   java8-openjfx-no-check-jfxrt-jar.patch
   java8-openjfx-fix-java-version-check.patch
+  java8-openjfx-offlineasm-warnings-ruby27.patch
 )
 sha256sums=('813ed6bbe7669b5acae7908720b9e353771e854be75c57a323310d0b9271daff'
             'd1c2255893e5ec6268d7c92bb6539cde629d325872f26cffb5f1f616c9d5f30d'
@@ -67,7 +69,8 @@ sha256sums=('813ed6bbe7669b5acae7908720b9e353771e854be75c57a323310d0b9271daff'
             '3487eb180fff9866c8b8b08be45f13fa9e8edd04e5719bc867e59b09b81954b4'
             'bd69e8a3363f9b3ade50fb29d4c9e3d7e59b42472ae00d425d20ddcda720b919'
             '47822da975832551bc3b20b3d75891135314f89cfcb75f7212eece148902aea3'
-            '88ecba988b6e05580cecc09c37add8e375097619d9fa106d65c09edd993c3bc7')
+            '88ecba988b6e05580cecc09c37add8e375097619d9fa106d65c09edd993c3bc7'
+            'fcc5d944055df246dd9282e6093b015a448d8a6207fa7425c85d2562b7f5a596')

 prepare() {
   cd rt-${pkgver//./}-ga
@@ -82,6 +85,7 @@ prepare() {
   patch -Np1 -i ../java8-openjfx-include-iterator.patch
   patch -Np1 -i ../java8-openjfx-no-check-jfxrt-jar.patch
   patch -Np1 -i ../java8-openjfx-fix-java-version-check.patch
+  patch -Np1 -i ../java8-openjfx-offlineasm-warnings-ruby27.patch
 }

 build() {
@@ -91,6 +95,10 @@ build() {
   CFLAGS+=' -fcommon'
   # fix errors when compiling gstreamer-lite
   CFLAGS+=' -Wno-incompatible-pointer-types -Wno-int-conversion'
+  # Remove "-Wl,-z,pack-relative-relocs" from LDFLAGS
+  export LDFLAGS="${LDFLAGS//-Wl,-z,pack-relative-relocs}"
+  # Remove invalid symbols from LDFLAGS
+  export LDFLAGS="$(echo ${LDFLAGS} | sed -e 's|[[:space:]][[:space:]]|[[:space:]]|g' -e 's|\n||g')"
   # build against ffmpeg4.4
   export PKG_CONFIG_PATH='/usr/lib/ffmpeg4.4/pkgconfig'
   # ensure jdk 8 is used when building

And the java8-openjfx-offlineasm-warnings-ruby27.patch file:

From c7d19a492d97f9282a546831beb918e03315f6ef Mon Sep 17 00:00:00 2001
From: Adrian Perez de Castro <aperez@igalia.com>
Date: Wed, 15 Jan 2020 22:15:38 +0000
Subject: [PATCH] Offlineasm warnings with newer Ruby versions
 https://bugs.webkit.org/show_bug.cgi?id=206233

Reviewed by Yusuke Suzuki.

Avoid a warning about using Object#=~ on Annotation instances, which
has been deprecated in Ruby 2.7.

* offlineasm/parser.rb: Swap checks to prevent applying the =~ operator
to Annotation instances, which do not define it.


Canonical link: https://commits.webkit.org/219400@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@254637 268f45cc-cd09-0410-ab3c-d52691b4dbfc
---
 Source/JavaScriptCore/ChangeLog            | 13 +++++++++++++
 Source/JavaScriptCore/offlineasm/parser.rb |  6 +++---
 2 files changed, 16 insertions(+), 3 deletions(-)

diff --git rt-8u202-ga.orig/modules/web/src/main/native/Source/JavaScriptCore/offlineasm/parser.rb rt-8u202-ga/modules/web/src/main/native/Source/JavaScriptCore/offlineasm/parser.rb
index 791c81a9868d..f14c873e2dbd 100644
--- rt-8u202-ga.orig/modules/web/src/main/native/Source/JavaScriptCore/offlineasm/parser.rb
+++ rt-8u202-ga/modules/web/src/main/native/Source/JavaScriptCore/offlineasm/parser.rb
@@ -628,9 +628,7 @@ def parseSequence(final, comment)
         firstCodeOrigin = @tokens[@idx].codeOrigin
         list = []
         loop {
-            if (@idx == @tokens.length and not final) or (final and @tokens[@idx] =~ final)
-                break
-            elsif @tokens[@idx].is_a? Annotation
+            if @tokens[@idx].is_a? Annotation
                 # This is the only place where we can encounter a global
                 # annotation, and hence need to be able to distinguish between
                 # them.
@@ -644,6 +642,8 @@ def parseSequence(final, comment)
                 list << Instruction.new(codeOrigin, annotationOpcode, [], @tokens[@idx].string)
                 @annotation = nil
                 @idx += 2 # Consume the newline as well.
+            elsif (@idx == @tokens.length and not final) or (final and @tokens[@idx] =~ final)
+                break
             elsif @tokens[@idx] == "\n"
                 # ignore
                 @idx += 1

~edit~ Fixed the code blocks!

katsu034 commented on 2024-12-29 09:11 (UTC)

I overlooked ruby's "=~' syntax error. This fix works. erb is needed as opamp22 said. I installed ruby-erb package instead of using the gem command.

opamp22 commented on 2024-12-18 12:45 (UTC) (edited on 2024-12-19 13:22 (UTC) by opamp22)

This fix works, I had to apply the ruby patch. But ran into another issue that could be mistaken for the same error if you don't look closely.

<internal:/usr/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:136:in require': cannot load such file -- erb (LoadError) Did you mean? drb

Task :web:compileNativeLinux FAILED

FAILURE: Build failed with an exception.

  • Where: Build file '/home/$USER/Downloads/java8-openjfx/src/rt-8u202-ga/build.gradle' line: 2583

  • What went wrong: Execution failed for task ':web:compileNativeLinux'.

    Process 'command 'perl'' finished with non-zero exit value 2

I fixed this by installing erb
gem install erb

and making sure my ruby verison was on the path
export PATH="$HOME/.local/share/gem/ruby/3.3.0/bin:$PATH"

katsu034 commented on 2024-12-01 14:18 (UTC) (edited on 2024-12-01 14:19 (UTC) by katsu034)

@polkip fix doesn't work for me either. build failed with

Execution failed for task ':web:compileNativeLinux'.
> Process 'command 'perl'' finished with non-zero exit value 2

grappas commented on 2024-11-23 22:53 (UTC)

@polkip : fix you provided doesn't work for me

polkip commented on 2024-10-17 17:48 (UTC) (edited on 2024-10-17 17:48 (UTC) by polkip)

For anyone else having issues installing this, I was able to get it to work with a few changes:

Change PKGBUILD to download the .gz archive instead of the .bz2

source=(
    https://hg.openjdk.java.net/openjfx/8u-dev/rt/archive/${pkgver//./}-ga.tar.gz
    ...

rerun makepkg with the -e flag and then run updpkgsums. Afterwards, use the following LDFLAGS in /etc/makepkg.conf and it should build without issue.

LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now"

Additionally, if you encounter an invalid syntax error for Ruby's '=~' operator while compiling JavaScriptCore, applying this patch to the offending file will fix it: https://src.fedoraproject.org/rpms/qt5-qtwebkit/blob/rawhide/f/webkit-offlineasm-warnings-ruby27.patch

achyyy commented on 2024-08-29 12:28 (UTC) (edited on 2024-08-31 19:37 (UTC) by achyyy)

After using "yay -S --mflags --skipinteg java8-openjfx" the problem comes down to extracting 8u202-ga.tar.bz2 file.

EDIT: Installing "https://hg.openjdk.java.net/openjfx/8u-dev/rt/archive/8u202-ga.tar.bz2" solved it i think, it now seen as installed.

EDIT 2: It still does not work.

EDIT3: Tried to recover the 8u202-ga.tar.bz2 with bzip2recover but it says "block 243 runs from 465536083 to 466352176 (incomplete)" I think I cant download the 8u202-ga.tar.bz2 file or its corrrupted.

EDIT4(last... maybe?): After finding an old file of https://hg.openjdk.java.net/openjfx/8u-dev/rt/archive/8u202-ga.tar.bz2 on Wayback Machine, it gets stuck at gradle errors.

erylflynn commented on 2024-08-24 16:11 (UTC)

I have the same issue, downloaded the file manually. I put it in the yay cache and tried doing it manually. In makepkg.conf I set my LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now" but still get a failure to build.

I even copied an older cache from another system with it and that same cache fails doing a local makepkg. I assume something in the build tools changed and this package isn't compatible.

aidonius commented on 2024-08-17 02:45 (UTC) (edited on 2024-08-17 02:50 (UTC) by aidonius)

For me the build fails on the checksum verification of 8u202-ga.tar.bz2. It passes the Retrieving sources check but doesn't actually download the file. If I try to download it manually with wget it hangs at "HTTP request sent, awaiting response" I successfully downloaded the file with a browser. It has the same checksum as in the PKGBUILD but I have to rename the file from rt-8u202-ga.tar.bz2 to 8u202-ga.tar.bz2 for it to pass the test.

It then failed with the same error as Exord shows. I tried removing the LDFLAGS in /etc/makepkg.conf as suggested by copycat. I changed the flags from

     LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro"

to

    LDFLAGS="-O1,--sort-common,--as-needed,relro"

I also tried(as suggested by rdtsc)

    LDFLAGS="-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now"

These all produced the same error as Exord.

rdtsc commented on 2024-06-07 22:04 (UTC) (edited on 2024-06-07 22:06 (UTC) by rdtsc)

Thank you copycat! In Mabox / Manjaro / Arch I had to change /etc/makepkg.conf:

LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now \
     -Wl,-z,pack-relative-relocs"

to

LDFLAGS="-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now"

It then compiled, but gave A LOT of warnings. Unsure if it will actually run.