Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <004301c081f7$b475d420$275c100a@actfs.co.uk> From: "Malcolm Boekhoff" To: "Cygwin News Group" References: <17B78BDF120BD411B70100500422FC6309E1D4 AT IIS000> Subject: Re: More problems with Make. Date: Fri, 19 Jan 2001 09:10:44 -0000 I use the $(subst ...) construct to translate directory delimiters. In the following snippet, I needed to replace the "\" delimiters with "/" (which is what "gcc" likes) in the environment variable JAVAHOME (inherited from my CMD DOS-Prompt session). This was necessary to pick up the Java C headers (for some native stuff). CC=gcc -c -I$(subst \,/,$(JAVAHOME))/include -I$(subst \,/,$(JAVAHOME))/include/win32 ----- Original Message ----- From: "Bernard Dautrevaux" To: "'John Melody'" ; Sent: Thursday, January 18, 2001 5:34 PM Subject: RE: More problems with Make. > > -----Original Message----- > > From: John Melody [mailto:john AT sybernet DOT ie] > > Sent: Thursday, January 18, 2001 5:21 PM > > To: cygwin AT cygwin DOT com > > Subject: More problems with Make. > > > > > > > > > > I still have some problems with make - I thought I had > > resolved the problems > > with the --unix qualifier but not so .... > > > > > > I am using > > cygwin 1.16 > > make 3.79 > > from the cygwin directory. > > > > I have included a part of my make file as follows: > > > > ------------------------------------------ > > SRC_ROOT=d:/work/squash02 > > OUTPUTDIR=d:\cm-build > > VERSION=checkmate-0.7.0 > > CM_VER= CheckMate API V0.7.0 > > DISTRIBUTION_DIR=$(OUTPUTDIR)\$(VERSION) > > > > CLASSES=d:\\classes > > CPath=.;$(CLASSES);$(SRC_ROOT)\lib\jaxp.jar;$(SRC_ROOT)\lib\pa > > rser.jar;$(SRC > > _ROOT)\lib\jh.jar > > > > Flags=-deprecation -d $(CLASSES) -classpath $(CPath) > > > > all: > > javac $(Flags) d:\work\squash02\squ\SQUCheckmate.java > > > > jar: > > cd $(CLASSES) ; \ > > jar -cvf $(DISTRIBUTION_DIR)\lib\classes.jar squ/ > > > > ------------------------------------------- > > > My suggestion: > > Use only forward slashes in the Makefile and, if javac or jar do not > like these, use cygpath to convert: > > ------------------------------------------ > SRC_ROOT=/cygdrive/d/work/squash02 > OUTPUTDIR=/cygdrive/d/cm-build > VERSION=checkmate-0.7.0 > CM_VER= CheckMate API V0.7.0 > DISTRIBUTION_DIR=$(OUTPUTDIR)/$(VERSION) > > CLASSES=/cygdrive/d/classes > CPath=.:$(CLASSES):$(SRC_ROOT)/lib/jaxp.jar:$(SRC_ROOT)/lib/parser.jar:$(SRC > _ROOT)/lib/jh.jar > Flags=-deprecation -d `cygpath -w $(CLASSES)` -classpath `cygpath -p -w > $(CPath)` > > JAVA_SOURCE=/cygdrive/d/work/squash02/squ/SQUCheckmate.java > > all: > javac $(Flags) `cygpath -w $(JAVA_SOURCE)` > > jar: > cd $(CLASSES) ; \ > jar -cvf $(DISTRIBUTION_DIR)/lib/classes.jar squ/ > > ------------------------------------------- > > Using cygpath everywhere allows to use the various paths as > targets/dependencies so that make could only rebuild what has to be rebuilt. > > HTH > > Bernard > > -------------------------------------------- > Bernard Dautrevaux > Microprocess Ingenierie > 97 bis, rue de Colombes > 92400 COURBEVOIE > FRANCE > Tel: +33 (0) 1 47 68 80 80 > Fax: +33 (0) 1 47 88 97 85 > e-mail: dautrevaux AT microprocess DOT com > b DOT dautrevaux AT usa DOT net > -------------------------------------------- > > -- > Want to unsubscribe from this list? > Check out: http://cygwin.com/ml/#unsubscribe-simple -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple