Added check that runs libpng's autogen.sh if needed.