[packages/socket.io-client-cpp] - new

qboosh qboosh at pld-linux.org
Sat Mar 2 21:02:34 CET 2024


commit 61988a8061efef646ba7dc0fe84a357605f7c8fe
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sat Mar 2 20:51:19 2024 +0100

    - new

 socket.io-client-cpp-pld.patch | 12 ++++++
 socket.io-client-cpp.spec      | 95 ++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 107 insertions(+)
---
diff --git a/socket.io-client-cpp.spec b/socket.io-client-cpp.spec
new file mode 100644
index 0000000..bba39f4
--- /dev/null
+++ b/socket.io-client-cpp.spec
@@ -0,0 +1,95 @@
+Summary:	Socket.IO C++ Client library
+Summary(pl.UTF-8):	Biblioteka kliencka Socket.IO dla C++
+Name:		socket.io-client-cpp
+Version:	3.1.0
+Release:	1
+License:	MIT
+Group:		Libraries
+#Source0Download: https://github.com/socketio/socket.io-client-cpp/releases
+Source0:	https://github.com/socketio/socket.io-client-cpp/archive/%{version}/socket.io-client-cpp-%{version}.tar.gz
+# Source0-md5:	942f8b519ec411cde08772f3cf83dd1e
+Patch0:		socket.io-client-cpp-pld.patch
+URL:		https://github.com/socketio/socket.io-client-cpp
+BuildRequires:	asio-devel
+BuildRequires:	cmake >= 2.8
+BuildRequires:	libstdc++-devel >= 6:4.7
+BuildRequires:	openssl-devel
+BuildRequires:	rapidjson-devel
+BuildRequires:	rpmbuild(macros) >= 1.605
+BuildRequires:	websocketpp-devel
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Socket.IO C++ Client library. Features:
+- 100% written in modern C++11
+- Binary support
+- Automatic JSON encoding
+- Multiplex support
+- Similar API to the Socket.IO JS client
+- Cross platform
+
+%description -l pl.UTF-8
+Biblioteka klienta Socket.IO C++. Cechy:
+- napisana w 100% we współczesnym C++11
+- obsługa trybu binarnego
+- automatyczne kodowanie JSON
+- obsługa multipleksowania
+- API podobne do klienta Socket.IO dla JS
+- wieloplatformowość
+
+%package devel
+Summary:	Header files for Socket.IO C++ Client library
+Summary(pl.UTF-8):	Pliki nagłówkowe biblioteki klienta Socket.IO dla C++
+Group:		Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+Requires:	libstdc++-devel >= 6:4.7
+
+%description devel
+Header files for Socket.IO C++ Client library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki klienta Socket.IO dla C++.
+
+%prep
+%setup -q -n socket.io-client-cpp-%{version}
+%patch0 -p1
+
+%build
+install -d build
+cd build
+%cmake ..
+
+%{__make}
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} -C build install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+cp -pr examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post	-p /sbin/ldconfig
+%postun	-p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc CHANGELOG.md LICENSE README.md
+%attr(755,root,root) %{_libdir}/libsioclient.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsioclient.so.1
+%attr(755,root,root) %{_libdir}/libsioclient_tls.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libsioclient_tls.so.1
+
+%files devel
+%defattr(644,root,root,755)
+%doc API.md
+%attr(755,root,root) %{_libdir}/libsioclient.so
+%attr(755,root,root) %{_libdir}/libsioclient_tls.so
+%{_includedir}/sio_client.h
+%{_includedir}/sio_message.h
+%{_includedir}/sio_socket.h
+%{_examplesdir}/%{name}-%{version}
diff --git a/socket.io-client-cpp-pld.patch b/socket.io-client-cpp-pld.patch
new file mode 100644
index 0000000..315028b
--- /dev/null
+++ b/socket.io-client-cpp-pld.patch
@@ -0,0 +1,12 @@
+--- socket.io-client-cpp-3.1.0/CMakeLists.txt.orig	2021-10-12 10:24:29.000000000 +0200
++++ socket.io-client-cpp-3.1.0/CMakeLists.txt	2024-03-02 20:02:42.791681417 +0100
+@@ -11,9 +11,6 @@ set(PATCH 0)
+ if(NOT CMAKE_BUILD_TYPE )
+ MESSAGE(STATUS "not define build type, set to release" )
+ set(CMAKE_BUILD_TYPE Release )
+-elseif(NOT (${CMAKE_BUILD_TYPE} STREQUAL "Release" OR ${CMAKE_BUILD_TYPE} STREQUAL "Debug" ))
+-MESSAGE(SEND_ERROR "CMAKE_BUILD_TYPE must be either Release or Debug")
+-return()
+ endif()
+ 
+ aux_source_directory(${CMAKE_CURRENT_LIST_DIR}/src ALL_SRC)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/socket.io-client-cpp.git/commitdiff/61988a8061efef646ba7dc0fe84a357605f7c8fe



More information about the pld-cvs-commit mailing list