Mail Archives: djgpp/1997/08/10/16:04:55
Curiouser and curiouser. I have been experimenting, and the following
works, while my original does not. I changed the directory name, too,
in case the name "test" might be mis-interpreted:
sh.exe/stest$ cat makefile
echo :
echo ${SHELL}
recurs :
make cshell SHELL=/bin/sh
cshell :
echo ${SHELL}
sh -c "if test -f makefile; then echo cshell; fi"
sh.exe/stest$ make cshell
echo /bin/sh
/bin/sh
sh -c "if test -f makefile; then echo cshell; fi"
cshell
sh.exe/stest$ make recurs
make cshell SHELL=/bin/sh
make.exe[1]: Entering directory `h:/stest'
echo /bin/sh
/bin/sh
sh -c "if test -f makefile; then echo cshell; fi"
cshell
make.exe[1]: Leaving directory `h:/stest'
sh.exe/stest$
I also realized someone might want to see my ~/.profile and/or
~/.bashrc files. They are identical, and here they are:
sh.exe/stest$ cat ~/.profile
PS1="\s\w\$ "
TERM=win32-win
export PS1 TERM
sh.exe/stest$ cat ~/.bashrc
PS1="\s\w\$ "
TERM=win32-win
export PS1 TERM
sh.exe/stest$
I do not have an /etc/profile file. Here is my environment list:
BASH=/bin/sh.exe
BASH_VERSION=1.14.7(2)
BLASTER=A220 I5 D1 T4
CMD=C:/COMMAND.COM
CMDLINE=H:\bin\sh -login
COMSPEC=C:\COMMAND.COM
DJDIR=h:
DJGPP=H:\DJGPP.ENV
EMU387=h:/bin/emu387.dxe
ETC=C:\TCPDOS\ETC
EUID=42
HISTFILE=h:/usr/users/pjf3/.bash_history
HISTFILESIZE=500
HISTSIZE=500
HOME=//h/usr/users/pjf3
HOSTTYPE=PCAT
IFS=
LFN=y
LIBPATH=C:\MWD\MANAGER
MAILCHECK=60
MWPATH=C:\MWD\MANAGER;C:\MWD\MWGAMES
MWROOT=C:\MWD
OLDPWD=/usr/users/pjf3
OPTERR=1
OPTIND=1
OSTYPE=MSDOS
PATH=/BIN://C/TCPDOS/BIN://C/MWW/DLL://C/MWD/MANAGER://C/PS1TOOLS://C/://C/WINDO
WS://C/WINDOWS/COMMAND://D/BAT://D/UT://D/VS://D/PT
PATH_EXPAND=Y
PATH_SEPARATOR=:
PPID=1
PROMPT=$p$g
PS1=\s\w$
PS2=>
PS4=+
PWD=/stest
SHELL=/bin/sh
SHLVL=1
SVCONFIG=APTIVA
SYSROOT=h:
TEMP=C:\WINDOWS\TEMP
TERM=win32-win
TMP=C:\WINDOWS\TEMP
TMPDIR=h:/tmp
UID=42
USER=dosuser
_=recurs
winbootdir=C:\WINDOWS
windir=C:\WINDOWS
<*Sigh*> Oh, the joys of programming. Once again, TIA for any help
or info you can offer.
Peter
pjfarley AT dorsai DOT org (Peter J. Farley III) wrote:
>I can run the very simple makefile listed below on SunOS Release
>4.1.3_U1, but under DJGPP/bash it always fails. I have listed the
>executables and versions I'm running for both bash and for make, then
>I cat the makefile and show the results of testing it under
>DJGPP/bash. I have created a sh.exe stub, as suggested in the bash
>documentation, so there is a /bin/sh to execute, and it points to
>bash.exe.
>
>I also list the results of running the makefile on SunOS for
>comparison.
>
>Question: Why do I get "Error -1" when I try to make the target
>"cshell" under DJGPP/bash?
>
>TIA for any help or info you can provide.
>
>Peter
>
>--------------- Exe/version info, cat makefile and tests -----------
>
>bash.exe/test$ ls -l /bin/bash*
>-rwxr-xr-x 1 dosuser dos 403968 Jun 7 03:38 /bin/bash.exe
>bash.exe/test$
>GNU bash, version 1.14.7(2) r3.1 w/multibyte extension
>bash.exe/test$ ls -l /bin/make.*
>-rwxr-xr-x 1 dosuser dos 168448 Oct 24 1996 /bin/make.exe
>bash.exe/test$ make --v
>GNU Make version 3.75, by Richard Stallman and Roland McGrath.
>Copyright (C) 1988, 89, 90, 91, 92, 93, 94, 95, 96
> Free Software Foundation, Inc.
>This is free software; see the source for copying conditions.
>There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
>PARTICULAR PURPOSE.
>
>Report bugs to <bug-gnu-utils AT prep DOT ai DOT mit DOT edu>.
>
>bash.exe/test$ cat makefile
>echo :
> echo ${SHELL}
>recurs :
> make cshell SHELL=/bin/sh
>cshell :
> echo ${SHELL}
> if test -f makefile ; then echo cshell ; fi
>bash.exe/test$ make
>echo /bin/sh
>/bin/sh
>bash.exe/test$ make cshell
>echo /bin/sh
>/bin/sh
>if test -f makefile ; then echo cshell ; fi
>make.exe: *** [cshell] Error -1
>bash.exe/test$ make cshell SHELL=/bin/sh
>echo /bin/sh
>/bin/sh
>if test -f makefile ; then echo cshell ; fi
>make.exe: *** [cshell] Error -1
>bash.exe/test$ make cshell SHELL=/bin/bash
>echo /bin/bash
>/bin/bash
>if test -f makefile ; then echo cshell ; fi
>make.exe: *** [cshell] Error -1
>bash.exe/test$
>
>----------- SunOS versions and results ----------------------
>
>[amanda]:~/test$
>GNU bash, version 1.14.6(1)
>[amanda]:~/test$ make --v
>GNU Make version 3.72.1, by Richard Stallman and Roland McGrath.
>Copyright (C) 1988, 89, 90, 91, 92, 93, 94 Free Software Foundation,
>Inc.
>This is free software; see the source for copying conditions.
>There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
>PARTICULAR PURPOSE.
>
>[amanda]:~/test$ make
>echo /bin/sh
>/bin/sh
>[amanda]:~/test$ make cshell
>echo /bin/sh
>/bin/sh
>if test -f makefile ; then echo cshell ; fi
>cshell
>[amanda]:~/test$ make cshell SHELL=/usr/local/bin/bash
>echo /usr/local/bin/bash
>/usr/local/bin/bash
>if test -f makefile ; then echo cshell ; fi
>cshell
>[amanda]:~/test$
----------------------------------------------------
Peter J. Farley III (pjfarley AT dorsai DOT org)
- Raw text -