First (uncontroversial) part of issue 9807.
* Expose the build flags to Python as sys.abiflags
* Shared library libpythonX.Y<abiflags>.so
* python-config --abiflags
* Make two distutils tests that failed with --enable-shared (even before this
patch) succeed.
* Fix a few small style issues.
diff --git a/Python/sysmodule.c b/Python/sysmodule.c
index d02ee5b..6c563f0 100644
--- a/Python/sysmodule.c
+++ b/Python/sysmodule.c
@@ -1521,6 +1521,10 @@
SET_SYS_FROM_STRING("winver",
PyUnicode_FromString(PyWin_DLLVersionString));
#endif
+#ifdef ABIFLAGS
+ SET_SYS_FROM_STRING("abiflags",
+ PyUnicode_FromString(ABIFLAGS));
+#endif
if (warnoptions == NULL) {
warnoptions = PyList_New(0);
}