corrected a load of set but unused variables which threw compiler warnings
Changes to Makefile to use -fno-aggressive-loop-optimizations for gcc>4.8, see #100