[slepc] 01/02: link header docs to the actual header files

Drew Parsons dparsons at moszumanska.debian.org
Tue Nov 29 07:51:36 UTC 2016


This is an automated email from the git hooks/post-receive script.

dparsons pushed a commit to branch master
in repository slepc.

commit 94f276d9aee576bf1c92027f47d5cb726f58c304
Author: Drew Parsons <dparsons at debian.org>
Date:   Tue Nov 29 14:21:33 2016 +0800

    link header docs to the actual header files
    
    be careful not to mix up finclude for include in
    include/slepc/finclude/
---
 debian/changelog |  6 ++++++
 debian/rules     | 11 ++++++++++-
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 096b27e..0e9c209 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+slepc (3.7.3+dfsg1-3) UNRELEASED; urgency=medium
+
+  * link header docs to the actual header files
+
+ -- Drew Parsons <dparsons at debian.org>  Tue, 29 Nov 2016 14:20:11 +0800
+
 slepc (3.7.3+dfsg1-2) unstable; urgency=medium
 
   * Handle shlibs dependencies via virtual libslepc3.7 and
diff --git a/debian/rules b/debian/rules
index 0e4a76d..5c724bc 100755
--- a/debian/rules
+++ b/debian/rules
@@ -167,7 +167,16 @@ override_dh_installdocs:
 	# html docs for header files in include have been installed,
 	# but dh_installdocs cannot exclude the .h (-X.h bans the .html files)
 	# so remove the excess .h files
-	find debian/$(SLEPC_DOC_PACKAGE)/usr/share/doc/$(SLEPC_DOC_PACKAGE)/include -name *.h -o -name *.h90 | xargs -r rm
+        # test if header docs were installed (in a binary-only build they won't be)
+	if [ -d ./debian/$(SLEPC_DOC_PACKAGE)/usr/share/doc/$(SLEPC_DOC_PACKAGE)/include ]; then  \
+	  find debian/$(SLEPC_DOC_PACKAGE)/usr/share/doc/$(SLEPC_DOC_PACKAGE)/include -name *.h -o -name *.h90 | xargs -r rm; \
+	# make header docs "generic" (pointing to headers in preferred alternative /usr/include/slepc)  \
+	  for hdoc in `find ./debian/$(SLEPC_DOC_PACKAGE)/usr/share/doc/$(SLEPC_DOC_PACKAGE)/include/ -name "*.html"`; do  \
+	    h=`echo $${hdoc} | xargs basename | sed "s/.html//"`; \
+	    hdir=`echo $${hdoc} | xargs dirname | sed "s|^.*/include||"`; \
+	    sed "s|href=\"$${h}\"|href=\"/usr/include/slepc$${hdir}/$${h}\"|" -i $${hdoc};  \
+	  done  \
+	fi
 	for examples in $$( find src -name *example* ); do \
 	  dh_install -p$(SLEPC_DOC_PACKAGE) $$examples/* usr/share/doc/$(SLEPC_DOC_PACKAGE)/examples/$$(echo $$examples | sed "s/src\///; s/examples//" ); \
 	done

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/slepc.git



More information about the debian-science-commits mailing list