delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2002/11/27/02:28:30

Date: Wed, 27 Nov 2002 08:25:58 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Ed Manlove <emanlove AT ieee DOT org>
cc: djgpp AT delorie DOT com
Subject: Re: Expansion of "$srcdir" and '${DJDIR}' in gnu\binutl-2.121\build.djg\djconfig.sh
In-Reply-To: <RzQE9.782$xb7.268286996@news.netcarrier.net>
Message-ID: <Pine.SUN.3.91.1021127082106.8482F-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On Tue, 26 Nov 2002, Ed Manlove wrote:

> How does the configure script expand or what results from the expansion
> of --srcdir="$srcdir" --prefix='${DJDIR}' in the configure script for
> binutils, gnu\binutl-2.121\build.djg\djconfig.sh?

This is a normal expansion of environment variables, where ${DJDIR} 
stands for the value of the variable DJDIR.  This variable is set by the 
startup code of any DJGPP program from the value of the DJGPP variable.  
That is, if you have set DJGPP=c:\foo\bar\djgpp.env, the startup code 
will read djgpp.env and set DJDIR to c:/foo/bar.

> I want to add the --with-headers parameter to gcc configure script.  The
> directory I wish to add is
> /dev/env/DJDIR/lib/gcc-lib/h8300-hitachi-hms/2.952/include.

The "/dev/env" trick will only work with the DJGPP programs, not with 
Unix programs.  It works because the library functions from DJGPP's 
libc.a treat /dev/env/FOO specially: they expand this into the value of 
the environment variable FOO and substitute that value instead of 
/dev/env/FOO.

> I an trying to
> understand how the above terms are expanded by configure and the difference
> between the single quotes '' and the double quotes"".

'${DJDIR}' in single quotes is not expanded by the shell, while in double 
quotes it _is_ expanded immediatly.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019