#!/bin/bash

INSTALL=`which install`
STRIP=`which strip`

BINDIR=/usr/bin
PIXMAPSDIR=/usr/share/pixmaps
MANDIREN=/usr/share/man/man1
MANDIRIT=/usr/share/man/it/man1
FONTSDIR=/usr/share/fonts/ra3701control
LOCALEDIR=/usr/share/locale/it/LC_MESSAGES
DOCSDIR=/usr/share/doc/ra3701control
GPLV3DIR=$DOCSDIR/GPLv3

if ! test "$UID" = "0" ; then
    echo "'Install' must be run as root"
    exit
fi

if test -z $INSTALL ; then
	echo "'install' program not found"
	exit
fi

echo "Installing..."

$INSTALL -m 755 ../src/RF550Control $BINDIR
if test -n $STRIP ; then
	$STRIP $BINDIR/RF550Control
fi

$INSTALL -m 644 ../src/HarrisLogo.png $PIXMAPSDIR/RF550Control.png
$INSTALL -m 644 ../fonts/digital-dream-fat.ttf $FONTSDIR

echo "Done!"
