Skip to contentSkip to conversation

qjson: new package

PATCH Superseded Zoltan Gyarmati 2 participants 2 messages Apr 6, 2013 – Apr 7, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qjson: new package

---
 package/Config.in                                  |    1 +
 package/qjson/Config.in                            |    8 ++++++
 ...0.8.1-fix-Qt4-package-error-in-CMakeLists.patch |   27 ++++++++++++++++++++
 package/qjson/qjson.mk                             |   13 ++++++++++
 4 files changed, 49 insertions(+)
 create mode 100644 package/qjson/Config.in
 create mode 100644 package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch
 create mode 100644 package/qjson/qjson.mk
package/Config.in +1 -0
index 69d87f0..f84d8d0 100644
@@ -143,6 +143,7 @@ if BR2_PACKAGE_QT
 comment "QT libraries and helper libraries"
 source "package/grantlee/Config.in"
 source "package/qextserialport/Config.in"
+source "package/qjson/Config.in"
 source "package/qtuio/Config.in"
 source "package/qwt/Config.in"
 endif
package/qjson/Config.in new file +8 -0
new file mode 100644
index 0000000..e21a336
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_QJSON
+	bool "qjson"
+    depends on BR2_PACKAGE_QT
+	help
+      QJson is a Qt-based library that maps JSON data to 
+      QVariant objects and vice versa.
+	  
+      http://qjson.sourceforge.net
package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch new file +27 -0
new file mode 100644
index 0000000..736438b
@@ -0,0 +1,27 @@
+From 529e50939316abc3c4190f89a482b17a4d4b3355 Mon Sep 17 00:00:00 2001
+From: Zoltan Gyarmati <[email protected]>
+Date: Sat, 6 Apr 2013 16:54:25 +0200
+Subject: [PATCH 1/1] fix Qt4 package error in CMakeLists.txt
+
+
+Signed-off-by: Zoltan Gyarmati <[email protected]>
+---
+ CMakeLists.txt |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 13e65f1..447f209 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -32,7 +32,7 @@ SET(FRAMEWORK_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/Library/Frameworks"
+ SET(QT_USE_IMPORTED_TARGETS TRUE)
+ 
+ # Find Qt4
+-FIND_PACKAGE( Qt4 REQUIRED )
++find_package(Qt4 COMPONENTS QtCore REQUIRED )
+ 
+ IF (NOT WIN32)
+   SET( QT_DONT_USE_QTGUI TRUE )
+-- 
+1.7.10.4
+
package/qjson/qjson.mk new file +13 -0
new file mode 100644
index 0000000..ea4b875
@@ -0,0 +1,13 @@
+#############################################################
+#
+# qjson
+#
+#############################################################
+
+QJSON_VERSION = 0.8.1
+QJSON_SITE = git://github.com/flavio/qjson.git 
+QJSON_INSTALL_STAGING = YES
+QJSON_DEPENDENCIES =  qt
+
+$(eval $(cmake-package))
+
Signature · 1 line
1.7.10.4
#1 lore raw

PATCH 1/1 qjson: new package

Dear Zoltan Gyarmati,

Thanks for your contribution! A few comments below.

package/qjson/Config.in line 3

Quoted 9 lines · Zoltan Gyarmati
package/qjson/Config.in new file +3 -0
new file mode 100644
index 0000000..e21a336
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_QJSON
+	bool "qjson"
+    depends on BR2_PACKAGE_QT

This dependency is not needed: your qjson/Config.in file is already included inside a if BR2_PACKAGE_QT...endif condition (in package/Config.in). And also, the indentation of this line was wrong.

package/qjson/Config.in line 8

Quoted 5 lines
package/qjson/Config.in new file +5 -0
+	help
+      QJson is a Qt-based library that maps JSON data to 
+      QVariant objects and vice versa.
+	  
+      http://qjson.sourceforge.net

The indentation for the help text is one tab + two spaces. Here you have only spaces.

package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch

Quoted 1 line
package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch +0 -0

The package version should be in the file name of patches. And also, I believe we don't like too much mixed-case in filenames. So your patch should probably be named:

qjson-fix-qt4-package-error-in-cmakelists.patch

package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch line 7

Quoted 12 lines

new file mode 100644
index 0000000..736438b

package/qjson/qjson-0.8.1-fix-Qt4-package-error-in-CMakeLists.patch new file +7 -0
@@ -0,0 +1,27 @@
+From 529e50939316abc3c4190f89a482b17a4d4b3355 Mon Sep 17 00:00:00 2001
+From: Zoltan Gyarmati <[email protected]>
+Date: Sat, 6 Apr 2013 16:54:25 +0200
+Subject: [PATCH 1/1] fix Qt4 package error in CMakeLists.txt
+
+
+Signed-off-by: Zoltan Gyarmati <[email protected]>

Good to have a description, but I wish you added a bit more details about what you're fixing.

Quoted 6 lines
package/qjson/qjson.mk new file +0 -0
new file mode 100644
index 0000000..ea4b875

package/qjson/qjson.mk line 8

Quoted 8 lines
package/qjson/qjson.mk new file +8 -0
@@ -0,0 +1,13 @@
+#############################################################
+#
+# qjson
+#
+#############################################################
+
+QJSON_VERSION = 0.8.1
+QJSON_SITE = git://github.com/flavio/qjson.git 

See
http://buildroot.org/downloads/manual/manual.html#github-download-url.
We prefer to use tarballs when possible.

package/qjson/qjson.mk line 12

Quoted 4 lines
package/qjson/qjson.mk new file +4 -0
+QJSON_INSTALL_STAGING = YES
+QJSON_DEPENDENCIES =  qt
+
+$(eval $(cmake-package))

It would be great if you could add the licensing informations. It seems to be:

QJSON_LICENSE = LGPLv2.1
QJSON_LICENSE_FILES = COPYING.lib

Best regards,

Thomas

Signature · 4 lines
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com