According to:
 http://msdn.microsoft.com/en-us/library/windows/desktop/ms682653(v=vs.85).aspx

the total size of the environment is 32kByte. This has hit me several
times in GNU-make when CreateProcess() triggers the mysterious error
87 (ERROR_INVALID_PARAMETER). Like in a very simple rule that involves
'echo':

process_begin: CreateProcess(g:\MingW32\msys\bin\echo.exe, echo "Generating 
...", ...) failed.
make (e=87): Parameteren er feil  << Invalid parameter.

I've added a patch to arr2envblk() that checks the Win OS-version and prints a 
warning
if 'size_needed' exceeds 32 kByte.
Googling for this error, returns approx 50.000 hits. So I think this warning is 
warranted.
On Windows Vista and Windows Server 2008 (or above), MS has luckily removed that limit. The command-line length has similar limit on Win-XP and below. But that error is probably easier to spot.

I'm not sure if the warning should be printed only when "--debug=jobs" is in 
effect
or always. But only once. Your choice.

Patch attached.

--gv

Attachment: misc.diff
Description: Binary data

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

Reply via email to