Re: [AD] New OSX makefile targets

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> A note on the template: the file generated is main.m instead of main.c
> or main.cpp -- was this intentional?  Also, it sets up 320x200 as a
> default mode, which is doomed to fail under OSX (I've yet to find any
> modes below 640x480 that don't generate an error on modern macs).
> Also, someone should change GFX_SAFE in src/macosx/quartz.m.

320x200 is perfectly safe under OSX: it'll just always work in a window, as
fullscreen only supports resolutions higher than 640x480.
And main.m is intentional: more below.

> Hmm... I just realized that GFX_AUTODETECT uses windowed mode by
> default, so 320x200 is fine.  Well, the thought's still there for
> anyone who's interested. :)  Does the PB build of main.m take an
> inordinate amount of time for anyone else?

Yes, main.m takes a lot of time to compile: I suppose that's because the
compiler assumes it's objective-C.
If I use a .c or .cpp extension (I would have preferred a .c one), the
compile would have been a lot faster, but unfortunately if I use main.c, PB
reports a LOT of errors on the first compile of the project... On second
compile, no errors are reported; I know, it's weird, and I haven't come up
with a solution other than using a .m file as default.
I think the compiler assumes plain C if compiling a .c file, and thus it
complains when it scans allegro.h and finds objective-c definitions in the
included headers. But this doesn't make much sense as if I compile a .c
including allegro.h from the command line, it compiles just fine...

> Oh, and I haven't forgotten the icon program.  I'm looking at a
> seperate program from fixbundle.sh -- it'll be a program which takes an
> image from the command line and generates an icon family .icns
> resource.  However, I'm waiting on a response to an e-mail regarding
> it, as somebody else has already come up with a perfectly good solution
> to this issue and I don't want to reinvent the wheel.  ^_^;;

Great! But please write it in the spirit of the other existing Allegro
tools: wfixicon and bfixicon (in the tools/win and tools/beos directories).
The app should work this way from the command line IMO:

fixbundle exename [-o bundlename] [icon16x16] [icon32x32] [icon48x48]
[icon128x128]

As you probably know, icon resouces in OSX have several versions of the same
icon: a 16x16 one, 32x32, 48x48 and 128x128. fixbundle should automatically
detect the upper size of a passed icon image and stretch it if needed.

> I'll also add a bit to fixbundle.sh (error checks, checking for
> overwriting of files, etc) as soon as I have time, scout's honor.

If you plan on writing a real app, better wait for it :)

-- 
Angelo Mottola
a.mottola@xxxxxxxxxx





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/