From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxim Cournoyer Subject: bug#33497: [PATCH] Re: bug#33497: Our CMake package has no documentation Date: Sun, 25 Nov 2018 01:54:55 -0500 Message-ID: <87y39h4pfk.fsf@gmail.com> References: <8736rp649l.fsf@apteryx.i-did-not-set--mail-host-address--so-tickle-me> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39361) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gQoKt-0006Jc-8X for bug-guix@gnu.org; Sun, 25 Nov 2018 01:56:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gQoKo-00079K-AU for bug-guix@gnu.org; Sun, 25 Nov 2018 01:56:07 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:41755) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gQoKo-000797-4u for bug-guix@gnu.org; Sun, 25 Nov 2018 01:56:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gQoKn-0000mb-Vk for bug-guix@gnu.org; Sun, 25 Nov 2018 01:56:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <8736rp649l.fsf@apteryx.i-did-not-set--mail-host-address--so-tickle-me> (Maxim Cournoyer's message of "Sun, 25 Nov 2018 01:49:10 -0500") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: 33497@debbugs.gnu.org --=-=-= Content-Type: text/plain Maxim Cournoyer writes: > Hello, > > Our CMake package lacks any documentation (manpage or other). Patch to > follow. > > Maxim Here's the patch to be merged in core-updates (or core-updates-next). --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-gnu-cmake-Generate-the-documentation.patch >From 07625983cd901c94e4ac25b157035c95e33a115e Mon Sep 17 00:00:00 2001 From: Maxim Cournoyer Date: Sun, 25 Nov 2018 01:39:54 -0500 Subject: [PATCH] gnu: cmake: Generate the documentation. This fixes https://bugs.gnu.org/33497. * gnu/packages/cmake.scm (gnu): Use the (gnu package python) and (gnu packages texinfo) modules. (cmake)[configure]: Add arguments to configure so that manual pages, info and HTML documentation is generated. [move-html-doc]: New phase. [native-inputs]: Add the native inputs required for building the documentation. [outputs]: Add a "doc" output. --- gnu/packages/cmake.scm | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/gnu/packages/cmake.scm b/gnu/packages/cmake.scm index 5abf08755..36e887c51 100644 --- a/gnu/packages/cmake.scm +++ b/gnu/packages/cmake.scm @@ -38,7 +38,9 @@ #:use-module (gnu packages curl) #:use-module (gnu packages file) #:use-module (gnu packages libevent) + #:use-module (gnu packages python) #:use-module (gnu packages ncurses) + #:use-module (gnu packages texinfo) #:use-module (gnu packages xml)) (define-public cmake @@ -136,7 +138,21 @@ "--mandir=share/man" ,(string-append "--docdir=share/doc/cmake-" - (version-major+minor version))))))))) + (version-major+minor version)) + "--sphinx-man" + "--sphinx-html" + "--sphinx-info")))) + (add-after 'install 'move-html-doc + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (doc (assoc-ref outputs "doc")) + (html (string-append "/share/doc/cmake-" + ,(version-major+minor version) + "/html"))) + (copy-recursively (string-append out html) + (string-append doc html)) + (delete-file-recursively (string-append out html)) + #t)))))) (inputs `(("bzip2" ,bzip2) ("curl" ,curl) @@ -147,6 +163,10 @@ ("ncurses" ,ncurses) ; required for ccmake ("rhash" ,rhash) ("zlib" ,zlib))) + (native-inputs + `(("python-sphinx" ,python-sphinx) + ("texinfo" ,texinfo))) + (outputs '("out" "doc")) (native-search-paths (list (search-path-specification (variable "CMAKE_PREFIX_PATH") -- 2.19.0 --=-=-=--