libraries/udunits: Fix docs.

Signed-off-by: B. Watson <yalhcru@gmail.com>
This commit is contained in:
B. Watson 2022-04-19 18:30:22 -04:00
parent 61d6bea8c3
commit af225f9eaf

View file

@ -21,11 +21,14 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# 20220419 bkw: Modified by SlackBuilds.org, BUILD=4:
# - fix broken symlink in doc dir.
cd $(dirname $0) ; CWD=$(pwd) cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=udunits PRGNAM=udunits
VERSION=${VERSION:-2.2.28} VERSION=${VERSION:-2.2.28}
BUILD=${BUILD:-3} BUILD=${BUILD:-4}
TAG=${TAG:-_SBo} TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz} PKGTYPE=${PKGTYPE:-tgz}
@ -37,9 +40,6 @@ if [ -z "$ARCH" ]; then
esac esac
fi fi
# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
# the name of the created package would be, and then exit. This information
# could be useful to other scripts.
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
exit 0 exit 0
@ -74,9 +74,9 @@ cd $PRGNAM-$VERSION
chown -R root:root . chown -R root:root .
find -L . \ find -L . \
\( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
-o -perm 511 \) -exec chmod 755 {} \; -o \ -o -perm 511 \) -exec chmod 755 {} \+ -o \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+
CFLAGS="$SLKCFLAGS" \ CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \
@ -92,18 +92,21 @@ CXXFLAGS="$SLKCFLAGS" \
--build=$ARCH-slackware-linux --build=$ARCH-slackware-linux
make make
make install DESTDIR=$PKG make install-strip DESTDIR=$PKG
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
rm -f $PKG/usr/info/dir rm -f $PKG/usr/info/dir
gzip -9 $PKG/usr/info/*.info* gzip -9 $PKG/usr/info/*.info*
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
cp -a BACKLOG CHANGE_LOG COPYRIGHT README \
$PKG/usr/doc/$PRGNAM-$VERSION # 20220419 bkw: 'make install' tries to symlink the *.xml files
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild # to the doc dir, but fails because it expects the doc dir to be
# /usr/share/doc.
rm -f $PKGDOC/*.xml
( cd $PKGDOC ; ln -s ../../share/$PRGNAM/*.xml . )
cp -a BACKLOG CHANGE_LOG COPYRIGHT README $PKGDOC
cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
rm -f $PKG/usr/lib*/*.la rm -f $PKG/usr/lib*/*.la