This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: xm-djgpp.h undefined function?
- To: Neil Booth <neil at daikokuya dot demon dot co dot uk>, gcc at gcc dot gnu dot org
- Subject: Re: xm-djgpp.h undefined function?
- From: "Mark E." <snowball3 at bigfoot dot com>
- Date: Sat, 11 Aug 2001 19:44:25 -0400
> It uses a function called _fixpath (), but
> I can find no definition of it. The only reference to it in the GCC
> tree is in the macro.
_fixpath is a djgpp-specific function to canonicalize a path. It's needed to
canonicalize paths using the default djgpp prefix which is '/dev/env/DJDIR'.
DJGPP can be installed by a user in any directory, and this type of path was
invented so configure scripts and the generated makefiles will do the right
thing, especially when distributed pre-configured. The environment variable
DJDIR points to the root directory of the djgpp installation, so
"/dev/env/DJDIR" evaluates to the value of "DJDIR".
UPDATE_PATH_HOST_CANONICALIZE turns "/dev/" paths into canonical form
("/dev/env/DJDIR" evaluates to "c:/djgpp" if DJDIR contains "c:/djgpp" for
example). This is done to prevent paths in this specicial form from being
passed to gcc.c's make_relative_prefix. make_relative_prefix has no way of
knowing that "/dev/env/DJDIR" and "c:/djgpp" can be the same, so it will
generate bad output as a result. So the upshot is "/dev/env/DJDIR" is turned
into its result "c:/djgpp" to keep gcc.c's make_relative_prefix happy.
Mark