Homebrew [Release] SDL-3DS 1.2.15 - Simple DirectMedia Layer for 3DS

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
It's the same error as above

Code:
C:\~\Desktop\SDL-3DS-master\SDL_ttf>make
make: *** No rule to make target `SDL_ttf.o', needed by `all'.  Stop.

Then please take and post a print screen of the content of the SDL_ttf folder.

There you should have all the files and folders that are in the SDL_ttf-2.0.11 folder from the SDL_ttf-2.0.11.zip package.
 

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
Then please take and post a print screen of the content of the SDL_ttf folder.

There you should have all the files and folders that are in the SDL_ttf-2.0.11 folder from the SDL_ttf-2.0.11.zip package.
I thought it was supposed to be the makefile by itself, but it works now (also can you PM the makefile for libmikmod)
 
D

Deleted User

Guest
upload_2017-3-6_6-38-17.png
I had this problem before and after testing your steps. It is probably something I did very wrong.
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
View attachment 80505
I had this problem before and after testing your steps. It is probably something I did very wrong.
seems your system can't find the awk program. I had such problems the first time I installed devkitpro, but can't remember how I solved it (only remember I googled for the solution)

probably you only need to set a directory in you path. Hope someone can help you. If I remember how to solve I'll post it here.


EDIT: awk should bue in the devkitPro\msys\bin, and this folder (with it's full path) should be in your PATH enviroment variable.
 
Last edited by nop90,
D

Deleted User

Guest
seems your system can't find the config program. I had such problems the first time I installed devkitpro, but can't remember how I solved it (only remember I googled for the solution)

probably you only need to set a directory in you path. Hope someone can help you. If I remember how to solve I'll post it here.
alright thanks. thought i did that but will try again when I get home. thanks!
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
I thought it was supposed to be the makefile by itself, but it works now (also can you PM the makefile for libmikmod)

Makefile attached. It's for @blujay too.

Compare it with that one of the portlibs, and you'll be able to make a makefile for other portable libs.
 

Attachments

  • libmikmod_makefile.zip
    1,012 bytes · Views: 206

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
This should be my last error, as I've already installed SDL_ttf and SDL_mixer, but when I try to install SDL_image, I get this error:

Code:
arm-none-eabi-gcc -g -Wall -O2 -mword-relocations -fomit-frame-pointer -ffast-math -march=armv6k -mtune=mpcore -mfloat-abi=hard -I./include -I/c/devkitPro/libctru/include  -DARM11 -D_3DS -D__3DS__ -DENABLE_3DS -DLOAD_BMP -DLOAD_GIF -DLOAD_LBM -DLOAD_PCX -DLOAD_PNM -DLOAD_TGA -DLOAD_XCF -DLOAD_XPM -DLOAD_XV -DLOAD_JPG -DLOAD_PNG -I/c/devkitPro/libctru/../portlibs/armv6k/include -I/c/devkitPro/libct
ru/../portlibs/3ds/include/SDL -Wno-unused-variable   -c -o IMG_bmp.o IMG_bmp.c
IMG_bmp.c: In function 'LoadBMP_RW':
IMG_bmp.c:424:35: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 palette->colors[i].a = SDL_ALPHA_OPAQUE;
                                   ^
In file included from c:\devkitpro\portlibs\3ds\include\sdl\SDL_audio.h:36:0,
                 from c:\devkitpro\portlibs\3ds\include\sdl\sdl.h:32,
                 from SDL_image.h:27,
                 from IMG_bmp.c:36:
IMG_bmp.c:431:52: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 SDL_RWread(src, &palette->colors[i].a, 1, 1);
                                                    ^
c:\devkitpro\portlibs\3ds\include\sdl\SDL_rwops.h:124:56: note: in definition of macro 'SDL_RWread'
 #define SDL_RWread(ctx, ptr, size, n) (ctx)->read(ctx, ptr, size, n)
                                                        ^~~
IMG_bmp.c:437:35: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 palette->colors[i].a = SDL_ALPHA_OPAQUE;
                                   ^
IMG_bmp.c:257:12: warning: variable 'biClrImportant' set but not used [-Wunused-but-set-variable]
     Uint32 biClrImportant;
            ^~~~~~~~~~~~~~
IMG_bmp.c:255:12: warning: variable 'biYPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biYPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:254:12: warning: variable 'biXPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biXPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:253:12: warning: variable 'biSizeImage' set but not used [-Wunused-but-set-variable]
     Uint32 biSizeImage;
            ^~~~~~~~~~~
IMG_bmp.c:250:12: warning: variable 'biPlanes' set but not used [-Wunused-but-set-variable]
     Uint16 biPlanes;
            ^~~~~~~~
IMG_bmp.c:243:12: warning: variable 'bfReserved2' set but not used [-Wunused-but-set-variable]
     Uint16 bfReserved2;
            ^~~~~~~~~~~
IMG_bmp.c:242:12: warning: variable 'bfReserved1' set but not used [-Wunused-but-set-variable]
     Uint16 bfReserved1;
            ^~~~~~~~~~~
IMG_bmp.c:241:12: warning: variable 'bfSize' set but not used [-Wunused-but-set-variable]
     Uint32 bfSize;
            ^~~~~~
IMG_bmp.c: In function 'LoadICOCUR_RW':
IMG_bmp.c:596:12: warning: variable 'biClrImportant' set but not used [-Wunused-but-set-variable]
     Uint32 biClrImportant;
            ^~~~~~~~~~~~~~
IMG_bmp.c:594:12: warning: variable 'biYPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biYPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:593:12: warning: variable 'biXPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biXPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:592:12: warning: variable 'biSizeImage' set but not used [-Wunused-but-set-variable]
     Uint32 biSizeImage;
            ^~~~~~~~~~~
IMG_bmp.c:589:12: warning: variable 'biPlanes' set but not used [-Wunused-but-set-variable]
     Uint16 biPlanes;
            ^~~~~~~~
IMG_bmp.c:573:12: warning: variable 'Bmask' set but not used [-Wunused-but-set-variable]
     Uint32 Bmask;
            ^~~~~
IMG_bmp.c:572:12: warning: variable 'Gmask' set but not used [-Wunused-but-set-variable]
     Uint32 Gmask;
            ^~~~~
IMG_bmp.c:571:12: warning: variable 'Rmask' set but not used [-Wunused-but-set-variable]
     Uint32 Rmask;
            ^~~~~
make: *** [IMG_bmp.o] Error 1

Any fix? I have the required portlibs.
 
D

Deleted User

Guest
@nop90 any thoughts?
Code:
*** couldn't commit memory for cygwin heap, Win32 error 0
make: *** [freetype] Error 1
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
@nop90 any thoughts?
Code:
*** couldn't commit memory for cygwin heap, Win32 error 0
make: *** [freetype] Error 1

No sorry, honestly don't know how to help you not knowin anything about the configuration of your toolchain.

but "cygwin heap" and "Win32" words in your makefile error sound very strange.

--------------------- MERGED ---------------------------

This should be my last error, as I've already installed SDL_ttf and SDL_mixer, but when I try to install SDL_image, I get this error:

Code:
arm-none-eabi-gcc -g -Wall -O2 -mword-relocations -fomit-frame-pointer -ffast-math -march=armv6k -mtune=mpcore -mfloat-abi=hard -I./include -I/c/devkitPro/libctru/include  -DARM11 -D_3DS -D__3DS__ -DENABLE_3DS -DLOAD_BMP -DLOAD_GIF -DLOAD_LBM -DLOAD_PCX -DLOAD_PNM -DLOAD_TGA -DLOAD_XCF -DLOAD_XPM -DLOAD_XV -DLOAD_JPG -DLOAD_PNG -I/c/devkitPro/libctru/../portlibs/armv6k/include -I/c/devkitPro/libct
ru/../portlibs/3ds/include/SDL -Wno-unused-variable   -c -o IMG_bmp.o IMG_bmp.c
IMG_bmp.c: In function 'LoadBMP_RW':
IMG_bmp.c:424:35: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 palette->colors[i].a = SDL_ALPHA_OPAQUE;
                                   ^
In file included from c:\devkitpro\portlibs\3ds\include\sdl\SDL_audio.h:36:0,
                 from c:\devkitpro\portlibs\3ds\include\sdl\sdl.h:32,
                 from SDL_image.h:27,
                 from IMG_bmp.c:36:
IMG_bmp.c:431:52: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 SDL_RWread(src, &palette->colors[i].a, 1, 1);
                                                    ^
c:\devkitpro\portlibs\3ds\include\sdl\SDL_rwops.h:124:56: note: in definition of macro 'SDL_RWread'
 #define SDL_RWread(ctx, ptr, size, n) (ctx)->read(ctx, ptr, size, n)
                                                        ^~~
IMG_bmp.c:437:35: error: 'SDL_Color {aka struct SDL_Color}' has no member named 'a'
                 palette->colors[i].a = SDL_ALPHA_OPAQUE;
                                   ^
IMG_bmp.c:257:12: warning: variable 'biClrImportant' set but not used [-Wunused-but-set-variable]
     Uint32 biClrImportant;
            ^~~~~~~~~~~~~~
IMG_bmp.c:255:12: warning: variable 'biYPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biYPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:254:12: warning: variable 'biXPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biXPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:253:12: warning: variable 'biSizeImage' set but not used [-Wunused-but-set-variable]
     Uint32 biSizeImage;
            ^~~~~~~~~~~
IMG_bmp.c:250:12: warning: variable 'biPlanes' set but not used [-Wunused-but-set-variable]
     Uint16 biPlanes;
            ^~~~~~~~
IMG_bmp.c:243:12: warning: variable 'bfReserved2' set but not used [-Wunused-but-set-variable]
     Uint16 bfReserved2;
            ^~~~~~~~~~~
IMG_bmp.c:242:12: warning: variable 'bfReserved1' set but not used [-Wunused-but-set-variable]
     Uint16 bfReserved1;
            ^~~~~~~~~~~
IMG_bmp.c:241:12: warning: variable 'bfSize' set but not used [-Wunused-but-set-variable]
     Uint32 bfSize;
            ^~~~~~
IMG_bmp.c: In function 'LoadICOCUR_RW':
IMG_bmp.c:596:12: warning: variable 'biClrImportant' set but not used [-Wunused-but-set-variable]
     Uint32 biClrImportant;
            ^~~~~~~~~~~~~~
IMG_bmp.c:594:12: warning: variable 'biYPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biYPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:593:12: warning: variable 'biXPelsPerMeter' set but not used [-Wunused-but-set-variable]
     Sint32 biXPelsPerMeter;
            ^~~~~~~~~~~~~~~
IMG_bmp.c:592:12: warning: variable 'biSizeImage' set but not used [-Wunused-but-set-variable]
     Uint32 biSizeImage;
            ^~~~~~~~~~~
IMG_bmp.c:589:12: warning: variable 'biPlanes' set but not used [-Wunused-but-set-variable]
     Uint16 biPlanes;
            ^~~~~~~~
IMG_bmp.c:573:12: warning: variable 'Bmask' set but not used [-Wunused-but-set-variable]
     Uint32 Bmask;
            ^~~~~
IMG_bmp.c:572:12: warning: variable 'Gmask' set but not used [-Wunused-but-set-variable]
     Uint32 Gmask;
            ^~~~~
IMG_bmp.c:571:12: warning: variable 'Rmask' set but not used [-Wunused-but-set-variable]
     Uint32 Rmask;
            ^~~~~
make: *** [IMG_bmp.o] Error 1

Any fix? I have the required portlibs.

Seems you are trying to compile SDL_Image 2 on SDL 1.2. You have to use SDL Image 1.2
 

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
No sorry, honestly don't know how to help you not knowin anything about the configuration of your toolchain.

but "cygwin heap" and "Win32" words in your makefile error sound very strange.

--------------------- MERGED ---------------------------



Seems you are trying to compile SDL_Image 2 on SDL 1.2. You have to use SDL Image 1.2
I was about to bump my problem because I didn't get the notification of this, but thanks, it compiled and installed :D

EDIT: I've even managed to compile Opentyrian
 
Last edited by YugamiSekai,
  • Like
Reactions: nop90

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
Is there something in the path I have to edit to use SDL.h, because I get this:

Code:
c:/~/source/main.c:3:17: fatal error: SDL.h: No such file or directory
 #include <SDL.h>
                 ^
compilation terminated.
make[1]: *** [main.o] Error 1
make: *** [build] Error 2
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
Is there something in the path I have to edit to use SDL.h, because I get this:

Code:
c:/~/source/main.c:3:17: fatal error: SDL.h: No such file or directory
 #include <SDL.h>
                 ^
compilation terminated.
make[1]: *** [main.o] Error 1
make: *** [build] Error 2

you have to use

Code:
#include <SDL/sdl.h>

or you cha use a trick in your makefile addingh the SDL folder to the list of folder to search for the file to lib headers included

Code:
export INCLUDE   :=   $(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \
           $(foreach dir,$(LIBDIRS),-I$(dir)/include),$(foreach dir,$(LIBDIRS),-I$(dir)/include/SDL) \
           -I$(CURDIR)/$(BUILD)

The right solution should be to use in the LIBS variable of your makefile something like

Code:
LIBS   :=   -lm$(sdl-config --libs) -lcitro3d -lctru -lm

but it's not working now, I have to fix the building of the sdl lib with autotools (I have a version of the lib with the sdl-config working on my pc, but had to tweak the configure file to compile the vshader. It's not clean and I have to fix it before releasing)
 
Last edited by nop90,
  • Like
Reactions: YugamiSekai

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
FinallyI solved the flickering problem, later I'll upload the fix on github.

But is there anyone using the lib for porting games or for original works.

I'd like to have feedbacks on how to improve the lib and to link their works in the OP (I already posted my WIP).
 
  • Like
Reactions: angelhp and Joel16

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
Code on github updated.

Now I'm releasing a new version of Meritous without flickering, an update of Hex-a-hop with background music and the first release of Supertux Milestone one.
 
  • Like
Reactions: Cid2mizard

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
I get this error when compiling the latest SDL_mixer:

Code:
arm-none-eabi-gcc -g -Wall -O2 -mword-relocations -fomit-frame-pointer -ffast-math  -fno-pic -march=armv6k -mtune=mpcore -mfloat-abi=hard -I./include -I/c/devkitPro/libctru/include  -DARM11 -D_3DS -D__3DS__ -DENABLE_3DS -I/c/devkitPro/libctru/../portlibs/armv6k/include -I/c/devkitPro/libctru/../portlibs/3ds/include/SDL -DWAV_MUSIC -DMOD_MUSIC -DLIBMIKMOD_MUSIC -DMP3_MAD_MUSIC -DOGG_MUSIC -DOGG_USE_TREMOR  -DMP3_MAD_MUSIC -Wno-unused-variable   -c -o dynamic_ogg.o dynamic_ogg.c
In file included from dynamic_ogg.c:26:0:
dynamic_ogg.h:26:32: fatal error: tremor/ivorbisfile.h: No such file or directory
 #include <tremor/ivorbisfile.h>
                                ^
compilation terminated.
make: *** [dynamic_ogg.o] Error 1

Is there another library/portlib I'm supposed to install?
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
I enables other file format to sdl mixer, so now you need libmad tremor mikmod and libogg.

Everything but mikmod is un the devkitarm portlib makefile, and to build mikmod follow the example of the other libs to add it to the makefile.

But I found a problem with tremor and I had to modify the the autogen.sh file.

Don't know if it's only on my toolchain, but if someone need it I can share the patch.

Ps: sorry for the typos, I'm writing on a very small mobile
 

YugamiSekai

Mr. Picross
Member
Joined
Dec 24, 2014
Messages
2,015
Trophies
1
Age
21
XP
2,275
Country
United States
I enables other file format to sdl mixer, so now you need libmad tremor mikmod and libogg.

Everything but mikmod is un the devkitarm portlib makefile, and to build mikmod follow the example of the other libs to add it to the makefile.

But I found a problem with tremor and I had to modify the the autogen.sh file.

Don't know if it's only on my toolchain, but if someone need it I can share the patch.

Ps: sorry for the typos, I'm writing on a very small mobile
I'm going to need the patch, it's not detecting libogg even though I installed it
 

nop90

Well-Known Member
OP
Member
Joined
Jan 11, 2014
Messages
1,556
Trophies
0
Location
Rome
XP
3,136
Country
Italy
The problem is not libogg but pkgconf not returning it's path, so there is a function call with an empty parameter that throws an error.

In the portlibs makefile there is a flag for skipping the ogg check, but it's not used in the autoconf make, so probably someone forgot to post a patch for the tremor lib in the portlibs folder on github.

I back home in an hour and I'll post what to comment out to building the lib.
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    SylverReZ @ SylverReZ: @Psionic Roshambo, Thats pretty cool.