patch-2.3.27 linux/drivers/net/pcmcia/Makefile

Next file: linux/drivers/net/pcmcia/netwave_cs.c
Previous file: linux/drivers/net/pcmcia/Config.in
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.26/linux/drivers/net/pcmcia/Makefile linux/drivers/net/pcmcia/Makefile
@@ -9,110 +9,44 @@
 ALL_SUB_DIRS := $(SUB_DIRS)
 
 O_TARGET := pcmcia_net.o
-O_OBJS   :=
-M_OBJS   :=
-MOD_LIST_NAME := PCMCIA_MODULES
-
-#CFLAGS_3c575_cb.o = -DCARDBUS
-#CFLAGS_tulip_cb.o = -DCARDBUS
-
-ifeq ($(CONFIG_PCMCIA_3C589),y)
-  O_OBJS += 3c589_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_3C589),m)
-    M_OBJS += 3c589_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_3C574),y)
-  O_OBJS += 3c574_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_3C574),m)
-    M_OBJS += 3c574_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_FMVJ18X),y)
-  O_OBJS += fmvj18x_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_FMVJ18X),m)
-    M_OBJS += fmvj18x_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_NMCLAN),y)
-  O_OBJS += nmclan_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_NMCLAN),m)
-    M_OBJS += nmclan_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_PCNET),y)
-  O_OBJS += pcnet_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_PCNET),m)
-    M_OBJS += pcnet_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_SMC91C92),y)
-  O_OBJS += smc91c92_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_SMC91C92),m)
-    M_OBJS += smc91c92_cs.o
-  endif
-endif
-
-#ifeq ($(CONFIG_PCMCIA_3C575),y)
-#  O_OBJS += 3c575_cb.o
-#else
-#  ifeq ($(CONFIG_PCMCIA_3C575),m)
-#    M_OBJS += 3c575_cb.o
-#  endif
-#endif
-
-#ifeq ($(CONFIG_PCMCIA_TULIP),y)
-#  O_OBJS += tulip_cb.o
-#else
-#  ifeq ($(CONFIG_PCMCIA_TULIP),m)
-#    M_OBJS += tulip_cb.o
-#  endif
-#endif
-
-#ifeq ($(CONFIG_PCMCIA_EPIC100),y)
-#  O_OBJS += epic100_cb.o
-#else
-#  ifeq ($(CONFIG_PCMCIA_EPIC100),m)
-#    M_OBJS += epic100_cb.o
-#  endif
-#endif
-
-ifeq ($(CONFIG_PCMCIA_RAYCS),y)
-  OX_OBJS += ray_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_RAYCS),m)
-  MX_OBJS += ray_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_NETWAVE),y)
-  OX_OBJS += netwave_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_NETWAVE),m)
-  M_OBJS += netwave_cs.o
-  endif
-endif
-
-ifeq ($(CONFIG_PCMCIA_WAVELAN),y)
-  OX_OBJS += wavelan_cs.o
-else
-  ifeq ($(CONFIG_PCMCIA_WAVELAN),m)
-  M_OBJS += wavelan_cs.o
-  endif
-endif
+MOD_LIST_NAME := PCMCIA_NET_MODULES
+
+obj-y		:=
+obj-m		:=
+obj-n		:=
+obj-		:=
+
+# Things that need to export symbols
+export-objs	:= ray_cs.o
+
+CFLAGS_3c575_cb.o = -DCARDBUS -DMODULE
+CFLAGS_tulip_cb.o = -DCARDBUS -DMODULE
+
+# 16-bit client drivers
+obj-$(CONFIG_PCMCIA_3C589)	+= 3c589_cs.o
+obj-$(CONFIG_PCMCIA_3C574)	+= 3c574_cs.o
+obj-$(CONFIG_PCMCIA_FMVJ18X)	+= fmvj18x_cs.o
+obj-$(CONFIG_PCMCIA_NMCLAN)	+= nmclan_cs.o
+obj-$(CONFIG_PCMCIA_PCNET)	+= pcnet_cs.o
+obj-$(CONFIG_PCMCIA_SMC91C92)	+= smc91c92_cs.o
+obj-$(CONFIG_PCMCIA_XIRC2PS)	+= xirc2ps_cs.o
+
+# 16-bit wireless client drivers
+obj-$(CONFIG_PCMCIA_RAYCS)	+= ray_cs.o
+obj-$(CONFIG_PCMCIA_NETWAVE)	+= netwave_cs.o
+obj-$(CONFIG_PCMCIA_WAVELAN)	+= wavelan_cs.o
+
+# Cardbus client drivers
+obj-$(CONFIG_PCMCIA_3C575)	+= 3c575_cb.o
+obj-$(CONFIG_PCMCIA_TULIP)	+= tulip_cb.o
+obj-$(CONFIG_PCMCIA_EPIC100)	+= epic100_cb.o
+
+O_OBJS		:= $(filter-out $(export-objs), $(obj-y))
+OX_OBJS		:= $(filter     $(export-objs), $(obj-y))
+M_OBJS		:= $(filter-out $(export-objs), $(obj-m))
+MX_OBJS		:= $(filter     $(export-objs), $(obj-m))
 
 include $(TOPDIR)/Rules.make
 
-#epic100_cb.o: ../epic100.c
-#	$(CC) $(CFLAGS) -DCARDBUS -c -o $@ ../epic100.c
+epic100_cb.o: ../epic100.c
+	$(CC) $(CFLAGS) -DMODULE -DCARDBUS -c -o $@ ../epic100.c

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)