Now sure if this was reported already… (quick search didn’t find it) - there’s a problem with how Panda3D 1.7.0 installer for Mac OSX modifies the ~/.MacOSX/envrionment.plist file.
On my system (10.6 Snow Leopard), it modified the PATH variable and only left the path to panda binaries in it:
So, all the default system paths are gone (/usr/bin, etc.). This is not good… and it’s not immediately obvious what’s going on, when all of a sudden totally unrelated applications start to act strange. (For instance, i had Macports os check not being able to determine the version of my OS correctly, because it couldn’t locate the “uname” binary)
The same problem may exist with “DYLD_LIBRARY_PATH” and “PYTHONPATH” keys. I see that they also only contain Panda3D paths, but i have no idea what they were before
/usr/bin and /bin are not specified in the environment.plist file. The installer merely modifies it. If PATH already exists, it simply appends the Panda3D path to it.
So, these paths weren’t in there in the first place.
hm… so if it preserves the existing value, then it’s one of the two: either i didn’t even have a ~/.MacOSX/environment.plist file before, or it could be that the PATH key wasn’t defined in there. Either of the two scenarios are possible.
So, i tried to remove the ~/.MacOSX/environment.plist file completely, logged out/in, and MacPorts installer’s version check worked fine. However, i put back the plist file, and also removed everything from the PATH key value, except for /Developer/Tools/Panda3D, logged out/back in, and now the installer had the same problem again: it wasn’t finding the commands from /usr/bin.
Maybe this is a MacPorts installer bug really… because i wrote a simple script that would utilize “which” and “uname” commands, and launched it from both the terminal and from Finder, and it worked both times. It’s odd…
Hm, interesting. Perhaps the values in environment.plist override the current values, rather than appending to them.
Looks like i was too quick to blame the macports installer. Here’s a better explanation of a problem related to using ~/.MacOSX/environment.plist: