diff options
Diffstat (limited to 'board/xilinx/zynq/Makefile')
-rw-r--r-- | board/xilinx/zynq/Makefile | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/board/xilinx/zynq/Makefile b/board/xilinx/zynq/Makefile index 5a76a26720..03ad5f0532 100644 --- a/board/xilinx/zynq/Makefile +++ b/board/xilinx/zynq/Makefile @@ -5,10 +5,18 @@ obj-y := board.o -hw-platform-y :=$(shell echo $(CONFIG_DEFAULT_DEVICE_TREE)) +ifneq ($(CONFIG_XILINX_PS_INIT_FILE),"") +PS_INIT_FILE := $(shell cd $(srctree); readlink -f $(CONFIG_XILINX_PS_INIT_FILE)) +init-objs := ps_init_gpl.o +spl/board/xilinx/zynq/ps_init_gpl.o board/xilinx/zynq/ps_init_gpl.o: $(PS_INIT_FILE) + $(CC) $(c_flags) -I $(srctree)/$(src) -c -o $@ $^ +endif +ifeq ($(init-objs),) +hw-platform-y :=$(shell echo $(CONFIG_DEFAULT_DEVICE_TREE)) init-objs := $(if $(wildcard $(srctree)/$(src)/$(hw-platform-y)/ps7_init_gpl.c),\ $(hw-platform-y)/ps7_init_gpl.o) +endif ifeq ($(init-objs),) ifneq ($(wildcard $(srctree)/$(src)/ps7_init_gpl.c),) |