[packages/dbh] - added bsd patch (fixes BSD configure check to get proper mandir on Linux) - package manuals, gtk-d
qboosh
qboosh at pld-linux.org
Wed Jan 15 19:21:51 CET 2014
commit 6923bdb8a475833c97d57755a8a78e9f2a54f44d
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Wed Jan 15 19:22:49 2014 +0100
- added bsd patch (fixes BSD configure check to get proper mandir on Linux)
- package manuals, gtk-doc API documentation moved to -apidocs package
dbh-bsd.patch | 11 +++++++++++
dbh.spec | 49 ++++++++++++++++++++++++++++++++++++-------------
2 files changed, 47 insertions(+), 13 deletions(-)
---
diff --git a/dbh.spec b/dbh.spec
index 6087fdb..0495ab2 100644
--- a/dbh.spec
+++ b/dbh.spec
@@ -9,12 +9,14 @@ Version: 5.0.7
Release: 1
License: LGPL
Group: Libraries
-Source0: http://dl.sourceforge.net/dbh/%{name}-%{version}.tar.gz
+Source0: http://downloads.sourceforge.net/dbh/%{name}-%{version}.tar.gz
# Source0-md5: 15e1bd22aca735415dfb5ec60f48181b
Patch0: am.patch
+Patch1: %{name}-bsd.patch
URL: http://dbh.sourceforge.net/
BuildRequires: autoconf >= 2.52
BuildRequires: automake
+BuildRequires: gtk-doc >= 1.15
BuildRequires: libtool
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -61,9 +63,21 @@ Disk based hash static library.
%description static -l pl.UTF-8
Statyczna biblioteka dbh.
+%package apidocs
+Summary: API documentation for dbh library
+Summary(pl.UTF-8): Dokumentacja API biblioteki dbh
+Group: Documentation
+
+%description apidocs
+API documentation for dbh library.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API biblioteki dbh.
+
%prep
%setup -q
%patch0 -p1
+%patch1 -p1
%build
%{__libtoolize}
@@ -72,7 +86,8 @@ Statyczna biblioteka dbh.
%{__autoheader}
%{__automake}
%configure \
- %{!?with_static_libs:--disable-static}
+ %{!?with_static_libs:--disable-static} \
+ --without-examples
%{__make}
@@ -83,9 +98,12 @@ install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
-cd examples
-install filesystem.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
-install simple_hash.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+cp -p examples/{filesystem,simple_hash}.c $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
+
+# belongs to man3
+%{__mv} $RPM_BUILD_ROOT%{_mandir}/man1/dbh.h.1 $RPM_BUILD_ROOT%{_mandir}/man3/dbh.h.3
+# just a copy of dbh.h.1, useless
+%{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/dbh.1
%clean
rm -rf $RPM_BUILD_ROOT
@@ -95,21 +113,26 @@ rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%doc AUTHORS ChangeLog
-%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
-%attr(755,root,root) %ghost %{_libdir}/lib*.so.0
+%doc AUTHORS ChangeLog NEWS
+%attr(755,root,root) %{_libdir}/libdbh2.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libdbh2.so.0
%files devel
%defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/lib*.so
-%{_gtkdocdir}/dbh
-%{_libdir}/lib*.la
+%attr(755,root,root) %{_libdir}/libdbh2.so
+%{_libdir}/libdbh2.la
%{_includedir}/dbh
-%{_pkgconfigdir}/*.pc
+%{_pkgconfigdir}/dbh2.pc
%{_examplesdir}/%{name}-%{version}
+%{_mandir}/man3/dbh.h.3*
+%{_mandir}/man3/dbh_*.3*
%if %{with static_libs}
%files static
%defattr(644,root,root,755)
-%{_libdir}/lib*.a
+%{_libdir}/libdbh2.a
%endif
+
+%files apidocs
+%defattr(644,root,root,755)
+%{_gtkdocdir}/dbh
diff --git a/dbh-bsd.patch b/dbh-bsd.patch
new file mode 100644
index 0000000..401ed8b
--- /dev/null
+++ b/dbh-bsd.patch
@@ -0,0 +1,11 @@
+--- dbh-5.0.7/configure.ac.orig 2013-07-18 22:55:37.000000000 +0200
++++ dbh-5.0.7/configure.ac 2014-01-14 22:00:51.501153224 +0100
+@@ -161,7 +161,7 @@
+
+ ac_uname_s=`uname -s`
+ echo "system: $ac_uname_s"
+-AM_CONDITIONAL(WANT_FREEBSD, [test "$ac_uname_s"=FreeBSD || "$ac_uname_s"=OpenBSD])
++AM_CONDITIONAL(WANT_FREEBSD, [test "$ac_uname_s" = FreeBSD -o "$ac_uname_s" = OpenBSD])
+
+ AC_CHECK_LIB([pthread],[pthread_create])
+ AC_CHECK_LIB([pthread],[pthread_cond_signal],[ac_pthread_ok=yes],[ac_pthread_ok=no])
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/dbh.git/commitdiff/6923bdb8a475833c97d57755a8a78e9f2a54f44d
More information about the pld-cvs-commit
mailing list