renamed configure.in to configure.ac
did some refactoring and added some comments