#! /bin/bash
#
gcc -c -g -Wall -I/$HOME/include tsp_greedy_test.c
if [ $? -ne 0 ]; then
  echo "Compile error."
  exit
fi
#
gcc -o tsp_greedy_test tsp_greedy_test.o /$HOME/libc/tsp_greedy.o -lm
if [ $? -ne 0 ]; then
  echo "Load error."
  exit
fi
rm tsp_greedy_test.o
#
./tsp_greedy_test > tsp_greedy_test.txt
if [ $? -ne 0 ]; then
  echo "Run error."
  exit
fi
rm tsp_greedy_test
#
echo "Normal end of execution."
