Skip to contentSkip to conversation

target: rename Kbuild files to Makefile

PATCH In review Christoph Hellwig 3 participants 4 messages Nov 15, 2010 – Nov 16, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/2 target: rename Kbuild files to Makefile

drivers/target/Kbuild deleted +0 -31
Index: lio-core/drivers/target/Kbuild
===================================================================
@@ -1,31 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
-
-target_core_mod-y		:= target_core_configfs.o \
-				   target_core_device.o \
-				   target_core_fabric_configfs.o \
-				   target_core_fabric_lib.o \
-				   target_core_hba.o \
-				   target_core_pr.o \
-				   target_core_alua.o \
-				   target_core_scdb.o \
-				   target_core_tmr.o \
-				   target_core_tpg.o \
-				   target_core_transport.o \
-				   target_core_cdb.o \
-				   target_core_ua.o \
-				   target_core_rd.o \
-				   target_core_mib.o
-
-obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
-
-# Subsystem modules
-obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
-obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
-obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
-obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
-
-# Fabric modules
-obj-$(CONFIG_LIO_TARGET)	+= lio-target/
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
-
-obj-$(CONFIG_TCM_FC)		+= tcm_fc/
drivers/target/Makefile new file +31 -0
Index: lio-core/drivers/target/Makefile
===================================================================
@@ -0,0 +1,31 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
+
+target_core_mod-y		:= target_core_configfs.o \
+				   target_core_device.o \
+				   target_core_fabric_configfs.o \
+				   target_core_fabric_lib.o \
+				   target_core_hba.o \
+				   target_core_pr.o \
+				   target_core_alua.o \
+				   target_core_scdb.o \
+				   target_core_tmr.o \
+				   target_core_tpg.o \
+				   target_core_transport.o \
+				   target_core_cdb.o \
+				   target_core_ua.o \
+				   target_core_rd.o \
+				   target_core_mib.o
+
+obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
+
+# Subsystem modules
+obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
+obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
+obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
+obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
+
+# Fabric modules
+obj-$(CONFIG_LIO_TARGET)	+= lio-target/
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
+
+obj-$(CONFIG_TCM_FC)		+= tcm_fc/
drivers/target/tcm_fc/Kbuild deleted +0 -16
Index: lio-core/drivers/target/tcm_fc/Kbuild
===================================================================
@@ -1,16 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
-		-I$(srctree)/drivers/scsi/ \
-		-I$(srctree)/include/scsi/ \
-		-I$(srctree)/drivers/target/tcm_fc/
-
-tcm_fc-objs := \
-		tfc_cmd.o \
-		tfc_conf.o \
-		tfc_io.o \
-		tfc_sess.o
-
-obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
-
-ifdef CONFIGFS_TCM_FC_DEBUG
-EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
-endif
drivers/target/tcm_fc/Makefile new file +15 -0
Index: lio-core/drivers/target/tcm_fc/Makefile
===================================================================
@@ -0,0 +1,15 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
+		-I$(srctree)/drivers/scsi/ \
+		-I$(srctree)/include/scsi/ \
+		-I$(srctree)/drivers/target/tcm_fc/
+
+tcm_fc-y +=	tfc_cmd.o \
+		tfc_conf.o \
+		tfc_io.o \
+		tfc_sess.o
+
+obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
+
+ifdef CONFIGFS_TCM_FC_DEBUG
+EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
+endif
drivers/target/tcm_loop/Kbuild deleted +0 -11
Index: lio-core/drivers/target/tcm_loop/Kbuild
===================================================================
@@ -1,11 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
-
-tcm_loop-objs			:= tcm_loop_fabric.o \
-				   tcm_loop_fabric_scsi.o \
-				   tcm_loop_configfs.o \
-
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
-
-ifdef CONFIG_TCM_LOOP_CDB_DEBUG
-EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
-endif
drivers/target/tcm_loop/Makefile new file +11 -0
Index: lio-core/drivers/target/tcm_loop/Makefile
===================================================================
@@ -0,0 +1,11 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
+
+tcm_loop-y			:= tcm_loop_fabric.o \
+				   tcm_loop_fabric_scsi.o \
+				   tcm_loop_configfs.o \
+
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
+
+ifdef CONFIG_TCM_LOOP_CDB_DEBUG
+EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
+endif
drivers/target/lio-target/Kbuild deleted +0 -37
Index: lio-core/drivers/target/lio-target/Kbuild
===================================================================
@@ -1,37 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
-
-EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
-
-iscsi_target_mod-objs		:=	iscsi_auth_chap.o \
-					iscsi_debug_opcodes.o \
-					iscsi_parameters.o \
-					iscsi_seq_and_pdu_list.o \
-					iscsi_serial.o \
-					iscsi_thread_queue.o \
-					iscsi_target_datain_values.o \
-					iscsi_target_device.o \
-					iscsi_target_discovery.o \
-					iscsi_target_erl0.o \
-					iscsi_target_erl1.o \
-					iscsi_target_erl2.o \
-					iscsi_target_login.o \
-					iscsi_target_nego.o \
-					iscsi_target_nodeattrib.o \
-					iscsi_target_tmr.o \
-					iscsi_target_tpg.o \
-					iscsi_target_util.o \
-					iscsi_target.o \
-					iscsi_target_configfs.o \
-					iscsi_target_mib.o
-
-ifdef CONFIG_LIO_TARGET_DEBUG_ERL
-iscsi_target_mod-objs		+= iscsi_target_debugerl.o
-EXTRA_CFLAGS			+= -DDEBUG_ERL
-endif
-
-ifdef CONFIG_LIO_TARGET_DEBUG
-EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
-endif
-
-
-obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o
drivers/target/lio-target/Makefile new file +36 -0
Index: lio-core/drivers/target/lio-target/Makefile
===================================================================
@@ -0,0 +1,36 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
+
+EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
+
+iscsi_target_mod-y +=		iscsi_auth_chap.o \
+				iscsi_debug_opcodes.o \
+				iscsi_parameters.o \
+				iscsi_seq_and_pdu_list.o \
+				iscsi_serial.o \
+				iscsi_thread_queue.o \
+				iscsi_target_datain_values.o \
+				iscsi_target_device.o \
+				iscsi_target_discovery.o \
+				iscsi_target_erl0.o \
+				iscsi_target_erl1.o \
+				iscsi_target_erl2.o \
+				iscsi_target_login.o \
+				iscsi_target_nego.o \
+				iscsi_target_nodeattrib.o \
+				iscsi_target_tmr.o \
+				iscsi_target_tpg.o \
+				iscsi_target_util.o \
+				iscsi_target.o \
+				iscsi_target_configfs.o \
+				iscsi_target_mib.o
+
+ifdef CONFIG_LIO_TARGET_DEBUG_ERL
+iscsi_target_mod-y		+= iscsi_target_debugerl.o
+EXTRA_CFLAGS			+= -DDEBUG_ERL
+endif
+
+ifdef CONFIG_LIO_TARGET_DEBUG
+EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
+endif
+
+obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o
#1 lore raw
Quoted 2 lines · Christoph Hellwig

I was under the impression that $(srcdir)/Kbuild was the preferred modern name..?

--nab

Quoted 232 lines

Index: lio-core/drivers/target/Kbuild
===================================================================

drivers/target/Kbuild deleted +0 -31
@@ -1,31 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
-
-target_core_mod-y		:= target_core_configfs.o \
-				   target_core_device.o \
-				   target_core_fabric_configfs.o \
-				   target_core_fabric_lib.o \
-				   target_core_hba.o \
-				   target_core_pr.o \
-				   target_core_alua.o \
-				   target_core_scdb.o \
-				   target_core_tmr.o \
-				   target_core_tpg.o \
-				   target_core_transport.o \
-				   target_core_cdb.o \
-				   target_core_ua.o \
-				   target_core_rd.o \
-				   target_core_mib.o
-
-obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
-
-# Subsystem modules
-obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
-obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
-obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
-obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
-
-# Fabric modules
-obj-$(CONFIG_LIO_TARGET)	+= lio-target/
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
-
-obj-$(CONFIG_TCM_FC)		+= tcm_fc/

Index: lio-core/drivers/target/Makefile
===================================================================

drivers/target/Makefile new file +31 -0
@@ -0,0 +1,31 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
+
+target_core_mod-y		:= target_core_configfs.o \
+				   target_core_device.o \
+				   target_core_fabric_configfs.o \
+				   target_core_fabric_lib.o \
+				   target_core_hba.o \
+				   target_core_pr.o \
+				   target_core_alua.o \
+				   target_core_scdb.o \
+				   target_core_tmr.o \
+				   target_core_tpg.o \
+				   target_core_transport.o \
+				   target_core_cdb.o \
+				   target_core_ua.o \
+				   target_core_rd.o \
+				   target_core_mib.o
+
+obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
+
+# Subsystem modules
+obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
+obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
+obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
+obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
+
+# Fabric modules
+obj-$(CONFIG_LIO_TARGET)	+= lio-target/
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
+
+obj-$(CONFIG_TCM_FC)		+= tcm_fc/

Index: lio-core/drivers/target/tcm_fc/Kbuild
===================================================================

drivers/target/tcm_fc/Kbuild deleted +0 -16
@@ -1,16 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
-		-I$(srctree)/drivers/scsi/ \
-		-I$(srctree)/include/scsi/ \
-		-I$(srctree)/drivers/target/tcm_fc/
-
-tcm_fc-objs := \
-		tfc_cmd.o \
-		tfc_conf.o \
-		tfc_io.o \
-		tfc_sess.o
-
-obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
-
-ifdef CONFIGFS_TCM_FC_DEBUG
-EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
-endif

Index: lio-core/drivers/target/tcm_fc/Makefile
===================================================================

drivers/target/tcm_fc/Makefile new file +15 -0
@@ -0,0 +1,15 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
+		-I$(srctree)/drivers/scsi/ \
+		-I$(srctree)/include/scsi/ \
+		-I$(srctree)/drivers/target/tcm_fc/
+
+tcm_fc-y +=	tfc_cmd.o \
+		tfc_conf.o \
+		tfc_io.o \
+		tfc_sess.o
+
+obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
+
+ifdef CONFIGFS_TCM_FC_DEBUG
+EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
+endif

Index: lio-core/drivers/target/tcm_loop/Kbuild
===================================================================

drivers/target/tcm_loop/Kbuild deleted +0 -11
@@ -1,11 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
-
-tcm_loop-objs			:= tcm_loop_fabric.o \
-				   tcm_loop_fabric_scsi.o \
-				   tcm_loop_configfs.o \
-
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
-
-ifdef CONFIG_TCM_LOOP_CDB_DEBUG
-EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
-endif

Index: lio-core/drivers/target/tcm_loop/Makefile
===================================================================

drivers/target/tcm_loop/Makefile new file +11 -0
@@ -0,0 +1,11 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
+
+tcm_loop-y			:= tcm_loop_fabric.o \
+				   tcm_loop_fabric_scsi.o \
+				   tcm_loop_configfs.o \
+
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
+
+ifdef CONFIG_TCM_LOOP_CDB_DEBUG
+EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
+endif

Index: lio-core/drivers/target/lio-target/Kbuild
===================================================================

drivers/target/lio-target/Kbuild deleted +0 -37
@@ -1,37 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
-
-EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
-
-iscsi_target_mod-objs		:=	iscsi_auth_chap.o \
-					iscsi_debug_opcodes.o \
-					iscsi_parameters.o \
-					iscsi_seq_and_pdu_list.o \
-					iscsi_serial.o \
-					iscsi_thread_queue.o \
-					iscsi_target_datain_values.o \
-					iscsi_target_device.o \
-					iscsi_target_discovery.o \
-					iscsi_target_erl0.o \
-					iscsi_target_erl1.o \
-					iscsi_target_erl2.o \
-					iscsi_target_login.o \
-					iscsi_target_nego.o \
-					iscsi_target_nodeattrib.o \
-					iscsi_target_tmr.o \
-					iscsi_target_tpg.o \
-					iscsi_target_util.o \
-					iscsi_target.o \
-					iscsi_target_configfs.o \
-					iscsi_target_mib.o
-
-ifdef CONFIG_LIO_TARGET_DEBUG_ERL
-iscsi_target_mod-objs		+= iscsi_target_debugerl.o
-EXTRA_CFLAGS			+= -DDEBUG_ERL
-endif
-
-ifdef CONFIG_LIO_TARGET_DEBUG
-EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
-endif
-
-
-obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o

Index: lio-core/drivers/target/lio-target/Makefile
===================================================================

drivers/target/lio-target/Makefile new file +36 -1
@@ -0,0 +1,36 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
+
+EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
+
+iscsi_target_mod-y +=		iscsi_auth_chap.o \
+				iscsi_debug_opcodes.o \
+				iscsi_parameters.o \
+				iscsi_seq_and_pdu_list.o \
+				iscsi_serial.o \
+				iscsi_thread_queue.o \
+				iscsi_target_datain_values.o \
+				iscsi_target_device.o \
+				iscsi_target_discovery.o \
+				iscsi_target_erl0.o \
+				iscsi_target_erl1.o \
+				iscsi_target_erl2.o \
+				iscsi_target_login.o \
+				iscsi_target_nego.o \
+				iscsi_target_nodeattrib.o \
+				iscsi_target_tmr.o \
+				iscsi_target_tpg.o \
+				iscsi_target_util.o \
+				iscsi_target.o \
+				iscsi_target_configfs.o \
+				iscsi_target_mib.o
+
+ifdef CONFIG_LIO_TARGET_DEBUG_ERL
+iscsi_target_mod-y		+= iscsi_target_debugerl.o
+EXTRA_CFLAGS			+= -DDEBUG_ERL
+endif
+
+ifdef CONFIG_LIO_TARGET_DEBUG
+EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
+endif
+
+obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o
--

To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#2 lore raw
Quoted 7 lines · Nicholas A. Bellinger
Quoted 2 lines · Christoph Hellwig

I was under the impression that $(srcdir)/Kbuild was the preferred modern name..?

This is in fact mainline convention, commited as 9093542.

Thanks!

--nab

Quoted 239 lines

--nab

Quoted 229 lines

Index: lio-core/drivers/target/Kbuild
===================================================================

drivers/target/Kbuild deleted +0 -31
@@ -1,31 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
-
-target_core_mod-y		:= target_core_configfs.o \
-				   target_core_device.o \
-				   target_core_fabric_configfs.o \
-				   target_core_fabric_lib.o \
-				   target_core_hba.o \
-				   target_core_pr.o \
-				   target_core_alua.o \
-				   target_core_scdb.o \
-				   target_core_tmr.o \
-				   target_core_tpg.o \
-				   target_core_transport.o \
-				   target_core_cdb.o \
-				   target_core_ua.o \
-				   target_core_rd.o \
-				   target_core_mib.o
-
-obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
-
-# Subsystem modules
-obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
-obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
-obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
-obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
-
-# Fabric modules
-obj-$(CONFIG_LIO_TARGET)	+= lio-target/
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
-
-obj-$(CONFIG_TCM_FC)		+= tcm_fc/

Index: lio-core/drivers/target/Makefile
===================================================================

drivers/target/Makefile new file +31 -0
@@ -0,0 +1,31 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/
+
+target_core_mod-y		:= target_core_configfs.o \
+				   target_core_device.o \
+				   target_core_fabric_configfs.o \
+				   target_core_fabric_lib.o \
+				   target_core_hba.o \
+				   target_core_pr.o \
+				   target_core_alua.o \
+				   target_core_scdb.o \
+				   target_core_tmr.o \
+				   target_core_tpg.o \
+				   target_core_transport.o \
+				   target_core_cdb.o \
+				   target_core_ua.o \
+				   target_core_rd.o \
+				   target_core_mib.o
+
+obj-$(CONFIG_TARGET_CORE)	+= target_core_mod.o
+
+# Subsystem modules
+obj-$(CONFIG_TCM_IBLOCK)	+= target_core_iblock.o
+obj-$(CONFIG_TCM_FILEIO)	+= target_core_file.o
+obj-$(CONFIG_TCM_PSCSI)		+= target_core_pscsi.o
+obj-$(CONFIG_TCM_STGT)		+= target_core_stgt.o
+
+# Fabric modules
+obj-$(CONFIG_LIO_TARGET)	+= lio-target/
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop/
+
+obj-$(CONFIG_TCM_FC)		+= tcm_fc/

Index: lio-core/drivers/target/tcm_fc/Kbuild
===================================================================

drivers/target/tcm_fc/Kbuild deleted +0 -16
@@ -1,16 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
-		-I$(srctree)/drivers/scsi/ \
-		-I$(srctree)/include/scsi/ \
-		-I$(srctree)/drivers/target/tcm_fc/
-
-tcm_fc-objs := \
-		tfc_cmd.o \
-		tfc_conf.o \
-		tfc_io.o \
-		tfc_sess.o
-
-obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
-
-ifdef CONFIGFS_TCM_FC_DEBUG
-EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
-endif

Index: lio-core/drivers/target/tcm_fc/Makefile
===================================================================

drivers/target/tcm_fc/Makefile new file +15 -0
@@ -0,0 +1,15 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ \
+		-I$(srctree)/drivers/scsi/ \
+		-I$(srctree)/include/scsi/ \
+		-I$(srctree)/drivers/target/tcm_fc/
+
+tcm_fc-y +=	tfc_cmd.o \
+		tfc_conf.o \
+		tfc_io.o \
+		tfc_sess.o
+
+obj-$(CONFIG_TCM_FC)	+= tcm_fc.o
+
+ifdef CONFIGFS_TCM_FC_DEBUG
+EXTRA_CFLAGS	+= -DTCM_FC_DEBUG
+endif

Index: lio-core/drivers/target/tcm_loop/Kbuild
===================================================================

drivers/target/tcm_loop/Kbuild deleted +0 -11
@@ -1,11 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
-
-tcm_loop-objs			:= tcm_loop_fabric.o \
-				   tcm_loop_fabric_scsi.o \
-				   tcm_loop_configfs.o \
-
-obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
-
-ifdef CONFIG_TCM_LOOP_CDB_DEBUG
-EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
-endif

Index: lio-core/drivers/target/tcm_loop/Makefile
===================================================================

drivers/target/tcm_loop/Makefile new file +11 -0
@@ -0,0 +1,11 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/drivers/scsi/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/tcm_loop/
+
+tcm_loop-y			:= tcm_loop_fabric.o \
+				   tcm_loop_fabric_scsi.o \
+				   tcm_loop_configfs.o \
+
+obj-$(CONFIG_TCM_LOOP_FABRIC)	+= tcm_loop.o
+
+ifdef CONFIG_TCM_LOOP_CDB_DEBUG
+EXTRA_CFLAGS			+= -DTCM_LOOP_CDB_DEBUG
+endif

Index: lio-core/drivers/target/lio-target/Kbuild
===================================================================

drivers/target/lio-target/Kbuild deleted +0 -37
@@ -1,37 +0,0 @@
-EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
-
-EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
-
-iscsi_target_mod-objs		:=	iscsi_auth_chap.o \
-					iscsi_debug_opcodes.o \
-					iscsi_parameters.o \
-					iscsi_seq_and_pdu_list.o \
-					iscsi_serial.o \
-					iscsi_thread_queue.o \
-					iscsi_target_datain_values.o \
-					iscsi_target_device.o \
-					iscsi_target_discovery.o \
-					iscsi_target_erl0.o \
-					iscsi_target_erl1.o \
-					iscsi_target_erl2.o \
-					iscsi_target_login.o \
-					iscsi_target_nego.o \
-					iscsi_target_nodeattrib.o \
-					iscsi_target_tmr.o \
-					iscsi_target_tpg.o \
-					iscsi_target_util.o \
-					iscsi_target.o \
-					iscsi_target_configfs.o \
-					iscsi_target_mib.o
-
-ifdef CONFIG_LIO_TARGET_DEBUG_ERL
-iscsi_target_mod-objs		+= iscsi_target_debugerl.o
-EXTRA_CFLAGS			+= -DDEBUG_ERL
-endif
-
-ifdef CONFIG_LIO_TARGET_DEBUG
-EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
-endif
-
-
-obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o

Index: lio-core/drivers/target/lio-target/Makefile
===================================================================

drivers/target/lio-target/Makefile new file +36 -1
@@ -0,0 +1,36 @@
+EXTRA_CFLAGS += -I$(srctree)/drivers/target/ -I$(srctree)/include/scsi/ -I$(srctree)/drivers/target/lio-target
+
+EXTRA_CFLAGS+=-D_TARGET -DPYX_ISCSI_VENDOR='"Linux-iSCSI.org"'
+
+iscsi_target_mod-y +=		iscsi_auth_chap.o \
+				iscsi_debug_opcodes.o \
+				iscsi_parameters.o \
+				iscsi_seq_and_pdu_list.o \
+				iscsi_serial.o \
+				iscsi_thread_queue.o \
+				iscsi_target_datain_values.o \
+				iscsi_target_device.o \
+				iscsi_target_discovery.o \
+				iscsi_target_erl0.o \
+				iscsi_target_erl1.o \
+				iscsi_target_erl2.o \
+				iscsi_target_login.o \
+				iscsi_target_nego.o \
+				iscsi_target_nodeattrib.o \
+				iscsi_target_tmr.o \
+				iscsi_target_tpg.o \
+				iscsi_target_util.o \
+				iscsi_target.o \
+				iscsi_target_configfs.o \
+				iscsi_target_mib.o
+
+ifdef CONFIG_LIO_TARGET_DEBUG_ERL
+iscsi_target_mod-y		+= iscsi_target_debugerl.o
+EXTRA_CFLAGS			+= -DDEBUG_ERL
+endif
+
+ifdef CONFIG_LIO_TARGET_DEBUG
+EXTRA_CFLAGS			+= -DCONFIG_ISCSI_DEBUG=1
+endif
+
+obj-$(CONFIG_LIO_TARGET)	+= iscsi_target_mod.o
--
Quoted 3 lines

To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#3 lore raw
Quoted 9 lines · Nicholas A. Bellinger
Quoted 7 lines · Nicholas A. Bellinger
Quoted 2 lines · Christoph Hellwig

I was under the impression that $(srcdir)/Kbuild was the preferred modern name..?

Quoted 5 lines

This is in fact mainline convention, commited as 9093542.

Thanks!

--nab

[Rant below please ignore]

Quoted 1 line

From Documentation/kbuild/makefiles.txt

=== 3 The kbuild files

Most Makefiles within the kernel are kbuild Makefiles that use the kbuild infrastructure. This chapter introduces the syntax used in the kbuild makefiles.
The preferred name for the kbuild files are 'Makefile' but 'Kbuild' can be used and if both a 'Makefile' and a 'Kbuild' file exists, then the 'Kbuild' file will be used.

This has changed since the time I started. Back then that text was:
The preferred name for the kbuild files are Kbuild

If I go to a random subdirectory in the Kernel and do:
[drivers/foo]$ make
With a Kbuild file it outputs:
make: *** No targets specified and no makefile found. Stop.

With a Makefile it outputs:
make: *** No targets. Stop.

Sigh! For me a "Makefile" is a make's makefile. Kbuild files are not makefiles and should not be named as one.

But that's a lost cause
Boaz