diff options
author | Kyle Guinn <elyk03@gmail.com> | 2015-02-28 18:59:39 -0600 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2015-03-08 06:35:12 +0700 |
commit | c2116761843b9e6234d170f1c1d21f6ab3e0c814 (patch) | |
tree | 4b84d23e54e1ae6cd99dc938b308dc7c64851931 /libraries/blas | |
parent | 87fdc913a30a2c4741d4ae64c61d9862d4af1436 (diff) | |
download | slackbuilds-c2116761843b9e6234d170f1c1d21f6ab3e0c814.tar.gz |
libraries/blas: Add man pages.
Thanks to Mario Benincasa for the suggestion.
Signed-off-by: Kyle Guinn <elyk03@gmail.com>
Diffstat (limited to 'libraries/blas')
-rw-r--r-- | libraries/blas/blas.SlackBuild | 30 |
1 files changed, 28 insertions, 2 deletions
diff --git a/libraries/blas/blas.SlackBuild b/libraries/blas/blas.SlackBuild index 72d2920110..f1a563d57a 100644 --- a/libraries/blas/blas.SlackBuild +++ b/libraries/blas/blas.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for BLAS -# Copyright 2014 Kyle Guinn <elyk03@gmail.com>, USA +# Copyright 2014-2015 Kyle Guinn <elyk03@gmail.com>, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -25,7 +25,7 @@ PRGNAM=blas SRCNAM=lapack VERSION=${VERSION:-3.5.0} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -120,6 +120,32 @@ sed -i \ -e "/^Libs:/s/-L[^ ]*/-L\${libdir}/" \ $PKG/usr/lib${LIBDIRSUFFIX}/pkgconfig/blas.pc +# Generate man pages. Also requires some fix-ups: +# 1. Replace "LAPACK" with "BLAS" in headers/footers. +# 2. Version is wrong. +# 3. Only generate on the BLAS sources. +# 4. Turn off some repetitive comments. +# 5. Turn off HAVE_DOT. Graphs are unnecessary for this purpose. +# 6. Turn off MAN_LINKS. See below. +sed -i \ + -e "s/^\(PROJECT_NAME *=\).*/\1 BLAS/" \ + -e "s/^\(PROJECT_NUMBER *=\).*/\1 ${VERSION}/" \ + -e "s/^\(INPUT *=\).*/\1 BLAS\/SRC/" \ + -e "s/^\(REPEAT_BRIEF *=\).*/\1 NO/" \ + -e "s/^\(HAVE_DOT *=\).*/\1 NO/" \ + -e "s/^\(MAN_LINKS *=\).*/\1 NO/" \ + DOCS/Doxyfile_man +doxygen DOCS/Doxyfile_man +# Doxygen generates manpages on a file-by-file basis (note the .f extensions). +# We want a page for each function, not each file. MAN_LINKS creates a page +# for each function that just sources the page for the corresponding file. +# This adds a lot of bloat. Luckily, functions map 1:1 with files, so we can +# rename .f.3 -> .3 to have the page named after the function. +mkdir -p $PKG/usr/man/man3 +for i in DOCS/man/man3/*.f.3; do + gzip -9c $i > $PKG/usr/man/man3/$(basename $i .f.3).3.gz +done + mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a $DOCS $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild |