Added uid/gid setting
Refactor configure.ac structure