summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt12
-rw-r--r--INSTALL.rst2
-rw-r--r--doc/biboumi.1.rst1
-rw-r--r--docker/biboumi-test/debian/Dockerfile2
-rw-r--r--docker/biboumi-test/fedora/Dockerfile2
-rw-r--r--packaging/biboumi.spec.cmake7
6 files changed, 12 insertions, 14 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index b3321cd..bb13460 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -61,15 +61,17 @@ include_directories("${CMAKE_CURRENT_BINARY_DIR}/")
#
## Documentation
#
+execute_process(COMMAND "date" "+%Y-%m-%d" OUTPUT_VARIABLE DOC_DATE
+ OUTPUT_STRIP_TRAILING_WHITESPACE)
set(MAN_PAGE ${CMAKE_CURRENT_BINARY_DIR}/doc/${PROJECT_NAME}.1)
-set(DOC_PAGE ${CMAKE_CURRENT_SOURCE_DIR}/doc/${PROJECT_NAME}.1.md)
-find_program(RONN_EXECUTABLE NAMES ronn
- DOC "The ronn software, to build the man page from the markdown documentation")
-if(RONN_EXECUTABLE)
+set(DOC_PAGE ${CMAKE_CURRENT_SOURCE_DIR}/doc/${PROJECT_NAME}.1.rst)
+find_program(PANDOC_EXECUTABLE NAMES pandoc
+ DOC "The pandoc software, to build the man page from the rst documentation")
+if(PANDOC_EXECUTABLE)
set(WITH_DOC true)
file(MAKE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/doc/)
add_custom_command(OUTPUT ${MAN_PAGE}
- COMMAND ${RONN_EXECUTABLE} --roff < ${DOC_PAGE} > ${MAN_PAGE}
+ COMMAND ${PANDOC_EXECUTABLE} -M date="${DOC_DATE}" -s -t man ${DOC_PAGE} -o ${MAN_PAGE}
DEPENDS ${DOC_PAGE})
add_custom_target(doc ALL DEPENDS ${MAN_PAGE})
endif()
diff --git a/INSTALL.rst b/INSTALL.rst
index 1e5d0f5..1526d7e 100644
--- a/INSTALL.rst
+++ b/INSTALL.rst
@@ -18,7 +18,7 @@ Tools:
- A C++14 compiler (clang >= 3.4 or gcc >= 4.9 for example)
- CMake
-- ronn (optional) to build the man page
+- pandoc (optional) to build the man page
Libraries:
~~~~~~~~~~
diff --git a/doc/biboumi.1.rst b/doc/biboumi.1.rst
index 6411efe..2a6dae3 100644
--- a/doc/biboumi.1.rst
+++ b/doc/biboumi.1.rst
@@ -4,7 +4,6 @@ Biboumi(1) User Manual
.. contents:: :depth: 2
-
NAME
====
diff --git a/docker/biboumi-test/debian/Dockerfile b/docker/biboumi-test/debian/Dockerfile
index 32f294f..fd341c5 100644
--- a/docker/biboumi-test/debian/Dockerfile
+++ b/docker/biboumi-test/debian/Dockerfile
@@ -18,7 +18,7 @@ RUN apt install -y libexpat1-dev
RUN apt install -y libidn11-dev
RUN apt install -y uuid-dev
RUN apt install -y libsystemd-dev
-RUN apt install -y ruby-ronn
+RUN apt install -y pandoc
# Needed to run tests
RUN apt install -y git
diff --git a/docker/biboumi-test/fedora/Dockerfile b/docker/biboumi-test/fedora/Dockerfile
index 704b413..853c444 100644
--- a/docker/biboumi-test/fedora/Dockerfile
+++ b/docker/biboumi-test/fedora/Dockerfile
@@ -18,7 +18,7 @@ RUN dnf install -y expat-devel
RUN dnf install -y libidn-devel
RUN dnf install -y uuid-devel
RUN dnf install -y systemd-devel
-RUN dnf install -y rubygem-ronn
+RUN dnf install -y pandoc
# Needed to run tests
RUN dnf install -y git
diff --git a/packaging/biboumi.spec.cmake b/packaging/biboumi.spec.cmake
index 08b5c6d..f38f4c4 100644
--- a/packaging/biboumi.spec.cmake
+++ b/packaging/biboumi.spec.cmake
@@ -13,7 +13,7 @@ BuildRequires: libuuid-devel
BuildRequires: systemd-devel
BuildRequires: cmake
BuildRequires: systemd
-BuildRequires: rubygem-ronn
+BuildRequires: pandoc
%global _hardened_build 1
@@ -39,9 +39,6 @@ cmake . -DCMAKE_CXX_FLAGS="%{optflags}" \
-DWITH_SYSTEMD=1 \
-DWITH_LIBIDN=1
-# The documentation is in utf-8, ronn fails to build it if that locale is
-# not specified
-export LC_ALL=en_GB.utf-8
make %{?_smp_mflags}
@@ -56,7 +53,7 @@ make check %{?_smp_mflags}
%files
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1*
-%doc README.md COPYING doc/biboumi.1.md
+%doc README.rst COPYING doc/biboumi.1.rst
%{_unitdir}/%{name}.service
%config(noreplace) %{biboumi_confdir}/biboumi.cfg