Skip to content

Can't build latest checkout #985

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
babaissarkar opened this issue Mar 19, 2025 · 6 comments · Fixed by #989
Closed

Can't build latest checkout #985

babaissarkar opened this issue Mar 19, 2025 · 6 comments · Fixed by #989
Assignees

Comments

@babaissarkar
Copy link
Contributor

Trying to build latest checkout (commit b9e7f55) with ./gradlew build causes the following error:

 ./gradlew build
Downloading https://services.gradle.org/distributions/gradle-8.11-bin.zip
.............10%.............20%.............30%.............40%.............50%.............60%.............70%.............80%.............90%.............100%

Welcome to Gradle 8.11!

Here are the highlights of this release:
 - Parallel load and store for Configuration Cache
 - Java compilation errors at the end of the build output
 - Consolidated report for warnings and deprecations

For more details see https://docs.gradle.org/8.11/release-notes.html

Starting a Gradle Daemon (subsequent builds will be faster)

> Configure project :app
w: file:///home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4/app/build.gradle.kts:477:13: 'exec(Action<ExecSpec>): ExecResult' is deprecated. This method will be removed in Gradle 9.0. Use ExecOperations.exec(Action) or ProviderFactory.exec(Action) instead.

> Task :java:preprocessor:ant-preproc
warning(109): /home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4/java/src/processing/mode/java/preproc/JavaParser.g4:47:0: options ignored in imported grammar JavaParser

The message received from the daemon indicates that the daemon has disappeared.
Build request sent: Build{id=cbfbd2cf-6243-4297-8cae-11e6de396ad8, currentDir=/home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4}
Attempting to read last messages from the daemon log...
Daemon pid: 21739
  log file: /home/ssarkar/.gradle/daemon/8.11/daemon-21739.out.log
----- Last 20 lines from daemon log file - daemon-21739.out.log -----
2025-03-20T05:01:10.853+0530 [DEBUG] [org.gradle.launcher.daemon.server.DefaultIncomingConnectionHandler] Starting executing command: Build{id=cbfbd2cf-6243-4297-8cae-11e6de396ad8, currentDir=/home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4} with connection: socket connection from /127.0.0.1:37887 to /127.0.0.1:55036.
2025-03-20T05:01:10.856+0530 [DEBUG] [org.gradle.launcher.daemon.server.DaemonStateCoordinator] Command execution: started DaemonCommandExecution[command = Build{id=cbfbd2cf-6243-4297-8cae-11e6de396ad8, currentDir=/home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4}, connection = DefaultDaemonConnection: socket connection from /127.0.0.1:37887 to /127.0.0.1:55036] after 0.00245 minutes of idle
2025-03-20T05:01:10.857+0530 [INFO] [org.gradle.launcher.daemon.server.DaemonRegistryUpdater] Marking the daemon as busy, address: [84e1ee1c-7df6-4a98-89f4-c06445971d77 port:37887, addresses:[localhost/127.0.0.1]]
2025-03-20T05:01:10.857+0530 [DEBUG] [org.gradle.launcher.daemon.registry.PersistentDaemonRegistry] Marking busy by address: [84e1ee1c-7df6-4a98-89f4-c06445971d77 port:37887, addresses:[localhost/127.0.0.1]]
2025-03-20T05:01:10.858+0530 [DEBUG] [org.gradle.cache.internal.DefaultFileLockManager] Waiting to acquire exclusive lock on daemon addresses registry.
2025-03-20T05:01:10.858+0530 [DEBUG] [org.gradle.cache.internal.DefaultFileLockManager] Lock acquired on daemon addresses registry.
2025-03-20T05:01:10.859+0530 [DEBUG] [org.gradle.cache.internal.DefaultFileLockManager] Releasing lock on daemon addresses registry.
2025-03-20T05:01:10.860+0530 [DEBUG] [org.gradle.launcher.daemon.server.DaemonStateCoordinator] resetting idle timer
2025-03-20T05:01:10.860+0530 [DEBUG] [org.gradle.launcher.daemon.server.DaemonStateCoordinator] daemon is running. Sleeping until state changes.
2025-03-20T05:01:10.866+0530 [INFO] [org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy] Daemon is about to start building Build{id=cbfbd2cf-6243-4297-8cae-11e6de396ad8, currentDir=/home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4}. Dispatching build started information...
2025-03-20T05:01:10.867+0530 [DEBUG] [org.gradle.launcher.daemon.server.SynchronizedDispatchConnection] thread 28: dispatching org.gradle.launcher.daemon.protocol.BuildStarted@5075207f
2025-03-20T05:01:10.872+0530 [DEBUG] [org.gradle.launcher.daemon.server.exec.EstablishBuildEnvironment] Configuring env variables: [PATH, XAUTHORITY, XMODIFIERS, XDG_DATA_DIRS, GDMSESSION, GTK_IM_MODULE, DBUS_SESSION_BUS_ADDRESS, PS1, XDG_CURRENT_DESKTOP, INSIDE_NEMO_PYTHON, SSH_AGENT_PID, LD_LIBRARY_PATH, COLORTERM, SESSION_MANAGER, LOGNAME, PWD, SHELL, LESSOPEN, GNOME_DESKTOP_SESSION_ID, GNOME_TERMINAL_SCREEN, GTK_MODULES, CLUTTER_IM_MODULE, XDG_SESSION_PATH, LC_ALL, LS_COLORS, XDG_SESSION_DESKTOP, SHLVL, LESSCLOSE, QT_IM_MODULE, JAVA_HOME, TERM, GNOME_TERMINAL_SERVICE, XDG_SEAT_PATH, LANG, XDG_SESSION_ID, XDG_SESSION_TYPE, DISPLAY, XDG_SESSION_CLASS, _, GDM_LANG, XDG_DATA_HOME, GTK3_MODULES, XDG_GREETER_DATA_DIR, LIBOVERLAY_SCROLLBAR, GPG_AGENT_INFO, DESKTOP_SESSION, USER, QT_ACCESSIBILITY, VTE_VERSION, LC_NUMERIC, XDG_SEAT, SSH_AUTH_SOCK, GTK_OVERLAY_SCROLLING, QT_QPA_PLATFORMTHEME, XDG_VTNR, XDG_RUNTIME_DIR, HOME]
2025-03-20T05:01:10.877+0530 [DEBUG] [org.gradle.launcher.daemon.server.exec.LogToClient] About to start relaying all logs to the client via the connection.
2025-03-20T05:01:10.877+0530 [INFO] [org.gradle.launcher.daemon.server.exec.LogToClient] The client will now receive all logging from the daemon (pid: 21739). The daemon log file: /home/ssarkar/.gradle/daemon/8.11/daemon-21739.out.log
2025-03-20T05:01:10.880+0530 [INFO] [org.gradle.launcher.daemon.server.exec.LogAndCheckHealth] Starting build in new daemon [memory: 1 GiB]
2025-03-20T05:01:10.887+0530 [DEBUG] [org.gradle.launcher.daemon.server.exec.ExecuteBuild] The daemon has started executing the build.
2025-03-20T05:01:10.888+0530 [DEBUG] [org.gradle.launcher.daemon.server.exec.ExecuteBuild] Executing build with daemon context: DefaultDaemonContext[uid=cca94240-7d45-4976-bcb9-bfcfe0a7503e,javaHome=/home/ssarkar2/Downloads/Software/jdk-21.0.5+11,javaVersion=21,javaVendor=Eclipse Adoptium,daemonRegistryDir=/home/ssarkar/.gradle/daemon,pid=21739,idleTimeout=1800000,priority=NORMAL,applyInstrumentationAgent=true,nativeServicesMode=ENABLED,daemonOpts=-XX:MaxMetaspaceSize=512m,-Xmx1024m,-Dfile.encoding=UTF-8,-Duser.country=IN,-Duser.language=en,-Duser.variant]
w: file:///home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4/app/build.gradle.kts:477:13: 'exec(Action<ExecSpec>): ExecResult' is deprecated. This method will be removed in Gradle 9.0. Use ExecOperations.exec(Action) or ProviderFactory.exec(Action) instead.
warning(109): /home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4/java/src/processing/mode/java/preproc/JavaParser.g4:47:0: options ignored in imported grammar JavaParser
Daemon vm is shutting down... The daemon has exited normally or was terminated in response to a user interrupt.----- End of the daemon log -----

System info:
OS: Devuan Daedalus
Java: tried with both Java 17 and Java 21
Gradle: tried with both gradle wrapper and locally installed gradle (8.11.1)

@babaissarkar
Copy link
Contributor Author

babaissarkar commented Mar 20, 2025

Seems like if I correctly set the JAVA_HOME to the java 17 home directory this error goes away, but I get

warning(109): /home/ssarkar2/hd2/Documents/Projects/Java/Eclipse/processing4/java/src/processing/mode/java/preproc/JavaParser.g4:47:0: options ignored in imported grammar JavaParser

> Task :java:libraries:dxf:compile FAILED

Edit: managed to fix it by running buildDependants first. However, now I can find no way to actually run it? From BUILD.md, I'm supposed to run gradle app:run, however that tries to download a full JDK for bundling. Is that really necessary for a debug build? Is there a way to build and run it quickly, with the existing JDK?

Also, BUILD.md contains no guide for command-line building.

@Stefterv
Copy link
Collaborator

Hi @babaissarkar, first of all, thank you for building Processing and giving detailled feedback!

What architecture are you running on, arm64 by chance? I've seen this issue of the preprocessor:ant-preproc appearing when I used any other JDK than 17 x64 edition. In any case this bug should be fixed by #957 which is almost ready to merge

To answer your other question, yes it would work with the already building jdk, you're right, I'll check if I can modify the debug builds to fix this issue

@babaissarkar
Copy link
Contributor Author

@Stefterv I'm using x86_64 arch.

@babaissarkar
Copy link
Contributor Author

babaissarkar commented Mar 20, 2025

Slightly offtopic, but related to building:
I do not understand the latter part of this line from BUILD.md, fully

The main task to run or debug the PDE is app:run this run the application with compose desktop

A typo might have crept in unintentionally somewhere (a missing or?).
(I understand the first part of that line however.)

@Stefterv
Copy link
Collaborator

Image

This writing was based on the way it is visible within Intellij IDEA, under the ground compose desktop

@SableRaf
Copy link
Collaborator

Thanks for catching that. Stef and I made some edits to BUILD.md to improve clarity in #989

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants