[meta-freescale] [PATCH 29/60] rcw: swap qspi binary in do_install_append

ting.liu at nxp.com ting.liu at nxp.com
Fri Jan 8 22:43:22 PST 2016


From: Ting Liu <ting.liu at nxp.com>

Signed-off-by: Ting Liu <ting.liu at nxp.com>
Signed-off-by: Zhenhua Luo <zhenhua.luo at nxp.com>
---
 ...ake-BOARDS-DESTDIR-overidable-in-Makefile.patch | 57 ----------------------
 recipes-bsp/rcw/rcw_git.bb                         | 10 ++--
 2 files changed, 7 insertions(+), 60 deletions(-)
 delete mode 100644 recipes-bsp/rcw/rcw/rcw-make-BOARDS-DESTDIR-overidable-in-Makefile.patch

diff --git a/recipes-bsp/rcw/rcw/rcw-make-BOARDS-DESTDIR-overidable-in-Makefile.patch b/recipes-bsp/rcw/rcw/rcw-make-BOARDS-DESTDIR-overidable-in-Makefile.patch
deleted file mode 100644
index 49d99fc..0000000
--- a/recipes-bsp/rcw/rcw/rcw-make-BOARDS-DESTDIR-overidable-in-Makefile.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-From f2e796c903b2a3f81dbd38da3dc087cb7539d307 Mon Sep 17 00:00:00 2001
-From: Zhenhua Luo <zhenhua.luo at freescale.com>
-Date: Wed, 3 Sep 2014 03:03:42 -0500
-Subject: [PATCH] Makefile: make BOARDS/DESTDIR overidable and add endian
- switch
-
-1. For one specific board, no need to build the rcw for all supported
-   targets, make BOARDS and DESTDIR overridable to achieve this.
-2. Add the endian swap for qspiboot rcw
-
-Upstream-Status: Pending
-
-Signed-off-by: Zhenhua Luo <zhenhua.luo at freescale.com>
----
- Makefile     |    4 ++--
- Makefile.inc |    9 +++++++--
- 2 files changed, 9 insertions(+), 4 deletions(-)
-
-diff --git a/Makefile b/Makefile
-index 6ec1697..0f94293 100644
---- a/Makefile
-+++ b/Makefile
-@@ -1,5 +1,5 @@
--DESTDIR = .
--BOARDS = b4420qds b4860qds \
-+DESTDIR ?= .
-+BOARDS ?= b4420qds b4860qds \
- 	 ls1021aqds ls1021atwr \
- 	 p2041rdb p3041ds p4080ds p5020ds p5040ds \
- 	 t1024qds t1023rdb t1024rdb t1040rdb t1042rdb t1042rdb_pi t1040qds \
-diff --git a/Makefile.inc b/Makefile.inc
-index 4cadb2e..6e8b78f 100644
---- a/Makefile.inc
-+++ b/Makefile.inc
-@@ -1,4 +1,4 @@
--DESTDIR = .
-+DESTDIR ?= .
- INSTALL = install
- PYTHON ?= python2
- RCW = $(PYTHON) ../rcw.py
-@@ -18,7 +18,12 @@ all: $(targets)
- install: $(targets)
- 	$(INSTALL) -d $(DESTDIR)
- 	@for file in $^; do \
--		$(INSTALL) -m 644 -D $$file $(DESTDIR)/$$file; \
-+		case $$file in \
-+			*qspiboot*) file_swap="`echo $$file | sed -e 's/qspiboot/qspiboot_swap/'`"; \
-+						tclsh byte_swap.tcl $$file $$file_swap 8 ; \
-+						$(INSTALL) -m 644 -D $$file_swap $(DESTDIR)/$$file_swap ;; \
-+			*) $(INSTALL) -m 644 -D $$file $(DESTDIR)/$$file; \
-+        esac \
- 	done
- 	$(INSTALL) -m 644 -D README $(DESTDIR)
- 
--- 
-1.7.9.7
-
diff --git a/recipes-bsp/rcw/rcw_git.bb b/recipes-bsp/rcw/rcw_git.bb
index 016ef82..0647c2c 100644
--- a/recipes-bsp/rcw/rcw_git.bb
+++ b/recipes-bsp/rcw/rcw_git.bb
@@ -9,9 +9,7 @@ inherit deploy
 
 SRCBRANCH = "master"
 SRCREV = "426f7a6535d93dac76f5125035e0938a85e778d2"
-SRC_URI = "git://git.freescale.com/ppc/sdk/rcw.git;branch=${SRCBRANCH} \
-    file://rcw-make-BOARDS-DESTDIR-overidable-in-Makefile.patch \
-"
+SRC_URI = "git://git.freescale.com/ppc/sdk/rcw.git;branch=${SRCBRANCH}"
 
 S = "${WORKDIR}/git"
 
@@ -20,6 +18,12 @@ EXTRA_OEMAKE = "BOARDS=${@d.getVar('MACHINE', True).replace('-64b','')} DESTDIR=
 do_install () {
     oe_runmake install
 }
+do_install_append_ls102xa () {
+    for f in `find ${D}/boot/rcw/ -name "*qspiboot*"`;do
+        f_swap=`echo $f |sed -e 's/qspiboot/qspiboot_swap/'`
+        tclsh ${STAGING_BINDIR_NATIVE}/byte_swap.tcl $f $f_swap 8
+    done
+}
 
 do_deploy () {
     install -d ${DEPLOYDIR}/rcw
-- 
1.9.2



More information about the meta-freescale mailing list