]> git.pld-linux.org Git - packages/mdds.git/commitdiff
- updated to 1.0.0 (now with versioned API, currently 1.0) auto/th/mdds-1.0.0-1
authorJakub Bogusz <qboosh@pld-linux.org>
Sun, 29 Nov 2015 15:22:25 +0000 (16:22 +0100)
committerJakub Bogusz <qboosh@pld-linux.org>
Sun, 29 Nov 2015 15:22:25 +0000 (16:22 +0100)
- added doc patch, build apidocs

mdds-doc.patch [new file with mode: 0644]
mdds.spec

diff --git a/mdds-doc.patch b/mdds-doc.patch
new file mode 100644 (file)
index 0000000..f2f8a38
--- /dev/null
@@ -0,0 +1,11 @@
+--- mdds_1.0.0/Makefile.in.orig        2015-10-07 00:57:07.000000000 +0200
++++ mdds_1.0.0/Makefile.in     2015-11-29 15:52:19.781596214 +0100
+@@ -237,7 +237,7 @@
+ build-doc-sphinx:
+       @echo "Building documentation by sphinx..."
+-      @sphinx-build -b html ./doc/ ./doc/_build
++      cd doc && sphinx-build -b html ./ ./_build
+ build-doc: build-doc-doxygen build-doc-sphinx
index 265b7ff4b3ee5dc9d9d418a3555fc817d9ffd567..1d34b93d4ed26751229de974138564729bc718e6 100644 (file)
--- a/mdds.spec
+++ b/mdds.spec
@@ -1,18 +1,29 @@
+#
+# Conditional build:
+%bcond_without apidocs # doxygen/sphinx+breathe API documentation
+#
 Summary:       A collection of multi-dimensional data structures and indexing algorithms
 Summary(pl.UTF-8):     Zbiór struktur danych wielowymiarowych oraz algorytmów indeksujących
 Name:          mdds
-Version:       0.12.1
+Version:       1.0.0
 Release:       1
 License:       MIT
 Group:         Development/Libraries
 #Source0Download: https://gitlab.com/mdds/mdds
 Source0:       http://kohei.us/files/mdds/src/%{name}_%{version}.tar.bz2
-# Source0-md5: ef2560ed5416652a7fe195305b14cebe
+# Source0-md5: 74e0a81c5af4137285fe6a52217f71e4
+Patch0:                %{name}-doc.patch
 URL:           https://gitlab.com/mdds/mdds
 BuildRequires: autoconf >= 2.50
 BuildRequires: boost-devel >= 1.39
+BuildRequires: libstdc++-devel >= 6:4.7
 BuildRequires: rpmbuild(macros) >= 1.446
 BuildRequires: sed >= 4.0
+%if %{with apidocs}
+BuildRequires: doxygen
+BuildRequires: python-sphinx_bootstrap_theme
+BuildRequires: sphinx-pdg
+%endif
 BuildArch:     noarch
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
@@ -41,6 +52,7 @@ Summary:      A collection of multi-dimensional data structures and indexing algorith
 Summary(pl.UTF-8):     Zbiór struktur danych wielowymiarowych oraz algorytmów indeksujących
 Group:         Development/Libraries
 Requires:      boost-devel >= 1.39
+Requires:      libstdc++-devel >= 6:4.7
 
 %description devel
 A collection of multi-dimensional data structures and indexing
@@ -62,30 +74,49 @@ Zaimplementowane są następujące struktury danych:
 - drzewo czwórkowe (quadtree) dla punktów
 - macierz mieszana
 
+%package apidocs
+Summary:       API documentation for MDDS
+Summary(pl.UTF-8):     Dokumentacja API biblioteki MDDS
+Group:         Documentation
+
+%description apidocs
+API documentation for MDDS.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API biblioteki MDDS.
+
 %prep
 %setup -q -n %{name}_%{version}
+%patch0 -p1
 
 # this is only used in tests
-sed -i -e '/^CPPFLAGS_NODEBUG/s/-Wall -Os -g/%{rpmcflags} -Wall/' configure.ac
+sed -i -e '/^CPPFLAGS=/s/-Os -g /%{rpmcflags} /' configure.ac
 
 %build
 %{__autoconf}
-# we can switch from boost to c++0x (the default) if sufficiently new C++11 compliant g++ is enforced
-%configure \
-       --with-hash-container=boost
-%{__make}
+%configure
+
+%{__make} all %{?with_apidocs:build-doc} \
+       CXX="%{__cxx}"
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_includedir}/mdds
-cp -a include/mdds/* $RPM_BUILD_ROOT%{_includedir}/mdds
-install -Dp misc/mdds.pc $RPM_BUILD_ROOT%{_npkgconfigdir}/mdds.pc
+
+%{__make} install \
+       DESTDIR=$RPM_BUILD_ROOT
+
+# packaged as %doc
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/mdds-1.0
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %files devel
 %defattr(644,root,root,755)
-%doc AUTHORS COPYING NEWS README
-%{_includedir}/mdds
-%{_npkgconfigdir}/mdds.pc
+%doc AUTHORS CHANGELOG LICENSE README.md
+%{_includedir}/mdds-1.0
+%{_npkgconfigdir}/mdds-1.0.pc
+
+%files apidocs
+%defattr(644,root,root,755)
+%doc doc/html doc/_build/{_static,*.html,*.js}
This page took 0.058518 seconds and 4 git commands to generate.