All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] tinycbor: new package
@ 2016-07-25  8:37 Fabrice Fontaine
  2016-07-25 21:35 ` Thomas Petazzoni
  2016-07-30 14:43 ` Thomas Petazzoni
  0 siblings, 2 replies; 7+ messages in thread
From: Fabrice Fontaine @ 2016-07-25  8:37 UTC (permalink / raw)
  To: buildroot

Concise Binary Object Representation (CBOR) Library

Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
---
 package/Config.in              |  1 +
 package/tinycbor/Config.in     | 20 ++++++++++++++++++++
 package/tinycbor/tinycbor.hash |  2 ++
 package/tinycbor/tinycbor.mk   | 38 ++++++++++++++++++++++++++++++++++++++
 4 files changed, 61 insertions(+)
 create mode 100644 package/tinycbor/Config.in
 create mode 100644 package/tinycbor/tinycbor.hash
 create mode 100644 package/tinycbor/tinycbor.mk

diff --git a/package/Config.in b/package/Config.in
index 814141f..8ceeb9e 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1328,6 +1328,7 @@ endif
 	source "package/qlibc/Config.in"
 	source "package/sphinxbase/Config.in"
 	source "package/startup-notification/Config.in"
+	source "package/tinycbor/Config.in"
 	source "package/tz/Config.in"
 	source "package/tzdata/Config.in"
 endmenu
diff --git a/package/tinycbor/Config.in b/package/tinycbor/Config.in
new file mode 100644
index 0000000..edbe64a
--- /dev/null
+++ b/package/tinycbor/Config.in
@@ -0,0 +1,20 @@
+config BR2_PACKAGE_TINYCBOR
+	bool "tinyCBOR"
+	help
+	  Concise Binary Object Representation (CBOR) Library
+
+	  https://github.com/01org/tinycbor
+
+if BR2_PACKAGE_TINYCBOR
+
+config BR2_PACKAGE_TINYCBOR_JSON2CBOR
+	bool "json2cbor"
+	depends on !BR2_STATIC_LIBS # cJSON
+	select BR2_PACKAGE_CJSON
+	help
+	  The TinyCBOR library does not provide a way to convert from
+	  JSON representation back to encoded form. However, json2cbor
+	  can be used for that purpose. That tool supports the metadata
+	  format that these functions may produce.
+
+endif # BR2_PACKAGE_TINYCBOR
diff --git a/package/tinycbor/tinycbor.hash b/package/tinycbor/tinycbor.hash
new file mode 100644
index 0000000..e60a86c
--- /dev/null
+++ b/package/tinycbor/tinycbor.hash
@@ -0,0 +1,2 @@
+# Locally computed:
+sha256	e73a617b3a51fac103df1faab9ea037e509c1491cca29c1fd4b5083d74267597	tinycbor-v0.3.1.tar.gz
diff --git a/package/tinycbor/tinycbor.mk b/package/tinycbor/tinycbor.mk
new file mode 100644
index 0000000..5d05a22
--- /dev/null
+++ b/package/tinycbor/tinycbor.mk
@@ -0,0 +1,38 @@
+################################################################################
+#
+# tinycbor
+#
+################################################################################
+
+TINYCBOR_VERSION = v0.3.1
+TINYCBOR_SITE = $(call github,01org,tinycbor,$(TINYCBOR_VERSION))
+TINYCBOR_LICENSE = MIT
+TINYCBOR_LICENSE_FILES = LICENSE
+
+TINYCBOR_DEPENDENCIES = host-pkgconf
+TINYCBOR_INSTALL_STAGING = YES
+
+ifeq ($(BR2_PACKAGE_CJSON),y)
+TINYCBOR_DEPENDENCIES += cjson
+endif
+
+TINYCBOR_MAKE_OPTS = \
+	$(TARGET_CONFIGURE_OPTS) \
+	V=1 \
+	prefix=/usr
+
+define TINYCBOR_BUILD_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE) $(TINYCBOR_MAKE_OPTS) -C $(@D)
+endef
+
+define TINYCBOR_INSTALL_STAGING_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE) $(TINYCBOR_MAKE_OPTS) -C $(@D) \
+		DESTDIR=$(STAGING_DIR) install
+endef
+
+define TINYCBOR_INSTALL_TARGET_CMDS
+	$(TARGET_MAKE_ENV) $(MAKE) $(TINYCBOR_MAKE_OPTS) -C $(@D) \
+		DESTDIR=$(TARGET_DIR) install
+endef
+
+$(eval $(generic-package))
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-25  8:37 [Buildroot] [PATCH 1/1] tinycbor: new package Fabrice Fontaine
@ 2016-07-25 21:35 ` Thomas Petazzoni
  2016-07-30 14:43 ` Thomas Petazzoni
  1 sibling, 0 replies; 7+ messages in thread
From: Thomas Petazzoni @ 2016-07-25 21:35 UTC (permalink / raw)
  To: buildroot

Hello,

On Mon, 25 Jul 2016 10:37:39 +0200, Fabrice Fontaine wrote:
> Concise Binary Object Representation (CBOR) Library
> 
> Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>

Applied, after doing a few minor changes:

    [Thomas:
     - use lower-case letters in the Config.in option prompt
     - remove BR2_PACKAGE_TINYCBOR_JSON2CBOR sub-option, simply rely on
       the cjson package being enabled
     - pass prefix=/usr only at install time.]

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-25  8:37 [Buildroot] [PATCH 1/1] tinycbor: new package Fabrice Fontaine
  2016-07-25 21:35 ` Thomas Petazzoni
@ 2016-07-30 14:43 ` Thomas Petazzoni
  2016-07-30 19:52   ` Thomas Petazzoni
  1 sibling, 1 reply; 7+ messages in thread
From: Thomas Petazzoni @ 2016-07-30 14:43 UTC (permalink / raw)
  To: buildroot

Hello,

On Mon, 25 Jul 2016 10:37:39 +0200, Fabrice Fontaine wrote:
> Concise Binary Object Representation (CBOR) Library
> 
> Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
> ---
>  package/Config.in              |  1 +
>  package/tinycbor/Config.in     | 20 ++++++++++++++++++++
>  package/tinycbor/tinycbor.hash |  2 ++
>  package/tinycbor/tinycbor.mk   | 38 ++++++++++++++++++++++++++++++++++++++
>  4 files changed, 61 insertions(+)
>  create mode 100644 package/tinycbor/Config.in
>  create mode 100644 package/tinycbor/tinycbor.hash
>  create mode 100644 package/tinycbor/tinycbor.mk

This package is causing two types of build failures:

 * On Blackfin only:

   http://autobuild.buildroot.net/?reason=tinycbor-v0.3.1&arch=bfin

   The Blackfin external toolchain uses gcc 4.3, which is pretty old.
   The error occurs on unnamed unions, maybe there's a problem with
   that. But
   https://gcc.gnu.org/onlinedocs/gcc-4.3.2/gcc/Unnamed-Fields.html
   seems to indicate it was already supported in gcc 4.3. More
   investigation is needed.

 * On other architectures, a problem occurs when
   output/target/usr/lib/libtinycbor.a is created as a directory, for
   some reason:

   http://autobuild.buildroot.net/results/760/7605c301f460398c2435f6b73d6d07c7d1022e8c/build-end.log

Could you look into those issues?

Thanks,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-30 14:43 ` Thomas Petazzoni
@ 2016-07-30 19:52   ` Thomas Petazzoni
  2016-07-30 20:03     ` Fabrice Fontaine
  0 siblings, 1 reply; 7+ messages in thread
From: Thomas Petazzoni @ 2016-07-30 19:52 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 30 Jul 2016 16:43:01 +0200, Thomas Petazzoni wrote:

>  * On other architectures, a problem occurs when
>    output/target/usr/lib/libtinycbor.a is created as a directory, for
>    some reason:
> 
>    http://autobuild.buildroot.net/results/760/7605c301f460398c2435f6b73d6d07c7d1022e8c/build-end.log

I have committed a patch to fix this problem:
https://git.buildroot.org/buildroot/commit/?id=04c9be519de922cda3e20a00be2fad39b265d398.

The Blackfin problem remains to be solved, however.

Thanks,

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-30 19:52   ` Thomas Petazzoni
@ 2016-07-30 20:03     ` Fabrice Fontaine
  2016-07-30 21:24       ` Thomas Petazzoni
  0 siblings, 1 reply; 7+ messages in thread
From: Fabrice Fontaine @ 2016-07-30 20:03 UTC (permalink / raw)
  To: buildroot

Dear Thomas,

Issue with unnamed union will be fixed by giving a name to it, patch has
been accepted upstream: https://github.com/01org/tinycbor/pull/35.
Thanks a lot for fixing the other issue.

Best Regards,

Fabrice

2016-07-30 21:52 GMT+02:00 Thomas Petazzoni <
thomas.petazzoni@free-electrons.com>:

> Hello,
>
> On Sat, 30 Jul 2016 16:43:01 +0200, Thomas Petazzoni wrote:
>
> >  * On other architectures, a problem occurs when
> >    output/target/usr/lib/libtinycbor.a is created as a directory, for
> >    some reason:
> >
> >
> http://autobuild.buildroot.net/results/760/7605c301f460398c2435f6b73d6d07c7d1022e8c/build-end.log
>
> I have committed a patch to fix this problem:
>
> https://git.buildroot.org/buildroot/commit/?id=04c9be519de922cda3e20a00be2fad39b265d398
> .
>
> The Blackfin problem remains to be solved, however.
>
> Thanks,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20160730/ee5b5980/attachment.html>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-30 20:03     ` Fabrice Fontaine
@ 2016-07-30 21:24       ` Thomas Petazzoni
  2016-07-31  6:56         ` Fabrice Fontaine
  0 siblings, 1 reply; 7+ messages in thread
From: Thomas Petazzoni @ 2016-07-30 21:24 UTC (permalink / raw)
  To: buildroot

Hello,

On Sat, 30 Jul 2016 22:03:14 +0200, Fabrice Fontaine wrote:

> Issue with unnamed union will be fixed by giving a name to it, patch has
> been accepted upstream: https://github.com/01org/tinycbor/pull/35.
> Thanks a lot for fixing the other issue.

Will you send a Buildroot patch to integrate the tinycbor fix until
upstream makes a new release?

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [Buildroot] [PATCH 1/1] tinycbor: new package
  2016-07-30 21:24       ` Thomas Petazzoni
@ 2016-07-31  6:56         ` Fabrice Fontaine
  0 siblings, 0 replies; 7+ messages in thread
From: Fabrice Fontaine @ 2016-07-31  6:56 UTC (permalink / raw)
  To: buildroot

Dear Thomas,

Thiago will rework the patch:
https://github.com/01org/tinycbor/commit/4628a110b736c3c31bd8c577ea1d29400e0c0a53
so we'll have to wait for the 0.4 release.

Best Regards,

Fabrice

2016-07-30 23:24 GMT+02:00 Thomas Petazzoni <
thomas.petazzoni@free-electrons.com>:

> Hello,
>
> On Sat, 30 Jul 2016 22:03:14 +0200, Fabrice Fontaine wrote:
>
> > Issue with unnamed union will be fixed by giving a name to it, patch has
> > been accepted upstream: https://github.com/01org/tinycbor/pull/35.
> > Thanks a lot for fixing the other issue.
>
> Will you send a Buildroot patch to integrate the tinycbor fix until
> upstream makes a new release?
>
> Thanks!
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux, Kernel and Android engineering
> http://free-electrons.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20160731/2865d6c9/attachment.html>

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-07-31  6:56 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-25  8:37 [Buildroot] [PATCH 1/1] tinycbor: new package Fabrice Fontaine
2016-07-25 21:35 ` Thomas Petazzoni
2016-07-30 14:43 ` Thomas Petazzoni
2016-07-30 19:52   ` Thomas Petazzoni
2016-07-30 20:03     ` Fabrice Fontaine
2016-07-30 21:24       ` Thomas Petazzoni
2016-07-31  6:56         ` Fabrice Fontaine

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.