def setBEGINLIBPATH():
    dllpath = os.path.join(sys.prefix, "Lib", "lib-dynload")
    libpath = os.environ['BEGINLIBPATH'].split(';')
    if libpath[-1]:
        libpath.append(dllpath)
    else:
        libpath[-1] = dllpath
    os.environ['BEGINLIBPATH'] = ';'.join(libpath)
The OS/2 EMX port has optional extension modules that do double duty
dataset/ETHPy150Open deanhiller/databus/webapp/play1.3.x/python/Lib/site.py/setBEGINLIBPATH