fixed lib flag error in configure.ac
moved some stuff around to fix a linking error
updated version