Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 1 | # |
| 2 | # (C) Copyright 2008 |
| 3 | # Wolfgang Denk, DENX Software Engineering, wd@denx.de. |
| 4 | # |
Wolfgang Denk | 1a45966 | 2013-07-08 09:37:19 +0200 | [diff] [blame] | 5 | # SPDX-License-Identifier: GPL-2.0+ |
Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 6 | # |
| 7 | |
| 8 | include $(TOPDIR)/config.mk |
| 9 | |
Sebastien Carlier | 6d8962e | 2010-11-05 15:48:07 +0100 | [diff] [blame] | 10 | LIB := $(obj)libfpga.o |
Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 11 | |
| 12 | ifdef CONFIG_FPGA |
| 13 | COBJS-y += fpga.o |
| 14 | COBJS-$(CONFIG_FPGA_SPARTAN2) += spartan2.o |
| 15 | COBJS-$(CONFIG_FPGA_SPARTAN3) += spartan3.o |
| 16 | COBJS-$(CONFIG_FPGA_VIRTEX2) += virtex2.o |
Michal Simek | d5dae85 | 2013-04-22 15:43:02 +0200 | [diff] [blame] | 17 | COBJS-$(CONFIG_FPGA_ZYNQPL) += zynqpl.o |
Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 18 | COBJS-$(CONFIG_FPGA_XILINX) += xilinx.o |
Stefano Babic | 3b8ac46 | 2010-06-29 11:47:48 +0200 | [diff] [blame] | 19 | COBJS-$(CONFIG_FPGA_LATTICE) += ivm_core.o lattice.o |
Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 20 | ifdef CONFIG_FPGA_ALTERA |
| 21 | COBJS-y += altera.o |
| 22 | COBJS-$(CONFIG_FPGA_ACEX1K) += ACEX1K.o |
| 23 | COBJS-$(CONFIG_FPGA_CYCLON2) += cyclon2.o |
| 24 | COBJS-$(CONFIG_FPGA_STRATIX_II) += stratixII.o |
| 25 | endif |
| 26 | endif |
| 27 | |
| 28 | COBJS := $(COBJS-y) |
| 29 | SRCS := $(COBJS:.o=.c) |
| 30 | OBJS := $(addprefix $(obj),$(COBJS)) |
| 31 | |
| 32 | all: $(LIB) |
| 33 | |
| 34 | $(LIB): $(obj).depend $(OBJS) |
Sebastien Carlier | 6d8962e | 2010-11-05 15:48:07 +0100 | [diff] [blame] | 35 | $(call cmd_link_o_target, $(OBJS)) |
Jean-Christophe PLAGNIOL-VILLARD | c8aa7df | 2008-10-31 12:26:55 +0100 | [diff] [blame] | 36 | |
| 37 | ######################################################################### |
| 38 | |
| 39 | # defines $(obj).depend target |
| 40 | include $(SRCTREE)/rules.mk |
| 41 | |
| 42 | sinclude $(obj).depend |
| 43 | |
| 44 | ######################################################################### |