Mail Archives: djgpp/1996/11/25/12:10:49
On Mon, 25 Nov 1996, Koen Van Herck wrote:
> does anyone know if it is possible to detect the installation path of
> djgpp in a makefile ? I want to do the following:
>
> INSTALLDIR = a:/
> DJGPP_PATH = ?????
Every DJGPP program, including Make (if it is compiled with DJGPP) gets an
environment variable called DJDIR which points to the top DJGPP
installation directory, assuming that the machine where you run this
defines the DJGPP environment variable (set DJGPP=c:/djgpp/djgpp.env) and
if DJGPP.ENV was not screwed up by the user who edited it. If you cannot
assume the above (i.e., you want your installer to work on broken DJGPP
installations), then there is no way to achieve what you want. Otherwise,
just say this:
DJGPP_PATH = $(DJDIR)
> install:
> cp $(DJGPP_PATH)/bin/cwsdpmi.exe $(INSTALLDIR)
> cp myprog.exe $(INSTALLDIR)
Why do you need to copy CWSDPMI at all? If it's on the PATH, the stub
will always find it. It doesn't have to be in the same directory as your
DJGPP program.
- Raw text -