[meta-xilinx] [PATCH 3/4] kc705-bitstream_2016.3.bb: Update to use the PetaLinux BSP bitstream
Nathan Rossi
nathan at nathanrossi.com
Mon Aug 21 05:43:51 PDT 2017
This recipe was never updated when the rest of the configuration was
updated to be built for the PetaLinux v2016.3 BSP. This was due to
download access issues which were not resolved.
Instead of pointing at the old bitstream point at the download path on
Xilinx's servers which is restricted by account access, and using the
xilinx-fetch-restricted class to handle erroring properly and providing
user instructions for fetching the BSP file.
This recipe now also manually extracts the 'download.bit' from the BSP
and populates it into a package as well as the deploy directory.
The recipe is now marked with the 'xilinx' license flag due to its use
of content that has licensing/legal requirements.
Signed-off-by: Nathan Rossi <nathan at nathanrossi.com>
---
.../reference-design/kc705-bitstream_2016.1.bb | 44 --------------------
.../reference-design/kc705-bitstream_2016.3.bb | 48 ++++++++++++++++++++++
2 files changed, 48 insertions(+), 44 deletions(-)
delete mode 100644 recipes-bsp/reference-design/kc705-bitstream_2016.1.bb
create mode 100644 recipes-bsp/reference-design/kc705-bitstream_2016.3.bb
diff --git a/recipes-bsp/reference-design/kc705-bitstream_2016.1.bb b/recipes-bsp/reference-design/kc705-bitstream_2016.1.bb
deleted file mode 100644
index 56bb54dc22..0000000000
--- a/recipes-bsp/reference-design/kc705-bitstream_2016.1.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-SUMMARY = "KC705 design file for bitstream"
-DESCRIPTION = "Contains the pre-built bitstream and hardware project."
-HOMEPAGE = "http://www.xilinx.com"
-SECTION = "bsp"
-
-LICENSE = "Proprietary"
-LIC_FILES_CHKSUM = "file://implementation/system.mmi;md5=1992d9c9006c524f4178949897749f21"
-
-COMPATIBLE_MACHINE = "kc705-microblazeel"
-
-inherit deploy
-
-SRC_URI = "http://www.xilinx.com/support/documentation/boards_and_kits/k7_emb/2016_1/xilinx-kc705-axi-full-2016.1.tar"
-SRC_URI[md5sum] = "59ade57ab0a15c8700c129f040fe4c75"
-SRC_URI[sha256sum] = "8e3e5c5d30e6d02eaa58cb6e9255b8d6456857185744904fb931e3d8e44ba62e"
-
-S = "${WORKDIR}/Xilinx-KC705-AXI-full-2016.1"
-
-PROVIDES = "virtual/bitstream"
-
-FILES_${PN} += "/boot/download.bit"
-
-INHIBIT_DEFAULT_DEPS = "1"
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-
-# Copy the bitstream into the boot directory
-do_install() {
- install -d ${D}/boot
- install ${S}/implementation/system.bit ${D}/boot/download.bit
-}
-
-do_compile() {
- :
-}
-
-do_deploy () {
- install -d ${DEPLOYDIR}
- if [ -e ${D}/boot/download.bit ]; then
- install ${D}/boot/download.bit ${DEPLOYDIR}/download.bit
- fi
-}
-
-addtask deploy before do_build after do_install
-
diff --git a/recipes-bsp/reference-design/kc705-bitstream_2016.3.bb b/recipes-bsp/reference-design/kc705-bitstream_2016.3.bb
new file mode 100644
index 0000000000..195d60cc8e
--- /dev/null
+++ b/recipes-bsp/reference-design/kc705-bitstream_2016.3.bb
@@ -0,0 +1,48 @@
+SUMMARY = "KC705 Pre-built Bitstream"
+DESCRIPTION = "A Pre-built bitstream for the KC705, which is capable of booting a Linux system."
+HOMEPAGE = "http://www.xilinx.com"
+SECTION = "bsp"
+
+# The BSP package does not include any license information.
+LICENSE = "Proprietary"
+LICENSE_FLAGS = "xilinx"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/Proprietary;md5=0557f9d92cf58f2ccdd50f62f8ac0b28"
+
+COMPATIBLE_MACHINE = "kc705-microblazeel"
+
+inherit deploy
+inherit xilinx-fetch-restricted
+
+BSP_NAME = "Xilinx-KC705"
+BSP_FILE = "${BSP_NAME}-v${PV}-final.bsp"
+SRC_URI = "https://www.xilinx.com/member/forms/download/xef.html?filename=${BSP_FILE};downloadfilename=${BSP_FILE}"
+SRC_URI[md5sum] = "6a2276088759f10b9504eae2f13fe8a2"
+SRC_URI[sha256sum] = "dbb722cc051a2d8517238948ddec1c029511ff391a8f9fc0b0f1e58e52ade399"
+
+PROVIDES = "virtual/bitstream"
+
+FILES_${PN} += "/boot/download.bit"
+
+INHIBIT_DEFAULT_DEPS = "1"
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+# deps needed to extract content from the .bsp file
+DEPENDS += "tar-native gzip-native"
+
+do_compile() {
+ # Extract the bitstream into workdir
+ tar -xf ${WORKDIR}/${BSP_FILE} ${BSP_NAME}-AXI-full-${PV}/pre-built/linux/images/download.bit -C ${S}
+ # move the bit file to ${S}/ as it is in a subdir in the tar file
+ for i in $(find -type f -name download.bit); do mv $i ${S}; done
+}
+
+do_install() {
+ install -D ${S}/download.bit ${D}/boot/download.bit
+}
+
+do_deploy () {
+ install -D ${S}/download.bit ${DEPLOYDIR}/download.bit
+}
+
+addtask deploy before do_build after do_install
+
--
2.14.1
More information about the meta-xilinx
mailing list