Date: Wed, 6 Jan 93 10:15:32 -0600
From: lupson@geom.umn.edu
To: gnu-objc@prep.ai.mit.edu
Subject: Re: questions...
> 3: Why does gcc not like "#import" statements? It seems that
> using "#include" with the #ifndef _File_INCLUDE_ statements is kind of a
> ugly way to do this.
This is really annoying, and I don't understand why gcc has this warning on by
default. I posted a question about this to gnu.misc.discuss and got no replies.
You can stop the pest by putting -Wno-import on the command line when you compile,
or if you want to kill it forever edit
/usr/local/lib/gcc-lib//2.3.2/specs:
[...]
*cpp:
%{!ansi:-D__EXTENSIONS__} -D_MIPSEB -D_SYSTYPE_SYSV %{.S:
-D_LANGUAGE_ASSEMBLY %{!ansi:-DLANGUAGE_ASSEMBLY}} %{.cc:
-D_LANGUAGE_C_PLUS_PLUS} %{.cxx: -D_LANGUAGE_C_PLUS_PLUS} %{.C:
-D_LANGUAGE_C_PLUS_PLUS} %{.m: -D_LANGUAGE_OBJECTIVE_C -Wno-import} %{!.S:
^^^^^^^^^^^
%{!.cc: %{!.cxx: %{!.C: %{!.m: -D_LANGUAGE_C %{!ansi:-DLANGUAGE_C}}}}}}
[...]
I could not find any documentation on the specs file so I'm guessing that my
modification won't break anything. Another route would be to modify the cccp
source code.
Linus Upson
lupson@geom.umn.edu
|