2006-08-15 Johan Rydberg <jrydberg@gnu.org>
* genmk.rb: Let GCC generate dependenceies the first time it compiles a file; using the -MD option. * conf/common.mk: Regenerate. * conf/i386-pc.mk: Likewise. * conf/i386-efi.mk: Likewise. * conf/powerpc-ieee1275.mk: Likewise. * conf/sparc64-ieee1275.mk: Likewise.
This commit is contained in:
parent
1064790dc6
commit
01b82a64e2
7 changed files with 450 additions and 2212 deletions
36
genmk.rb
36
genmk.rb
|
@ -71,14 +71,7 @@ MOSTLYCLEANFILES += #{deps_str}
|
|||
dir = File.dirname(src)
|
||||
|
||||
"#{obj}: #{src}
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) #{extra_flags} $(TARGET_#{flag}) $(#{prefix}_#{flag}) -c -o $@ $<
|
||||
|
||||
#{dep}: #{src}
|
||||
set -e; \
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) #{extra_flags} $(TARGET_#{flag}) $(#{prefix}_#{flag}) -M $< \
|
||||
| sed 's,#{Regexp.quote(fake_obj)}[ :]*,#{obj} $@ : ,g' > $@; \
|
||||
[ -s $@ ] || rm -f $@
|
||||
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) #{extra_flags} $(TARGET_#{flag}) $(#{prefix}_#{flag}) -MD -c -o $@ $<
|
||||
-include #{dep}
|
||||
|
||||
"
|
||||
|
@ -153,14 +146,7 @@ endif
|
|||
dir = File.dirname(src)
|
||||
|
||||
"#{obj}: #{src}
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_#{flag}) $(#{prefix}_#{flag}) -c -o $@ $<
|
||||
|
||||
#{dep}: #{src}
|
||||
set -e; \
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_#{flag}) $(#{prefix}_#{flag}) -M $< \
|
||||
| sed 's,#{Regexp.quote(fake_obj)}[ :]*,#{obj} $@ : ,g' > $@; \
|
||||
[ -s $@ ] || rm -f $@
|
||||
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_#{flag}) $(#{prefix}_#{flag}) -MD -c -o $@ $<
|
||||
-include #{dep}
|
||||
|
||||
CLEANFILES += #{command} #{fs}
|
||||
|
@ -213,14 +199,7 @@ MOSTLYCLEANFILES += #{deps_str}
|
|||
dir = File.dirname(src)
|
||||
|
||||
"#{obj}: #{src}
|
||||
$(CC) -I#{dir} -I$(srcdir)/#{dir} $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(#{prefix}_CFLAGS) -c -o $@ $<
|
||||
|
||||
#{dep}: #{src}
|
||||
set -e; \
|
||||
$(CC) -I#{dir} -I$(srcdir)/#{dir} $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(#{prefix}_CFLAGS) -M $< \
|
||||
| sed 's,#{Regexp.quote(fake_obj)}[ :]*,#{obj} $@ : ,g' > $@; \
|
||||
[ -s $@ ] || rm -f $@
|
||||
|
||||
$(CC) -I#{dir} -I$(srcdir)/#{dir} $(CPPFLAGS) $(CFLAGS) -DGRUB_UTIL=1 $(#{prefix}_CFLAGS) -MD -c -o $@ $<
|
||||
-include #{dep}
|
||||
|
||||
"
|
||||
|
@ -258,14 +237,7 @@ MOSTLYCLEANFILES += #{deps_str}
|
|||
dir = File.dirname(src)
|
||||
|
||||
"#{obj}: #{src}
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) $(#{prefix}_CFLAGS) -c -o $@ $<
|
||||
|
||||
#{dep}: #{src}
|
||||
set -e; \
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) $(#{prefix}_CFLAGS) -M $< \
|
||||
| sed 's,#{Regexp.quote(fake_obj)}[ :]*,#{obj} $@ : ,g' > $@; \
|
||||
[ -s $@ ] || rm -f $@
|
||||
|
||||
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_CFLAGS) $(#{prefix}_CFLAGS) -MD -c -o $@ $<
|
||||
-include #{dep}
|
||||
|
||||
"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue