Environment Variables No Longer Supported?

Discussion in 'Mac OS X Lion (10.7)' started by johnnyham, Aug 8, 2011.

  1. johnnyham macrumors regular

    Joined:
    Jun 18, 2010
    #1
    I tried firing up Macports earlier today, only to find that Lion no longer saw /opt/local/bin and /opt/local/sbin as being environmental variables. I checked ~/.profile and it was there. All my Macports executables were present as well. I finally edited my ~/.MacOSX/environment.plist file to include the paths (Xcode 4 seems to have omitted the PList Editor...), and that seemed to work, although I've never had to use environment.plist before for setting path variables. One person over at stackoverflow claimed that Apple support told him Lion no longer officially supports environmental variables.

    Does anybody have any input into this? I find it odd that Apple would have changed such a core feature of the underlying infrastructure. I'm slowly edging toward reinstalling SL until some of this crap in Lion gets cleared out... if ever.
     
  2. CyBeRino macrumors 6502a

    Joined:
    Jun 18, 2011
    #2
    Environment Variables are a core concept of POSIX and OSX being a POSIX-correct OS, will never discontinue them.

    The problem most likely lies in the filename of your .profile so it's probably not being sourced when you start a shell. If you were to rename it .bash_profile (assuming you use bash), that might help. At the very least, that's what my set-up looks like and here it works as it always has.
     

Share This Page