Setting Environment Variables for Mac OS X Programs
For the most part, Mac OS X programs do not use environment variables or the PATH. They behave in a very different way from other Unix environments on this score. However, as Java developer I use several tools that require that other command line programs be available on the system PATH. In Windows and Unix there are well known places to put this kind of information but in Mac OS X the location for these changes is obscure.
Adding the variables to the /etc/profile, /etc/bashrc, ~/.profile, or ~/.bashrc files does not accomplish the task since these files are not used to setup the environment of the WindowServer process, the parent of all Mac OS X programs. I did, eventually, find some information on the subject.
There are these articles: Environment Variables, QA1255 and QA1068.
These articles were really hard for me to find, I think, because they were written mostly for folks wanting to port Unix applications to Mac OS X. In my case, I am attempting to use Java applications like Eclipse and Netbeans. Specifically, they needed the subversion commands on the path and they were installed into /usr/local/bin instead of /usr/bin. A good policy but not on the default PATH variable.
NOTE: I forgot to mention, you have to logout for these changes to have any effect.
- danapsimer's blog
- 4466 reads


























Thanks for this!
مسجات شوق مسجات اشتياق مسجات نكت مسجات مقالب مسجات مسجات عتاب شعر حب شعر حامد زيد شعر غزل قصائد حامد زيد قصائد حب قصائد عتاب ماسنجر لايف صور رمانسيه صور رومنسيه صور عشق صور قلوب صور حلوه خلفيات متحركة خلفيات سطح المكتب خلفيات بنات خلفيات اسلامية خلفيات للكمبيوتر تسريحات شعر قصات شعر فساتين فساتين سهره ايلي صعب فساتين خطوبة فساتين زفاف مكياج عيون صور مكياج صور فساتين مكياج العيون صور ديكور ديكور غرف نوم ديكور مطابخ الديكور الديكور المنزلي افلام انمي تحميل انمي اناشيد العفاسي
/etc/launchd.conf
You were close with /etc/profile, and environment.plist will _nearly_ work, but the parent of all processes on Mac OS X is launchd, not WindowServer. So the file you want to make a truly global (system-wide) change is /etc/launchd.conf.
Have a look at http://www.digitaledgesw.com/node/31 if you're interested in my full writeup on this.
Thanks for this!
Thanks for this!
Post new comment