#!/bin/sh
#
# kTm port by Juzer
#
#	regards to hns & psych
#

# local config:
BUILD="1"
PACKAGE="sms"

check() { 
# Checking for configuration
# Downloading sources lists
INSTALLED="`ls -1 $PACKAGES/packages/|grep $PACKAGE-|cut -d "-" -f 1,2`"
$WGET -q http://ceti.pl/~miki/komputery/download/sms/
NEW=`grep $PACKAGE- index.html|grep .tar|cut -d '"' -f 6|sed -e s/.tar.gz//|grep -v current|tail -1`
#Checking for new version
    checkpkg
# clean
rm index.html
}
download() {
# Downloading version from "${VERFILE}"
$WGET -P $DOWNL http://ceti.pl/~miki/komputery/download/sms/$SRC.tar.gz
}

build() {
# Creating new
tar zxvf $DOWNL/$SRC.tar.gz
cd sms
make || exit
make install PREFIX=$PKG/usr || exit
    postbuild
rm -rf $TMP/sms
}

source "${DATA:-/usr/lib/ktm}/ktm.ports.sh"
