improve configure.ac; improve search; organizing