Skip to content
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

JDK 22 support for libappindicator-gtk3-java-full and libayatana-appindicator-java-full #37

Closed
1 task done
purejava opened this issue Mar 1, 2024 · 1 comment
Closed
1 task done
Labels
bug Something isn't working feature-request upstream

Comments

@purejava
Copy link
Owner

purejava commented Mar 1, 2024

Please agree to the following

Summary

Bindings need to be creatad newly via jextract

Motivation

Java 22 will be released by the end of the month.
These bindings have already been successfully generated with Java 22 for the minimal variant.

Nevertheless, using jextract fails for the other two variants due to a bug in jextract.

The generated bindings contain a lot of dumped in locations like the following, that make it impossible to compile the code:

purejava/appindicator/sigevent.java:        sigevent.union (unnamed at /usr/include/bits/types/sigevent_t.h:28:5).layout().withName("_sigev_un")
purejava/appindicator/sigevent.java:    public static class union (unnamed at /usr/include/bits/types/sigevent_t.h:28:5) {
purejava/appindicator/sigevent.java:        union (unnamed at /usr/include/bits/types/sigevent_t.h:28:5)() {
purejava/appindicator/sigevent.java:            sigevent.union (unnamed at /usr/include/bits/types/sigevent_t.h:28:5).struct (unnamed at /usr/include/bits/types/sigevent_t.h:36:2).layout().withName("_sigev_thread")
purejava/appindicator/sigevent.java:        ).withName("union (unnamed at /usr/include/bits/types/sigevent_t.h:28:5)");
purejava/appindicator/sigevent.java:        public static class struct (unnamed at /usr/include/bits/types/sigevent_t.h:36:2) {
purejava/appindicator/sigevent.java:            struct (unnamed at /usr/include/bits/types/sigevent_t.h:36:2)() {
purejava/appindicator/sigevent.java:            ).withName("struct (unnamed at /usr/include/bits/types/sigevent_t.h:36:2)");
purejava/appindicator/__mbstate_t.java:        __mbstate_t.union (unnamed at /usr/include/bits/types/__mbstate_t.h:16:3).layout().withName("__value")
purejava/appindicator/__mbstate_t.java:    public static class union (unnamed at /usr/include/bits/types/__mbstate_t.h:16:3) {
purejava/appindicator/__mbstate_t.java:        union (unnamed at /usr/include/bits/types/__mbstate_t.h:16:3)() {
purejava/appindicator/__mbstate_t.java:        ).withName("union (unnamed at /usr/include/bits/types/__mbstate_t.h:16:3)");
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_LINK_MAX = 0
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_MAX_CANON = 1
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_MAX_INPUT = 2
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_NAME_MAX = 3
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_PATH_MAX = 4
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_PIPE_BUF = 5
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_CHOWN_RESTRICTED = 6
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_NO_TRUNC = 7
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_VDISABLE = 8
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_SYNC_IO = 9
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_ASYNC_IO = 10
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_PRIO_IO = 11
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_SOCK_MAXBUF = 12
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_FILESIZEBITS = 13
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_REC_INCR_XFER_SIZE = 14
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_REC_MAX_XFER_SIZE = 15
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_REC_MIN_XFER_SIZE = 16
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_REC_XFER_ALIGN = 17
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_ALLOC_SIZE_MIN = 18
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_SYMLINK_MAX = 19
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:24:1)._PC_2_SYMLINKS = 20
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_ARG_MAX = 0
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_CHILD_MAX = 1
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_CLK_TCK = 2
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_NGROUPS_MAX = 3
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_OPEN_MAX = 4
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_STREAM_MAX = 5
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_TZNAME_MAX = 6
purejava/appindicator/app_indicator_h_14.java:     * enum enum (unnamed at /usr/include/bits/confname.h:71:1)._SC_JOB_CONTROL = 7

Considered Alternatives

No response

Anything else?

The bindings for minimal were generated on Java 22 with jextract 22
JDK version 22-ea+28-2271
clang version 18.1.0rc (http://git.linaro.org/toolchain/jenkins-scripts.git 09f505cadfbe9987730e641398ab9a2ca0cdb67f).

@purejava purejava added feature-request bug Something isn't working upstream labels Mar 1, 2024
@purejava
Copy link
Owner Author

purejava commented Mar 16, 2024

The bindings for libappindicator-gtk3-java-full and libayatana-appindicator-java-full can be generated with jextract, when the tool was compiled with clang+llvm-13.0.1 before.
Nevertheless, this requires an additional package installed for building: yay -S ncurses5-compat-libs.

Done with cfa3c3c and 7b89573.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working feature-request upstream
Projects
None yet
Development

No branches or pull requests

1 participant