]> code.ossystems Code Review - meta-freescale.git/commitdiff
utp-com: Add recipe 6/head
authorVincent Prince <vincent.prince.fr@gmail.com>
Tue, 22 May 2018 11:45:08 +0000 (13:45 +0200)
committerVincent Prince <vincent.prince.fr@gmail.com>
Tue, 22 May 2018 12:43:52 +0000 (14:43 +0200)
This utility is used to send commands to the device
using the NXP's UTP protocol.

Signed-off-by: Vincent Prince <vincent.prince.fr@gmail.com>
recipes-devtools/utp-com/utp-com/0001-Fix-Makefile-for-crosscompilation.patch [new file with mode: 0644]
recipes-devtools/utp-com/utp-com_git.bb [new file with mode: 0644]
recipes-support/sg3-utils/sg3-utils_%.bbappend [new file with mode: 0644]

diff --git a/recipes-devtools/utp-com/utp-com/0001-Fix-Makefile-for-crosscompilation.patch b/recipes-devtools/utp-com/utp-com/0001-Fix-Makefile-for-crosscompilation.patch
new file mode 100644 (file)
index 0000000..5db050c
--- /dev/null
@@ -0,0 +1,19 @@
+--- a/makefile
++++ b/makefile
+@@ -1,10 +1,12 @@
+-CC=gcc
+-CFLAGS=-I. -Wall -O2
+-DEPS=
++CC ?= gcc
++CFLAGS ?= -I. -Wall -O2
++LDFLAGS ?=
++DEPS ?=
++
+ OBJ=utp_com.o
+ %.o: %.c $(DEPS)
+       $(CC) -c -o $@ $< $(CFLAGS)
+ utp_com: $(OBJ)
+-      gcc -o $@ $^ $(CFLAGS)
++      $(CC) -o $@ $^ $(LDFLAGS)
diff --git a/recipes-devtools/utp-com/utp-com_git.bb b/recipes-devtools/utp-com/utp-com_git.bb
new file mode 100644 (file)
index 0000000..163f585
--- /dev/null
@@ -0,0 +1,28 @@
+DESCRIPTION = "Tool used to send commands to hardware via NXP's UTP protocol"
+LICENSE = "GPLv2"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=8264535c0c4e9c6c335635c4026a8022"
+
+DEPENDS = "sg3-utils"
+
+SRCREV = "7fe590fef812561cceb08aaa10b64e9bac8f542f"
+SRC_URI = " \
+    git://github.com/ixonos/utp_com;protocol=https \
+    file://0001-Fix-Makefile-for-crosscompilation.patch \
+"
+
+PV = "1.0+git${SRCPV}"
+
+S = "${WORKDIR}/git"
+
+do_configure[noexec] = "1"
+
+do_compile () {
+       oe_runmake
+}
+
+do_install () {
+    install -d -m 0755 ${D}${bindir}
+    install -m 0755 ${S}/utp_com ${D}${bindir}/utp_com
+}
+
+BBCLASSEXTEND = "native nativesdk"
diff --git a/recipes-support/sg3-utils/sg3-utils_%.bbappend b/recipes-support/sg3-utils/sg3-utils_%.bbappend
new file mode 100644 (file)
index 0000000..608377e
--- /dev/null
@@ -0,0 +1 @@
+BBCLASSEXTEND = "native nativesdk"