The difficulty I’m having is the configure step for emscripten won’t pick up a custom PKG_CONFIG_PATH environment variable. I’m a total noob with respect to building CPython so maybe I’m just not doing something correctly.
Is there a doc somewhere explaining how configure reads environment variables or perhaps somebody else has gotten ctypes to work in the emscripten build?
emconfigure resets PKG_CONFIG_PATH and sets PKG_CONFIG_LIBDIR for cross compiling. Your workaround does the trick. You can also create $EMSCRIPTEN/cache/sysroot/local/lib/pkgconfig and copy the pc files into that directory.