Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
content-class: urn:content-classes:message
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
Subject: RE: if construct doesn't work in makefile
Date: Thu, 11 Nov 2004 13:21:37 +0100
Message-ID: <D7FBE8A336018A4EB5EBDC6C898821930991C931@HUELVA.belgium.fhm.de>
X-MS-Has-Attach: 
X-MS-TNEF-Correlator: 
From: "Morche Matthias" <Matthias.Morche@P7S1Produktion.de>
To: <cygwin@cygwin.com>
X-OriginalArrivalTime: 11 Nov 2004 12:21:38.0115 (UTC) FILETIME=[FE02C130:01C4C7E8]
X-IsSubscribed: yes
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id iABCM8bZ027030

cygwin-owner@cygwin.com wrote:
> Hi,
> 
>   In my make file I am trying to check whether a directory exists or
> not then set a path differently if doesn't exist.
>   I am using cygwin installed on windows 2000.
>   The if construct I have is as follows.
> 
>   if test [-dc:/tools]; then DRIVE = c:/tools; else DRIVE =
> c:/altTools; fi 
> 
>  pls help me out.
> 
> Regards,
> sitaram

Does the following work better?
if test [ -d /cygdrive/C/tools ]; then DRIVE=c:/tools; else DRIVE=

By the way: this seems not to be a cygwin problem and it would be very helpful to provide at least the error message.

See http://cygwin.com/problems.html

  matthias


--
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/


