Trying to port SuperTux using DevKitPro

Trying to port SuperTux using DevKitPro

Postby blendy » 06 Apr 2024, 23:56

DevKitPro (https://devkitpro.org/) is a toolchain for developing homebrew for nintendo consoles, and I'm trying to port st for the switch but I'm having some problems. I'm also not very experienced with c++/cmake.
So far I setup the dkp repo for pacman, installed all the switch packages and all the library packages from there, cross compiled glew and added it to the portlibs location.

After cloning st and doing
{l Code}: {l Select All Code}
git submodule update --init --recursive
, creating/cd'ing into build
I ran
{l Code}: {l Select All Code}
/opt/devkitpro/portlibs/switch/bin/aarch64-none-elf-cmake ..
, which finished and created a Makefile (though output is different from regular compilation)
Output of this was https://privatebin.net/?e95018ad302fc57f#48mbMVYi8pv6Ep3WMQFpvhza8RNFj7X7gCjg8ZxfK6A3
Running
{l Code}: {l Select All Code}
make
afterwards fails with https://privatebin.net/?2e880d00ae105717#HnJg2Py18MtATJDT1zStDXu5Mpq6tqbJ6uxv7S95XrrC
After seeing the error appeared to be with the PhysFS library (there was no mention of it when compiling for linux) I made sure it was present in the portlibs folder (it was, installed through (dkp)-pacman).
Noticing that -rdynamic seemed to be causing issues (even though it seems that it gets ignored if dynamic linking isn't available), I ran
{l Code}: {l Select All Code}
strace -f make 2>&1 | grep rdyn
, with output https://privatebin.net/?e8ee32f4c91ffdc7#BdfqbhCapopG2kTULmFKmCHKcpmREnK8vyupogrxdzep.
I also tried editing
{l Code}: {l Select All Code}
supertux/mk/cmake/SuperTux/ProvidePhysfs.cmake
to debug, in which
{l Code}: {l Select All Code}
if(PHYSFS_LIBRARY)
returned FALSE (when cross compiling), and TRUE when compiling for linux, even though the library was present in the portlibs folder, and I don't know how to continue debugging this.
blendy
 
Posts: 1
Joined: 06 Apr 2024, 23:27

Who is online

Users browsing this forum: No registered users and 1 guest