Use setuptools instead of distutils in _run_setup_py():

Some parameters to distutils.core.setup() are only supported
by setuptools and not by distutils, e.g. install_requires.
Support for these parameters is monkeypatched into distutils
by setuptools.

If distutils is used in _run_setup_py(), these parameters
will not be part of the distutils.dist.Distribution object.
Thus, they can only be retrieved by _parse_setup_py() and
consequently the parameters cannot be generated dynamically
at runtime of setup.py.

Switching to setuptools fixes this and also allows us to
improve security by sandboxing extraction of the tarball
and execution of setup.py.
Amend _parse_setup_py() and _run_setup_py() to support the
exact same set of setup() parameters.
Make "parse" and "run" two separate modes.

Neither mode is guaranteed to work but now if one mode
fails, the user may retry in the other mode. Previously
parse mode would always be executed even if the user
had invoked the program with "--run".
Support all the syntactic variations allowed for install_requires,
extras_require and data_files parameters.

It seems to make sense to canonicalize these in __init__.py so that
the Jinja2 templates can expect the data to be in a standard form.
Add support for "entry_points" and "console_scripts" parameters.

Fix regex for "scripts" parameter in _parse_setup_py to not
match "console_scripts".
Quote %doc filenames if they contain shell metacharacters
to keep rpmbuild happy.