2007-10-20 Robert Millan <rmh@aybabtu.com>

* genmk.rb (Image): Copy `extra_flags' from here ...
	(PModule): ... to here.  Use it in `#{obj}: #{src}' rule.

	* commands/i386/cpuid.c (grub_cmd_cpuid): Add __attribute__ ((unused))
	to `argc' and `args' arguments.
This commit is contained in:
robertmh 2007-10-20 18:32:18 +00:00
parent 1d284f8497
commit 54b71c4b7b
3 changed files with 13 additions and 4 deletions

View file

@ -143,10 +143,11 @@ endif
fs = 'fs-' + obj.suffix('lst')
dep = deps[i]
flag = if /\.c$/ =~ src then 'CFLAGS' else 'ASFLAGS' end
extra_flags = if /\.S$/ =~ src then '-DASM_FILE=1' else '' end
dir = File.dirname(src)
"#{obj}: #{src}
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) $(TARGET_#{flag}) $(#{prefix}_#{flag}) -MD -c -o $@ $<
$(TARGET_CC) -I#{dir} -I$(srcdir)/#{dir} $(TARGET_CPPFLAGS) #{extra_flags} $(TARGET_#{flag}) $(#{prefix}_#{flag}) -MD -c -o $@ $<
-include #{dep}
CLEANFILES += #{command} #{fs}