From 488d0191b1cd81eca990076e0f48c1e31fa88d5f Mon Sep 17 00:00:00 2001 From: rdb Date: Wed, 24 Feb 2010 13:31:40 +0000 Subject: [PATCH] More antidote for the OSX environment.plist poison. Write a .pth file in /Library/Python/#.#/site-packages --- makepanda/makepanda.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/makepanda/makepanda.py b/makepanda/makepanda.py index 0d3cd814e4..899cb2c8a3 100755 --- a/makepanda/makepanda.py +++ b/makepanda/makepanda.py @@ -4987,7 +4987,7 @@ def MakeInstallerOSX(): oscmd("mkdir -p dstroot/tools/Developer/Tools/Panda3D") oscmd("mkdir -p dstroot/tools/Developer/Panda3D") - oscmd("ln -s /Developer/Tools/Panda3D") + oscmd("mkdir -p dstroot/tools/etc/paths.d") WriteFile("dstroot/tools/etc/paths.d/Panda3D", "/Developer/Tools/Panda3D") for base in os.listdir(GetOutputDir()+"/bin"): binname = "dstroot/tools/Developer/Tools/Panda3D/" + base @@ -5004,8 +5004,11 @@ def MakeInstallerOSX(): oscmd("install_name_tool -change %s /Developer/Panda3D/lib/%s %s" % (libdep, os.path.basename(libdep), binname), True) if PkgSkip("PYTHON")==0: + PV = SDK["PYTHONVERSION"].replace("python", "") oscmd("mkdir -p dstroot/pythoncode/usr/bin") oscmd("mkdir -p dstroot/pythoncode/Developer/Panda3D/lib/direct") + oscmd("mkdir -p dstroot/pythoncode/Library/Python/%s/site-packages" % PV) + WriteFile("dstroot/pythoncode/Library/Python/%s/Panda3D.pth" % PV, "/Developer/Panda3D/lib") oscmd("cp -R %s/pandac dstroot/pythoncode/Developer/Panda3D/lib/pandac" % GetOutputDir()) oscmd("cp -R direct/src/* dstroot/pythoncode/Developer/Panda3D/lib/direct") oscmd("cp direct/src/ffi/panda3d.py dstroot/pythoncode/Developer/Panda3D/lib/panda3d.py")