#!/bin/bash
# Initially written by Didier Spaier 2016
# No guarantee of any kind
# Public domain
# This script makes a package for version 14.2.
VERSION=14.2
PKG="slackware-docs"
TAG=${TAG:-slint}
BUILD=1
ARCH="noarch"
PKGNAME=${PKG}-${VERSION}-${ARCH}-${BUILD}$TAG
CWD=$(pwd)
TMP=$CWD
rm -rf  $TMP/$PKG
mkdir -p $TMP/$PKG

( cd $TMP/$PKG
  mkdir -p usr/doc/slackware-${VERSION}
  cp -a $CWD/* usr/doc/slackware-${VERSION}
  mkdir install
  cat << EOF > install/slack-desc
#             |-----handy-ruler------------------------------------------------------| 
slackware-docs: Slackware docs (misc documents gathered from Slackwaree (R)).
slackware-docs: This package contains miscellaneous documents useful for Slint users 
slackware-docs:
slackware-docs: These documents are gathered unmodified from a Slackware installation
slackware-docs: media.
slackware-docs:
slackware-docs: Slackware is a registered trademark of Slackware, inc.
slackware-docs:
slackware-docs:
slackware-docs:
slackware-docs:
EOF
/sbin/makepkg -l y -c n $TMP/${PKGNAME}.txz
)
rm -rf  $TMP/$PKG
