X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org X-Authority-Analysis: v=1.0 c=1 a=hFDmfU4WUWwA:10 a=uQph3V7OTCQA:10 a=xe8BsctaAAAA:8 a=MnxlmToSlUATRl4chjEA:9 a=EgL7obWOeAvLi0bBvC6cg3OTYvYA:4 a=eDFNAWYWrCwA:10 a=rPt6xJ-oxjAA:10 Message-ID: <480D6329.9020608@byu.net> Date: Mon, 21 Apr 2008 22:01:45 -0600 From: Eric Blake User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.12) Gecko/20080213 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 MIME-Version: 1.0 To: cygwin AT cygwin DOT com, norliansyah AT gmail DOT com Subject: Re: Calling Cygwin from Dos - problem with sub program References: <16760067 DOT post AT talk DOT nabble DOT com> In-Reply-To: <16760067.post@talk.nabble.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit 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 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 According to nlian on 4/17/2008 9:58 PM: | Hi, | | I have a bash script (e.g. test.sh), and I have the following command | inside the script: | | #!/usr/bin/bash | export PROG_LIB="D:\batch\prod\prog\lib" Non-portable use of back-slashes. But more importantly, a non-POSIX path inside a bash script. | export PATH="$PROG_LIB:$PATH" Running this script with 'bash -vx', or adding 'cmd /c echo %PATH%', may prove instructive of what you are setting PATH to. For starters, the leading D followed by a path separator : means that you are searching the relative directory D (and not anchoring a path in the d drive; for that you need /cygdrive/d/). | However when I execute from dos, I got an error: | functions.library: No such file or directory Probably because your PATH wasn't set correctly. - -- Don't work too hard, make some time for fun as well! Eric Blake ebb9 AT byu DOT net -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) Comment: Public key at home.comcast.net/~ericblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkgNYykACgkQ84KuGfSFAYClIwCfbLEKsN0jHJvGRj36iYcTt62u K80An0ZNRGTqkBz13Z3JY+MieCD/XyeT =Db1W -----END PGP SIGNATURE----- -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/