[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Porting autogsdoc to OSX
From: |
Pascal Bourguignon |
Subject: |
Re: Porting autogsdoc to OSX |
Date: |
Tue, 26 Feb 2002 18:13:09 +0100 (CET) |
> From: =?ISO-8859-1?Q?Marcus_M=FCller?= <znek@mulle-kybernetik.com>
> Date: Tue, 26 Feb 2002 17:47:25 +0100
>
> On Tuesday, February 26, 2002, at 05:31 PM, Adam Fedor wrote:
>
> > Since we are talking about a limited number of files (in this case,
> > only autogsdoc, and the XML parser files), and at least autogsdoc files
> > always have '#include <Foundation/Foundation.h>', we could put in
> > something like
> >
> > #ifdef MACOSX_COMPATIBILITY
> > #import <Foundation/Foundation.h>
> > #else
> > #include <Foundation/Foundation.h>
> > #endif
>
> Well, I read through the archive (as Nicola proposed) and now do
> understand the problems with #import. The above proposal would certainly
> be feasible in the example of autogsdoc, but then again every GNUstep
> application would have to use such a construct in order to maintain Mac
> OS X compatibility - not that desirable I guess. Isn't there a better
> way to do it? (One that could convince more people to adopt such a
> mechanism)
>
> Cheers,
>
> Marcus
Why not write a script that would add #ifndef/#define/#endif into the
headers from Apple? (Well, this would not work if some source is
#including twice the same header for some reason, like some C
programmers like to do. Perhaps that's why they don't want to go back
to #include at Apple's, otherwise it would be quite easy to sed
's/#import/#include/g' everywhere).
Otherwise, my first idea would be to avoid using directly the headers
from Apple, but use some "compatibility" headers.
----------------(compatibility/Foundation/Foundation.h)-----------------
#ifndef compatibility_Foundation_Foundation_h
#define compatibility_Foundation_Foundation_h
#import </System/Library/Frameworks/Foundation.framework/Headers/Foundation.h>
#endif
------------------------------------------------------------------------
And use -I$(somewhere)/compatibility before the foundation include
that would then be shadowed.
Same for AppKit.
--
__Pascal_Bourguignon__ (o_ Software patents are endangering
() ASCII ribbon against html email //\ the computer industry all around
/\ and Microsoft attachments. V_/ the world http://lpf.ai.mit.edu/
1962:DO20I=1.100 2001:my($f)=`fortune`; http://petition.eurolinux.org/
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/IT d? s++:++(+++)>++ a C+++ UB+++L++++$S+X++++>$ P- L+++ E++ W++
N++ o-- K- w------ O- M++$ V PS+E++ Y++ PGP++ t+ 5? X+ R !tv b++(+)
DI+++ D++ G++ e+++ h+(++) r? y---? UF++++
------END GEEK CODE BLOCK------
- Re: import vs include Re: Porting autogsdoc to OSX, (continued)
- Re: import vs include Re: Porting autogsdoc to OSX, Pascal Bourguignon, 2002/02/27
- Re: import vs include Re: Porting autogsdoc to OSX, Richard Frith-Macdonald, 2002/02/27
- Re: import vs include Re: Porting autogsdoc to OSX, Dirk Theisen, 2002/02/27
- Re: import vs include Re: Porting autogsdoc to OSX, Nicola Pero, 2002/02/27
- Re: import vs include Re: Porting autogsdoc to OSX, Dirk Theisen, 2002/02/27
- Re: Porting autogsdoc to OSX, Adam Fedor, 2002/02/26
- Re: Porting autogsdoc to OSX, Marcus Müller, 2002/02/26
- Re: Porting autogsdoc to OSX,
Pascal Bourguignon <=
- Re: Porting autogsdoc to OSX, Helge Hess, 2002/02/26
Re: Porting autogsdoc to OSX, Lars Sonchocky-Helldorf, 2002/02/26
Re: Porting autogsdoc to OSX, Lars Sonchocky-Helldorf, 2002/02/26
Re: Porting autogsdoc to OSX, Lars Sonchocky-Helldorf, 2002/02/26