- Home
- Discussion Forum
- AROS FORUMS
- Development General
- SDL 2.0 for AROS
SDL 2.0 for AROS
amigamiaAdmin
Posted 2 years agoThat's fantastic work and thank you for all that! I agree with you, it was time to bring Janus-UAE up to date. I believe if we can manage to port SDL 2.0 to AROS, it is going to open a gate to a lot of new applications, games, etc. etc. but one thing that I noticed is the OS is still somewhat very unstable.
I recently managed to get AROS One 1.8 by Amigasystem on AROS-EXEC working (Supported Video, Wifi, and Audio) on a Dell Latitude D520. I struggled with the Wifi card but figured out what was the problem (will post an article in here soon). I am still experiencing occasional lock-ups, unexpected crashes, and annoyances such as a shell icon on the desktop showing multiple times after placing just one via "leave out" option.
It's frustrating and distracting when I am trying to focus on one particular problem/task and other things around go crashing.
In any case, it is still fun in trying to port a piece of software for the first time on a new OS like AROS
I recently managed to get AROS One 1.8 by Amigasystem on AROS-EXEC working (Supported Video, Wifi, and Audio) on a Dell Latitude D520. I struggled with the Wifi card but figured out what was the problem (will post an article in here soon). I am still experiencing occasional lock-ups, unexpected crashes, and annoyances such as a shell icon on the desktop showing multiple times after placing just one via "leave out" option.
It's frustrating and distracting when I am trying to focus on one particular problem/task and other things around go crashing.
In any case, it is still fun in trying to port a piece of software for the first time on a new OS like AROS
MiDWaNNewbie
Posted 2 years ago@amigamia -@MiDWaN - Was there any more progress on this matter?
I would like to see if I can improve Janus-UAE on AROS, and one of the things would be moving it to SDL2 - but that requires the library first, of course
Hello MiDWaN, welcome to AROSWorld!
I haven't made much progress unfortunately. It's on pause right now as I had to redo my virtual machines hosting AROS on them. However, I plan on picking it up again but I am no expert. I am doing it it as a learning experience as well as because no one else seems interested on porting SDL 2 to AROS.
I thought I would give it a shot. I was in contact with one of the AOS4 developers who suggested to use the MorphOS code because it's closer to AROS. I have the code here on this web site but I am going to put it on GitHub soon.
Would you be interested in collaborating?
Hi there!
No problem, I'd love to collaborate on this - I would probably have to look into it myself otherwise.
I just managed to get everything to compile (using SDL1) yesterday, after a lot of trial and error. The sources of Janus-UAE were a little stale for a few years, and things had changed in the meantime.
That means that the "fun" part is only starting, as the first requirement (and the pain in the butt) was making sure I have an environment that I can use to test new builds in (AROS itself, and a fool-proof way of building Janus-UAE). Well, now I have more than one (Ubuntu under Windows 11 with WSL2, Manjaro Linux) and I know more about the pitfalls of the process.
In other words, no rush and no expectations from my side. Happy to help wherever I can!
My work on Janus-UAE is on Github, since I've made some modifications already (with plenty more expected to follow): https://github.co.../janus-uae
amigamiaAdmin
Posted 2 years ago@MiDWaN - Was there any more progress on this matter?
I would like to see if I can improve Janus-UAE on AROS, and one of the things would be moving it to SDL2 - but that requires the library first, of course
Hello MiDWaN, welcome to AROSWorld!
I haven't made much progress unfortunately. It's on pause right now as I had to redo my virtual machines hosting AROS on them. However, I plan on picking it up again but I am no expert. I am doing it it as a learning experience as well as because no one else seems interested on porting SDL 2 to AROS.
I thought I would give it a shot. I was in contact with one of the AOS4 developers who suggested to use the MorphOS code because it's closer to AROS. I have the code here on this web site but I am going to put it on GitHub soon.
Would you be interested in collaborating?
1 user reacted to this post
MiDWaN
MiDWaNNewbie
Posted 2 years agoWas there any more progress on this matter?
I would like to see if I can improve Janus-UAE on AROS, and one of the things would be moving it to SDL2 - but that requires the library first, of course
I would like to see if I can improve Janus-UAE on AROS, and one of the things would be moving it to SDL2 - but that requires the library first, of course
magoriumSoftware Dev
Posted 2 years agoJust to make sure we are on the same page: You are using the source-code that is found at the github link you posted earlier ?
I'm puzzled about the real suffix..... Unless i overlooked i did not see one of the macro's expand to add such suffix.
Note that creating a dynamic version of the library is something else then creating a static one.
Trying to compile as the library as linux library isn't the way to go there. You are better of trying to see what is inside the amigaos4 makefile and try to replicate that (minus the ppc specific parts ofc).
I wish i had more time on my hands so i could give it a shot myself. Cavemann/deadwood (or anyone else with a bit of c/make knowledge) not around ?
I'm puzzled about the real suffix..... Unless i overlooked i did not see one of the macro's expand to add such suffix.
Note that creating a dynamic version of the library is something else then creating a static one.
Trying to compile as the library as linux library isn't the way to go there. You are better of trying to see what is inside the amigaos4 makefile and try to replicate that (minus the ppc specific parts ofc).
I wish i had more time on my hands so i could give it a shot myself. Cavemann/deadwood (or anyone else with a bit of c/make knowledge) not around ?
amigamiaAdmin
Posted 2 years agoI issued the
and I cannot find just SDL_Init for example. I can find SDL_Init_REAL which is strange but maybe that'll work??
Code Download source
nm libSDL2.a > lib.txt
You do not have access to view attachments
amigamiaAdmin
Posted 2 years agoFound online that I can use
to bypass the issue with the platform but goes into all sorts of other errors (See attached). So, I decided to give the Makefile.minimal a shot and that one worked after some modifications. Generates the LibSDL.a
Code Download source
make -j$(nproc)
You do not have access to view attachments
amigamiaAdmin
Posted 2 years agoWell I tried different things. What worked first was to run a slightly modified Makefile.minimal to match the correct Includes and gcc
This generated a libSDL.a file but I get the same issue when compiling against this library.
I also was able to run the configure by tricking it into thinking it's a linux box with the following command:
This goes all the way to the end. In the process it asks for an empty volume and an opt as well but clicking on cancel makes it continue. See the attached for the end result of that.
This generates the default Makefile and if I issue the following command with no switches, it reads the Makefile that was just generated
However, it complains about the platform
Code Download source
make -f Makefile.minimal
This generated a libSDL.a file but I get the same issue when compiling against this library.
I also was able to run the configure by tricking it into thinking it's a linux box with the following command:
Code Download source
./configure --build=i386 --host=i386-unknwon-linux --disable-video-opengl --disable-video-x11 --disable-video-rpi --disable-pulseaudio --disable-esd
This goes all the way to the end. In the process it asks for an empty volume and an opt as well but clicking on cancel makes it continue. See the attached for the end result of that.
This generates the default Makefile and if I issue the following command with no switches, it reads the Makefile that was just generated
Code Download source
make
However, it complains about the platform
You do not have access to view attachments
magoriumSoftware Dev
Posted 2 years agoWell, the routines as mentioned in your screenshot are definitely part of SDL.c.
Have you tried the nm tool (might have full platform arch included in the name) to see what symbol-names are exported in your SDL.a archive ?
Your test-program tries to locate the symbols in the SDL library that you've created but seem unable to find/locate them.
There can be a bit of gcc voodoo involved (e.g. parameters/options that I don't know about) to get those symbols visible as intended.
Have you followed the amigaos4 makefile when you created/build your SDL lib ? (as that probably is your best bet with regards to 'being similar to AROS'.
Have you tried the nm tool (might have full platform arch included in the name) to see what symbol-names are exported in your SDL.a archive ?
Your test-program tries to locate the symbols in the SDL library that you've created but seem unable to find/locate them.
There can be a bit of gcc voodoo involved (e.g. parameters/options that I don't know about) to get those symbols visible as intended.
Have you followed the amigaos4 makefile when you created/build your SDL lib ? (as that probably is your best bet with regards to 'being similar to AROS'.
Edited by magorium on 21-07-2022 10:41, 2 years ago
amigamiaAdmin
Posted 2 years agoHmmm, I have the libSDL2.a that compiled earlier and placed it in /Development/lib. I also created a new folder called SDL2 in /Development/include/SDL2 and copied the .h files from the source archive
I created a Makefile according to https://lazyfoo.net/tutorials/SDL/01_hello_SDL/linux/cli/index.php
I know it's finding the correct library (libSDL2.a) because if I rename it I get a different error.
However, it can seem to find the SDL_Quit. SDL_Init, and a bunch of other SDL_****xx functions. (See screenshot)
The source file 01_hello_SDL.cpp has been modified to include the SDL2/SDL.h
Any idea?
I created a Makefile according to https://lazyfoo.net/tutorials/SDL/01_hello_SDL/linux/cli/index.php
I know it's finding the correct library (libSDL2.a) because if I rename it I get a different error.
However, it can seem to find the SDL_Quit. SDL_Init, and a bunch of other SDL_****xx functions. (See screenshot)
The source file 01_hello_SDL.cpp has been modified to include the SDL2/SDL.h
Any idea?
Edited by amigamia on 20-07-2022 12:30, 2 years ago
You do not have access to view attachments
magoriumSoftware Dev
Posted 2 years agoThat would be very nice if you managed to get that going amigamia
After having taken a quick look it indeed shouldn't be too difficult after seeing the os4 parts and bits. but i simply haven't had the time to try it myself.
Thank you sofar !
After having taken a quick look it indeed shouldn't be too difficult after seeing the os4 parts and bits. but i simply haven't had the time to try it myself.
Thank you sofar !
amigamiaAdmin
Posted 2 years agoI think I just managed to compile SDL 2.0 library for AROS after a few changes and switches between configure and the make file. This is compiled using the Makefile.minimal settings. Still need to test it though.
Edited by amigamia on 18-07-2022 15:14, 2 years ago
You do not have access to view attachments
cavemannSoftware Dev
Posted 2 years agoThanks for the link. Imo that changes things. Instead of using configure, it might be better to use the Amiga makefile. The problem of course is that you would have to deal with the endian issues. Not an easy task. Good luck!!!
amigamiaAdmin
Posted 2 years ago@cavemann - Deadwood has released 6.5.0. It will probably be on the next version of Aros-One. I would upgrade because of some fixes. Also try spoofing linux and see what happens.
That's great! I must have missed that thread on AROS-Exec. I am patiently waiting for AROS One 1.8 until then, I'll keep toyin around it but I am not sure what you mean by spoofing linux. I mean, I know what spoofing means but how to trick AROS into thinking it is linux, I am not sure how to do that.
The files I am using as source are located here: https://github.com/AmigaPorts/SDL-2.0
Edited by amigamia on 18-06-2022 08:46, 2 years ago
cavemannSoftware Dev
Posted 2 years agoDeadwood has released 6.5.0. It will probably be on the next version of Aros-One. I would upgrade because of some fixes. Also try spoofing linux and see what happens.
amigamiaAdmin
Posted 2 years agoHi All,
We now have GCC 6.3.0 native in AROS and I am giving this a shot to compile SDL 2.0. Received a "Please insert volume "empty"" but clicking on cancel, seemed to have continued until the error in the attached image.
We now have GCC 6.3.0 native in AROS and I am giving this a shot to compile SDL 2.0. Received a "Please insert volume "empty"" but clicking on cancel, seemed to have continued until the error in the attached image.
Edited by amigamia on 15-06-2022 16:20, 2 years ago
You do not have access to view attachments
amigamiaAdmin
Posted 3 years agoHi deadwood, how is the progress going with GCC 6.5?
amigamiaAdmin
Posted 4 years agoIndeed very good news. Thanks for your support deadwood.
cavemannSoftware Dev
Posted 4 years agoVery nice... expect more ports
deadwoodAROS Dev
Posted 4 years agoActually I'm planning to update GCC to 6.5.0 as part of ABIv0 refresh. Hopefully this will give enough C++ support.
You can view all discussion threads in this forum.
You cannot start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You cannot download attachments in this forum.
You cannot start a new discussion thread in this forum.
You cannot reply in this discussion thread.
You cannot start on a poll in this forum.
You cannot upload attachments in this forum.
You cannot download attachments in this forum.
Moderator: Administrator, Moderators