Re: Small DJGPP specific patch.

2022-10-12 Thread Juan Manuel Guerrero
Am Wed, 12 Oct 2022 16:50:40 -0400
schrieb Paul Smith :

> On Wed, 2022-10-12 at 22:18 +0200, Juan Manuel Guerrero wrote:
> > Here is a small patch to get the current make code compiled and
> > running on MSDOS/FreeDOS using DJGPP.  I assume that for such minor
> > changes no paper work is required.
> 
> Correct.  But, note that the FSF considers contributions cumulative, so
> over time if the contributions add up to more significant changes,
> paperwork would be needed.
> 
> > Thank you for keep the DJGPP specific code available.
> 
> Thanks for the patch Juan!

Sorry, I have noted that the patch has been malformed by the mail program
so I submit the same a second time.  Excuse the inconveniences.



2022-10-12  Juan M. Guerrero 

* builddos.bat: Changes required to support building with DJGPP 2.05.

* src/configh.dos.template: Changes required to support building with 
DJGPP 2.05.



diff --git a/builddos.bat b/builddos.bat
index d4ff8a63..d54953e9 100644
--- a/builddos.bat
+++ b/builddos.bat
@@ -49,14 +49,14 @@ gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib 
-DHAVE_CONFIG_H -O2 -g %XSRC%/s
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/dir.c -o dir.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/file.c -o file.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/misc.c -o misc.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/main.c -o main.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DINCLUDEDIR=\"c:/djgpp/include\" -O2 -g %XSRC%/src/read.c -o read.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLIBDIR=\"c:/djgpp/lib\" -O2 -g %XSRC%/src/remake.c -o remake.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLOCALEDIR=\"/dev/env/DJDIR/share/locale\" -O2 -g %XSRC%/src/main.c -o main.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DINCLUDEDIR=\"/dev/env/DJDIR/include\" -O2 -g %XSRC%/src/read.c -o read.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLIBDIR=\"/dev/env/DJDIR/lib\" -O2 -g %XSRC%/src/remake.c -o remake.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/rule.c -o rule.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/implicit.c -o implicit.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/default.c -o default.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/variable.c -o variable.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/expand.c -o eyxpand.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/expand.c -o expand.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/function.c -o function.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/vpath.c -o vpath.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/hash.c -o hash.o
@@ -69,15 +69,16 @@ gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib 
-DHAVE_CONFIG_H -O2 -g %XSRC%/s
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/getopt.c -o getopt.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/getopt1.c -o getopt1.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/shuffle.c -o shuffle.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/load.c -o load.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/lib/glob.c -o lib/glob.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/lib/fnmatch.c -o lib/fnmatch.o
 @echo off
 echo commands.o > respf.$$$
-for %%f in (job output dir file misc main read remake rule implicit default 
variable) do echo %%f.o >> respf.$$$
+for %%f in (job output dir file misc main read remake rule implicit default 
variable load) do echo %%f.o >> respf.$$$
 for %%f in (expand function vpath hash strcache version ar arscan signame 
remote-stub getopt getopt1 shuffle) do echo %%f.o >> respf.$$$
 for %%f in (lib\glob lib\fnmatch) do echo %%f.o >> respf.$$$
-rem gcc  -c -I./src -I%XSRC% -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/guile.c -o guile.o
-rem echo guile.o >> respf.$$$
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/guile.c -o guile.o
+echo guile.o >> respf.$$$
 @echo Linking...
 @echo on
 gcc -o make.exe @respf.$$$
@@ -85,7 +86,7 @@ gcc -o make.exe @respf.$$$
 if not exist make.exe echo Make.exe build failed...
 if exist make.exe echo make.e

Small DJGPP specific patch.

2022-10-12 Thread Juan Manuel Guerrero
Here is a small patch to get the current make code compiled and running
on MSDOS/FreeDOS using DJGPP.  I assume that for such minor changes no
paper work is required.  Thank you for keep the DJGPP specific code available.

Regards,
Juan M. Guerrero




2022-10-12  Juan M. Guerrero 

* builddos.bat: Changes required to support building with DJGPP 2.05.

* src/configh.dos.template: Changes required to support building with 
DJGPP 2.05.



diff --git a/builddos.bat b/builddos.bat
index d4ff8a63..d54953e9 100644
--- a/builddos.bat
+++ b/builddos.bat
@@ -49,14 +49,14 @@ gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib 
-DHAVE_CONFIG_H -O2 -g %XSRC%/s
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/dir.c -o dir.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/file.c -o file.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/misc.c -o misc.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/main.c -o main.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DINCLUDEDIR=\"c:/djgpp/include\" -O2 -g %XSRC%/src/read.c -o read.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLIBDIR=\"c:/djgpp/lib\" -O2 -g %XSRC%/src/remake.c -o remake.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLOCALEDIR=\"/dev/env/DJDIR/share/locale\" -O2 -g %XSRC%/src/main.c -o main.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DINCLUDEDIR=\"/dev/env/DJDIR/include\" -O2 -g %XSRC%/src/read.c -o read.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H 
-DLIBDIR=\"/dev/env/DJDIR/lib\" -O2 -g %XSRC%/src/remake.c -o remake.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/rule.c -o rule.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/implicit.c -o implicit.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/default.c -o default.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/variable.c -o variable.o
-gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/expand.c -o eyxpand.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/expand.c -o expand.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/function.c -o function.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/vpath.c -o vpath.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/hash.c -o hash.o
@@ -69,15 +69,16 @@ gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib 
-DHAVE_CONFIG_H -O2 -g %XSRC%/s
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/getopt.c -o getopt.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/getopt1.c -o getopt1.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/shuffle.c -o shuffle.o
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/load.c -o load.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/lib/glob.c -o lib/glob.o
 gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/lib/fnmatch.c -o lib/fnmatch.o
 @echo off
 echo commands.o > respf.$$$
-for %%f in (job output dir file misc main read remake rule implicit default 
variable) do echo %%f.o >> respf.$$$
+for %%f in (job output dir file misc main read remake rule implicit default 
variable load) do echo %%f.o >> respf.$$$
 for %%f in (expand function vpath hash strcache version ar arscan signame 
remote-stub getopt getopt1 shuffle) do echo %%f.o >> respf.$$$
 for %%f in (lib\glob lib\fnmatch) do echo %%f.o >> respf.$$$
-rem gcc  -c -I./src -I%XSRC% -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/guile.c -o guile.o
-rem echo guile.o >> respf.$$$
+gcc -c -I./src -I%XSRC%/src -I./lib -I%XSRC%/lib -DHAVE_CONFIG_H -O2 -g 
%XSRC%/src/guile.c -o guile.o
+echo guile.o >> respf.$$$
 @echo Linking...
 @echo on
 gcc -o make.exe @respf.$$$
@@ -85,7 +86,7 @@ gcc -o make.exe @respf.$$$
 if not exist make.exe echo Make.exe build failed...
 if exist make.exe echo make.exe is now built!
 if exist make.exe del respf.$$$
-if exist make.exe copy /Y Basic.mk Makefile
+if exist make.exe copy /Y %XSRC%\Basic.mk Makefile
 goto End

 :SmallEnv
diff --git a/src/configh.dos.template b/src/configh.dos.template
index 3f0f6e0a..8e1466b2 100644
--- a/src/configh.dos.template
+++ b/src/configh.dos.template
@@ -97,7 +97,7 @@ this program.  If not, see .  */
 #define PACKAGE_VERSION "%VERSION%"

 /* Output sync support */
-#define NO_OUTPUT_SYNC
+#define NO_OUTPUT_SYNC 1

 /* Version number of package */
 #define VERSION "%VERSION%"
@@ -116,8 +116,1

Re: Deprecating OS support

2022-10-04 Thread Juan Manuel Guerrero
Am Sat, 01 Oct 2022 21:52:03 +0300
schrieb Eli Zaretskii :

> > From: Paul Smith 
> > Cc: bug-make@gnu.org, Juan Manuel Guerrero 
> > Date: Sat, 01 Oct 2022 14:48:01 -0400
> >
> > On Sat, 2022-10-01 at 20:42 +0300, Eli Zaretskii wrote:
> > > The DJGPP project has been routinely porting all versions of Make
> > > up to and including 4.3.
> >
> > By "DJGPP project" I expect you are referring to the MSDOS port (I'm
> > not familiar with all the alternative names).
>
> Yes.  DJGPP is the MSDOS port of GNU development tools, based on GCC
> and GNU Binutils.
>
> > The thing that I'm specifically looking at in the code are ifdef's
> > using __MSDOS__.  Are these the ifdefs used by DJPP?
>
> Yes.

Sorry, I was abscent a couple of days so I could not respond to this.
As Eli already pointed out __MSDOS__ is used by the DJGPP port.  If
this is an incoveniece may be a different macro can be used, like
__DJGPP__ or what ever may see to you as appropriate.
As long as the existing MSDOS/DJGPP support is still part of the make
code I will continue providing ports for the DJGPP community.  If
I encounter some DJGPP specific issue I will try to provide a
port to fix it.

Regards,
Juan M. Guerrero



Re: Some DJGPP specific fixes for Make 4.2.1 and later.

2016-06-12 Thread Juan Manuel Guerrero

Am 12.06.2016 19:28, schrieb Eli Zaretskii (e...@gnu.org) [via 
dj...@delorie.com]:

Date: Sun, 12 Jun 2016 19:18:36 +0200
From: "Juan Manuel Guerrero (juan.guerr...@gmx.de) [via 
dj...@delorie.com]"

 -  For systems like MSDOS, WINDOWS32 and other ones, the function 
get_bad_stdin
is defined as a no-op macro in os.h but at the same time exists an
implementation of the function in posixos.c.  This implementation
is always compiled no matter if __MSDOS__ and/or MAKE_JOBSERVER is
defined or not in posixos.c.  To avoid this contradiction, I have put
the get_bad_stdin definition inside the same #ifdef than the ones used
in os.h.  Please inspect the patch.  This approach is only a suggestion;
may be there is a different way to solve this issue.


posixos.c is not supposed to be compiled on MSDOS (or any other
non-Posix system).  Why is it being compiled in the DJGPP build?

The other changes look fine to me, thanks.



Did not know this.  Because I never know how well maintained are the DJGPP
specific files like Makefile.DOS, etc I prefer to configure it by running
the configure script.  But this had produced a Makefile that had posixos
added to the list of object files thus making the build fail.  But if that
file is supposed not to used at all with non-Posix systems, please ignore
the proposed changes concerning posixos.c.  That is ok with me.


Regards,
Juan M. Guerrero

___
Bug-make mailing list
Bug-make@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-make


Some DJGPP specific fixes for Make 4.2.1 and later.

2016-06-12 Thread Juan Manuel Guerrero

I would like to suggest some fixes that are DJGPP specific but that may also be
usefull for other systems.
A) General issues.
   -  The current version produces for absolute every run the warning:
"Parallel jobs (-j) are not supported on this platform."
  although "-j" has never been passed as argument to the make program.
  The reason is that arg_job_slots is initialized to -1 and no code
  changes this value to 1 for platforms that do not support parallel
  jobs.  Because -1 is different to 1, the warning is countinuously
  issued.  An explicit check for greather than 1 seems the better
  approach.  Please inspect the patch below.
   -  For systems like MSDOS, WINDOWS32 and other ones, the function 
get_bad_stdin
  is defined as a no-op macro in os.h but at the same time exists an
  implementation of the function in posixos.c.  This implementation
  is always compiled no matter if __MSDOS__ and/or MAKE_JOBSERVER is
  defined or not in posixos.c.  To avoid this contradiction, I have put
  the get_bad_stdin definition inside the same #ifdef than the ones used
  in os.h.  Please inspect the patch.  This approach is only a suggestion;
  may be there is a different way to solve this issue.

B) DJGPP specific issues.
   -  Use "/dev/env/DJDIR" to get the installation directory instead of the
  hard coded "c:/djgpp".
   -  Support the creation of documentation in pdf format.  The Makefile.DOS
  has been adjusted accordingly


As usual suggestions, objections, comments are welcome.


Regards,
Juan M. Guerrero





2016-06-12 Juan Manuel Guerrero  

* Makefile.DOS: Added rule to create pdf formated documentation.

* dosbuild.bat:  Use /dev/env/DJDIR instead of c:/djgpp.

* main.c (main):  Issue message about not supported parallel jobs only
if arg_job_slots is set greather than 1.

* posixos.c (get_bad_stdin):  Compile only if not replaced by macro
defined in os.h.





diff -aprNU8 make-4.2.1.orig/dosbuild.bat make-4.2.1/dosbuild.bat
--- make-4.2.1.orig/dosbuild.bat2016-02-28 18:48:44 +0100
+++ make-4.2.1/dosbuild.bat 2016-06-12 17:13:24 +0200
@@ -21,18 +21,18 @@ rem Echo ON so they will see what is goi
 @echo on
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g commands.c -o commands.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g output.c -o output.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g job.c -o job.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g dir.c -o dir.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g file.c -o file.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g misc.c -o misc.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g main.c -o main.o
-gcc  -c -I. -I./glob -DHAVE_CONFIG_H -DINCLUDEDIR=\"c:/djgpp/include\" -O2 -g 
read.c -o read.o
-gcc  -c -I. -I./glob -DHAVE_CONFIG_H -DLIBDIR=\"c:/djgpp/lib\" -O2 -g remake.c 
-o remake.o
+gcc  -c -I. -I./glob -DHAVE_CONFIG_H -DINCLUDEDIR=\"/dev/env/DJDIR/include\" 
-O2 -g read.c -o read.o
+gcc  -c -I. -I./glob -DHAVE_CONFIG_H -DLIBDIR=\"/dev/env/DJDIR/include\" -O2 
-g remake.c -o remake.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g rule.c -o rule.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g implicit.c -o implicit.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g default.c -o default.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g variable.c -o variable.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g expand.c -o expand.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g function.c -o function.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g vpath.c -o vpath.o
 gcc  -c -I. -I./glob -DHAVE_CONFIG_H -O2 -g hash.c -o hash.o
diff -aprNU8 make-4.2.1.orig/main.c make-4.2.1/main.c
--- make-4.2.1.orig/main.c  2016-05-31 09:17:26 +0200
+++ make-4.2.1/main.c   2016-06-12 17:13:24 +0200
@@ -2039,19 +2039,22 @@ main (int argc, char **argv, char **envp

 #if defined (__MSDOS__) || defined (__EMX__) || defined (VMS)
   if (arg_job_slots != 1
 # ifdef __EMX__
   && _osmode != OS2_MODE /* turn off -j if we are in DOS mode */
 # endif
   )
 {
-  O (error, NILF,
- _("Parallel jobs (-j) are not supported on this platform."));
-  O (error, NILF, _("Resetting to single job (-j1) mode."));
+  if (arg_job_slots > 1)
+{
+  O (error, NILF,
+   _("Parallel jobs (-j) are not supported on this platform."));
+  O (error, NILF, _("Resetting to single job (-j1) mode."));
+}
   arg_job_slots = job_slots = 1;
 }
 #endif

   /* If we have >1 slot at this point, then we're a top-level make.
  Set up the jobserver.

  Every make assumes that it always has one job it can run.  For the
diff -aprNU8 make-4.2.1.orig/Makefile.DOS make-4.2.1/Makefile.DOS
--- make-4.2.1.orig/Makefile.DOS2016-06-11 01:03:54 +0200
+++ make-4.2.1/Makefile.DOS 2

Small djgpp specific patch

2010-08-02 Thread Juan Manuel Guerrero
Here is a small patch to make "make" compile out-of-the-box with djgpp.


Regards,

Juan M. Guerrero




2010-07-31 Juan Manuel Guerrero  

* configh.dos: Define HAVE_STRNCASECMP.

* dosbuild.bat:  Use /dev/env/DJDIR instead of c:/djgpp.
Add ./popen.c to the list of objects to build.



diff -aprNU5 make-3.82.orig/configh.dos make-3.82/configh.dos
--- make-3.82.orig/configh.dos  2010-07-28 05:42:18 +
+++ make-3.82/configh.dos   2010-08-02 20:05:40 +
@@ -88,10 +88,13 @@ this program.  If not, see <http://www.g
 #define HAVE_VPRINTF 1
 
 /* Define to 1 if you have the stricmp function.  */
 #define HAVE_STRICMP 1
 
+/* Define to 1 if you have the `strncasecmp' function. */
+#define HAVE_STRNCASECMP 1
+
 /* Name of the package */
 #define PACKAGE "make"
 
 /* Define to the address where bug reports for this package should be sent. */
 #define PACKAGE_BUGREPORT "bug-make@gnu.org"
diff -aprNU5 make-3.82.orig/dosbuild.bat make-3.82/dosbuild.bat
--- make-3.82.orig/dosbuild.bat 2010-07-13 01:20:38 +
+++ make-3.82/dosbuild.bat  2010-08-02 20:05:40 +
@@ -18,18 +18,19 @@ rem with this program.  If not, see http://lists.gnu.org/mailman/listinfo/bug-make


Re: [psm...@gnu.org: GNU make: Next release schedule.]

2009-09-28 Thread Juan Manuel Guerrero
Am Sonntag, 27. September 2009 schrieb Paul Smith:
[snip]
> I haven't heard from Juan regarding the test suite changes yet, either.


Sorry, but due to mayor difficulties with my day time job I cannot care about
the testsuite issue anymore.  I do not think that this is a mayor issue.  The
most important topics concerning a working DJGPP port of make have been the
absolute path issue and the makefile issue.  Both have been fixed.  The 
testsuite
difficulties can be fixed in the DJGPP port itself by the person who decides to
build it and upload it to ftp.delorie.com.  A serious fix of the testsuite to
be included in the official make code can be presented some time later.

Regards,
Juan M. Guerrero




___
Bug-make mailing list
Bug-make@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-make


Re: [psm...@gnu.org: GNU make: Next release schedule.]

2009-09-17 Thread Juan Manuel Guerrero
Am Mittwoch, 16. September 2009 schrieb Eli Zaretskii:
> FYI
> 
> Juan, this would be a good time to resubmit your DJGPP patches, so
> that they will be included in Make 3.82.
> 
> Thanks.
> 
[snip]

This patch contains the changes required to compile and run the testsuite
using DJGPP.  It is basicaly the same that I have submitted almost two years
ago.  I have removed the part to fix the broken path support for MSDOS/WINDOWS
because this has already been fixed.
For a description of what the patch was supposed to fix in its original version
see:
<http://lists.gnu.org/archive/html/bug-make/2008-01/msg8.html>
<http://lists.gnu.org/archive/html/bug-make/2008-06/msg00059.html>


Regards,
Juan M. Guerrero



2008-01-14  Juan Manuel Guerrero  

* glob/glob.c (my_realloc): Don't define, and don't redefine realloc
to call it since the DJGPP realloc handles NULL pointers.

* configh.dos.template: Remove unconditional definition of 
SYS_SIGLIST_DECLARED.
Include  because ports of GCC 4.3.0 and later no longer
include it, so macros like __DJGPP_MINOR__ are no longer defined 
automatically.

* Makefile.DOS.template (INCLUDES): Use $(prefix) and the corresponding
variables to define LIBDIR, INCLUDEDIR and LOCALEDIR instead of using
the hardcoded ones.
(SUBDIRS): doc subdir added.
(INFO_DEPS, DVIS): Values changed to 'make.info' and 'make.dvi'.
(TEXI2HTML, TEXI2HTML_FLAGS): Removed.  Use makeinfo --html to
create html formated docs.  texi2html may not be ported to DOS.
(make.info, make.dvi, make.ps, make.html): Make targets depend on
'make.texi'.
(.texi.info, .texi, .texi.dvi): Now recursively invocate.  Change
-I switch to look in ./ instead of ./doc.
(html): Target depend on html-recursive instead of make_1.html.
(make_1.html): Removed.
(mostlyclean-aminfo): Use $(srcdir)/doc instead of ./ as prefix.
(all-recursive): Allow for more than one subdir in the build process.
(mostlyclean-recursive, clean-recursive, distclean-recursive,
maintainer-clean-recursive, check-recursive): Enter in doc/ too.
(tags-recursive): Allow for more than one subdir in the build process.
(info-recursive, dvi-recursive, ps-recursive, html-recursive): New
targets.  Enter into doc/ to produce the targets.
(all-am): $(INFO_DEPS) replaced by info.

* tests/scripts/options/dash-B: Define $error_message to allow for an
error message that may be specific to a particular libc implementation.

* tests/scripts/options/dash-k: Define $error_message to allow for an
error message that may be specific to a particular libc implementation.

* tests/scripts/options/dash-W: Define $error_message to allow for an
error message that may be specific to a particular libc implementation.

* tests/scripts/targets/SECONDARY: If the port does not support
parallelism inhibit test cases #9 and #10 (Savannah bug #15919).

* tests/scripts/variables/MAKE_RESTARTS: Define $error_message to allow
error message that may be specific to a particular libc implementation.

* tests/scripts/variables/SHELL: If compiled with DJGPP, do not run
this test at all.




Index: Makefile.DOS.template
===
RCS file: /sources/make/make/Makefile.DOS.template,v
retrieving revision 2.16
diff -u -r2.16 Makefile.DOS.template
--- Makefile.DOS.template   22 Dec 2007 12:07:36 -  2.16
+++ Makefile.DOS.template   17 Sep 2009 19:54:09 -
@@ -2,7 +2,7 @@
 # Makefile.in generated automatically by automake 1.2 from Makefile.am
 #
 # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
-# 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+# 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 # This file is part of GNU Make.
 #
 # GNU Make is free software; you can redistribute it and/or modify it under
@@ -85,13 +85,13 @@
 
 man_MANS = make.1
 
-INCLUDES = -I$(srcdir)/glob -DLIBDIR=\"c:/djgpp/lib\" 
-DINCLUDEDIR=\"c:/djgpp/include\" -DLOCALEDIR=\"$(localedir)\"
+INCLUDES = -I$(srcdir)/glob -DLIBDIR=\"$(prefix)$(libdir)\" 
-DINCLUDEDIR=\"$(prefix)$(includedir)\" -DLOCALEDIR=\"$(prefix)$(localedir)\"
 
 BUILT_SOURCES =README build.sh-in
 
 EXTRA_DIST =   $(BUILT_SOURCES) $(man_MANS) README.customs remote-cstms.c  
make-stds.texi texinfo.tex SCOPTIONS SMakefile  Makefile.ami README.Amiga 
config.ami amiga.c amiga.h  NMakefile README.DOS configh.dos configure.bat 
makefile.com  README.W32 build_w32.bat config.h-W32 subproc.bat make.lnk  
config.h-vms makefile.vms readme.vms vmsdir.h vmsfunctions.c  vmsify.c
 
-SUBDIRS =  glob
+SUBDIRS =

Reimplementing DJGPP support for make.

2008-06-30 Thread Juan Manuel Guerrero
directory (ENOENT)

Although the test was successful, diff will note the difference in the output
strings and will report that the test has failed.  To avoid this kind of
failure the following lines have been added where they were required:

if ($port_type eq "DOS") {
  if (exists $ENV{DJDIR}) {
$error_message = '(ENOENT)';
  }
}
else {
  $error_message = '';
}

This concerns the tests options/dash-B, options/dash-k, options/dash-W and
variables/MAKE_RESTARTS.


3) The supplementary DOS specific build files
The most important change is that $(prefix) is used to define the variables
LIBDIR, INCLUDEDIR and LOCALEDIR instead of hard coded ones.  Also the way
the docs are generated have been modified so that the results and intermediary
files are generated in doc/ instead of the $(srcdir).



For further  details, please inspect the patch.
As usual suggestions, objections, comments are welcome.


Regards,
Juan M. Guerrero





2008-06-30  Juan Manuel Guerrero  <[EMAIL PROTECTED]>

* implicit.c: Add const qualifier to *lastslash so it matches the
declaration of *filename.

* dir.c (file_exists_p) [HAVE_DOS_PATHS]: Use IS_DRIVE_SPECIFIER.
(file_impossible) [HAVE_DOS_PATHS]: Use IS_DRIVE_SPECIFIER.
(file_impossible_p) [HAVE_DOS_PATHS]: Use IS_DRIVE_SPECIFIER.

* function.c [HAVE_DOS_PATHS, VMS]: Remove IS_PATHSEP definition.
Now it is defined in its canonical place in make.h.
(abspath) [HAVE_DOS_PATHS]: Use IS_DIR_SEPARATOR instead of a literal 
'/'
and '\\'.
Support d:foo style absolute file names.
Add logic for the case that backslash are path separators too.
Include colon as separator char in the IS_DIR_SEPARATOR definition and
use it to check for root char.
(func_notdir_suffix, func_basename_dir, abspath): Use IS_DRIVE_SPECIFIER
and IS_DIR_SEPARATOR.

* glob/glob.c (my_realloc): Don't define, and don't redefine realloc
to call it since the DJGPP realloc handles NULL pointers.

* hash.c (round_up_2): Use 4294967295U to avoid compiler warnings.

* implicit.c (pattern_search) [HAVE_DOS_PATHS]: Use IS_DRIVE_SPECIFIER.

* make.h: All OS specific macros to handle path syntax peculiarities
are defined here.
[HAVE_DOS_PATHS]: New macro IS_DRIVE_SPECIFIER to check for drive 
specifier
strings like 'a:'.  For all other supported OSs this macro is empty
and optimzed out.
[HAVE_DOS_PATHS, VMS]:  Define macro IS_DIR_SEPARATOR.  Previous 
definition
of IS_PATHSEP in function.c removed accordingly.

* vpath.c (construct_vpath_list) [HAVE_DOS_PATHS, PATH_SEPARATOR_CHAR]: 
Use
IS_DIR_SEPARATOR instead of a literal '/' and '\\'.
(vpath_search) [HAVE_DOS_PATHS]: Use IS_ABSOLUTE.

* configure.in (PATH_SEPARATOR_CHAR): Definition of PATH_SEPARATOR_CHAR
removed.  Now PATH_SEPARATOR_CHAR is always defined in make.h in a OS
dependent way.

* configh.dos.template: Remove unconditional definition of 
SYS_SIGLIST_DECLARED.
Include  because ports of GCC 4.3.0 and later no longer
include it, so macros like __DJGPP_MINOR__ are no longer defined 
automatically.

* Makefile.DOS.template (INCLUDES): Use $(prefix) and the corresponding
variables to define LIBDIR, INCLUDEDIR and LOCALEDIR instead of using
the hardcoded ones.
(SUBDIRS): doc subdir added.
(INFO_DEPS, DVIS): Values changed to 'make.info' and 'make.dvi'.
(TEXI2HTML, TEXI2HTML_FLAGS): Removed.  Use makeinfo --html to
create html formated docs.  texi2html may not be ported to DOS.
(make.info, make.dvi, make.ps, make.html): Make targets depend on
'make.texi'.
(.texi.info, .texi, .texi.dvi): Now recursively invocate.  Change
-I switch to look in ./ instead of ./doc.
(html): Target depend on html-recursive instead of make_1.html.
(make_1.html): Removed.
(mostlyclean-aminfo): Use $(srcdir)/doc instead of ./ as prefix.
(all-recursive): Allow for more than one subdir in the build process.
(mostlyclean-recursive, clean-recursive, distclean-recursive,
maintainer-clean-recursive, check-recursive): Enter in doc/ too.
(tags-recursive): Allow for more than one subdir in the build process.
(info-recursive, dvi-recursive, ps-recursive, html-recursive): New
targets.  Enter into doc/ to produce the targets.
(all-am): $(INFO_DEPS) replaced by info.

* dosbuild.bat: Add -DLOCALEDIR to compiler command line to compile
main.c.
Remove make.new if build successfull.
Use /dev/env/DJDIR instead of c:/djgpp for -DINCLUDEDIR and
-DLOCALEDIR.

* tests/scripts/functions/abspath: Added new MSDOS sp

Re: Fixing broken djgpp support in make 3.81

2008-01-15 Thread Juan Manuel Guerrero
Hello Paul:

[snip]
> It seems like the amount of change you've made will require
> copyright assignment.  I see you've already done some of these,
> for Bison etc., but if you need paperwork let me know.

Please send the required paperwork to me or let me known
where I can get it and I will sign the copyright assignment.


> As for the above, I wonder whether it might be useful to add:
>
>   # define HAVE_DRIVE(n)0
>
> for the non-HAVE_DOS_PATHS sections of the above ifdef.  That would
> allow us to use HAVE_DRIVE(foo) without enclosing it in ifdefs for DOS
> etc., and still have the compiler omit the code (via optimization of
> always-false values).

You are right and that is the way i would do it but an inspection of
the make code showed me that all code lines where the macro can be used
were enclosed by ifdefs for DOS, so I have assumed that this was the
prefered coding style and in such a case it made no much sense to me
to define macros that would never be used for other OSs.  If some day
someone decides to criticaly review the existing code, one of the goals
should be to get rid of all these #ifdef HAVE_DOS_PATHS and VMS (if
possible at all) and to replace that code with some generic path syntax
handling code that will make use of such macros to hide OS path syntax
peculiarities.  Then it will become responsability of the different
port maintainers to provide adecuate macros to handle the issue.


I resend the patch with included empty/false definitions of HAVE_DRIVE
for the other OSs in make.h and also fixed character set issues I have
noticed to late in the changelog text.


Regards,
Juan M. Guerrero



2008-01-15  Juan Manuel Guerrero  <[EMAIL PROTECTED]>

* implicit.c: Add const qualifier to *lastslash so it matches the
declaration of *filename.

* dir.c (file_exists_p) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.
(file_impossible) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.
(file_impossible_p) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.

* function.c [HAVE_DOS_PATHS, VMS]: Remove IS_PATHSEP definition.
Now it is defined in its canonical place in make.h.
(abspath) [HAVE_DOS_PATHS]: Use IS_PATHSEP instead of a literal '/'.
Support d:foo style absolute file names.
Add logic for the case that backslash are path separators too.
Include colon as separator char in the IS_PATHSEP definition and
use it to check for root char.
(func_notdir_suffix, func_basename_dir, abspath): Use HAVE_DRIVE.

* glob/glob.c (my_realloc): Don't define, and don't redefine realloc
to call it since the DJGPP realloc handles NULL pointers.

* hash.c (round_up_2): Use 4294967295U to avoid compiler warnings.

* implicit.c (pattern_search) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.

* make.h: All OS specific macros to handle path syntax peculiarities
are defined here.
[HAVE_DOS_PATHS]: New macro HAVE_DRIVE to check for drive specifier
strings like 'a:'.  For all other supported OSs this macro is a no
operation.
[HAVE_DOS_PATHS, VMS]:  Define macro IS_PATHSEP.  Previous definition
in function.c removed accordingly.

* Makefile.DOS.template (INCLUDES): Use $(prefix) and the corresponding
variables to define LIBDIR, INCLUDEDIR and LOCALEDIR instead of using
the hardcoded ones.
(SUBDIRS): doc subdir added.
(INFO_DEPS, DVIS): Values changed to 'make.info' and 'make.dvi'.
(TEXI2HTML, TEXI2HTML_FLAGS): Removed.  Use makeinfo --html to
create html formated docs.  texi2html may not be ported to DOS.
(make.info, make.dvi, make.ps, make.html): Make targets depend on
'make.texi'.
(.texi.info, .texi, .texi.dvi): Now recursively invocate.  Change
-I switch to look in ./ instead of ./doc.
(html): Target depend on html-recursive instead of make_1.html.
(make_1.html): Removed.
(mostlyclean-aminfo): Use $(srcdir)/doc instead of ./ as prefix.
(all-recursive): Allow for more than one subdir in the build process.
(mostlyclean-recursive, clean-recursive, distclean-recursive,
maintainer-clean-recursive, check-recursive): Enter in doc/ too.
(tags-recursive): Allow for more than one subdir in the build process.
(info-recursive, dvi-recursive, ps-recursive, html-recursive): New
targets.  Enter into doc/ to produce the targets.
(all-am): $(INFO_DEPS) replaced by info.

* dosbuild.bat: Add -DLOCALEDIR to compiler command line to compile
main.c.
Remove make.new if build successfull.
Use /dev/env/DJDIR instead of c:/djgpp for -DINCLUDEDIR and
-DLOCALEDIR.

* tests/scripts/functions/abspath: Added new MSDOS specific tests.
They reproduce the complete test cases adding up t

Re: Fixing broken djgpp support in make 3.81

2008-01-14 Thread Juan Manuel Guerrero
the DJGPP port will produce output like this:

 #MAKEFILE#:4: foo.x: No such file or directory (ENOENT)

Although the test was successful, diff will note the difference in the output
strings and will report that the test has failed.  To avoid this kind of
failure the following lines have been added where they were required:

if ($port_type eq "DOS") {
  if (exists $ENV{DJDIR}) {
$error_message = '(ENOENT)';
  }
}
else {
  $error_message = '';
}

This concerns the tests options/dash-B, options/dash-k, options/dash-W and
variables/MAKE_RESTARTS.


3) The supplementary DOS specific build files
The most important change is that $(prefix) is used to define the variables
LIBDIR, INCLUDEDIR and LOCALEDIR instead of hard coded ones.  Also the way
the docs are generated have been modified so that the results and intermediary
files are generated in doc/ instead of the $(srcdir).



For further  details, please inspect the path.
I cc the message to djgpp-workers, may be someone else want to contribute
something.  As usual suggestions, objections, comments are welcome.


Regards,
Juan m. Guerrero





2008-01-14  Juan Manuel Guerrero  <[EMAIL PROTECTED]>

* implicit.c: Add const qualifier to *lastslash so it has the
same one than *filename and to avoid compiler warnings.

* dir.c (file_exists_p) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.
(file_impossible) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.
(file_impossible_p) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.

* function.c [HAVE_DOS_PATHS, VMS]: Remove IS_PATHSEP definition.
Now it is defined in its canonical place in make.h.
(abspath) [HAVE_DOS_PATHS]: Use IS_PATHSEP instead of a literal '/'.
Support d:foo style absolute file names.
Add logic for the case that backslash are path separators.
Include colon as separator char in the IS_PATHSEP definition and
use it to check for root char.
(func_notdir_suffix, func_basename_dir, abspath): Use HAVE_DRIVE.

* glob/glob.c (my_realloc): Don't define, and don't redefine realloc
to call it since the DJGPP realloc handles NULL pointers.

* hash.c (round_up_2): Use 4294967295U to avoid compiler warnings.

* implicit.c (pattern_search) [HAVE_DOS_PATHS]: Use HAVE_DRIVE.

* make.h: All OS specific macros to handle path peculiarities are
defined here.
[HAVE_DOS_PATHS]: New macro HAVE_DRIVE to check for drive specifier
strings like`a:�.
[HAVE_DOS_PATHS, VMS]:  Define macro IS_PATHSEP.

* Makefile.DOS.template (INCLUDES): Use $(prefix) instead of the
hardcoded ones in LIBDIR, INCLUDEDIR and LOCALEDIR.
(SUBDIRS): doc subdir added.
(INFO_DEPS, DVIS): Values changed to `make.info� and `make.dvi�.
(TEXI2HTML, TEXI2HTML_FLAGS): Removed.  Use makeinfo --html to
create html formated docs.  texi2html may not be ported to DOS.
(make.info, make.dvi, make.ps, make.html): Make targets depend on
`make.texi�.
(.texi.info, .texi, .texi.dvi): Now recursively invocate.  Change
-I switch to look in ./ instead of ./doc.
(html): Target depend on html-recursive instead of make_1.html.
(make_1.html): Removed.
(mostlyclean-aminfo): Use $(srcdir)/doc instead of ./ as prefix.
(all-recursive): Allow for more than one subdir in the build process.
(mostlyclean-recursive, clean-recursive, distclean-recursive,
maintainer-clean-recursive, check-recursive): Enter in doc/ too.
(tags-recursive): Allow for more than one subdir in the build process.
(info-recursive, dvi-recursive, ps-recursive, html-recursive): New
targets.  Enter into doc/ to produce the targets.
(all-am): $(INFO_DEPS) replaced by info.

* dosbuild.bat: Add -DLOCALEDIR to command line to compile main.c.
Remove make.new if build successfull.
Use /dev/env/DJDIR instead of c:/djgpp for -DINCLUDEDIR and
-DLOCALEDIR.

* tests/scripts/functions/abspath: Added new MSDOS specific tests.
They reproduce the complete testcases but using backslash instead
of slash as dir separator and prepend a DOS typical drive letter.
They are only started if DJGPP is used as compiler.

* tests/scripts/options/dash-B: Define $error_message to allow for an
error message that may be issued by different systems.

* tests/scripts/options/dash-k: Define $error_message to allow for an
error message that may be issued by different systems.

* tests/scripts/options/dash-W: Define $error_message to allow for an
error message that may be issued by different systems.

* tests/scripts/targets/SECONDARY: If the port does not support
parallelism inhibit test cases #9 and #10 (Savannah bug #15919).

  

Fixing broken djgpp support in make 3.81

2007-11-20 Thread Juan Manuel Guerrero
 be added.  It would also be usefull
not to split the MSDOS version of make.info anymore.  The extensions .info-[0-9]
are changed to .i[0-9] to acomplish with the 8.3 file name rule but it is always
forgotten to adjust the file name strings in make.info accordingly.  All this
difficulties can be avoided by no spliting the info formated docs anymore.

I have compiled make 3.81 on WinXP(home) with djdev204 and the djgpp ports of
gcc 4.2.2, binutils 2.17 and perl 5.8.8.  If more information is needed, please
contact me.

I have cc the mail to djgpp-workers.  May be that someone there has some
djgpp specific fix to contribute.


Regards,
Juan M. Guerrero



2007-11-19  Juan Manuel Guerrero  <[EMAIL PROTECTED]>

* glob/glob.c [__GNU_LIBRARY__] [__DJGPP__]: Add a realloc declaration
that matches the djgpp's libc one.

* configh.dos [__DJGPP__]: Replace HAVE_SYS_SIGLIST with 
HAVE_DECL_SYS_SIGLIST.

* job.c (child_execute_job): Remove __MSDOS__ because MSDOS/DJGPP build
do not use child_execute_job.

* variable.c (define_automatic_variables) [__MSDOS__]: Export always
the SHELL environment variable to the child.





diff -aprNU5 make-3.81.orig/configh.dos make-3.81/configh.dos
--- make-3.81.orig/configh.dos  2006-04-01 06:42:38 +
+++ make-3.81/configh.dos   2007-11-15 05:12:02 +
@@ -23,11 +23,11 @@ Foundation, Inc., 51 Franklin St, Fifth 
 
 /* Define if `sys_siglist' is declared by .  */
 # define SYS_SIGLIST_DECLARED 1
 
 /* Define this if the C library defines the variable `_sys_siglist'.  */
-# define HAVE_SYS_SIGLIST 1
+# define HAVE_DECL_SYS_SIGLIST 1
 
 #else
 
 /* Define NSIG.  */
 # define NSIG SIGMAX
diff -aprNU5 make-3.81.orig/glob/glob.c make-3.81/glob/glob.c
--- make-3.81.orig/glob/glob.c  2006-03-10 02:20:44 +
+++ make-3.81/glob/glob.c   2007-11-15 01:58:30 +
@@ -187,16 +187,19 @@ __inline
 # endif
 # ifndef __SASC
 #  ifdef WINDOWS32
 static void *
 my_realloc (void *p, unsigned int n)
+#  elif defined(__DJGPP__)
+static void *
+my_realloc (void *p, size_t n)
 #  else
 static char *
 my_realloc (p, n)
  char *p;
  unsigned int n;
-# endif
+#  endif
 {
   /* These casts are the for sake of the broken Ultrix compiler,
  which warns of illegal pointer combinations otherwise.  */
   if (p == NULL)
 return (char *) malloc (n);
diff -aprNU5 make-3.81.orig/job.c make-3.81/job.c
--- make-3.81.orig/job.c2006-03-20 03:03:04 +
+++ make-3.81/job.c 2007-11-15 01:58:30 +
@@ -1890,11 +1890,11 @@ start_waiting_jobs (void)
 }
  
 #ifndef WINDOWS32
 
 /* EMX: Start a child process. This function returns the new pid.  */
-# if defined __MSDOS__ || defined __EMX__
+# if defined __EMX__
 int
 child_execute_job (int stdin_fd, int stdout_fd, char **argv, char **envp)
 {
   int pid;
   /* stdin_fd == 0 means: nothing to do for stdin;
diff -aprNU5 make-3.81.orig/variable.c make-3.81/variable.c
--- make-3.81.orig/variable.c   2006-03-08 20:15:08 +
+++ make-3.81/variable.c2007-11-15 01:58:30 +
@@ -793,10 +793,13 @@ define_automatic_variables (void)
 #endif
 
   /* This won't override any definition, but it will provide one if there
  isn't one there.  */
   v = define_variable ("SHELL", 5, default_shell, o_default, 0);
+#ifdef __MSDOS__
+  v->export = v_export;  /*  Export always SHELL.  */
+#endif
 
   /* On MSDOS we do use SHELL from environment, since it isn't a standard
  environment variable on MSDOS, so whoever sets it, does that on purpose.
  On OS/2 we do not use SHELL from environment but we have already handled
  that problem above. */


make.exe: *** No rule to make target `make.texinfo', needed by `make.info'.
Making check in glob
e:/p2/__/make-3.81/make.exe -C glob -f ../Makefile check-am
make.exe[1]: Entering directory `e:/p2/__/make-3.81/glob'
make.exe[1]: Nothing to be done for `check-am'.
make.exe[1]: Leaving directory `e:/p2/__/make-3.81/glob'
If Make says Error -1, you do not have Unix-style shell installed
cd tests && perl ./run_make_tests.pl -make ../make.exe 
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LC_ALL = (unset),
LANG = "de"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
--
 Running tests for GNU make on MS-DOS MEIN_COM 5 i786
GNU Make 3.81
--

Finding tests...

features/comments ... ok (1 passed)
features/conditionals ... ok (4 passed)
features/default_names .. ok (2 passed)
features/double_colon