GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — The `System.getProperty("java.home")` points to the JRE bundled with Processing and not the JDK · Issue #1163 · processing/processing4

The System.getProperty("java.home") points to the JRE bundled with Processing and not the JDK #1163

New issue
Copy link
New issue
Copy link
Closed
#1199
Closed
The System.getProperty("java.home") points to the JRE bundled with Processing and not the JDK#1163
#1199
Copy link
Assignees
Stefterv
Labels
bugSomething isn't workingSomething isn't working
Milestone
4.4.6

Description

@pervisjohannsen
pervisjohannsen
opened on Jun 30, 2025
Issue body actions

Most appropriate sub-area of Processing 4?

Core/Environment/Rendering

Processing version

4.4.0 through 4.4.4

Operating system

Linux Fedora/KDE, Windows 11, and MacOS X Sonoma (intel)

Bug description

I’m getting these errors with code that worked in version 4.3.4,

The package “java.sql” does not exist. You might be missing a library.
The package “com.sun.net” does not exist. You might be missing a library.

Steps to reproduce this

"1.Run a sketch that imports these packages.

"

snippet

// Paste your code below :)
import java.sql.*;
import com.sun.net.httpserver.*;

void setup() {

}

void draw() {

}

Additional context

I've tested version 4.4.4 and previous versions back to 4.4.0 on Linux/MacOS/Windows and all exhibit this bug.
I am selecting that I'd like to help but I have no experience in Gradle, etc.

Would you like to work on the issue?

Yes, I’d like to help with this

Reacted by Raphaël de Courville

Activity

  1. pervisjohannsen
    added
    bugSomething isn't workingSomething isn't working
    on Jun 30, 2025
  2. SableRaf commented on Jul 2, 2025

    @SableRaf
    SableRaf
    on Jul 2, 2025
    Collaborator
    More actions

    Thanks @pervisjohannsen for reporting this and testing on different versions.

    Processing 4.4 switched from bundling a full JDK to generating a custom JRE with jlink as part of the new Gradle build (see #888, #968, and the 4.4 release notes). To reduce the download size, only a minimal set of modules was included.

    I tested a fix locally by adding java.sql to the modules list in nativeDistributions inside of app/build.gradle.kts (same place where java.scripting was added in PR #1056). After rebuilding, the sketch compiles and runs fine again (see screenshot below). I also tried adding jdk.httpserver but the sketch still shows No library found for com.sun.net.httpserver 🤔 That's as far as I was able to get with my limited knowledge of Gradle.

    We could include these in the build, but this raises a broader question about which modules we should include by default. We're currently migrating the internal sketch runner to Gradle, and I'm guessing that could eventually support automatically resolving or downloading missing modules (@Stefterv let me know if I’m on the right track here).

    Image
  3. Stefterv commented on Jul 2, 2025

    @Stefterv
    Stefterv
    on Jul 2, 2025
    Member
    More actions

    Hmm, I am surprised that did anything to be honest. We include the entire JDK for building sketches so there should not be any missing modules. At #1056 there was a missing module for code that ran within the PDE, so that is a different case than here. I suspect somehow the compilation stage is using the wrong JDK?

    Reacted by Raphaël de Courville
  4. SableRaf commented on Jul 2, 2025

    @SableRaf
    SableRaf
    on Jul 2, 2025
    Collaborator
    More actions

    Ok I edited my comment to cross out my wrong assumptions :D

  5. pervisjohannsen commented on Jul 2, 2025

    @pervisjohannsen
    pervisjohannsen
    on Jul 2, 2025
    Author
    More actions

    This may be irrelevant now, but I think jdk.httpserver is just a wrapper for com.sun.net.httpserver.

  6. Stefterv commented on Jul 2, 2025

    @Stefterv
    Stefterv
    on Jul 2, 2025
    Member
    More actions

    Just ran the debugger and the Eclipse Compiler is hardcoded to use the System.getProperty("java.home") so we can temporarily override the system property before running the old compiler, or another solution if anyone has better ideas.

  7. Stefterv commented on Jul 2, 2025

    @Stefterv
    Stefterv
    on Jul 2, 2025
    Member
    More actions
    Image

    This solves the issue with java.sql not being available, not sure if setting System.getProperty("java.home") is going wreck havoc somewhere else so not a fan of this solution.

    Reacted by Raphaël de Courville
  8. Stefterv
    self-assigned this
    on Jul 10, 2025
  9. Stefterv commented on Aug 11, 2025

    @Stefterv
    Stefterv
    on Aug 11, 2025
    Member
    More actions

    https://discourse.processing.org/t/javadoc-doesnt-work-anymore-processing-on-linux/46868

    I just took a look through the code in this repo and it also relies on java.home property

  10. Stefterv
    changed the title [-]Missing package/libraries in new builds[/-] [+]The `System.getProperty("java.home")` points to the JRE bundled with Processing and not the JDK[/+] on Aug 11, 2025
  11. Stefterv
    added this to the 4.4.6 milestone on Aug 11, 2025
  12. Stefterv commented on Aug 11, 2025

    @Stefterv
    Stefterv
    on Aug 11, 2025
    Member
    More actions

    Also seems to be related to ongoing the Android mode issues: https://discourse.processing.org/t/android-programming-for-beginners/46813/13

  13. SableRaf
    closed this as completedin #1199on Aug 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @Stefterv
    Stefterv

Labels

bugSomething isn't workingSomething isn't working

Type

No type

Projects

No projects

    Milestone

    • 4.4.6

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402503 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.