#!/bin/bash

# Simple list absolute path to file(s)
# Copyright (C) 2012  Jerry B Nettrouer II <j2@inpito.org>

#    This program is free software: you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation, either version 3 of the License, or
#    (at your option) any later version.

#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.

#    You should have received a copy of the GNU General Public License
#    along with this program.  If not, see <http://www.gnu.org/licenses/>.


PRGNAME="inpito-scripts"
VERSION="0.0.2"
ARCH="noarch"
BUILD="inpito"

CWD=$( pwd )
TMP=/tmp
PKG=$TMP/package-$PRGNAME

cd $TMP
rm -rf $PKG
tar zxvf $CWD/$PRGNAME-$VERSION.tar.gz
cd $TMP/$PRGNAME
chown -R root.root .

mkdir -p $PKG/usr/doc/$PRGNAME-$VERSION
cp -a LICENSE README $PKG/usr/doc/$PRGNAME-$VERSION

mkdir -p $PKG/usr/bin
cp -a lap lsp xz2gz $PKG/usr/bin

mkdir -p $PKG/usr/sbin
cp -a mbr* $PKG/usr/sbin

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc

# Build the package:
cd $PKG
makepkg -l y -c n $TMP/$PRGNAME-$VERSION-$ARCH-$BUILD.tgz


