From f49821ee32b76b1a356fab17316eb62430182ecf Mon Sep 17 00:00:00 2001 From: Nicholas Piggin Date: Sun, 11 Feb 2018 00:25:04 +1000 Subject: kbuild: rename built-in.o to built-in.a Incremental linking is gone, so rename built-in.o to built-in.a, which is the usual extension for archive files. This patch does two things, first is a simple search/replace: git grep -l 'built-in\.o' | xargs sed -i 's/built-in\.o/built-in\.a/g' The second is to invert nesting of nested text manipulations to avoid filtering built-in.a out from libs-y2: -libs-y2 := $(filter-out %.a, $(patsubst %/, %/built-in.a, $(libs-y))) +libs-y2 := $(patsubst %/, %/built-in.a, $(filter-out %.a, $(libs-y))) Signed-off-by: Nicholas Piggin Signed-off-by: Masahiro Yamada --- drivers/s390/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/s390/Makefile b/drivers/s390/Makefile index 2fdab400c1fe..a863b0462b43 100644 --- a/drivers/s390/Makefile +++ b/drivers/s390/Makefile @@ -5,5 +5,5 @@ obj-y += cio/ block/ char/ crypto/ net/ scsi/ virtio/ -drivers-y += drivers/s390/built-in.o +drivers-y += drivers/s390/built-in.a -- cgit v1.2.3 From f605005a50fc1443a14b4e8c9c1727881f8f96ae Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Mon, 19 Mar 2018 20:26:10 +0900 Subject: net: liquidio: clean up Makefile for simpler composite object handling Now, Kbuild nicely handles composite objects to avoid multiple definition. Makefiles can simply add the same objects multiple times across composite objects. Signed-off-by: Masahiro Yamada --- drivers/net/ethernet/cavium/liquidio/Makefile | 51 +++++++++------------------ 1 file changed, 16 insertions(+), 35 deletions(-) (limited to 'drivers') diff --git a/drivers/net/ethernet/cavium/liquidio/Makefile b/drivers/net/ethernet/cavium/liquidio/Makefile index e3fc4645cd8a..bc9937502043 100644 --- a/drivers/net/ethernet/cavium/liquidio/Makefile +++ b/drivers/net/ethernet/cavium/liquidio/Makefile @@ -2,42 +2,23 @@ # # Cavium Liquidio ethernet device driver # -obj-$(CONFIG_LIQUIDIO) += liquidio.o -liquidio-$(CONFIG_LIQUIDIO) += lio_ethtool.o \ - lio_core.o \ - request_manager.o \ - response_manager.o \ - octeon_device.o \ - cn66xx_device.o \ - cn68xx_device.o \ - cn23xx_pf_device.o \ - cn23xx_vf_device.o \ - octeon_mailbox.o \ - octeon_mem_ops.o \ - octeon_droq.o \ - octeon_nic.o +common-objs := lio_ethtool.o \ + lio_core.o \ + request_manager.o \ + response_manager.o \ + octeon_device.o \ + cn66xx_device.o \ + cn68xx_device.o \ + cn23xx_pf_device.o \ + cn23xx_vf_device.o \ + octeon_mailbox.o \ + octeon_mem_ops.o \ + octeon_droq.o \ + octeon_nic.o -liquidio-objs := lio_main.o octeon_console.o lio_vf_rep.o $(liquidio-y) +obj-$(CONFIG_LIQUIDIO) += liquidio.o +liquidio-y := lio_main.o octeon_console.o lio_vf_rep.o $(common-objs) obj-$(CONFIG_LIQUIDIO_VF) += liquidio_vf.o - -ifeq ($(CONFIG_LIQUIDIO)$(CONFIG_LIQUIDIO_VF), yy) - liquidio_vf-objs := lio_vf_main.o -else -liquidio_vf-$(CONFIG_LIQUIDIO_VF) += lio_ethtool.o \ - lio_core.o \ - request_manager.o \ - response_manager.o \ - octeon_device.o \ - cn66xx_device.o \ - cn68xx_device.o \ - cn23xx_pf_device.o \ - cn23xx_vf_device.o \ - octeon_mailbox.o \ - octeon_mem_ops.o \ - octeon_droq.o \ - octeon_nic.o - -liquidio_vf-objs := lio_vf_main.o $(liquidio_vf-y) -endif +liquidio_vf-y := lio_vf_main.o $(common-objs) -- cgit v1.2.3