Open oschijns opened 2 months ago
Hello, delete raylib directory Could you use: sh -x ./nintendo64build.sh And paste output? Is the custom mk file on directory expected?
I will review tomorrow
i have old libdragon:
$ git log
commit 465b0bf8377006a1aeda206bdfa4cebf8f74ef09 (HEAD -> unstable, origin/unstable)
Executing on wsl was fine. I have not free time now to update libdragon and test, new raylib version is on the way so i suppose that i will update then.
+ test ! /usr/local/n64dev
+ git clone https://github.com/raylib4Consoles/raylib -b dreamcast
Cloning into 'raylib'...
remote: Enumerating objects: 42173, done.
remote: Counting objects: 100% (12625/12625), done.
remote: Compressing objects: 100% (343/343), done.
remote: Total 42173 (delta 12308), reused 12285 (delta 12282), pack-reused 29548 (from 1)
Receiving objects: 100% (42173/42173), 382.80 MiB | 3.73 MiB/s, done.
Resolving deltas: 100% (30943/30943), done.
+ cp custom/raylib4Nintendo64.mk /usr/local/n64dev/include
+ cd raylib/src
+ make PLATFORM=PLATFORM_NINTENDO64
/usr/local/n64dev/bin/mips64-elf-gcc -c rcore.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
In file included from rcore.c:117:
rlgl.h: In function 'rlLoadTexture':
rlgl.h:3071:22: warning: passing argument 2 of 'glGenTextures' from incompatible pointer type [-Wincompatible-pointer-types]
3071 | glGenTextures(1, &id); // Generate texture id
| ^~~
| |
| unsigned int *
In file included from rlgl.h:807:
/usr/local/n64dev/mips64-elf/include/GL/gl.h:453:39: note: expected 'GLuint *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
453 | void glGenTextures(GLsizei n, GLuint *textures);
| ~~~~~~~~^~~~~~~~
rlgl.h:3162:5: warning: implicit declaration of function 'rlLoadTextureN64'; did you mean 'rlLoadTexture'? [-Wimplicit-function-declaration]
3162 | rlLoadTextureN64(data,width,height,format,mipmapCount);
| ^~~~~~~~~~~~~~~~
| rlLoadTexture
rlgl.h: In function 'rlUnloadTexture':
rlgl.h:3404:25: warning: passing argument 2 of 'glDeleteTextures' from incompatible pointer type [-Wincompatible-pointer-types]
3404 | glDeleteTextures(1, &id);
| ^~~
| |
| unsigned int *
/usr/local/n64dev/mips64-elf/include/GL/gl.h:452:48: note: expected 'const GLuint *' {aka 'const long unsigned int *'} but argument is of type 'unsigned int *'
452 | void glDeleteTextures(GLsizei n, const GLuint *textures);
| ~~~~~~~~~~~~~~^~~~~~~~
In file included from rcore.c:512:
platforms/rcore_nintendo64.c: In function 'PollInputEvents':
platforms/rcore_nintendo64.c:409:21: warning: unused variable 'inputs' [-Wunused-variable]
409 | joypad_inputs_t inputs;
| ^~~~~~
platforms/rcore_nintendo64.c:408:10: warning: unused variable 'rumble_active' [-Wunused-variable]
408 | bool rumble_active;
| ^~~~~~~~~~~~~
platforms/rcore_nintendo64.c:407:10: warning: unused variable 'rumble_supported' [-Wunused-variable]
407 | bool rumble_supported;
| ^~~~~~~~~~~~~~~~
platforms/rcore_nintendo64.c:406:29: warning: unused variable 'accessory_type' [-Wunused-variable]
406 | joypad_accessory_type_t accessory_type;
| ^~~~~~~~~~~~~~
platforms/rcore_nintendo64.c:405:20: warning: unused variable 'style' [-Wunused-variable]
405 | joypad_style_t style;
| ^~~~~
platforms/rcore_nintendo64.c: At top level:
platforms/rcore_nintendo64.c:507:6: warning: conflicting types for 'rlLoadTextureN64'; have 'void(const void *, int, int, int, int)'
507 | void rlLoadTextureN64(const void *data, int width, int height, int format, int mipmapCount)
| ^~~~~~~~~~~~~~~~
rlgl.h:3162:5: note: previous implicit declaration of 'rlLoadTextureN64' with type 'void(const void *, int, int, int, int)'
3162 | rlLoadTextureN64(data,width,height,format,mipmapCount);
| ^~~~~~~~~~~~~~~~
platforms/rcore_nintendo64.c: In function 'rlLoadTextureN64':
platforms/rcore_nintendo64.c:513:16: warning: 'return' with a value, in function returning void [-Wreturn-type]
513 | return 0;
| ^
platforms/rcore_nintendo64.c:507:6: note: declared here
507 | void rlLoadTextureN64(const void *data, int width, int height, int format, int mipmapCount)
| ^~~~~~~~~~~~~~~~
platforms/rcore_nintendo64.c:526:54: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
526 | platform.surfaces[platform.surface_index].buffer = data;
| ^
platforms/rcore_nintendo64.c: In function 'rayDefaultFontGliphGlTextureInit':
platforms/rcore_nintendo64.c:550:25: warning: passing argument 2 of 'glGenTextures' from incompatible pointer type [-Wincompatible-pointer-types]
550 | glGenTextures(1,&(platform.rayFonts.fontGLTextures[index].id));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| unsigned int *
/usr/local/n64dev/mips64-elf/include/GL/gl.h:453:39: note: expected 'GLuint *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
453 | void glGenTextures(GLsizei n, GLuint *textures);
| ~~~~~~~~^~~~~~~~
rcore.c: In function 'LoadDirectoryFiles':
rcore.c:2178:20: warning: unused variable 'entity' [-Wunused-variable]
2178 | struct dirent *entity;
| ^~~~~~
rcore.c:2176:18: warning: unused variable 'fileCounter' [-Wunused-variable]
2176 | unsigned int fileCounter = 0;
| ^~~~~~~~~~~
rlgl.h: At top level:
rlgl.h:4909:15: warning: 'rlMatrixMultiply' defined but not used [-Wunused-function]
4909 | static Matrix rlMatrixMultiply(Matrix left, Matrix right)
| ^~~~~~~~~~~~~~~~
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-gcc -c rshapes.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
In file included from rshapes.c:63:
utils.h:36: warning: "TRACELOG" redefined
36 | #define TRACELOG(level, ...) TraceLog(level, __VA_ARGS__)
|
In file included from rshapes.c:56:
rlgl.h:131: note: this is the location of the previous definition
131 | #define TRACELOG(level, ...) (void)0
|
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-gcc -c rtextures.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
rtextures.c: In function 'HalfToFloat':
rtextures.c:4992:30: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
4992 | const unsigned int v = (*(unsigned int*)&fm)>>23; // evil log2 bit hack to count leading zeros in denormalized format
| ^~~~~~~~~~~~~~~~~~
rtextures.c:4994:13: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
4994 | return *(float*)&r;
| ^~~~~~~~~~
rtextures.c: In function 'FloatToHalf':
rtextures.c:4998:30: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
4998 | const unsigned int b = (*(unsigned int*)&x)+0x00001000; // round-to-nearest-even: add last bit after truncated mantissa
| ^~~~~~~~~~~~~~~~~
rtextures.c: In function 'HalfToFloat':
rtextures.c:4992:29: warning: 'fm' is used uninitialized [-Wuninitialized]
4992 | const unsigned int v = (*(unsigned int*)&fm)>>23; // evil log2 bit hack to count leading zeros in denormalized format
| ~^~~~~~~~~~~~~~~~~~~~
rtextures.c:4991:17: note: 'fm' declared here
4991 | const float fm = (float)m;
| ^~
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-gcc -c rtext.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-gcc -c utils.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-gcc -c rmodels.c -march=vr4300 -mtune=vr4300 -I/usr/local/n64dev/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/usr/local/n64dev/git/test/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /usr/local/n64dev/mips64-elf/include
In file included from rmodels.c:95:
external/m3d.h: In function 'm3d_load':
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3312:13: note: in expansion of macro 'M3D_GETSTR'
3312 | M3D_GETSTR(t->name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3438:17: note: in expansion of macro 'M3D_GETSTR'
3438 | M3D_GETSTR(model->bone[i].name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3483:13: note: in expansion of macro 'M3D_GETSTR'
3483 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3543:29: note: in expansion of macro 'M3D_GETSTR'
3543 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3569:13: note: in expansion of macro 'M3D_GETSTR'
3569 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3592:25: note: in expansion of macro 'M3D_GETSTR'
3592 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3603:25: note: in expansion of macro 'M3D_GETSTR'
3603 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3678:17: note: in expansion of macro 'M3D_GETSTR'
3678 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3703:25: note: in expansion of macro 'M3D_GETSTR'
3703 | M3D_GETSTR(model->voxtype[i].item[j].name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3716:13: note: in expansion of macro 'M3D_GETSTR'
3716 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3776:13: note: in expansion of macro 'M3D_GETSTR'
3776 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3817:29: note: in expansion of macro 'M3D_GETSTR'
3817 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3858:13: note: in expansion of macro 'M3D_GETSTR'
3858 | M3D_GETSTR(name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3859:13: note: in expansion of macro 'M3D_GETSTR'
3859 | M3D_GETSTR(lang);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3881:17: note: in expansion of macro 'M3D_GETSTR'
3881 | M3D_GETSTR(model->label[i].text);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:2278:67: warning: passing argument 3 of '_m3d_getidx' from incompatible pointer type [-Wincompatible-pointer-types]
2278 | #define M3D_GETSTR(x) do{offs=0;data=_m3d_getidx(data,model->si_s,&offs);x=offs?((char*)model->raw+16+offs):NULL;}while(0)
| ^~~~~
| |
| unsigned int *
external/m3d.h:3892:13: note: in expansion of macro 'M3D_GETSTR'
3892 | M3D_GETSTR(a->name);
| ^~~~~~~~~~
external/m3d.h:2279:86: note: expected 'M3D_INDEX *' {aka 'long unsigned int *'} but argument is of type 'unsigned int *'
2279 | _inline static unsigned char *_m3d_getidx(unsigned char *data, char type, M3D_INDEX *idx)
| ~~~~~~~~~~~^~~
external/m3d.h:3488:21: warning: argument 1 null where non-null expected [-Wnonnull]
3488 | if(!strcmp(name, model->material[i].name)) {
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from rmodels.c:58:
/usr/local/n64dev/mips64-elf/include/string.h:36:10: note: in a call to function 'strcmp' declared 'nonnull'
36 | int strcmp (const char *, const char *);
| ^~~~~~
In function 'LoadModelAnimationsM3D',
inlined from 'LoadModelAnimations' at rmodels.c:2113:57:
rmodels.c:6089:17: warning: 'strncpy' specified bound 32 equals destination size [-Wstringop-truncation]
6089 | strncpy(animations[a].bones[i].name, m3d->bone[i].name, sizeof(animations[a].bones[i].name));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mips64-elf-gcc: warning: /usr/local/n64dev/mips64-elf/include: linker input file unused because linking not done
/usr/local/n64dev/bin/mips64-elf-ar rcs ../src/libraylib.a rcore.o rshapes.o rtextures.o rtext.o utils.o rmodels.o
raylib static library generated (libraylib.a) in ../src!```
Would it be possible to build the project using the libdragon docker image ? It is really a chore to clone the libdragon repo, compile the whole toolchain and then compile my own source file.
If libdragon docker image is based in unstable branch it should compile fine but i did not test it.
i just add a compiler flag in raylib, delete raylib directory and execute again nintendo64build.sh. Please report if it is fixing the issue
Which compiler flag did you use ?
I actually managed to use the docker image of libdragon with your repo. I had to modify raylib4Nintendo64/raylib/src/MakeFile
to replace include $N64_INST/include/raylib4Nintendo64.mk
by include /libdragon/libdragon/include/raylib4Nintendo64.mk
.
But still, I end up on exactly the same error.
/n64_toolchain/bin/mips64-elf-gcc -c rcore.c -march=vr4300 -mtune=vr4300 -I/n64_toolchain/mips64-elf/include -falign-functions=32 -ffunction-sections -fdata-sections -g -ffile-prefix-map="/libdragon/raylib4Nintendo64/raylib/src"= -ffast-math -ftrapping-math -fno-associative-math -DN64 -O2 -Wall -Wno-error=deprecated-declarations -fdiagnostics-color=always -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=unused-function -Wno-error=unused-parameter -Wno-error=unused-but-set-parameter -Wno-error=unused-label -Wno-error=unused-local-typedefs -Wno-error=unused-const-variable -std=gnu99 -Wno-error=incompatible-pointer-types -DPLATFORM_NINTENDO64 -DGRAPHICS_API_OPENGL_11 /n64_toolchain/mips64-elf/include
In file included from rcore.c:117:
rlgl.h: In function 'rlLoadTexture':
rlgl.h:3071:22: warning: passing argument 2 of 'glGenTextures' from incompatible pointer type [-Wincompatible-pointer-types]
3071 | glGenTextures(1, &id); // Generate texture id
| ^~~
| |
| unsigned int *
...
https://github.com/raylib4Consoles/raylib/blob/88abda83896c9a4b6a8ea12becd163022bc06031/src/Makefile#L557 It should be a warning not error
I have followed the process described in
InstallNintendo64.md
I have cloned the libdragon repo:I have set the variable
N64_INST
to/home/oschijns/raylib_on_n64/
. I have run./build-toolchain.sh
and then./build.sh
.But when I run
./nintendo64build.sh
, I get the following output: