All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0
@ 2016-11-19 15:25 Fabrice Fontaine
  2016-11-19 15:25 ` [Buildroot] [PATCH 2/2] tinycbor: fix cjson include path and library name Fabrice Fontaine
  2016-11-19 18:24 ` [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Danomi Manchego
  0 siblings, 2 replies; 3+ messages in thread
From: Fabrice Fontaine @ 2016-11-19 15:25 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
---
 package/cjson/Config.in  |  4 +---
 package/cjson/cjson.hash |  2 ++
 package/cjson/cjson.mk   | 22 +++-------------------
 3 files changed, 6 insertions(+), 22 deletions(-)
 create mode 100644 package/cjson/cjson.hash

diff --git a/package/cjson/Config.in b/package/cjson/Config.in
index bbe4c4a..04eff4c 100644
--- a/package/cjson/Config.in
+++ b/package/cjson/Config.in
@@ -1,9 +1,7 @@
 config BR2_PACKAGE_CJSON
 	bool "cJSON"
-	# For static build with cJSON.c directly see README
-	depends on !BR2_STATIC_LIBS
 	help
 	  An ultra-lightweight, portable, single-file, simple-as-can-be ANSI-C
 	  compliant JSON parser, under MIT license.
 
-	  http://cjson.sourceforge.net/
+	  https://github.com/DaveGamble/cJSON
diff --git a/package/cjson/cjson.hash b/package/cjson/cjson.hash
new file mode 100644
index 0000000..1fd6805
--- /dev/null
+++ b/package/cjson/cjson.hash
@@ -0,0 +1,2 @@
+# Locally computed:
+sha256  e49954e3b50f2257ab0c890b6151e794790ef7cce881426cb0e0e80037beabb4        cjson-v1.0.0.tar.gz
diff --git a/package/cjson/cjson.mk b/package/cjson/cjson.mk
index 8f21ef8..46cf6a2 100644
--- a/package/cjson/cjson.mk
+++ b/package/cjson/cjson.mk
@@ -4,26 +4,10 @@
 #
 ################################################################################
 
-CJSON_VERSION = 58
-CJSON_SITE_METHOD = svn
-CJSON_SITE = http://svn.code.sf.net/p/cjson/code
+CJSON_VERSION = v1.0.0
+CJSON_SITE = $(call github,DaveGamble,cjson,$(CJSON_VERSION))
 CJSON_INSTALL_STAGING = YES
 CJSON_LICENSE = MIT
 CJSON_LICENSE_FILES = LICENSE
 
-define CJSON_BUILD_CMDS
-	cd $(@D) && $(TARGET_CC) $(TARGET_CFLAGS) -shared -fPIC -lm \
-		cJSON.c -o libcJSON.so
-endef
-
-define CJSON_INSTALL_STAGING_CMDS
-	$(INSTALL) -D $(@D)/cJSON.h $(STAGING_DIR)/usr/include/cJSON.h
-	$(INSTALL) -D $(@D)/libcJSON.so $(STAGING_DIR)/usr/lib/libcJSON.so
-endef
-
-define CJSON_INSTALL_TARGET_CMDS
-	$(INSTALL) -D $(@D)/cJSON.h $(TARGET_DIR)/usr/include/cJSON.h
-	$(INSTALL) -D $(@D)/libcJSON.so $(TARGET_DIR)/usr/lib/libcJSON.so
-endef
-
-$(eval $(generic-package))
+$(eval $(cmake-package))
-- 
2.5.0

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

* [Buildroot] [PATCH 2/2] tinycbor: fix cjson include path and library name
  2016-11-19 15:25 [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Fabrice Fontaine
@ 2016-11-19 15:25 ` Fabrice Fontaine
  2016-11-19 18:24 ` [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Danomi Manchego
  1 sibling, 0 replies; 3+ messages in thread
From: Fabrice Fontaine @ 2016-11-19 15:25 UTC (permalink / raw)
  To: buildroot

With the first official cjson release (v1.0.0), include path and library
name have changed

Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
---
 .../tinycbor/0001-Update-cjson-include-path.patch  | 69 ++++++++++++++++++++++
 1 file changed, 69 insertions(+)
 create mode 100644 package/tinycbor/0001-Update-cjson-include-path.patch

diff --git a/package/tinycbor/0001-Update-cjson-include-path.patch b/package/tinycbor/0001-Update-cjson-include-path.patch
new file mode 100644
index 0000000..5eea937
--- /dev/null
+++ b/package/tinycbor/0001-Update-cjson-include-path.patch
@@ -0,0 +1,69 @@
+From 9aa79d8e9e38b31b34d9933a266c698e79808a79 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fabrice.fontaine@orange.com>
+Date: Sun, 13 Nov 2016 15:43:40 +0100
+Subject: [PATCH] Update cjson include path
+
+Since cjson-v1.0.0 (https://github.com/DaveGamble/cJSON/releases),
+cJSON.h is installed into cjson/cJSON.h and library has been renamed
+from cJSON to cjson
+
+Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
+---
+ Makefile                    | 4 ++--
+ Makefile.configure          | 4 ++--
+ tools/json2cbor/json2cbor.c | 2 +-
+ 3 files changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index acd52eb..905fbdf 100644
+--- a/Makefile
++++ b/Makefile
+@@ -82,12 +82,12 @@ ifeq ($(open_memstream-pass),)
+   endif
+ endif
+ 
+-# json2cbor depends on an external library (cJSON)
++# json2cbor depends on an external library (cjson)
+ ifneq ($(cjson-pass)$(system-cjson-pass),)
+   JSON2CBOR_SOURCES = tools/json2cbor/json2cbor.c
+   INSTALL_TARGETS += $(bindir)/json2cbor
+   ifeq ($(system-cjson-pass),1)
+-    LDFLAGS_CJSON = -lcJSON
++    LDFLAGS_CJSON = -lcjson
+   else
+     JSON2CBOR_SOURCES += src/cjson/cJSON.c
+     json2cbor_CCFLAGS = -I$(SRCDIR)src/cjson
+diff --git a/Makefile.configure b/Makefile.configure
+index 28f4c92..424efb3 100644
+--- a/Makefile.configure
++++ b/Makefile.configure
+@@ -10,11 +10,11 @@ PROGRAM-gc_sections = int main() {}
+ CCFLAGS-gc_sections = -Wl,--gc-sections
+ 
+ PROGRAM-cjson  = \#include <stdlib.h>\n
+-PROGRAM-cjson += \#include <cJSON.h>\n
++PROGRAM-cjson += \#include <cjson/cJSON.h>\n
+ PROGRAM-cjson += int main() { return cJSON_False; }
+ CCFLAGS-cjson = -I$(dir $(MAKEFILE))src/cjson
+ PROGRAM-system-cjson = $(PROGRAM-cjson)
+-CCFLAGS-system-cjson = -lcJSON
++CCFLAGS-system-cjson = -lcjson
+ 
+ sink:
+ 	@echo >&2 Please run from the top-level Makefile.
+diff --git a/tools/json2cbor/json2cbor.c b/tools/json2cbor/json2cbor.c
+index 96d3ed1..e194299 100644
+--- a/tools/json2cbor/json2cbor.c
++++ b/tools/json2cbor/json2cbor.c
+@@ -27,7 +27,7 @@
+ #include "cbor.h"
+ #include "compilersupport_p.h"
+ 
+-#include <cJSON.h>
++#include <cjson/cJSON.h>
+ 
+ #include <errno.h>
+ #include <math.h>
+-- 
+2.5.0
+
-- 
2.5.0

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

* [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0
  2016-11-19 15:25 [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Fabrice Fontaine
  2016-11-19 15:25 ` [Buildroot] [PATCH 2/2] tinycbor: fix cjson include path and library name Fabrice Fontaine
@ 2016-11-19 18:24 ` Danomi Manchego
  1 sibling, 0 replies; 3+ messages in thread
From: Danomi Manchego @ 2016-11-19 18:24 UTC (permalink / raw)
  To: buildroot

Fabrice,


On Sat, Nov 19, 2016 at 10:25 AM, Fabrice Fontaine
<fontaine.fabrice@gmail.com> wrote:
> Signed-off-by: Fabrice Fontaine <fabrice.fontaine@orange.com>
> ---
>  package/cjson/Config.in  |  4 +---
>  package/cjson/cjson.hash |  2 ++
>  package/cjson/cjson.mk   | 22 +++-------------------
>  3 files changed, 6 insertions(+), 22 deletions(-)
>  create mode 100644 package/cjson/cjson.hash
>
> diff --git a/package/cjson/Config.in b/package/cjson/Config.in
> index bbe4c4a..04eff4c 100644
> --- a/package/cjson/Config.in
> +++ b/package/cjson/Config.in
> @@ -1,9 +1,7 @@
>  config BR2_PACKAGE_CJSON
>         bool "cJSON"
> -       # For static build with cJSON.c directly see README
> -       depends on !BR2_STATIC_LIBS
>         help
>           An ultra-lightweight, portable, single-file, simple-as-can-be ANSI-C
>           compliant JSON parser, under MIT license.
>
> -         http://cjson.sourceforge.net/
> +         https://github.com/DaveGamble/cJSON
> diff --git a/package/cjson/cjson.hash b/package/cjson/cjson.hash
> new file mode 100644
> index 0000000..1fd6805
> --- /dev/null
> +++ b/package/cjson/cjson.hash
> @@ -0,0 +1,2 @@
> +# Locally computed:
> +sha256  e49954e3b50f2257ab0c890b6151e794790ef7cce881426cb0e0e80037beabb4        cjson-v1.0.0.tar.gz
> diff --git a/package/cjson/cjson.mk b/package/cjson/cjson.mk
> index 8f21ef8..46cf6a2 100644
> --- a/package/cjson/cjson.mk
> +++ b/package/cjson/cjson.mk
> @@ -4,26 +4,10 @@
>  #
>  ################################################################################
>
> -CJSON_VERSION = 58
> -CJSON_SITE_METHOD = svn
> -CJSON_SITE = http://svn.code.sf.net/p/cjson/code
> +CJSON_VERSION = v1.0.0

It looks like there's already a 1.0.1 release.

Danomi -



> +CJSON_SITE = $(call github,DaveGamble,cjson,$(CJSON_VERSION))
>  CJSON_INSTALL_STAGING = YES
>  CJSON_LICENSE = MIT
>  CJSON_LICENSE_FILES = LICENSE
>
> -define CJSON_BUILD_CMDS
> -       cd $(@D) && $(TARGET_CC) $(TARGET_CFLAGS) -shared -fPIC -lm \
> -               cJSON.c -o libcJSON.so
> -endef
> -
> -define CJSON_INSTALL_STAGING_CMDS
> -       $(INSTALL) -D $(@D)/cJSON.h $(STAGING_DIR)/usr/include/cJSON.h
> -       $(INSTALL) -D $(@D)/libcJSON.so $(STAGING_DIR)/usr/lib/libcJSON.so
> -endef
> -
> -define CJSON_INSTALL_TARGET_CMDS
> -       $(INSTALL) -D $(@D)/cJSON.h $(TARGET_DIR)/usr/include/cJSON.h
> -       $(INSTALL) -D $(@D)/libcJSON.so $(TARGET_DIR)/usr/lib/libcJSON.so
> -endef
> -
> -$(eval $(generic-package))
> +$(eval $(cmake-package))
> --
> 2.5.0
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot

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

end of thread, other threads:[~2016-11-19 18:24 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-19 15:25 [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Fabrice Fontaine
2016-11-19 15:25 ` [Buildroot] [PATCH 2/2] tinycbor: fix cjson include path and library name Fabrice Fontaine
2016-11-19 18:24 ` [Buildroot] [PATCH 1/2] cjson: bump to version v1.0.0 Danomi Manchego

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.