Commit 5d043fec authored by Kai Germaschewski's avatar Kai Germaschewski

Merge linux-isdn@linux-isdn.bkbits.net:linux-2.5.make

into tp1.ruhr-uni-bochum.de:/home/kai/kernel/v2.5/linux-2.5.make
parents dae77dde a84f6cba
......@@ -120,6 +120,24 @@ $(L_TARGET): $(obj-y)
) > $(dir $@)/.$(notdir $@).flags
endif
#
# Rule to link composite objects
#
# for make >= 3.78 the following is cleaner:
# multi-used := $(foreach m,$(obj-y) $(obj-m), $(if $($(basename $(m))-objs), $(m)))
multi-used := $(sort $(foreach m,$(obj-y) $(obj-m),$(patsubst %,$(m),$($(basename $(m))-objs))))
ld-multi-used := $(filter-out $(list-multi),$(multi-used))
ld-multi-objs := $(foreach m, $(ld-multi-used), $($(basename $(m))-objs))
$(ld-multi-used) : %.o: $(ld-multi-objs)
rm -f $@
$(LD) $(EXTRA_LDFLAGS) -r -o $@ $(filter $($(basename $@)-objs), $^)
@ ( \
echo 'ifeq ($(strip $(subst $(comma),:,$(LD) $(EXTRA_LDFLAGS) $($(basename $@)-objs)),$$(strip $$(subst $$(comma),:,$$(LD) $$(EXTRA_LDFLAGS) $$($(basename $@)-objs)))))' ; \
echo 'FILES_FLAGS_UP_TO_DATE += $@' ; \
echo 'endif' \
) > $(dir $@)/.$(notdir $@).flags
#
# This make dependencies quickly
......@@ -200,8 +218,7 @@ script:
#
ifdef CONFIG_MODULES
multi-used := $(filter $(list-multi), $(obj-y) $(obj-m))
multi-objs := $(foreach m, $(multi-used), $($(basename $(m))-objs))
multi-objs := $(foreach m, $(obj-y) $(obj-m), $($(basename $(m))-objs))
active-objs := $(sort $(multi-objs) $(obj-y) $(obj-m))
ifdef CONFIG_MODVERSIONS
......
......@@ -10,7 +10,6 @@ export-objs := isdn_common.o
# Multipart objects.
list-multi := isdn.o
isdn-objs := isdn_net.o isdn_tty.o isdn_v110.o isdn_common.o
# Optional parts of multipart objects.
......@@ -50,8 +49,3 @@ obj-y += $(addsuffix /vmlinux-obj.o, $(subdir-y))
# The global Rules.make.
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
isdn.o: $(isdn-objs)
$(LD) -r -o $@ $(isdn-objs)
......@@ -6,7 +6,6 @@ O_TARGET := vmlinux-obj.o
# Multipart objects.
list-multi := act2000.o
act2000-objs := module.o capi.o act2000_isa.o
# Each configuration option enables a list of files.
......@@ -14,8 +13,3 @@ act2000-objs := module.o capi.o act2000_isa.o
obj-$(CONFIG_ISDN_DRV_ACT2000) += act2000.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
act2000.o: $(act2000-objs)
$(LD) -r -o $@ $(act2000-objs)
......@@ -10,7 +10,6 @@ export-objs := kcapi.o capiutil.o b1dma.o b1pcmcia.o b1.o capifs.o
# Multipart objects.
list-multi := kernelcapi.o
kernelcapi-objs := kcapi.o
# Ordering constraints: kernelcapi.o first
......@@ -32,9 +31,3 @@ obj-$(CONFIG_ISDN_DRV_AVMB1_C4) += c4.o b1.o
# The global Rules.make.
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
kernelcapi.o: $(kernelcapi-objs)
$(LD) -r -o $@ $(kernelcapi-objs)
......@@ -8,7 +8,6 @@ O_TARGET := vmlinux-obj.o
# Multipart objects.
list-multi := dss1_divert.o
dss1_divert-objs := isdn_divert.o divert_procfs.o divert_init.o
# Each configuration option enables a list of files.
......@@ -17,12 +16,6 @@ obj-$(CONFIG_ISDN_DIVERSION) += dss1_divert.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
dss1_divert.o: $(dss1_divert-objs)
$(LD) -r -o $@ $(dss1_divert-objs)
......
......@@ -10,7 +10,6 @@ export-objs := Divas_mod.o eicon_mod.o
# Multipart objects.
list-multi := eicon.o divas.o
eicon-objs := eicon_mod.o eicon_isa.o eicon_pci.o eicon_idi.o \
eicon_io.o
divas-objs := common.o idi.o bri.o pri.o log.o xlog.o kprintf.o fpga.o \
......@@ -30,13 +29,3 @@ obj-$(CONFIG_ISDN_DRV_EICON_OLD) += eicon.o
obj-$(CONFIG_ISDN_DRV_EICON_DIVAS) += divas.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
eicon.o: $(eicon-objs)
$(LD) -r -o $@ $(eicon-objs)
divas.o: $(divas-objs)
$(LD) -r -o $@ $(divas-objs)
......@@ -14,7 +14,6 @@ export-objs := config.o fsm.o hisax_isac.o hisax_hscx.o
# Multipart objects.
list-multi := hisax.o hisax_st5481.o
hisax-objs := config.o isdnl1.o tei.o isdnl2.o isdnl3.o \
lmgr.o q931.o callc.o fsm.o cert.o
hisax_st5481-objs := st5481_init.o st5481_usb.o st5481_d.o st5481_b.o \
......@@ -54,7 +53,7 @@ hisax-objs-$(CONFIG_HISAX_GAZEL) += gazel.o isac.o arcofi.o hscx.o
hisax-objs-$(CONFIG_HISAX_W6692) += w6692.o
#hisax-objs-$(CONFIG_HISAX_TESTEMU) += testemu.o
hisax-objs += $(sort $(hisax-objs-y))
hisax-objs += $(hisax-objs-y)
# Each configuration option enables a list of files.
......@@ -70,11 +69,3 @@ CERT := $(shell md5sum -c md5sums.asc >> /dev/null;echo $$?)
CFLAGS_cert.o := -DCERTIFICATION=$(CERT)
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
hisax.o: $(hisax-objs)
$(LD) -r -o $@ $(hisax-objs)
hisax_st5481.o: $(hisax_st5481-objs)
$(LD) -r -o $@ $(hisax_st5481-objs)
......@@ -6,7 +6,6 @@ O_TARGET := vmlinux-obj.o
# Multipart objects.
list-multi := hysdn.o
hysdn-objs := hysdn_procconf.o hysdn_proclog.o boardergo.o hysdn_boot.o \
hysdn_sched.o hysdn_net.o hysdn_init.o
......@@ -21,9 +20,3 @@ hysdn-objs += $(hysdn-objs-y)
obj-$(CONFIG_HYSDN) += hysdn.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
hysdn.o: $(hysdn-objs)
$(LD) -r -o $@ $(hysdn-objs)
......@@ -6,7 +6,6 @@ O_TARGET := vmlinux-obj.o
# Multipart objects.
list-multi := pcbit.o
pcbit-objs := module.o edss1.o drv.o layer2.o capi.o callbacks.o
# Each configuration option enables a list of files.
......@@ -14,8 +13,3 @@ pcbit-objs := module.o edss1.o drv.o layer2.o capi.o callbacks.o
obj-$(CONFIG_ISDN_DRV_PCBIT) += pcbit.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
pcbit.o: $(pcbit-objs)
$(LD) -r -o $@ $(pcbit-objs)
......@@ -6,7 +6,6 @@ O_TARGET := vmlinux-obj.o
# Multipart objects.
list-multi := sc.o
sc-objs := shmem.o init.o debug.o packet.o command.o event.o \
ioctl.o interrupt.o message.o timer.o
......@@ -15,8 +14,3 @@ sc-objs := shmem.o init.o debug.o packet.o command.o event.o \
obj-$(CONFIG_ISDN_DRV_SC) += sc.o
include $(TOPDIR)/Rules.make
# Link rules for multi-part drivers.
sc.o: $(sc-objs)
$(LD) -r -o $@ $(sc-objs)
......@@ -11,7 +11,7 @@
O_TARGET := pnp.o
export-objs := isapnp.o pnpbios_core.o
multi-objs := isa-pnp.o pnpbios.o
list-multi := isa-pnp.o pnpbios.o
isa-pnp-proc-$(CONFIG_PROC_FS) = isapnp_proc.o
pnpbios-proc-$(CONFIG_PROC_FS) = pnpbios_proc.o
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment