Skip Menu |
 

To: krb5-bugs@MIT.EDU
Subject: gcc -fworking-directory breaks make depend
From: Tom Yu <tlyu@MIT.EDU>
Date: Tue, 18 Sep 2007 00:40:49 -0400
I just had "make depend" fail spectacularly.

At some point recently (3.4.0?), gcc grew the option to output the
working directory in cpp output ("-fworking-directory"). This outputs
cpp line markers containing the working directory, and for some reason
occurs even while runing "make depend" using "gcc -M", causing broken
makefiles. I think it's because passing "-g" to gcc may turn on
"-fworking-directory" due to the specfile.

Workaround is to set CFLAGS=-P or CFLAGS=-fno-working-directory when
running "make depend", but we might want to make the depfix script
deal with the spurious line markers if they get output.
Alternatively, or additionally, add to ALL_CFLAGS a variable named
DEP_CFLAGS or something like that which will get configured to contain
gcc-version-specific flags to suppress line markers. Stripping line
markers in depfix sounds easier though.
From: tlyu@mit.edu
Subject: SVN Commit
Ignore dependency lines beginning with '#' to deal with gcc
-fworking-directory output during make depend.


Commit By: tlyu



Revision: 19961
Changed Files:
_U trunk/
U trunk/src/util/depfix.pl
From: tlyu@mit.edu
Subject: SVN Commit

pull up r19961 from trunk

r19961@cathode-dark-space: tlyu | 2007-09-18 22:54:56 -0400
ticket: 5752
target_version: 1.6.4
tags: pullup

Ignore dependency lines beginning with '#' to deal with gcc
-fworking-directory output during make depend.




Commit By: tlyu



Revision: 20169
Changed Files:
_U branches/krb5-1-6/
U branches/krb5-1-6/src/util/depfix.pl