#Packager: Shador <futur~DOT~andy~AT~googlemail.com>

pkgname=sg2conf
pkgver=1.1.15.1
pkgrel=1ab
arch=noarch
source=("http://gaia.homelinux.org/sg2conf/sg2conf-$pkgver.tar.bz2"
        "sg2conf.desktop" "sg2conf-kde.desktop")
sourcetemplate="http://gaia.homelinux.org/salix/slkbuilds/$pkgname/"
docs=("readme" "changelog" "grub.cfg")
url='http://gaia.homelinux.org/sg2conf/'

slackdesc=\
(
#|-----handy-ruler------------------------------------------------------|
"$pkgname (Simple Grub2 CONFiguration utility)"
"This application determines with a few prompts the right configuration"
"options for the grub2 tools. In the next step it uses grub-install"
"and grub-mkconfig to install and configure grub2 on your system."
"It also offers a simple way to just reinstall or reinstall and"
"reconfigure grub2 with the choices you made the last time."
"It's compatible to the /etc/default/grub configuration way."
)


build() {
  cd $startdir/src/sg2conf-$pkgver
  DESTDIR=$startdir/pkg \
  DISTRIBUTOR='Salix $(sed -e "s/^Slackware //" /etc/slackware-version)' \
  BACKGROUND='/boot/grub/salix.jpg' \
  GRUB_CMDLINE_LINUX_DEFAULT='quiet' \
  GRUB_CMDLINE_LINUX='vt.default_utf8=1' \
  PREFIX=/usr ETCDIR=/etc MANDIR=/usr/man \
    sh ./install.sh
    
  cd $startdir/src
  install -vD -m644 sg2conf.desktop $startdir/pkg/usr/share/applications/sg2conf.desktop
  install -vD -m644 sg2conf-kde.desktop $startdir/pkg/usr/share/applications/sg2conf-kde.desktop
}