88 lines · plain
1# SPDX-License-Identifier: GPL-2.02#3# Makefile for the Linux aic7xxx SCSI driver.4#5# $Id: //depot/linux-aic79xx-2.5.0/drivers/scsi/aic7xxx/Makefile#8 $6#7 8# Let kbuild descend into aicasm when cleaning9subdir- += aicasm10 11obj-$(CONFIG_SCSI_AIC7XXX) += aic7xxx.o12obj-$(CONFIG_SCSI_AIC79XX) += aic79xx.o13 14# Core Fast -> U160 files15aic7xxx-y += aic7xxx_core.o \16 aic7xxx_93cx6.o17aic7xxx-$(CONFIG_EISA) += aic7770.o18aic7xxx-$(CONFIG_PCI) += aic7xxx_pci.o19aic7xxx-$(CONFIG_AIC7XXX_REG_PRETTY_PRINT) += aic7xxx_reg_print.o20 21# Platform Specific Fast -> U160 Files22aic7xxx-y += aic7xxx_osm.o \23 aic7xxx_proc.o24aic7xxx-$(CONFIG_EISA) += aic7770_osm.o25aic7xxx-$(CONFIG_PCI) += aic7xxx_osm_pci.o26 27# Core U320 files28aic79xx-y += aic79xx_core.o \29 aic79xx_pci.o30aic79xx-$(CONFIG_AIC79XX_REG_PRETTY_PRINT) += aic79xx_reg_print.o31 32# Platform Specific U320 Files33aic79xx-y += aic79xx_osm.o \34 aic79xx_proc.o \35 aic79xx_osm_pci.o36 37ifdef WARNINGS_BECOME_ERRORS38ccflags-y += -Werror39endif40 41# Files generated that shall be removed upon make clean42clean-files := aic7xxx_seq.h aic7xxx_reg.h aic7xxx_reg_print.c43clean-files += aic79xx_seq.h aic79xx_reg.h aic79xx_reg_print.c44 45# Dependencies for generated files need to be listed explicitly46 47$(addprefix $(obj)/,$(aic7xxx-y)): $(obj)/aic7xxx_seq.h $(obj)/aic7xxx_reg.h48$(addprefix $(obj)/,$(aic79xx-y)): $(obj)/aic79xx_seq.h $(obj)/aic79xx_reg.h49 50aic7xxx-gen-$(CONFIG_AIC7XXX_BUILD_FIRMWARE) := $(obj)/aic7xxx_reg.h51aic7xxx-gen-$(CONFIG_AIC7XXX_REG_PRETTY_PRINT) += $(obj)/aic7xxx_reg_print.c52 53aicasm-7xxx-opts-$(CONFIG_AIC7XXX_REG_PRETTY_PRINT) := \54 -p $(obj)/aic7xxx_reg_print.c -i aic7xxx_osm.h55 56ifeq ($(CONFIG_AIC7XXX_BUILD_FIRMWARE),y)57$(obj)/aic7xxx_seq.h: $(src)/aic7xxx.seq $(src)/aic7xxx.reg $(obj)/aicasm/aicasm58 $(obj)/aicasm/aicasm -I $(src) -r $(obj)/aic7xxx_reg.h \59 $(aicasm-7xxx-opts-y) -o $(obj)/aic7xxx_seq.h \60 $(src)/aic7xxx.seq61 62$(aic7xxx-gen-y): $(objtree)/$(obj)/aic7xxx_seq.h63 @true64else65$(obj)/aic7xxx_reg_print.c: $(src)/aic7xxx_reg_print.c_shipped66endif67 68aic79xx-gen-$(CONFIG_AIC79XX_BUILD_FIRMWARE) := $(obj)/aic79xx_reg.h69aic79xx-gen-$(CONFIG_AIC79XX_REG_PRETTY_PRINT) += $(obj)/aic79xx_reg_print.c70 71aicasm-79xx-opts-$(CONFIG_AIC79XX_REG_PRETTY_PRINT) := \72 -p $(obj)/aic79xx_reg_print.c -i aic79xx_osm.h73 74ifeq ($(CONFIG_AIC79XX_BUILD_FIRMWARE),y)75$(obj)/aic79xx_seq.h: $(src)/aic79xx.seq $(src)/aic79xx.reg $(obj)/aicasm/aicasm76 $(obj)/aicasm/aicasm -I $(src) -r $(obj)/aic79xx_reg.h \77 $(aicasm-79xx-opts-y) -o $(obj)/aic79xx_seq.h \78 $(src)/aic79xx.seq79 80$(aic79xx-gen-y): $(objtree)/$(obj)/aic79xx_seq.h81 @true82else83$(obj)/aic79xx_reg_print.c: $(src)/aic79xx_reg_print.c_shipped84endif85 86$(obj)/aicasm/aicasm: $(src)/aicasm/*.[chyl]87 $(MAKE) -C $(src)/aicasm OUTDIR=$(shell pwd)/$(obj)/aicasm/88