Openembedded Devel Discussions
 help / color / mirror / Atom feed
From: Khem Raj <raj.khem@gmail.com>
To: openembedded-devel@lists.openembedded.org
Subject: [meta-oe][PATCH 41/49] jsonrpc: Add recipe
Date: Wed, 23 Nov 2016 01:22:01 -0800	[thread overview]
Message-ID: <20161123092209.23699-41-raj.khem@gmail.com> (raw)
In-Reply-To: <20161123092209.23699-1-raj.khem@gmail.com>

Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
 ...ce-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch | 77 ++++++++++++++++++++++
 ...torclient-Typecast-min-arguments-correctl.patch | 33 ++++++++++
 ...torserver-Include-sys-select.h-before-oth.patch | 34 ++++++++++
 meta-oe/recipes-devtools/jsonrpc/jsonrpc_0.7.0.bb  | 30 +++++++++
 4 files changed, 174 insertions(+)
 create mode 100644 meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-cmake-replace-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch
 create mode 100644 meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorclient-Typecast-min-arguments-correctl.patch
 create mode 100644 meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorserver-Include-sys-select.h-before-oth.patch
 create mode 100644 meta-oe/recipes-devtools/jsonrpc/jsonrpc_0.7.0.bb

diff --git a/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-cmake-replace-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-cmake-replace-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch
new file mode 100644
index 0000000..748e4da
--- /dev/null
+++ b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-cmake-replace-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch
@@ -0,0 +1,77 @@
+From ac61124df17ab76527508bbb9a3115d4d6cc1af6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 21 Nov 2016 11:26:26 -0800
+Subject: [PATCH] cmake: replace hardcoded lib/${CMAKE_LIBRARY_PATH} with
+ {CMAKE_INSTALL_LIBDIR}
+
+Fixes
+| CMake Error at src/jsonrpccpp/CMakeLists.txt:207 (install):
+|   install TARGETS given unknown argument "/lib".
+
+and
+
+Wrong install paths during cross compile
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/jsonrpccpp/CMakeLists.txt    | 8 ++++----
+ src/stubgenerator/CMakeLists.txt | 6 +++---
+ 2 files changed, 7 insertions(+), 7 deletions(-)
+
+diff --git a/src/jsonrpccpp/CMakeLists.txt b/src/jsonrpccpp/CMakeLists.txt
+index e4a1eb5..13f9056 100644
+--- a/src/jsonrpccpp/CMakeLists.txt
++++ b/src/jsonrpccpp/CMakeLists.txt
+@@ -205,15 +205,15 @@ if (WIN32)
+ endif()
+ 
+ install(TARGETS ${ALL_LIBS}
+-	LIBRARY DESTINATION lib${LIB_SUFFIX}/${CMAKE_LIBRARY_PATH}
+-	ARCHIVE DESTINATION lib${LIB_SUFFIX}/${CMAKE_LIBRARY_PATH}
++	LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
++	ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
+ 	RUNTIME DESTINATION bin
+ )
+ 
+ #set pkg-config
+ get_filename_component(FULL_PATH_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX} ABSOLUTE)
+ set(FULL_PATH_INCLUDEDIR "${FULL_PATH_INSTALL_PREFIX}/include")
+-set(FULL_PATH_LIBDIR "${FULL_PATH_INSTALL_PREFIX}/lib/${CMAKE_LIBRARY_PATH}")
++set(FULL_PATH_LIBDIR "${FULL_PATH_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}")
+ 
+ CONFIGURE_FILE(${PROJECT_SOURCE_DIR}/cmake/libjsonrpccpp-client.pc.cmake ${CMAKE_BINARY_DIR}/libjsonrpccpp-client.pc)
+ CONFIGURE_FILE(${PROJECT_SOURCE_DIR}/cmake/libjsonrpccpp-server.pc.cmake ${CMAKE_BINARY_DIR}/libjsonrpccpp-server.pc)
+@@ -223,6 +223,6 @@ INSTALL(FILES
+     "${CMAKE_BINARY_DIR}/libjsonrpccpp-server.pc"
+     "${CMAKE_BINARY_DIR}/libjsonrpccpp-client.pc"
+     "${CMAKE_BINARY_DIR}/libjsonrpccpp-common.pc"
+-    DESTINATION "lib${LIB_SUFFIX}/${CMAKE_LIBRARY_PATH}/pkgconfig")
++    DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
+ 
+ 
+diff --git a/src/stubgenerator/CMakeLists.txt b/src/stubgenerator/CMakeLists.txt
+index f9dbe4c..b57b0fe 100644
+--- a/src/stubgenerator/CMakeLists.txt
++++ b/src/stubgenerator/CMakeLists.txt
+@@ -58,15 +58,15 @@ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/cmake/libjsonrpccpp-stub.pc.cmake ${CMAKE_BIN
+ 
+ INSTALL(FILES
+     "${CMAKE_BINARY_DIR}/libjsonrpccpp-stub.pc"
+-    DESTINATION "lib/${CMAKE_LIBRARY_PATH}/pkgconfig")
++    DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig")
+ 
+ install(DIRECTORY ${CMAKE_SOURCE_DIR}/src/stubgenerator/
+         DESTINATION include/jsonrpccpp/stubgen
+         FILES_MATCHING PATTERN "*.h")
+ 
+ install(TARGETS ${ALL_LIBS} jsonrpcstub
+-        LIBRARY DESTINATION lib${LIB_SUFFIX}/${CMAKE_LIBRARY_PATH}
+-        ARCHIVE DESTINATION lib${LIB_SUFFIX}/${CMAKE_LIBRARY_PATH}
++        LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
++        ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
+         RUNTIME DESTINATION bin
+ )
+ 
+-- 
+2.10.2
+
diff --git a/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorclient-Typecast-min-arguments-correctl.patch b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorclient-Typecast-min-arguments-correctl.patch
new file mode 100644
index 0000000..d21e979
--- /dev/null
+++ b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorclient-Typecast-min-arguments-correctl.patch
@@ -0,0 +1,33 @@
+From 9500f12f5d827840634311d6ca972d9551211e4d Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 21 Nov 2016 01:00:51 -0800
+Subject: [PATCH] filedescriptorclient: Typecast min() arguments correctly
+
+Fixes
+
+| /mnt/a/build/tmp-glibc/work/cortexa7hf-neon-vfpv4-oe-linux-gnueabi/jsonrpc/0.7.0-r0/git/src/jsonrpccp
+p/client/connectors/filedescriptorclient.cpp:47:92: note:   deduced conflicting types for parameter 'co
+nst _Tp' ('unsigned int' and 'long unsigned int')
+|      ssize_t byteWritten = write(outputfd, toSend.c_str(), min(toSend.size(), MAX_WRITE_SIZE));
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/jsonrpccpp/client/connectors/filedescriptorclient.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/jsonrpccpp/client/connectors/filedescriptorclient.cpp b/src/jsonrpccpp/client/connectors/filedescriptorclient.cpp
+index 77aac7e..6325b5c 100644
+--- a/src/jsonrpccpp/client/connectors/filedescriptorclient.cpp
++++ b/src/jsonrpccpp/client/connectors/filedescriptorclient.cpp
+@@ -43,7 +43,7 @@ void FileDescriptorClient::SendRPCMessage(const std::string& message,
+   string toSend = message;
+   do
+   {
+-    ssize_t byteWritten = write(outputfd, toSend.c_str(), min(toSend.size(), MAX_WRITE_SIZE));
++    ssize_t byteWritten = write(outputfd, toSend.c_str(), min((long unsigned int)toSend.size(), MAX_WRITE_SIZE));
+     if (byteWritten < 1)
+       throw JsonRpcException(Errors::ERROR_CLIENT_CONNECTOR,
+         "Unknown error occured while writing to the output file descriptor");
+-- 
+2.10.2
+
diff --git a/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorserver-Include-sys-select.h-before-oth.patch b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorserver-Include-sys-select.h-before-oth.patch
new file mode 100644
index 0000000..3b9068a
--- /dev/null
+++ b/meta-oe/recipes-devtools/jsonrpc/jsonrpc/0001-filedescriptorserver-Include-sys-select.h-before-oth.patch
@@ -0,0 +1,34 @@
+From c7aad10628949e126f50e3264b5bc7eb417347c6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Mon, 21 Nov 2016 01:25:10 -0800
+Subject: [PATCH] filedescriptorserver: Include sys/select.h before other
+ headers
+
+Fixes errors e.g.
+| /mnt/a/build/tmp-glibc/work/cortexa7hf-neon-vfpv4-oe-linux-gnueabi/jsonrpc/0.7.0-r0/git/src/jsonrpccp
+p/server/connectors/filedescriptorserver.h:63:7: error: unknown type name 'fd_set'
+|       fd_set read_fds;
+|       ^
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/jsonrpccpp/server/connectors/filedescriptorserver.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/jsonrpccpp/server/connectors/filedescriptorserver.cpp b/src/jsonrpccpp/server/connectors/filedescriptorserver.cpp
+index 9d74223..8e019ca 100644
+--- a/src/jsonrpccpp/server/connectors/filedescriptorserver.cpp
++++ b/src/jsonrpccpp/server/connectors/filedescriptorserver.cpp
+@@ -7,8 +7,8 @@
+  * @license See attached LICENSE.txt
+  ************************************************************************/
+ 
+-#include "filedescriptorserver.h"
+ #include <sys/select.h>
++#include "filedescriptorserver.h"
+ #include <sys/types.h>
+ #include <sys/stat.h>
+ #include <unistd.h>
+-- 
+2.10.2
+
diff --git a/meta-oe/recipes-devtools/jsonrpc/jsonrpc_0.7.0.bb b/meta-oe/recipes-devtools/jsonrpc/jsonrpc_0.7.0.bb
new file mode 100644
index 0000000..3a43f90
--- /dev/null
+++ b/meta-oe/recipes-devtools/jsonrpc/jsonrpc_0.7.0.bb
@@ -0,0 +1,30 @@
+SUMMARY = "C++ framework for json-rpc 1.0 and 2.0"
+DESCRIPTION = "JsonRpc-Cpp is an OpenSource implementation of JSON-RPC \
+               protocol in C++. JSON-RPC is a lightweight remote procedure \
+               call protocol similar to XML-RPC."
+HOMEPAGE = "https://github.com/cinemast/libjson-rpc-cpp"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=ee72d601854d5d2a065cf642883c489b"
+
+PV = "0.7.0+git${SRCPV}"
+
+SRC_URI = "git://github.com/cinemast/libjson-rpc-cpp \
+           file://0001-cmake-replace-hardcoded-lib-CMAKE_LIBRARY_PATH-with-.patch \
+           file://0001-filedescriptorclient-Typecast-min-arguments-correctl.patch \
+           file://0001-filedescriptorserver-Include-sys-select.h-before-oth.patch \
+"
+SRCREV = "ccbdb41388bdd929828941652da816bf52a0580e"
+
+SECTION = "libs"
+
+DEPENDS = "curl jsoncpp libmicrohttpd"
+
+S = "${WORKDIR}/git"
+
+inherit cmake
+
+EXTRA_OECMAKE += "-DCOMPILE_TESTS=NO -DCOMPILE_STUBGEN=NO -DCOMPILE_EXAMPLES=NO \
+                  -DBUILD_SHARED_LIBS=YES -DBUILD_STATIC_LIBS=YES \
+                  -DCMAKE_LIBRARY_PATH=${libdir} \
+"
-- 
2.10.2



  parent reply	other threads:[~2016-11-23  9:22 UTC|newest]

Thread overview: 73+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-23  9:21 [meta-oe][PATCH 01/49] libqmi: Fix build with clang Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 02/49] meta_oe_security_flags: Disable PIE for s3c64xx-gpio/s3c24xx-gpio/cpufrequtils Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 03/49] boinc: Add recipe for boinc-client Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 04/49] libplist: Remove rpaths surgically Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 05/49] meta_oe_security_flags.inc: Add libcec, libmodplug, libcdio Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 06/49] dcadec, libsquish: Add new recipes Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 07/49] libcec: Update to 3.1.0+ Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 08/49] kodi: Add krypton/17.x Jarvis/16.x recipes Khem Raj
2016-11-26  0:15   ` Martin Jansa
2016-11-26  7:42     ` Koen Kooi
2016-11-28 17:48       ` Khem Raj
2016-11-29  0:57     ` Khem Raj
2016-12-15  9:53       ` Martin Jansa
2016-11-23  9:21 ` [meta-oe][PATCH 09/49] fwts: Update to 16.09 release Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 10/49] libvdpau: Add recipe Khem Raj
2016-12-17 23:53   ` Martin Jansa
2016-12-19 21:10     ` Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 11/49] krb5: Add -fPIC to compile flags Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 12/49] Disable PIE for libvdpau Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 13/49] kodi: Fix build with pic on x86_64 Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 14/49] kodi-17: Add packageconfig for lcms support Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 15/49] samba: Fix build with musl Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 16/49] lockdev: Pretend GNU libc on musl Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 17/49] kodi-17: Fix build with musl Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH V2 18/49] breakpad: Upgrade to latest Khem Raj
2016-11-26  0:12   ` Martin Jansa
2016-11-26  6:09     ` Khem Raj
2016-11-23  9:21 ` [meta-filesystems][PATCH 19/49] xfsprogs: Upgrade 3.2.3 -> 4.8.0 Khem Raj
2016-11-25  0:31   ` Martin Jansa
2016-11-25 10:41     ` Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 20/49] arno-iptables-firewall: Add recipe Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 21/49] dibbler: " Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 22/49] ez-ipupdate: " Khem Raj
2016-11-23  9:21 ` [meta-multimedia][PATCH 23/49] miniupnpd: " Khem Raj
2016-11-26  0:16   ` Martin Jansa
2016-11-26  6:00     ` Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 24/49] inetutils: Disable rsh, rcp, rlogin on musl Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 25/49] ssmtp: Add recipe Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 26/49] ne10: Update to latest Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 27/49] libgit2: Update to 0.24.3 Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 28/49] openldap: Fix Build error due to missing -fPIC Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 29/49] dante: Add recipe for 1.4.1 Khem Raj
2016-11-26  0:16   ` Martin Jansa
2016-11-26  6:03     ` Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 30/49] networkmanager-openvpn: Update 1.0.8->1.2.6 Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 31/49] openobex,obexftp: Update recipes Khem Raj
2016-11-26  0:17   ` Martin Jansa
2016-11-26  4:57     ` Khem Raj
2016-11-26  6:02       ` Khem Raj
2016-11-26  9:08         ` Martin Jansa
2016-11-28 19:38           ` Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 32/49] md5deep: Fix build with clang Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 33/49] dialog: Update 1.3-20160424 -> 1.3-20160828 Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 34/49] ipsec-tools: Fix build with clang Khem Raj
2016-11-23  9:21 ` [meta-networking][PATCH 35/49] crda: " Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 36/49] obex-data-server: Fix build with new openobex version Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 37/49] flashrom: Remove redundant const qualifier Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 38/49] fribidi: Fix build with security flags turned on Khem Raj
2016-11-23  9:21 ` [meta-oe][PATCH 39/49] libmicrohttpd: Upgrade to 0.9.52 Khem Raj
2016-11-23  9:22 ` [meta-oe][PATCH 40/49] jsoncpp: Add new recipe Khem Raj
2016-11-28 10:46   ` Piotr Lewicki
2016-11-28 21:10     ` Khem Raj
2016-11-23  9:22 ` Khem Raj [this message]
2016-11-23  9:22 ` [meta-oe][PATCH 42/49] libmad: Fix build with clang Khem Raj
2016-11-23  9:22 ` [meta-oe][PATCH 43/49] modemmanager: " Khem Raj
2016-11-23  9:22 ` [meta-oe][PATCH 44/49] libcec: Add missing dep on ncurses Khem Raj
2016-11-23  9:22 ` [meta-multimedia][PATCH 45/49] kodi-17: Update to latest Khem Raj
2016-11-23  9:22 ` [meta-multimedia][PATCH 46/49] tvheadend: Update to 4.0.9 Khem Raj
2016-11-26  0:18   ` Martin Jansa
2016-11-26  4:56     ` Khem Raj
2016-11-23  9:22 ` [meta-networking][PATCH 47/49] memcached: Update to 1.4.33 Khem Raj
2016-11-23  9:22 ` [meta-multimedia][PATCH 48/49] vlc: Add packageconfig for vdpau Khem Raj
2016-11-23  9:22 ` [meta-oe][PATCH 49/49] mpv: Add libvdpau to DEPENDS Khem Raj

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161123092209.23699-41-raj.khem@gmail.com \
    --to=raj.khem@gmail.com \
    --cc=openembedded-devel@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox