ppmdu icon indicating copy to clipboard operation
ppmdu copied to clipboard

Unable to compile with clang on linux

Open marius851000 opened this issue 6 years ago • 8 comments

Hello. I actually tried to compile a single file on linux, with clang, not using the solution. I've made a virtual environnment with nix-shell -p pugixml -p poco -p clang --command "clang++ statsutil.cpp -I ." It fail, with multiple errors. (clang 7.1.0) Do you thing you can help me to find what doesn't work/correct the code. I've just a basic knowledge of c++, but I'll try to find what doesn't work. error.txt

marius851000 avatar May 10 '19 13:05 marius851000

I think I found an error, in ppmdu/pmd2/pmd2.hpp, that is caused because major and minor at the line 61 is interpreted as function.

marius851000 avatar Jun 13 '19 11:06 marius851000

patch.txt Here is the patch of my current work. There is only 2 error remaining.

marius851000 avatar Jun 13 '19 12:06 marius851000

Well, first did you compile the dependencies? Also, this whole thing is probably going to be a pain to compile on clang/gcc as is. My suggestion would be to cut it down into smaller parts and compile those. VS project files are xml, so you can probably grep out the included file lists in those.

PsyCommando avatar Jun 21 '19 16:06 PsyCommando

Good news: I succesfully compiled a lightweight version of statutils, able to extract string (I have a problem with locale, thrught, so I sypply deleted them where they where useless. Also, there are strange <E9> thing like in the text, but that is probably because du to the locale removal). I've manually writed a Makefile for this, and I let my distro compile the dependancy. (I now need to clear some ugly hack. I just thing that VisualStudio only compiled needed function, while gcc compile the full c++ file. So some function that isn't parsable doesn't compile.

marius851000 avatar Jun 25 '19 12:06 marius851000

Its possible the locale names are wrong for linux. I used a refernce to see how they were called on other OSes.

PsyCommando avatar Sep 06 '19 21:09 PsyCommando

I'm sorry to necro this issue, but I have just come across this tool, which comprises the only implementation for an SWDL file decoder that I know of, and I am in dire need of that (for reverse-engineering Professor Layton games, some of which also use the SWDL format). Just like @marius851000, I use Linux, but as for me, I have no idea how to use the provided .sln files. Visual Studio cannot be installed on Linux, and as such, I do not know how to properly compile the project as it is. Would you have any recommendations ?

NyuBlara avatar Dec 06 '22 14:12 NyuBlara

So... I’m not sure why I needed to compile it, but I didn’t use it anymore (and instead use SkyTemple). I rewrote the part what most interested me in Rust. However, if you are interested, I think that Capypara, Irdkwia and Adex worked on this file format. I think Capy shared some python script, that I didn’t took a look at. You can find them on the SkyTemple Matrix/Discord server. ( more info on https://skytemple.org ). If that is of interest to you, I’m also working on an improved version of Irdkwia’s patch to play WAV files, althought it doesn’t use SWDL at all.

marius851000 avatar Dec 06 '22 16:12 marius851000

Thank you very much for this lead ! I'll be sure to contact the people you mentioned.

NyuBlara avatar Dec 09 '22 05:12 NyuBlara