Minor cleanup in drivers/net/pcmcia/Makefile

Message ID 20010524155138.F1477@arthur.ubicom.tudelft.nl
State New, archived
Headers show
  • Minor cleanup in drivers/net/pcmcia/Makefile
Related show

Commit Message

Erik Mouw May 24, 2001, 1:51 p.m. UTC

Because make can't track intermediate targets made in a rule, the
ibmtr_cs drivers was rebuild every time you run "make modules". This
patch fixes that by making the intermediate files explicit rules in the
Makefile. Patch is against linux-2.4.5-pre5, but should apply cleanly
against other kernel versions as well. Please apply.



--- drivers/net/pcmcia/Makefile.orig	Thu May 24 15:33:26 2001
+++ drivers/net/pcmcia/Makefile	Thu May 24 15:35:53 2001
@@ -38,8 +38,10 @@ 
 include $(TOPDIR)/Rules.make
 tmp-ibmtr.o: ../tokenring/ibmtr.c
-	$(CC) $(CFLAGS) -D__NO_VERSION__ -DPCMCIA -c -o $@ ../tokenring/ibmtr.c
+	$(CC) $(CFLAGS) -D__NO_VERSION__ -DPCMCIA -c -o $@ $<
-ibmtr_cs.o: tmp-ibmtr.o ibmtr_cs.c
-	$(CC) $(CFLAGS) -DPCMCIA -c -o tmp-$@ ibmtr_cs.c
-	$(LD) -r -o $@ tmp-$@ tmp-ibmtr.o
+tmp-ibmtr_cs.o: ibmtr_cs.c
+	$(CC) $(CFLAGS) -DPCMCIA -c -o $@ $<
+ibmtr_cs.o: tmp-ibmtr.o tmp-ibmtr_cs.o
+	$(LD) -r -o $@ tmp-ibmtr_cs.o tmp-ibmtr.o