BUG REPORT: OSX: Don't use ~/.MacOSX/environment.plist

I’ve been working with a user to figure out why his system has become unstable, and the root cause is your software package. You setup a ~/.MacOSX/environment.plist which essentially breaks all the user’s LaunchAgents:

$ cat ~/.MacOSX/environment.plist

<?xml version="1.0" encoding="UTF-8"?> DYLD_LIBRARY_PATH /Developer/Panda3D/lib MAYA_PLUG_IN_PATH /Developer/Panda3D/plugins MAYA_SCRIPT_PATH /Developer/Panda3D/plugins PATH /Developer/Tools/Panda3D PYTHONPATH /Developer/Panda3D/lib
  1. You are telling launchd to use /Developer/Tools/Panda3D as PATH. This means that no system directories are in PATH, and any other script started by at LaunchAgent will not have access to /usr/bin /bin, etc.

  2. Ditto for PYTHONPATH.

  3. Do NOT EVER EVER EVER EVER set DYLD_LIBRARY_PATH in a deployment scenario. If you find you need to, then you are doing something ELSE wrong, and setting DYLD_LIBRARY_PATH is NOT the solution.

1+2) Oh, my apologies. I didn’t know about that.
Can you check if adding :$PATH to the path setting works?

  1. You’re right, we don’t need it. I simply forgot to remove it before the release. Sorry about that.

Anyways, I’m totally in favor of removing the environment.plist. I’ll see what I can do for a future 1.7.1 release.
I don’t think its such a big deal for people to add /Developer/Tools/Panda3D/ to their PATH themselves.

If you want to add something to PATH, the way to do it is by creating a file in /etc/paths.d (just like X11 does)

Great, thanks! I didn’t know about that one.