diff options
author | Remi Collet <fedora@famillecollet.com> | 2016-03-15 16:12:40 +0100 |
---|---|---|
committer | Remi Collet <fedora@famillecollet.com> | 2016-03-15 16:12:40 +0100 |
commit | 4455e7515bf6701b67883ff1ec7c4d4fcb6dc6d9 (patch) | |
tree | 87f6a679a0ccc283eeafc8d24a56864fccad8f8d | |
parent | d5d5286665dd5e7758c9fbfb19d6bffac2fe6b27 (diff) |
libbson: 1.3.4 using Fedora spec file
-rw-r--r-- | libbson-1.3.1-Install-documentation-according-to-guidelines.patch | 31 | ||||
-rw-r--r-- | libbson.spec | 168 |
2 files changed, 140 insertions, 59 deletions
diff --git a/libbson-1.3.1-Install-documentation-according-to-guidelines.patch b/libbson-1.3.1-Install-documentation-according-to-guidelines.patch new file mode 100644 index 0000000..d738035 --- /dev/null +++ b/libbson-1.3.1-Install-documentation-according-to-guidelines.patch @@ -0,0 +1,31 @@ +From d2699d4d0e6cac7fe294f1c6ab3995f803ddec8f Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com> +Date: Fri, 22 Jan 2016 14:42:45 +0100 +Subject: [PATCH] Install documentation according to guidelines +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +We put COPYING into different directory. + +Signed-off-by: Petr Písař <ppisar@redhat.com> +--- + Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile.am b/Makefile.am +index b281d54..b2ff071 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -27,7 +27,7 @@ DISTCHECK_CONFIGURE_FLAGS = --enable-maintainer-flags --enable-silent-rules --en + + bsondocdir = ${docdir} + bsondoc_DATA = \ +- COPYING \ ++ ChangeLog \ + NEWS \ + README + +-- +2.5.0 + diff --git a/libbson.spec b/libbson.spec index fb79f5e..7aa0b23 100644 --- a/libbson.spec +++ b/libbson.spec @@ -1,99 +1,149 @@ -# remirepo spec file for libbson +# remirepo spec file for libbson, from # -# Copyright (c) 2015-2016 Remi Collet -# License: CC-BY-SA -# http://creativecommons.org/licenses/by-sa/4.0/ +# Fedora spec file for libbson +# +# License: MIT +# http://opensource.org/licenses/MIT # # Please, preserve the changelog entries # -%global gh_owner mongodb -%global gh_project libbson -%global libver 1.0 -#global prever rc0 -%global with_tests %{?_without_tests:0}%{!?_without_tests:1} - -# TODO bundled yajl version 2.0.4 -# See https://jira.mongodb.org/browse/CDRIVER-623 - -Name: libbson -Summary: Library to build, parse, and iterate BSON documents -Version: 1.3.3 -Release: 1%{?dist} -License: ASL 2.0 -Group: System Environment/Libraries -URL: https://github.com/%{gh_owner}/%{gh_project} -Source0: https://github.com/%{gh_owner}/%{gh_project}/releases/download/%{version}%{?prever:-%{prever}}/%{gh_project}-%{version}%{?prever:-%{prever}}.tar.gz - -BuildRequires: python +Name: libbson +Version: 1.3.4 +Release: 1%{?dist} +Summary: Building, parsing, and iterating BSON documents +Group: System Environment/Libraries +## Installed: +# COPYING: ASL 2.0 +# src/bson/b64_ntop.h: ISC and MIT +# src/bson/b64_pton.h: ISC and MIT +# src/bson/bson-md5.h: zlib +# src/yajl/yajl_alloc.h: ISC +# doc/man/bson_iter_symbol.3: GFDL +## Not installed: +# configure: FSFUL +# aclocal.m4: FSFULLR +# Makefile.in: FSFULLR +# build/autotools/depcomp: GPLv2+ with exceptions +# build/autotools/ltmain.sh: GPLv2+ with exceptions +# build/autotools/m4/ax_pthread.m4 GPLv3+ with exception +# build/autotools/install-sh: MIT and Public Domain +# doc/html/jquery.js: (MIT or GPLv2) and (MIT, BSD GPL) +# doc/html/jquery.syntax.js: MIT +# doc/mallard2man.py: GPLv3+ +# src/bson/bson-stdint-win32.h: BSD +License: ASL 2.0 and ISC and MIT and zlib +URL: https://github.com/mongodb/%{name} +Source0: %{url}/releases/download/%{version}/%{name}-%{version}.tar.gz +# Do not install COPYING, install ChangeLog, distribution specific +Patch0: %{name}-1.3.1-Install-documentation-according-to-guidelines.patch +BuildRequires: autoconf +BuildRequires: automake +BuildRequires: gcc +BuildRequires: libtool +BuildRequires: python +# Modified yajl-2.0.4 is bundled, waiting on yajl upstream to merge libbson's +# changes, <https://github.com/lloyd/yajl/issues/161>, +# <https://jira.mongodb.org/browse/CDRIVER-601>, bug #1215182 +Provides: bundled(yajl) = 2.0.4 %description -%{name} is a library providing useful routines related to building, -parsing, and iterating BSON documents. It is a useful base for those -wanting to write high-performance C extensions to higher level -languages such as python, ruby, or perl. - +This is a library providing useful routines related to building, parsing, +and iterating BSON documents <http://bsonspec.org/>. %package devel -Summary: Header files and development libraries for %{name} +Summary: Development files for %{name} Group: Development/Libraries +License: ASL 2.0 and GFDL Requires: %{name}%{?_isa} = %{version}-%{release} +# gcc for standard library header files +Requires: gcc%{?_isa} Requires: pkgconfig - %description devel -This package contains the header files and development libraries -for %{name}. - - +This package contains libraries and header files needed for developing +applications that use %{name}. %prep -%setup -q -n %{gh_project}-%{version}%{?prever:-%{prever}} - +%setup -q -%build -%configure --enable-man-pages +# Generate build scripts from sources +%if 0%{?fedora} >= 20 || 0%{?rhel} >= 7 +%patch0 -p1 +autoreconf --force --install +%endif -make %{_smp_mflags} V=1 +%build +%configure \ + --disable-coverage \ + --disable-debug \ + --disable-debug-symbols \ + --enable-extra-align \ + --disable-hardening \ + --disable-html-docs \ + --enable-ld-version-script \ + --disable-lto \ + --disable-maintainer-flags \ + --enable-man-pages \ + --disable-optimizations \ + --enable-shared \ + --disable-silent-rules \ + --disable-static \ + --disable-yelp +make %{?_smp_mflags} %install make install DESTDIR=%{buildroot} -make install-man DESTDIR=%{buildroot} - -rm %{buildroot}%{_libdir}/*la -rm -r %{buildroot}%{_datadir}/doc - -# drop "generic" man pages, avoid conflicts -# https://jira.mongodb.org/browse/CDRIVER-1039 -rm %{buildroot}/%{_mandir}/man3/[c-v]* +find %{buildroot} -name '*.la' -exec rm -f '{}' + +# Move ambiguously named manual pages into package-specific directory +# <https://jira.mongodb.org/browse/CDRIVER-1039> +install -d -m 0755 %{buildroot}%{_docdir}/%{name}-devel +for P in clock creating endianness errors index installing json memory \ + oid parsing performance threading utf8 version; do + mv %{buildroot}%{_mandir}/man3/"$P".3 %{buildroot}%{_docdir}/%{name}-devel +done +# Install examples here because it's forbidden to use relative %%doc with +# installing into %%_pkgdocdir +install -d -m 0755 %{buildroot}%{_docdir}/%{name}-devel/examples +install -m 0644 -t %{buildroot}%{_docdir}/%{name}-devel/examples examples/*.c + +%if 0%{?fedora} < 20 && 0%{?rhel} < 7 +rm -f %{buildroot}%{_docdir}/%{name}/COPYING +install -d Changelog %{buildroot}%{_docdir}/%{name}/Changelog +%endif %check -: Run test suite -make check - +make %{?_smp_mflags} check -%post -p /sbin/ldconfig +%post -p /sbin/ldconfig %postun -p /sbin/ldconfig - %files %{!?_licensedir:%global license %%doc} %license COPYING -%{_libdir}/%{name}-%{libver}.so.* - +# AUTHORS is empty, README etc. are installed by "make install" +%{_docdir}/%{name} +%{_libdir}/*.so.* %files devel -%doc NEWS README -%{_includedir}/%{name}-%{libver} -%{_libdir}/%{name}-%{libver}.so -%{_libdir}/pkgconfig/%{name}-%{libver}.pc -%{_mandir}/man3/bson* +%{_docdir}/%{name}-devel +%{_includedir}/* +%{_libdir}/*.so +%{_libdir}/pkgconfig/* +%{_mandir}/man3/* %changelog +* Tue Mar 15 2016 Remi Collet <remi@fedoraproject.org> - 1.3.4-1 +- switch to Fedora spec file +- tweak install for EL-6 (don't run autoconf) + +* Tue Mar 15 2016 Petr Pisar <ppisar@redhat.com> - 1.3.4-1 +- 1.3.4 bump + * Sun Feb 7 2016 Remi Collet <remi@fedoraproject.org> - 1.3.3-1 - Update to 1.3.3 |