I'm getting a crash when I launch my test app. I feel like its a config error but I'm not sure. I installed allegro with homebrew as suggested on the wiki. See below screenshots.
https://ibb.co/tDvJpRp
https://ibb.co/K7pf4hf
https://ibb.co/8jgW4WG
https://ibb.co/F6hMSR1
dyld: Symbol not found: __al_mangled_main
Referenced from: /usr/local/opt/allegro/lib/liballegro_main.5.2.dylib
Expected in: flat namespace
in /usr/local/opt/allegro/lib/liballegro_main.5.2.dylib
Program ended with exit code: 9
You need to link to allegro main, the addon.
Is this different than the one in my first screenshot?
Is your prog C++? - if so you have to be careful about your definition of main().
Can't check now but IIRC you need to lose the const from argv.
Anyway let me know if that helps otherwise I will look into it properly.
@Peter That worked! And yes, it is c++. Do you know why it's so picky about the main args? I've never had an issue with any particular main args. These args were generated by the Xcode project template.
It's something to do with mangling; Allegro #defines main to be _al_mangled_main and calls it from the real main which is in the addon. With C++, if you don't have the right types for your args, the symbol gets exported as __Z16_al_mangled_mainiPPKc so the linker can't find it.
This is in alosx.h.
I know effort went into making it as easy to use as possible but I don't really understand the details.