%global gh_owner couchbase %global gh_commit c7dd97ab67b1c66c6c44b8576b4a35ba825a3e8e %global gh_short %(c=%{gh_commit}; echo ${c:0:7}) # Tests require some need which are downloaded during make %global with_tests %{?_with_tests:1}%{!?_with_tests:0} %if 0%{?fedora} >= 15 || 0%{?rhel} >= 6 %global with_dtrace 1 %else %global with_dtrace 0 %endif Name: libcouchbase Version: 2.3.1 Release: 1%{?dist} Summary: Couchbase client library Group: System Environment/Libraries License: ASL 2.0 URL: http://www.couchbase.com/communities/c/getting-started #Source0: http://packages.couchbase.com/clients/c/%{name}-%{version}.tar.gz Source0: https://github.com/%{gh_owner}/%{name}/archive/%{gh_commit}/%{name}-%{version}-%{gh_short}.tar.gz %if %{with_tests} # grep DOWNLOAD Makefile.am Source10: http://googletest.googlecode.com/files/gtest-1.7.0-rc1.zip Source11: http://files.couchbase.com/maven2/org/couchbase/mock/CouchbaseMock/0.7-SNAPSHOT/CouchbaseMock-0.7-20140129.023144-1.jar %endif BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: libtool BuildRequires: cyrus-sasl-devel %if "%{?vendor}" == "Remi Collet" # ensure we use latest version (libevent-last) BuildRequires: libevent-devel >= 2.0.20 %else BuildRequires: libevent-devel >= 1.4 %endif BuildRequires: libev-devel %if %{with_dtrace} BuildRequires: systemtap-sdt-devel >= 1.8 %endif %description The C library provides fast access to documents in Couchbase Server 2.0. With JSON documents and Couchbase server 2.0 you have new ways to index and query data stored in the cluster through views. This client library, libcouchbase, also simplifies requests to Views through its handling of HTTP transport. This Couchbase Client Library for C and C++ provides a complete interface to the functionality of Couchbase Server. %package devel Summary: Development files for Couchbase client library Group: Development/Libraries Requires: %{name}%{?_isa} = %{version}-%{release} %description devel The %{name}-devel package contains libraries and header files for developing applications that use %{name}. %package tools Summary: Couchbase tools Group: Applications/System Requires: %{name}%{?_isa} = %{version}-%{release} %description tools The %{name}-tools package contains some command line tools to manage a Couchbase Server. %prep %setup -qn %{name}-%{gh_commit} cat < - 2.3.1-1 - update to 2.3.1 - always use libevent 2 * Sat Oct 5 2013 Remi Collet - 2.1.3-1 - update to 2.1.3 * Sun Apr 14 2013 Remi Collet - 2.0.5-1 - Initial package