Revert change a7ac4cf15cd0183d719d91a8d029bd457262ecab and move autoconf stuff to a separate branch