automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Objective C on Mac OS X


From: Alexandre Duret-Lutz
Subject: Re: Objective C on Mac OS X
Date: Wed, 16 Apr 2003 00:58:52 +0200
User-agent: Gnus/5.090016 (Oort Gnus v0.16) Emacs/21.2 (gnu/linux)

>>> "Martin" == Martin Wagner <address@hidden> writes:

 Martin> -----BEGIN PGP SIGNED MESSAGE-----
 Martin> Hash: SHA1

 Martin> alexandre,

 Martin> thanks a lot for your quick advice. automake now stopped complaining,
 Martin> but the dependency file .deps/main.Po (i have only a single input
 Martin> file,  it's called main.m) contains only the following line:

 Martin> # dummy

that's expected (before the first compilation)

 Martin> and when i try to compile my file, i get an error:

 Martin> address@hidden:~/cvs/dwarf/build/src/services/Speaker $ make
 Martin> if g++ -DHAVE_CONFIG_H -I.  -
                                    ^^^
 Martin> -I/Users/wagnerm/cvs/dwarf/src/services/Speaker -I../../..     -g -O2
 Martin> - -MT main.o -MD -MP -MF ".deps/main.Tpo" \
        ^^^
 Martin> -c -o main.o `test -f
 Martin> '/Users/wagnerm/cvs/dwarf/src/services/Speaker/main.m' || echo
 Martin> '/Users/wagnerm/cvs/dwarf/src/services/Speaker/'`/Users/wagnerm/cvs/
 Martin> dwarf/src/services/Speaker/main.m; \

Where do these two isolated `-' in the g++ invocation come from?

BTW I'm a bit surprised that this rules uses g++ while
you said you were using OBJC=gcc.

 Martin> then mv ".deps/main.Tpo" ".deps/main.Po"; \
 Martin> else rm -f ".deps/main.Tpo"; exit 1; \
 Martin> fi
 Martin> cpp-precomp: could not open 'main.o'
 Martin> make: *** [main.o] Error 1

 Martin> i guess the compiler doesn't like the double occurence of main.o, 

What version of GCC is this?  Can you reproduce this behavior
manually with on a simple hello word?  My copy of GCC seems to
grok this command line just fine (i.e., as documented).

% cat hello.m
int main()                                    
{
  printf("Hello world!\n");
  return 0;
}
% g++ -MT hello.o -MD -MP -MF hello.Tpo -o hello.o hello.m
% cat hello.Tpo
hello.o hello.o: hello.m
% g++ --version
g++ (GCC) 3.2.3 20030407 (Debian prerelease)    
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

 Martin> but it's intended to be like that in the Makefile:

Yes, this is intended.

[...]

-- 
Alexandre Duret-Lutz





reply via email to

[Prev in Thread] Current Thread [Next in Thread]