#!/bin/sh
#you can compile QPxTool simply by run "make"
#if it fails (mostly because your QT paths differs from my) try this script
inspath=/usr/local/bin
bin="qpxtool"
#qmake -project
qmake	# this will regenerate Makefile - enable, if you have compilation problems

#b_os=`uname -s`
#b_release=`uname -r`
#b_version=`uname -v`
#b_machine=`uname -m`
#b_node=`uname -n`

#echo "// This file generated by \"build\" script
#
##define b_os      \"$b_os\"
##define b_release \"$b_release\"
##define b_version \"$b_version\"
##define b_machine \"$b_machine\"
##define b_node    \"$b_node\"
#" > buildhost.h

make
strip --strip-unneeded qpxtool

#chown root $bin  # this needed to get full functionality
cp $bin $inspath/$bin
chmod 4755 $inspath/$bin       # of Plextor features

echo "*****************************************"
echo "   QPxTool binary ready:)"
echo "	 type qpxtool to run"
echo "*****************************************"
