diff --git a/.gitignore b/.gitignore index 8f13bf1..abf536a 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ clog /rabbitmq-c-0.5.1.tar.gz /rabbitmq-c-0.5.2.tar.gz /rabbitmq-c-0.6.0.tar.gz +/rabbitmq-c-0.7.0-4dde30c.tar.gz diff --git a/librabbitmq.spec b/librabbitmq.spec index e57d078..513e616 100644 --- a/librabbitmq.spec +++ b/librabbitmq.spec @@ -1,4 +1,4 @@ -# spec file for librabbitmq +# Fedora spec file for librabbitmq # # Copyright (c) 2012-2015 Remi Collet # License: CC-BY-SA @@ -7,20 +7,24 @@ # Please, preserve the changelog entries # -%global libname librabbitmq -%global soname 4 +%global gh_commit 4dde30ce8d984edda540349f57eb7995a87ba9de +%global gh_short %(c=%{gh_commit}; echo ${c:0:7}) +%global gh_owner alanxz +%global gh_project rabbitmq-c +%global libname librabbitmq +%global soname 4 -Name: librabbitmq +Name: %{libname} Summary: Client library for AMQP -Version: 0.6.0 -Release: 2%{?dist} +Version: 0.7.0 +Release: 1%{?dist} License: MIT Group: System Environment/Libraries URL: https://github.com/alanxz/rabbitmq-c -Source0: https://github.com/alanxz/rabbitmq-c/releases/download/v%{version}/rabbitmq-c-%{version}.tar.gz +Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{gh_project}-%{version}-%{gh_short}.tar.gz -BuildRequires: libtool +BuildRequires: cmake > 2.8 BuildRequires: openssl-devel # For tools BuildRequires: popt-devel @@ -60,22 +64,17 @@ amqp-publish Publish a message on an AMQP server %prep -%setup -q -n rabbitmq-c-%{version} +%setup -q -n %{gh_project}-%{gh_commit} # Copy sources to be included in -devel docs. cp -pr examples Examples %build -autoreconf -i -%configure \ - --enable-tools \ - --enable-docs \ - --with-ssl=openssl - -# rpath removal -sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool -sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool +# static lib required for tests +%cmake \ + -DBUILD_TOOLS_DOCS:BOOL=ON \ + -DBUILD_STATIC_LIBS:BOOL=ON make %{_smp_mflags} @@ -83,7 +82,7 @@ make %{_smp_mflags} %install make install DESTDIR="%{buildroot}" -rm %{buildroot}%{_libdir}/%{libname}.la +rm %{buildroot}%{_libdir}/%{libname}.a %check @@ -91,8 +90,7 @@ rm %{buildroot}%{_libdir}/%{libname}.la grep @ %{buildroot}%{_libdir}/pkgconfig/librabbitmq.pc && exit 1 : upstream tests -export LD_LIBRARY_PATH=%{buildroot}%{_libdir} -make check +make test %post -p /sbin/ldconfig @@ -120,6 +118,11 @@ make check %changelog +* Fri Jul 3 2015 Remi Collet - 0.7.0-1 +- update to 0.7.0 +- swicth to cmake +- switch from upstream tarball to github sources + * Wed Jun 17 2015 Fedora Release Engineering - 0.6.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild diff --git a/sources b/sources index 96e04e5..b9d6646 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -80b350ce0de3f44cbd7b501bbbd8daf3 rabbitmq-c-0.6.0.tar.gz +ebb34c7f395490c4a24808c5410556f6 rabbitmq-c-0.7.0-4dde30c.tar.gz