This is the mail archive of the
cygwin
mailing list for the Cygwin project.
RE: if construct doesn't work in makefile
- From: "Morche Matthias" <Matthias dot Morche at P7S1Produktion dot de>
- To: <cygwin at cygwin dot com>
- Date: Thu, 11 Nov 2004 13:21:37 +0100
- Subject: RE: if construct doesn't work in makefile
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/