MPW - SDL - GL - Include Paths

I’m trying to round out my collection of platforms - til now I’ve only
been able to compile against Linux and win32 (via cross compiling -
thanks Mingw32 guys). I’ve recently aquired an old iMac with MacOS 8.5.
My previous experience with MacOS was in professional graphics and
multimedia development - but never with software development - Linux got
me into that. I’ve downloaded MPW and put it into the “Mac Harddrive” -
I can’t say how tickled I am to have a free compiler for the Mac
platform as well as for Linux and Windows. I can’t believe I didn’t know
about MPW til now. It’s to the Mac what the gcc tools are to Linux. Now
I can compile my SDL apps on all three during development…

I downloaded the SDL source and started compiling it, but it complained
about the lack of GL/GL.h.

I also installed the runtime/devel and attempted to run a basic app -
but it complained about there being no “SDL/SDL.h”.

That leads me into where the headers go, and how the #includes need to
be configured to be happy with all platforms from a single code base (I
already have #ifndef WIN32 #include <windows.h> #endif). Anyone out
there using MPW? What, where, how, and reference are what I need. I hope
this is on topic - after all, I’m only doing this to compile SDL
applications…

Later on I’ll get a newer iMac with OS-X for a fourth platform. Drool…

Thanks,
Mike

I downloaded the SDL source and started compiling it, but it complained
about the lack of GL/GL.h.

You’ll have to download the OpenGL SDK from Apple’s website which will
contain the headers and libraries you need. That can be reached from
www.apple.com/opengl.

I also installed the runtime/devel and attempted to run a basic app -
but it complained about there being no “SDL/SDL.h”.

That leads me into where the headers go, and how the #includes need to
be configured to be happy with all platforms from a single code base (I
already have #ifndef WIN32 #include <windows.h> #endif). Anyone out
there using MPW? What, where, how, and reference are what I need. I hope
this is on topic - after all, I’m only doing this to compile SDL
applications…

For any platform, I’d recommend using #include “SDL.h”. Then you can edit
the makefiles/project settings to make sure files are located by the
compiler. By keeping the platform-specific details (in this case, where to
find the headers) separate from the code, you’ll also gain a bit of
portability in the process.

Cheers,
DarrellOn Mon, 31 Dec 2001, Mike Vanecek wrote: