update to 0.11.0
add patch to not install the static library, from https://github.com/alanxz/rabbitmq-c/pull/665
This commit is contained in:
parent
b6e910fef3
commit
f94a78763b
1
.gitignore
vendored
1
.gitignore
vendored
@ -14,3 +14,4 @@ clog
|
||||
/rabbitmq-c-0.8.0-caad0ef.tar.gz
|
||||
/rabbitmq-c-0.9.0-77e3805.tar.gz
|
||||
/rabbitmq-c-0.10.0-ffe918a.tar.gz
|
||||
/rabbitmq-c-0.11.0-a64c08c.tar.gz
|
||||
|
@ -1,13 +1,15 @@
|
||||
# Fedora spec file for librabbitmq
|
||||
#
|
||||
# Copyright (c) 2012-2020 Remi Collet
|
||||
# Copyright (c) 2012-2021 Remi Collet
|
||||
# License: CC-BY-SA
|
||||
# http://creativecommons.org/licenses/by-sa/4.0/
|
||||
#
|
||||
# Please, preserve the changelog entries
|
||||
#
|
||||
|
||||
%global gh_commit ffe918a5fcef72038a88054dca3c56762b1953d4
|
||||
%bcond_without tests
|
||||
|
||||
%global gh_commit a64c08c68aff34d49a2ac152f04988cd921084f9
|
||||
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
|
||||
%global gh_owner alanxz
|
||||
%global gh_project rabbitmq-c
|
||||
@ -16,13 +18,16 @@
|
||||
|
||||
Name: %{libname}
|
||||
Summary: Client library for AMQP
|
||||
Version: 0.10.0
|
||||
Release: 4%{?dist}
|
||||
Version: 0.11.0
|
||||
Release: 1%{?dist}
|
||||
License: MIT
|
||||
URL: https://github.com/alanxz/rabbitmq-c
|
||||
|
||||
Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz
|
||||
|
||||
# don't install static library
|
||||
Patch0: %{gh_project}-static.patch
|
||||
|
||||
BuildRequires: gcc
|
||||
BuildRequires: cmake > 2.8
|
||||
BuildRequires: openssl-devel
|
||||
@ -64,6 +69,7 @@ amqp-publish Publish a message on an AMQP server
|
||||
|
||||
%prep
|
||||
%setup -q -n %{gh_project}-%{gh_commit}
|
||||
%patch0 -p1
|
||||
|
||||
# Copy sources to be included in -devel docs.
|
||||
cp -pr examples Examples
|
||||
@ -76,7 +82,12 @@ sed -e '/test_basic/d' -i tests/CMakeLists.txt
|
||||
# static lib required for tests
|
||||
%cmake \
|
||||
-DBUILD_TOOLS_DOCS:BOOL=ON \
|
||||
-DBUILD_STATIC_LIBS:BOOL=ON \
|
||||
%if %{with tests}
|
||||
-DINSTALL_STATIC_LIBS:BOOL=OFF \
|
||||
%else
|
||||
-DBUILD_TESTS:BOOL=OFF \
|
||||
-DBUILD_STATIC_LIBS:BOOL=OFF \
|
||||
%endif
|
||||
-S .
|
||||
|
||||
%if 0%{?cmake_build:1}
|
||||
@ -93,19 +104,23 @@ make %{_smp_mflags}
|
||||
make install DESTDIR="%{buildroot}"
|
||||
%endif
|
||||
|
||||
rm %{buildroot}%{_libdir}/%{libname}.a
|
||||
|
||||
|
||||
%check
|
||||
: check .pc is usable
|
||||
grep @ %{buildroot}%{_libdir}/pkgconfig/librabbitmq.pc && exit 1
|
||||
: check cmake files are usable
|
||||
grep static %{buildroot}%{_libdir}/cmake/rabbitmq-c/*.cmake && exit 1
|
||||
|
||||
%if %{with tests}
|
||||
: upstream tests
|
||||
%if 0%{?ctest:1}
|
||||
%ctest
|
||||
%else
|
||||
make test
|
||||
%endif
|
||||
%else
|
||||
: Tests disabled
|
||||
%endif
|
||||
|
||||
|
||||
%files
|
||||
@ -119,6 +134,7 @@ make test
|
||||
%{_libdir}/%{libname}.so
|
||||
%{_includedir}/amqp*
|
||||
%{_libdir}/pkgconfig/%{libname}.pc
|
||||
%{_libdir}/cmake/rabbitmq-c
|
||||
|
||||
%files tools
|
||||
%{_bindir}/amqp-*
|
||||
@ -127,6 +143,11 @@ make test
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Apr 1 2021 Remi Collet <remi@remirepo.net> - 0.11.0-1
|
||||
- update to 0.11.0
|
||||
- add patch to not install the static library, from
|
||||
https://github.com/alanxz/rabbitmq-c/pull/665
|
||||
|
||||
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.10.0-4
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
|
41
rabbitmq-c-static.patch
Normal file
41
rabbitmq-c-static.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From a8c05cb16afbf852fc584f2c2d31d2f7f0e3a48d Mon Sep 17 00:00:00 2001
|
||||
From: Remi Collet <remi@remirepo.net>
|
||||
Date: Thu, 1 Apr 2021 11:21:36 +0200
|
||||
Subject: [PATCH] add option to install or not the static library
|
||||
|
||||
---
|
||||
CMakeLists.txt | 1 +
|
||||
librabbitmq/CMakeLists.txt | 8 +++++---
|
||||
2 files changed, 6 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index a9a29fdd..a7cf8f2c 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -245,6 +245,7 @@ endif()
|
||||
|
||||
option(BUILD_SHARED_LIBS "Build rabbitmq-c as a shared library" ON)
|
||||
option(BUILD_STATIC_LIBS "Build rabbitmq-c as a static library" ON)
|
||||
+option(INSTALL_STATIC_LIBS "Install rabbitmq-c static library" ON)
|
||||
|
||||
option(BUILD_EXAMPLES "Build Examples" ON)
|
||||
option(BUILD_TOOLS "Build Tools (requires POPT Library)" ${POPT_FOUND})
|
||||
diff --git a/librabbitmq/CMakeLists.txt b/librabbitmq/CMakeLists.txt
|
||||
index d8dcd262..72b4a875 100644
|
||||
--- a/librabbitmq/CMakeLists.txt
|
||||
+++ b/librabbitmq/CMakeLists.txt
|
||||
@@ -154,9 +154,11 @@ if (BUILD_STATIC_LIBS)
|
||||
set_target_properties(rabbitmq-static PROPERTIES VERSION ${RMQ_VERSION} SOVERSION ${RMQ_SOVERSION} OUTPUT_NAME rabbitmq)
|
||||
endif (WIN32)
|
||||
|
||||
- install(TARGETS rabbitmq-static EXPORT "${targets_export_name}"
|
||||
- ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
- )
|
||||
+ if (INSTALL_STATIC_LIBS)
|
||||
+ install(TARGETS rabbitmq-static EXPORT "${targets_export_name}"
|
||||
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
+ )
|
||||
+ endif (INSTALL_STATIC_LIBS)
|
||||
|
||||
if (NOT DEFINED RMQ_LIBRARY_TARGET)
|
||||
set(RMQ_LIBRARY_TARGET rabbitmq-static)
|
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (rabbitmq-c-0.10.0-ffe918a.tar.gz) = 05756176feffc3ccff9bf4f8416191c382c9e5b51d7dd72664cea0407c847d50cb4048b8669415d879396c0c7e8c1c38c65a66a98701e55de09afed893abc5a0
|
||||
SHA512 (rabbitmq-c-0.11.0-a64c08c.tar.gz) = 0e0c77c3ce2de49841b4d2a8745bfdb118fc3bdf924c1f60d8ca168d7a933276f5d86e1d1440c2936859e6a6bddeb77eaa3c59f5f20e998160dde7d57cea4282
|
||||
|
Loading…
Reference in New Issue
Block a user