Skip to content

Commit

Permalink
build,Makefile: add default Vivado SDK path to build
Browse files Browse the repository at this point in the history
And parametrize the Vivado release version.

Usually, the usecase is to use the default /opt/Xilinx path.
This change also passes the Vivado SDK path (for the compiler) to buildroot
so that it builds.

Signed-off-by: Alexandru Ardelean <[email protected]>
  • Loading branch information
commodo committed May 23, 2019
1 parent db91dc3 commit 74d917f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
#PATH=$PATH:/opt/Xilinx/SDK/2015.4/gnu/arm/lin/bin

CROSS_COMPILE ?= arm-xilinx-linux-gnueabi-
VIVADO_VERSION ?= 2018.2

VIVADO_TOOLCHAIN_PATH ?= /opt/Xilinx/SDK/$(VIVADO_VERSION)/gnu/aarch32/lin/gcc-arm-linux-gnueabi

CROSS_COMPILE ?= $(VIVADO_TOOLCHAIN_PATH)/bin/arm-linux-gnueabihf-

NCORES = $(shell grep -c ^processor /proc/cpuinfo)
VIVADO_SETTINGS ?= /opt/Xilinx/Vivado/2018.2/settings64.sh
VIVADO_SETTINGS ?= /opt/Xilinx/Vivado/$(VIVADO_VERSION)/settings64.sh
VSUBDIRS = hdl buildroot linux u-boot-xlnx

VERSION=$(shell git describe --abbrev=4 --dirty --always --tags)
Expand Down Expand Up @@ -94,7 +98,7 @@ buildroot/output/images/rootfs.cpio.gz:
make -C buildroot legal-info
scripts/legal_info_html.sh "$(COMPLETE_NAME)" "$(CURDIR)/buildroot/board/$(TARGET)/VERSIONS"
cp build/LICENSE.html buildroot/board/$(TARGET)/msd/LICENSE.html
make -C buildroot TOOLCHAIN_EXTERNAL_INSTALL_DIR= ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) BUSYBOX_CONFIG_FILE=$(CURDIR)/buildroot/board/$(TARGET)/busybox-1.25.0.config all
make -C buildroot TOOLCHAIN_EXTERNAL_INSTALL_DIR=$(VIVADO_TOOLCHAIN_PATH) ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) BUSYBOX_CONFIG_FILE=$(CURDIR)/buildroot/board/$(TARGET)/busybox-1.25.0.config all

.PHONY: buildroot/output/images/rootfs.cpio.gz

Expand Down

0 comments on commit 74d917f

Please sign in to comment.