#!/bin/bash
cd ./libvncauth
xmkmf
#makedepend *.[ch]
make
echo "********** libvncauth done **********"
cd -

cd ./vncviewer
xmkmf
#makedepend *.[ch]
make
echo "********** vncviewer done **********"
cd -

mkmf(){
  if [ ! -e Makefile ]; then
    ./autogen.sh
  fi
}

cd ./src_client
mkmf
make
echo "********** client done **********"
cd -

cd ./src_server
mkmf
make
echo "********** server done **********"
cd -

cp ./src_client/src/multivnc_client .
cp ./src_server/src/multivnc_server .
