I write the information of each package to a json file then call pip to install them and finally add the folder to sys.path. Please check out the code at
https://github.com/xxyzz/WordDumb/bl...2/unzip.py#L51
FYI, mac can't load unsigned compiled library.