#define LANDMARK L"os.py"
#endif
- #ifndef BASE_LIB
- #define BASE_LIB "lib"
- #endif
+#define DECODE_LOCALE_ERR(NAME, LEN) \
+ ((LEN) == (size_t)-2) \
+ ? _Py_INIT_USER_ERR("cannot decode " NAME) \
+ : _Py_INIT_NO_MEMORY()
+
+typedef struct {
+ wchar_t *path_env; /* PATH environment variable */
+
+ wchar_t *pythonpath; /* PYTHONPATH define */
+ wchar_t *prefix; /* PREFIX define */
+ wchar_t *exec_prefix; /* EXEC_PREFIX define */
+
+ wchar_t *lib_python; /* "lib/pythonX.Y" */
+ wchar_t argv0_path[MAXPATHLEN+1];
+ wchar_t zip_path[MAXPATHLEN+1]; /* ".../lib/pythonXY.zip" */
+
+ int prefix_found; /* found platform independent libraries? */
+ int exec_prefix_found; /* found the platform dependent libraries? */
+} PyCalculatePath;
+
+static const wchar_t delimiter[2] = {DELIM, '\0'};
+static const wchar_t separator[2] = {SEP, '\0'};
+
#ifndef BASE_LIB
#define BASE_LIB "lib"
#endif
return err;
}
++
static void
reduce(wchar_t *dir)
{