IGNOREPATH=/
STRIPLIB=y
STRIPBIN=y

PROGNAME="XFree86 $VERSION"
DESC="\
xfree86-docs (text documentation for XFree86)                          \n\
                                                                       \n\
Documentation and release notes for XFree86 that you can find in       \n\
/usr/X11R6/lib/X11/doc/."

BUILD=1
MAINTAINER="Mark Post <mark.post@eds.com>"
SOURCE=http://www.xfree86.org
SUBPKGNAME=xfree86-docs-$VERSION-s390-$BUILD
TAG=OPT

subinstall() {
   echo "Nothing to install for xfree86-docs"
}

subspecial() {
   mkdir -p $SUBPKG/usr/X11R6/lib/X11/doc

   ( cd $TMP/xc/programs/Xserver/hw/xfree86/doc
     cp -a BUILD DESIGN Install LICENSE README README.XKB-Config README.XKB-Enhancing \
           README.dps README.fonts RELNOTES ServersOnly Status Versions \
         $SUBPKG/usr/X11R6/lib/X11/doc
     sed -e 's%XF86_VERSION%$VERSION%' BugReport.cpp > $SUBPKG/usr/X11R6/lib/X11/doc/BugReport
   )

   cp -a $TMP/xm/usr/X11R6/lib/X11/doc/fontconfig* $SUBPKG/usr/X11R6/lib/X11/doc/

   cp -a $TMP/xm/usr/X11R6/lib/X11/doc/freetype-* $SUBPKG/usr/X11R6/lib/X11/doc/

   chown -R root.root $SUBPKG
   find $SUBPKG/usr/X11R6/lib/X11/doc/ -type f -maxdepth 1 | xargs chmod 444
   chmod 775 $SUBPKG/usr/X11R6/lib/X11/doc/freetype/
   chmod 664 $SUBPKG/usr/X11R6/lib/X11/doc/freetype/*
#  chmod 644 $SUBPKG/usr/X11R6/lib/X11/doc/fontconfig-*/*

   cd $SUBCTL
   cat $CWD/slack-desc/slack-desc.xfree86-docs > slack-desc
}

