Issue building gluegen: type mismatch in Buffers.c

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Issue building gluegen: type mismatch in Buffers.c

significantnose
Greetings, fellow gluegen-ers. I tried to follow the manual about the build process of gluegen, but I stumbled upon this error:

gluegen.build.c.impl:
     [echo] clearing gluegen.build.shasum.done (2) - was ${gluegen.build.shasum.done}
     [echo] Output lib name = gluegen_rt -> libgluegen_rt.so [shared]
     [echo] Compiling src/native/unix/*.c src/native/common/*.c
     [echo] user.dir=/home/significantnose/tsos/gluegen/make
       [cc] Starting dependency analysis for 6 files.
       [cc] Error writing /home/significantnose/tsos/gluegen/build/obj/dependencies.xml:java.io.FileNotFoundException: /home/significantnose/tsos/gluegen/build/obj/dependencies.xml (Permission denied)
       [cc] 6 files are up to date.
       [cc] 0 files to be recompiled from dependency analysis.
       [cc] 1 total files to be compiled.
       [cc] cc1: warning: command-line option ‘-fno-rtti’ is valid for C++/D/ObjC++ but not for C
       [cc] /home/significantnose/tsos/gluegen/src/native/common/Buffers.c: In function ‘Java_com_jogamp_common_nio_Buffers_memcpyImpl’:
       [cc] /home/significantnose/tsos/gluegen/src/native/common/Buffers.c:28:124: error: pointer/integer type mismatch in conditional expression [-Wint-conversion]
       [cc]    28 |     return ( 0 != jdest && 0 != jsrc && 0 < jlen ) ? memcpy((void *)(intptr_t)jdest, (void *)(intptr_t)jsrc, (size_t)jlen) : jdest;
       [cc]       |                                                                                                                            ^
       [cc] /home/significantnose/tsos/gluegen/src/native/common/Buffers.c:28:124: error: returning ‘void *’ from a function with return type ‘jlong’ {aka ‘long int’} makes integer from pointer without a cast [-Wint-conversion]
       [cc]    28 |     return ( 0 != jdest && 0 != jsrc && 0 < jlen ) ? memcpy((void *)(intptr_t)jdest, (void *)(intptr_t)jsrc, (size_t)jlen) : jdest;
       [cc]       |            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~

BUILD FAILED
/home/significantnose/tsos/gluegen/make/build.xml:464: The following error occurred while executing this line:
/home/significantnose/tsos/gluegen/make/build.xml:490: gcc failed with return code 1




what can possible be the issue? Can it be related to something in the code itself & nothing related to JDK or JRE installed on my machine?