Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

Advertisement
[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Kernel v2.5.4-pre6 /Rules.make

Filename:/Rules.make
Lines Added:4
Lines Deleted:2
Also changed in: (Previous) 2.5.4-pre5  2.4.3  2.4.3-pre8  2.4.3-pre7  2.4.3-pre6  2.4.3-pre5 
(Following) 2.5.4  2.5.5-pre1  2.5.5  2.5.7-pre2  2.5.7  2.5.8-pre1 

Location
[  2.5.4-pre6
   o  Rules.make

Patch

diff -Nru a/Rules.make b/Rules.make
--- a/Rules.make   Sun Feb 10 14:06:27 2002
+++ b/Rules.make   Sun Feb 10 14:06:27 2002
@@ -31,6 +31,8 @@
 unexport subdir-n
 unexport subdir-
 
+comma   := ,
+
 #
 # Get things started.
 #
@@ -54,7 +56,7 @@
    $(CPP) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) $< > $@
 
 %.o: %.c
-   $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -c -o $@ $<
+   $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -DKBUILD_BASENAME=$(subst $(comma),_,$(subst -,_,$(*F))) $(CFLAGS_$@) -c -o $@ $<
    @ ( \
        echo 'ifeq ($(strip $(subst $(comma),:,$(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@))),$$(strip $$(subst $$(comma),:,$$(CFLAGS) $$(+
EXTRA_CFLAGS) $$(CFLAGS_$@))))' ; \
        echo 'FILES_FLAGS_UP_TO_DATE += $@' ; \
@@ -270,7 +272,7 @@
 
 ifneq "$(strip $(export-objs))" ""
 $(export-objs): $(export-objs:.o=.c) $(TOPDIR)/include/linux/modversions.h
-   $(CC) $(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -DEXPORT_SYMTAB -c $(@:.o=.c)
+   $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -DKBUILD_BASENAME=$(subst $(comma),_,$(subst -,_,$(*F))) $(CFLAGS_$@) -DEXPORT_SYMTAB -c $(@:.o=+
.c)
    @ ( \
        echo 'ifeq ($(strip $(subst $(comma),:,$(CFLAGS) $(EXTRA_CFLAGS) $(CFLAGS_$@) -DEXPORT_SYMTAB)),$$(strip $$(subst $$(comma),+
:,$$(CFLAGS) $$(EXTRA_CFLAGS) $$(CFLAGS_$@) -DEXPORT_SYMTAB)))' ; \
        echo 'FILES_FLAGS_UP_TO_DATE += $@' ; \


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.