cc local labels
Steve Summit
stevesu at bronze.UUCP
Sat Oct 1 04:55:24 AEST 1983
Here's a weird problem: I have a large program, consisting of
many source files, which I have been modifying. Most of the
modifications are conditionally compiled. I wanted to find out
which files had been changed for good, i.e. whether conditionally
compiled or not. I had one directory full of the modified files,
and one full of the originals. I cc'ed everything -c. To my
surprise, every .o file was at least one byte different, even
those whose source files had not changed at all (not even
conditionally).
nm revealed that the c compiler had picked different names for
some local labels. The only thing different in the compilations
was the location (in the filesystem) of the source files, and the
time of day. I compiled them several times and the labels always
came out the same in a given directory, so the time-of-day
dependence is out. Does anyone understand how cc's behavior can
be affected by the directory the source files are in?
This never happened to me when I worked under 2.8bsd, so it may
be specific to the 4.1?bsd that I'm using now.
Steve Summit
tektronix!tekmdp!stevesu
More information about the Comp.unix.wizards
mailing list