This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
-MM and -MMD are not ignoring #include <xx.h> files
- From: "PENHEY, Tim, FM" <Tim dot PENHEY at rbos dot com>
- To: "'gcc-help at gcc dot gnu dot org'" <gcc-help at gcc dot gnu dot org>
- Date: Thu, 24 Feb 2005 08:55:08 -0000
- Subject: -MM and -MMD are not ignoring #include <xx.h> files
Hi,
I've been tearing my hair out with this one. I have reduced it to something
really simple:
-- start hack.cpp
#include <a.h>
#include "b.h"
int main()
{
return 0;
}
-- end hack.cpp
-- start bash shell commands
~/sandbox/proper-dependancy [41]$ touch a.h b.h
~/sandbox/proper-dependancy [44]$ gcc -M hack.cpp -I .
hack.o: hack.cpp a.h b.h
~/sandbox/proper-dependancy [45]$ gcc -MM hack.cpp -I .
hack.o: hack.cpp a.h b.h
~/sandbox/proper-dependancy [46]$ /opt/GDStools/pkgs/pd/gcc/3.4.1/bin/g++
-MM hack.cpp -I .
hack.o: hack.cpp ./a.h b.h
~/sandbox/proper-dependancy [47]$ /opt/GDStools/pkgs/pd/gcc/3.4.1/bin/g++ -M
hack.cpp -I .
hack.o: hack.cpp ./a.h b.h
~/sandbox/proper-dependancy [48]$ gcc --version
gcc (GCC) 3.2.3
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.
~/sandbox/proper-dependancy [49]$ /opt/GDStools/pkgs/pd/gcc/3.4.1/bin/g++
--version
g++ (GCC) 3.4.1
Copyright (C) 2004 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.
-- end of bash shell commands
Now I thought that -MM should not include <a.h> in the depenancy list.
What's going on. What am I missing?
Thanks,
Tim
--LongSig
***********************************************************************************
The Royal Bank of Scotland plc. Registered in Scotland No 90312. Registered Office: 36 St Andrew Square, Edinburgh EH2 2YB.
Authorised and regulated by the Financial Services Authority
This e-mail message is confidential and for use by the
addressee only. If the message is received by anyone other
than the addressee, please return the message to the sender
by replying to it and then delete the message from your
computer. Internet e-mails are not necessarily secure. The
Royal Bank of Scotland plc does not accept responsibility for
changes made to this message after it was sent.
Whilst all reasonable care has been taken to avoid the
transmission of viruses, it is the responsibility of the recipient to
ensure that the onward transmission, opening or use of this
message and any attachments will not adversely affect its
systems or data. No responsibility is accepted by The Royal
Bank of Scotland plc in this regard and the recipient should carry
out such virus and other checks as it considers appropriate.
Visit our websites at:
http://www.rbs.co.uk/CBFM
http://www.rbsmarkets.com
********************************************************************************