package/utp_com: Tool used to send commands to hardware via NXP's UTP protocol.
PATCH 1/1 package/utp_com: Tool used to send commands to hardware via NXP's UTP protocol.
--- package/Config.in | 1 + package/Config.in.host | 1 + .../0001-Fix-Makefile-for-crosscompilation.patch | 33 ++++++++++++++++++++++ package/utp_com/Config.in | 8 ++++++ package/utp_com/Config.in.host | 7 +++++ package/utp_com/utp_com.hash | 2 ++ package/utp_com/utp_com.mk | 28 ++++++++++++++++++ 7 files changed, 80 insertions(+) create mode 100644 package/utp_com/0001-Fix-Makefile-for-crosscompilation.patch create mode 100644 package/utp_com/Config.in create mode 100644 package/utp_com/Config.in.host create mode 100644 package/utp_com/utp_com.hash create mode 100644 package/utp_com/utp_com.mk
package/Config.in +1 -0
@@ -199,6 +199,7 @@ menu "Filesystem and flash utilities" source "package/sshfs/Config.in" source "package/sunxi-tools/Config.in" source "package/unionfs/Config.in" + source "package/utp_com/Config.in" source "package/xfsprogs/Config.in" endmenu
package/Config.in.host +1 -0
@@ -56,6 +56,7 @@ menu "Host utilities" source "package/ti-cgt-pru/Config.in.host" source "package/uboot-tools/Config.in.host" source "package/util-linux/Config.in.host" + source "package/utp_com/Config.in.host" source "package/vboot-utils/Config.in.host" source "package/xorriso/Config.in.host" source "package/zip/Config.in.host"
package/utp_com/0001-Fix-Makefile-for-crosscompilation.patch new file +33 -0
@@ -0,0 +1,33 @@ +From 548885c843e2d26c02631e6df69f50cfa686dde3 Mon Sep 17 00:00:00 2001 +From: Vincent Prince <[email protected]> +Date: Wed, 16 May 2018 10:02:10 +0200 +Subject: [PATCH] Makefile: Allow variables override for cross-compilation + +Signed-off-by: Vincent Prince <[email protected]> +--- + makefile | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/makefile b/makefile +index 7e19fe5..8517e38 100644 +--- a/makefile ++++ b/makefile +@@ -1,10 +1,10 @@ +-CC=gcc +-CFLAGS=-I. -Wall -O2 +-DEPS= +-OBJ=utp_com.o ++CC ?= gcc ++CFLAGS ?= -I. -Wall -O2 ++DEPS ?= ++OBJ ?= utp_com.o + + %.o: %.c $(DEPS) + $(CC) -c -o $@ $< $(CFLAGS) + + utp_com: $(OBJ) +- gcc -o $@ $^ $(CFLAGS) ++ $(CC) -o $@ $^ $(CFLAGS) +-- +2.7.4 +
package/utp_com/Config.in new file +8 -0
@@ -0,0 +1,8 @@ +config BR2_PACKAGE_UTP_COM + bool "utp_com" + select BR2_PACKAGE_SG3_UTILS + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
package/utp_com/Config.in.host new file +7 -0
@@ -0,0 +1,7 @@ +config BR2_PACKAGE_HOST_UTP_COM + bool "host utp_com" + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
package/utp_com/utp_com.hash new file +2 -0
@@ -0,0 +1,2 @@ +# locally computed +sha256 4176452866381fd53fe11951f59a933410734a97050b6ce7eae9df2937165b70 utp_com-7fe590fef812561cceb08aaa10b64e9bac8f542f.tar.gz
package/utp_com/utp_com.mk new file +28 -0
@@ -0,0 +1,28 @@ +################################################################################ +# +# utp_com +# +################################################################################ + +UTP_COM_VERSION = 7fe590fef812561cceb08aaa10b64e9bac8f542f +UTP_COM_SITE = $(call github,ixonos,utp_com,$(UTP_COM_VERSION)) +UTP_COM_LICENSE = GPL-2.0+ +UTP_COM_LICENSE_FILES = LICENSE +UTP_COM_DEPENDENCIES = sg3_utils + +define UTP_COM_BUILD_CMDS + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" +endef +define HOST_UTP_COM_BUILD_CMDS + $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(HOST_CFLAGS) -I$(HOST_DIR)/usr/include" +endef + +define UTP_COM_INSTALL_TARGET_CMDS + $(INSTALL) -m 755 $(@D)/utp_com $(TARGET_DIR)/usr/bin/utp_com +endef +define HOST_UTP_COM_INSTALL_CMDS + $(INSTALL) -m 755 $(@D)/utp_com $(HOST_DIR)/usr/bin/utp_com +endef + +$(eval $(generic-package)) +$(eval $(host-generic-package))
Signature · 1 line
2.7.4
PATCH 1/1 package/utp_com: Tool used to send commands to hardware via NXP's UTP protocol.
---------- Forwarded message ----------
From: Vincent Prince <[email protected]>
Date: 2018-05-22 9:44 GMT+02:00
Subject: [Buildroot][PATCH] package/utp_com: Tool used to send commands to hardware via NXP's UTP protocol.
To: buildroot at buildroot.org
Cc: Vincent Prince <[email protected]>
--- package/Config.in | 1 + package/Config.in.host | 1 + .../0001-Fix-Makefile-for-crosscompilation.patch | 33 ++++++++++++++++++++++ package/utp_com/Config.in | 8 ++++++ package/utp_com/Config.in.host | 7 +++++ package/utp_com/utp_com.hash | 2 ++ package/utp_com/utp_com.mk | 28 ++++++++++++++++++ 7 files changed, 80 insertions(+) create mode 100644 package/utp_com/0001-Fix-Makefile-for-crosscompilation. patch create mode 100644 package/utp_com/Config.in create mode 100644 package/utp_com/Config.in.host create mode 100644 package/utp_com/utp_com.hash create mode 100644 package/utp_com/utp_com.mk
package/Config.in +1 -0
@@ -199,6 +199,7 @@ menu "Filesystem and flash utilities" source "package/sshfs/Config.in" source "package/sunxi-tools/Config.in" source "package/unionfs/Config.in" + source "package/utp_com/Config.in" source "package/xfsprogs/Config.in" endmenu
package/Config.in.host +1 -0
@@ -56,6 +56,7 @@ menu "Host utilities" source "package/ti-cgt-pru/Config.in.host" source "package/uboot-tools/Config.in.host" source "package/util-linux/Config.in.host" + source "package/utp_com/Config.in.host" source "package/vboot-utils/Config.in.host" source "package/xorriso/Config.in.host" source "package/zip/Config.in.host"
(quoted diff) +0 -0
b/package/utp_com/0001-Fix-Makefile-for-crosscompilation.patch new file mode 100644
index 0000000..d1b7110
package/utp_com/0001-Fix-Makefile-for-crosscompilation.patch new file +33 -0
@@ -0,0 +1,33 @@ +From 548885c843e2d26c02631e6df69f50cfa686dde3 Mon Sep 17 00:00:00 2001 +From: Vincent Prince <[email protected]> +Date: Wed, 16 May 2018 10:02:10 +0200 +Subject: [PATCH] Makefile: Allow variables override for cross-compilation + +Signed-off-by: Vincent Prince <[email protected]> +--- + makefile | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/makefile b/makefile +index 7e19fe5..8517e38 100644 +--- a/makefile ++++ b/makefile +@@ -1,10 +1,10 @@ +-CC=gcc +-CFLAGS=-I. -Wall -O2 +-DEPS= +-OBJ=utp_com.o ++CC ?= gcc ++CFLAGS ?= -I. -Wall -O2 ++DEPS ?= ++OBJ ?= utp_com.o + + %.o: %.c $(DEPS) + $(CC) -c -o $@ $< $(CFLAGS) + + utp_com: $(OBJ) +- gcc -o $@ $^ $(CFLAGS) ++ $(CC) -o $@ $^ $(CFLAGS) +-- +2.7.4 +
package/utp_com/Config.in new file +8 -0
@@ -0,0 +1,8 @@ +config BR2_PACKAGE_UTP_COM + bool "utp_com" + select BR2_PACKAGE_SG3_UTILS + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
package/utp_com/Config.in.host new file +7 -0
@@ -0,0 +1,7 @@ +config BR2_PACKAGE_HOST_UTP_COM + bool "host utp_com" + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
package/utp_com/utp_com.hash new file +2 -0
@@ -0,0 +1,2 @@ +# locally computed +sha256 4176452866381fd53fe11951f59a933410734a97050b6ce7eae9df2937165b70
utp_com-7fe590fef812561cceb08aaa10b64e9bac8f542f.tar.gz
package/utp_com/utp_com.mk new file +1 -0
@@ -0,0 +1,28 @@ +###########################################################
#####################
+#
+# utp_com
+#
+###########################################################
#####################
+
+UTP_COM_VERSION = 7fe590fef812561cceb08aaa10b64e9bac8f542f +UTP_COM_SITE = $(call github,ixonos,utp_com,$(UTP_COM_VERSION)) +UTP_COM_LICENSE = GPL-2.0+
+UTP_COM_LICENSE_FILES = LICENSE
+UTP_COM_DEPENDENCIES = sg3_utils
+
+define UTP_COM_BUILD_CMDS
+ $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(TARGET_CFLAGS)
-I$(STAGING_DIR)/usr/include"
+endef
+define HOST_UTP_COM_BUILD_CMDS
+ $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(HOST_CFLAGS)
-I$(HOST_DIR)/usr/include"
+endef
+
+define UTP_COM_INSTALL_TARGET_CMDS
+ $(INSTALL) -m 755 $(@D)/utp_com $(TARGET_DIR)/usr/bin/utp_com
+endef
+define HOST_UTP_COM_INSTALL_CMDS
+ $(INSTALL) -m 755 $(@D)/utp_com $(HOST_DIR)/usr/bin/utp_com
+endef
+
+$(eval $(generic-package))
+$(eval $(host-generic-package))
Signature · 4 lines
2.7.4 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20180524/cf82de70/attachment.html>
PATCH 1/1 package/utp_com: Tool used to send commands to hardware via NXP's UTP protocol.
In reply to Vincent PrinceVincent, All,
Thanks for this contribution! :-)
Here's just a very rough and very quick review because I spotted a few minor issues...
On 2018-05-22 09:44 +0200, Vincent Prince spake thusly:
Quoted 1 line
Signed-off-by Vincent Prince <[email protected]>
[--SNIP--]
Quoted 6 lines
package/utp_com/Config.in new file +0
-0
package/utp_com/Config.in line 8
Quoted 8 lines
package/utp_com/Config.in new file +8
-0@@ -0,0 +1,8 @@ +config BR2_PACKAGE_UTP_COM + bool "utp_com" + select BR2_PACKAGE_SG3_UTILS + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
Indentation of the help text should be 1 TAB and 2 spaces, not 2 TABs.
package/utp_com/Config.in.host line 7
Quoted 13 lines
package/utp_com/Config.in.host new file +7
-0@@ -0,0 +1,7 @@ +config BR2_PACKAGE_HOST_UTP_COM + bool "host utp_com" + help + This package is used to send commands to hardware + via Freescale's UTP protocol. + + https://github.com/ixonos/utp_com
Indentation of the help text should be 1 TAB and 2 spaces, not 2 TABs.
[--SNIP--]
Quoted 11 lines
package/utp_com/utp_com.mk new file +5
-0@@ -0,0 +1,28 @@ +################################################################################ +# +# utp_com +# +################################################################################
package/utp_com/utp_com.mk line 15
Quoted 10 lines
package/utp_com/utp_com.mk new file +10
-0+ +UTP_COM_VERSION = 7fe590fef812561cceb08aaa10b64e9bac8f542f +UTP_COM_SITE = $(call github,ixonos,utp_com,$(UTP_COM_VERSION)) +UTP_COM_LICENSE = GPL-2.0+ +UTP_COM_LICENSE_FILES = LICENSE +UTP_COM_DEPENDENCIES = sg3_utils + +define UTP_COM_BUILD_CMDS + $(TARGET_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" +endef
Please add separatig lines between the various macros. Also, please group the target commands together and the host commands together:
define UTP_COM_BUILD_CMDS
Blabla
endef
define UTP_COM_INSTALL_TARGET_CMDS
Blabla
endef
define HOST_UTP_COM_BUILD_CMDS
Blabla
endef
define HOST_UTP_COM_INSTALL_CMDS
Blabla
endef
package/utp_com/utp_com.mk line 17
Quoted 2 lines
package/utp_com/utp_com.mk new file +2
-0+define HOST_UTP_COM_BUILD_CMDS + $(HOST_CONFIGURE_OPTS) $(MAKE) -C $(@D) CFLAGS="$(HOST_CFLAGS) -I$(HOST_DIR)/usr/include"
We've dropped use of "/usr" as a sub-dir of $(HOST_DIR) now, so includes are to be found directly in $(HOST_DIR)/include
package/utp_com/utp_com.mk line 24
Quoted 7 lines
package/utp_com/utp_com.mk new file +7
-0+endef + +define UTP_COM_INSTALL_TARGET_CMDS + $(INSTALL) -m 755 $(@D)/utp_com $(TARGET_DIR)/usr/bin/utp_com +endef +define HOST_UTP_COM_INSTALL_CMDS + $(INSTALL) -m 755 $(@D)/utp_com $(HOST_DIR)/usr/bin/utp_com
Ditto, no "/usr" anymore, so install directly in $(HOST_DIR)/bin/utp_com
Regards,
Yann E. MORIN.
Quoted 11 lines
package/utp_com/utp_com.mk new file +4
-0+endef + +$(eval $(generic-package)) +$(eval $(host-generic-package))Signature · 6 lines
2.7.4 _______________________________________________ buildroot mailing list buildroot at busybox.net http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'