bpo-36900: Replace global conf vars with config (GH-13299)

Replace global configuration variables with core_config read from the
current interpreter.

Cleanup dynload_hpux.c.
diff --git a/Python/pythonrun.c b/Python/pythonrun.c
index 199ea82..3d83044 100644
--- a/Python/pythonrun.c
+++ b/Python/pythonrun.c
@@ -591,10 +591,12 @@
     PyObject *exception, *value, *tb;
     int exitcode = 0;
 
-    if (Py_InspectFlag)
+    int inspect = _PyInterpreterState_GET_UNSAFE()->core_config.inspect;
+    if (inspect) {
         /* Don't exit if -i flag was given. This flag is set to 0
          * when entering interactive mode for inspecting. */
         return;
+    }
 
     PyErr_Fetch(&exception, &value, &tb);
     fflush(stdout);