freebsd-ports/java/openjdk8
Dimitry Andric d7146f6d33 java/openjdk8: fix build with clang 15
During an exp-run for llvm 15 (see bug 265425), it turned out that
java/openjdk8 failed to build with clang 15:

    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:64:30: error: incompatible pointer to integer conversion returning 'void *' from a function with result type 'int' [-Wint-conversion]
        INVOKE(SplashLoadMemory, NULL)(pdata, size);
                                 ^~~~
    /usr/include/sys/_null.h:34:14: note: expanded from macro 'NULL'
    #define NULL    ((void *)0)
                    ^~~~~~~~~~~
    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:60:39: note: expanded from macro 'INVOKE'
    #define INVOKE(name,def) _INVOKE(name,def,return)
                                          ^~~
    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:57:25: note: expanded from macro '_INVOKE'
        if (!proc) { return def; } \
                            ^~~
    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:68:28: error: incompatible pointer to integer conversion returning 'void *' from a function with result type 'int' [-Wint-conversion]
        INVOKE(SplashLoadFile, NULL)(filename);
                               ^~~~
    /usr/include/sys/_null.h:34:14: note: expanded from macro 'NULL'
    #define NULL    ((void *)0)
                    ^~~~~~~~~~~
    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:60:39: note: expanded from macro 'INVOKE'
    #define INVOKE(name,def) _INVOKE(name,def,return)
                                          ^~~
    /wrkdirs/usr/ports/java/openjdk8/work/jdk8u-jdk8u352-b08.1/jdk/src/share/bin/splashscreen_stubs.c:57:25: note: expanded from macro '_INVOKE'
        if (!proc) { return def; } \
                            ^~~
    2 errors generated.

Indeed, instead of the pointer value NULL, the integer value 0 should be
used.

PR:		268223
Approved by:	portmgr (tcberner)
MFH:		2022Q4
2022-12-18 18:23:58 +01:00
..
files java/openjdk8: fix build with clang 15 2022-12-18 18:23:58 +01:00
distinfo
Makefile
pkg-descr
pkg-message