[packages/libverto-jsonrpc] - new

qboosh qboosh at pld-linux.org
Sun Feb 19 10:11:45 CET 2017


commit 98d3769c403bc4ea8827702cc89c2366b45bc4e2
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun Feb 19 10:13:26 2017 +0100

    - new

 libverto-jsonrpc-json.patch |  22 ++++++++++
 libverto-jsonrpc.spec       | 103 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 125 insertions(+)
---
diff --git a/libverto-jsonrpc.spec b/libverto-jsonrpc.spec
new file mode 100644
index 0000000..b5521b2
--- /dev/null
+++ b/libverto-jsonrpc.spec
@@ -0,0 +1,103 @@
+#
+# Conditional build:
+%bcond_without	static_libs	# static library
+#
+Summary:	JSON-RPC support for libverto
+Summary(pl.UTF-8):	Obsługa JSON-RPC dla libverto
+Name:		libverto-jsonrpc
+Version:	0.1.0
+Release:	1
+License:	MIT
+Group:		Libraries
+Source0:	https://fedorahosted.org/releases/l/i/libverto-jsonrpc/%{name}-%{version}.tar.gz
+# Source0-md5:	5076eadc3e3b43f7139d0b8cf96e575d
+Patch0:		%{name}-json.patch
+URL:		https://fedorahosted.org/libverto/
+BuildRequires:	autoconf >= 2.59
+BuildRequires:	automake >= 1:1.11
+BuildRequires:	json-c-devel
+BuildRequires:	libtool >= 2:2
+BuildRequires:	libverto-devel >= 0.2.4
+BuildRequires:	pkgconfig
+Requires:	libverto >= 0.2.4
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+A library for doing JSON-RPC over a socket, using the libverto API.
+
+%description -l pl.UTF-8
+Biblioteka do wykonywania JSON-RPC na gnieździe przy użyciu API
+biblioteki libverto.
+
+%package devel
+Summary:	Header files for verto-jsonrpc library
+Summary(pl.UTF-8):	Pliki nagłówkowe biblioteki verto-jsonrpc
+Group:		Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+Requires:	json-c-devel
+Requires:	libverto-devel >= 0.2.4
+
+%description devel
+Header files for verto-jsonrpc library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki verto-jsonrpc.
+
+%package static
+Summary:	Static verto-jsonrpc library
+Summary(pl.UTF-8):	Statyczna biblioteka verto-jsonrpc
+Group:		Development/Libraries
+Requires:	%{name}-devel = %{version}-%{release}
+
+%description static
+Static verto-jsonrpc library.
+
+%description static -l pl.UTF-8
+Statyczna biblioteka verto-jsonrpc.
+
+%prep
+%setup -q
+%patch0 -p1
+
+%build
+%{__libtoolize}
+%{__aclocal} -I m4
+%{__autoconf}
+%{__automake}
+%configure \
+	--disable-silent-rules \
+	%{?with_static_libs:--enable-static}
+%{__make}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+# obsoleted by pkg-config
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/libverto-jsonrpc.la
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post	-p /sbin/ldconfig
+%postun	-p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc AUTHORS ChangeLog README
+%attr(755,root,root) %{_libdir}/libverto-jsonrpc.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libverto-jsonrpc.so.0
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libverto-jsonrpc.so
+%{_includedir}/verto-jsonrpc.h
+%{_pkgconfigdir}/libverto-jsonrpc.pc
+
+%if %{with static_libs}
+%files static
+%defattr(644,root,root,755)
+%{_libdir}/libverto-jsonrpc.a
+%endif
diff --git a/libverto-jsonrpc-json.patch b/libverto-jsonrpc-json.patch
new file mode 100644
index 0000000..b676259
--- /dev/null
+++ b/libverto-jsonrpc-json.patch
@@ -0,0 +1,22 @@
+--- libverto-jsonrpc-0.1.0/configure.ac.orig	2012-02-10 07:25:55.357213235 +0100
++++ libverto-jsonrpc-0.1.0/configure.ac	2017-02-19 08:11:59.670195112 +0100
+@@ -20,7 +20,7 @@
+ # Init compiler
+ AC_PROG_CC_STDC
+ 
+-PKG_CHECK_MODULES([JSON], [json], [], [AC_MSG_ERROR("json not found!")])
++PKG_CHECK_MODULES([JSON], [json-c], [], [AC_MSG_ERROR("json not found!")])
+ PKG_CHECK_MODULES([VERTO], [libverto], [], [AC_MSG_ERROR("libverto not found!")])
+ 
+ # Output
+--- libverto-jsonrpc-0.1.0/src/verto-jsonrpc.h.orig	2012-01-30 17:47:02.300293406 +0100
++++ libverto-jsonrpc-0.1.0/src/verto-jsonrpc.h	2017-02-19 08:40:06.410175852 +0100
+@@ -26,7 +26,7 @@
+ #define JSONRPC_H_
+ 
+ #include <verto.h>
+-#include <json/json.h>
++#include <json.h>
+ #include <stdbool.h>
+ 
+ #define JSONRPC_ERRCODE_INVALID_REQUEST  -32600
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/libverto-jsonrpc.git/commitdiff/98d3769c403bc4ea8827702cc89c2366b45bc4e2



More information about the pld-cvs-commit mailing list