X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,SPF_NEUTRAL X-Spam-Check-By: sourceware.org Message-ID: <4B154539.1030007@cornell.edu> Date: Tue, 01 Dec 2009 11:32:57 -0500 From: Ken Brown User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: Environment variable documentation References: <4B14415D DOT 1050701 AT cornell DOT edu> <20091201094531 DOT GE30043 AT calimero DOT vinschen DOT de> In-Reply-To: <20091201094531.GE30043@calimero.vinschen.de> Content-Type: multipart/mixed; boundary="------------070507000007030608000501" X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com --------------070507000007030608000501 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 12/1/2009 4:45 AM, Corinna Vinschen wrote: > On Nov 30 17:04, Ken Brown wrote: >> The discussion currently going on in the thread >> >> http://cygwin.com/ml/cygwin/2009-11/threads.html#00892 >> >> makes me think that the section on environment variables in the >> user's guide (http://cygwin.com/1.7/cygwin-ug-net/setup-env.html) >> could use some expansion. For example, it's not stated explicitly >> which Windows environment variables get imported into Cygwin (all of >> them?), nor is there a complete list of variables containing paths > > Yes, all of them. > >> that get converted to Unix format. PATH, HOME, and LD_LIBRARY_PATH >> are mentioned, but TMPDIR, TMP, and TEMP are omitted. I think the >> last three should be listed, along with the suggestion that users >> might want to unset them in the Cygwin environment. > > Yes, TMPDIR, TMP, and TEMP are handled the same way as PATH, HOME, and > LD_LIBRARY_PATH. These six variables are the set of environment > variables which are subject to path conversion from Windows to POSIX and > vice versa. > >> I would be willing to take a stab at writing a patch if the >> developers think this would be useful. > > That sounds like a nice idea. OK, my patch is attached. It anticipates the change to the default .bashrc file that we've been discussing in the thread cited above. Ken --------------070507000007030608000501 Content-Type: text/plain; name="environ.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="environ.patch" --- setup2.sgml.orig 2009-12-01 10:37:00.156250000 -0500 +++ setup2.sgml 2009-12-01 11:29:53.562500000 -0500 @@ -4,7 +4,9 @@ You may wish to specify settings of several important environment variables that affect Cygwin's operation. Some of these settings need to be in effect prior to launching the initial Cygwin session (before -starting your bash shell, for instance), and are, consequentially, best +starting your bash shell, for instance). They should therefore be set +in the Windows environment; all Windows environment variables are +imported when Cygwin starts. Such settings can be placed in a .bat file. An initial file is named Cygwin.bat and is created in the Cygwin root directory that you specified during setup. Note that the "Cygwin" option of the Start Menu points to Cygwin.bat. Edit @@ -66,6 +68,21 @@ dlopen () call and do not need this variable. + +In addition to PATH, HOME, +and LD_LIBRARY_PATH, there are three other environment +variables which, if they exist in the Windows environment, are +converted to UNIX format: TMPDIR, TMP, +and TEMP. The first is not set by default in the +Windows environment but the other two are, and they point to the +default Windows temporary directory. If set, these variables will be +used by some Cygwin applications, possibly with unexpected results. +They are therefore unset in the default .bashrc +file (/etc/defaults/etc/skel/.bashrc). You may +prefer to set them to point to /tmp or to any +other temporary directory of your choice. + + Changing Cygwin's Maximum Memory --------------070507000007030608000501 Content-Type: text/plain; charset=us-ascii -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple --------------070507000007030608000501--