[Pythonmac-SIG] Help with compiling Mac C extension
Jack Jansen
Jack.Jansen@oratrix.com
Tue, 26 Mar 2002 22:49:57 +0100
On dinsdag, maart 26, 2002, at 08:37 , Louis M. Pecora wrote:
> RE: QDRotate.ppc.slb extension used with Piddle graphics for
> QuickDraw text rotation.
>
> The Piddle package has an extension (above named) to help with
> text rotation in the drawstring routine. This because QD does
> not rotate text on its own. The latest version of Python that
> I installed (2.2) complains that the extension QDRotate.ppc.slb
> is for a previous version of Python. I have the original
> QDrotate code so I tried compiling it with the latest
> PythonCore. I've done this before and I had it working in
> older Pythons but in 2.2 I get a compile error that the
> Codewarrior project can't find Carbon/Carbonlib.h or other
> things like that when I try to compile the QDRotate module. If
> I define a C variable (compile option WITHOUT_FRAMES) to avoid
> that include and use what appears to be older Mac stuff, I get
> several arcane errors that leave me puzzled (things like
> "numbers beyond range" in other headers).
It sounds like you didn't include the right prefix file in your
project (mwerks_plugin_config.h for PPC builds,
mwerks_carbonplugin_config.h for Carbon builds). It defines
WITHOUT_FRAMEWORKS (I assume WITHOUT_FRAMES is a typo, yes?) and
for Carbon builds various other defines that are needed to make
Universal Headers behave correctly for Carbon.
If you look at xx.mcp (in :Mac:Build) it should tell you how to
modify your old project to work with Python 2.2 and all else
that has changed in the mean time.
--
- Jack Jansen <Jack.Jansen@oratrix.com>
http://www.cwi.nl/~jack -
- If I can't dance I don't want to be part of your revolution --
Emma Goldman -