makefile
makefile
Hi there,
I don't want to set the path's and options for the compiler in the Dialogs because I have to compile with several compilers.
So I'm writing my own makefiles. If I try to make(Workspace Make) or Compile (in Compile/Option Commandline = Make)
I get the Error
cl -o testzeus main.obj /link /LIBPATH:"C:\Programme\Microsoft Visual C++ Toolkit 2003\lib" /LIBPATH:"C:\Programme\Microsoft Platform SDK for Windows XP SP2\LIB" user32.lib gdi32.lib program.res
process_easy: DuplicateHandle(In) failed (e=6)
make: Interrupt/Exception caught (code = 0xc0000005, addr = 0x4163a4)
The makefile runs in the shell.
Have you an idea?
dirk
I don't want to set the path's and options for the compiler in the Dialogs because I have to compile with several compilers.
So I'm writing my own makefiles. If I try to make(Workspace Make) or Compile (in Compile/Option Commandline = Make)
I get the Error
cl -o testzeus main.obj /link /LIBPATH:"C:\Programme\Microsoft Visual C++ Toolkit 2003\lib" /LIBPATH:"C:\Programme\Microsoft Platform SDK for Windows XP SP2\LIB" user32.lib gdi32.lib program.res
process_easy: DuplicateHandle(In) failed (e=6)
make: Interrupt/Exception caught (code = 0xc0000005, addr = 0x4163a4)
The makefile runs in the shell.
Have you an idea?
dirk
Which version of windows are you running? When it comes to spawing processes each version of Windows does have a habit of working slightly differently 
To check that it is not some sort of environment variable issue, use the Options Editor Options menu and in the General section turn on the Help debug tools, macros and executables option. With this option enabled Zeus will display the make command line that it being run.
Next use the Tools, Dos Shell menu to bring up a command prompt and run the same make command. This would hopefully result in the same runtime error and if it does this means the error is environment related.
I am assuming this compile was run by the make tool. What type of make utility is it? Is the make utility a DOS or a Win32 based executable? It does not look like the microsoft nmake tool.
One other thing worth trying is setting up a tool to run the make and see if tool behaves in the same manner. Also try running the tool visible, but turn off the option to capture the output and see if that has any effect.
Jussi

To check that it is not some sort of environment variable issue, use the Options Editor Options menu and in the General section turn on the Help debug tools, macros and executables option. With this option enabled Zeus will display the make command line that it being run.
Next use the Tools, Dos Shell menu to bring up a command prompt and run the same make command. This would hopefully result in the same runtime error and if it does this means the error is environment related.
Code: Select all
cl -o testzeus main.obj /link /LIBPATH:"C:\Programme\Microsoft Visual C++ Toolkit 2003\lib" /LIBPATH:"C:\Programme\Microsoft
Platform SDK for Windows XP SP2\LIB" user32.lib gdi32.lib program.res
process_easy: DuplicateHandle(In) failed (e=6)
make: Interrupt/Exception caught (code = 0xc0000005, addr = 0x4163a4)
I am assuming this compile was run by the make tool. What type of make utility is it? Is the make utility a DOS or a Win32 based executable? It does not look like the microsoft nmake tool.
One other thing worth trying is setting up a tool to run the make and see if tool behaves in the same manner. Also try running the tool visible, but turn off the option to capture the output and see if that has any effect.
Jussi
make
Hi Jussi,
first of all thanks for your fast reply!
I'm working with Windows XP SP2.
If I use Toos/DosShell the make command works.
I'm using GNU Make version 3.78.1 compiled for Win32.
If I disable capture standard error I get the message "Compilation completed successfully" but nothing is done(no exe file). I see only the fist line of my makefile in the compileroutputwindow, the second is missing.
If I'm enable capture standard error I get the message I've send yesterday.
If I disable both it works fine.
dirk
first of all thanks for your fast reply!
I'm working with Windows XP SP2.
If I use Toos/DosShell the make command works.
I'm using GNU Make version 3.78.1 compiled for Win32.
If I disable capture standard error I get the message "Compilation completed successfully" but nothing is done(no exe file). I see only the fist line of my makefile in the compileroutputwindow, the second is missing.
If I'm enable capture standard error I get the message I've send yesterday.
If I disable both it works fine.

dirk
That rules out the environment variablesIf I use Toos/DosShell the make command works.

As the names of the check boxes suggest, they control what program output Zeus will try to capture. So it looks like the make utility is not happy with Zeus trying to capture its outputI'm using GNU Make version 3.78.1 compiled for Win32.
....
If I disable both it works fine. [Very Happy]

Looking back, the error message DuplicateHandle(In) failed (e=6) hints of this fact. As to why the this is happening, unfortunately I have no idea

But there are two other options that may yet fix the output capture problem entirely. Currently I am assuming you have a command line something like this:
Code: Select all
make -f "$pf"
The first option would be to create a my_make.cmd batch file as the follows:
Code: Select all
@echo off
echo Running my_make.cmd for make file: %1
make -f %1
Code: Select all
my_make.cmd "$pf"
If that does not work, the final option would be to change the batch file to read:
Code: Select all
@echo off
echo Running my_make.cmd for make file: %1
make -f %1 >>%1.err 2>&1
type %1.err
Jussi
In an effort to better understand this bug, I ran a quick search of google for the error message:
DuplicateHandle(In) failed (e=6)
From the results found it appears that Zeus is not the only IDE are having problems with this GNU make utility.
Jussi
DuplicateHandle(In) failed (e=6)
From the results found it appears that Zeus is not the only IDE are having problems with this GNU make utility.
Jussi
Last edited by jussij on Sun Jul 12, 2009 5:28 am, edited 1 time in total.
hi jussi,
with a little change the batch runs.
I have to start make in his own enviroment (command /c) otherwise make becomes the error with the duplicated handel.
dirk
with a little change the batch runs.

Code: Select all
@echo off
command /c make -f Makefile > makefile.err 2>>&1
type Makefile.err
dirk
Hi Dirk,

I can see how that would help.
Does it also work if you use cmd.exe /c instead of command.exe /c. The command.exe is the older DOS command interpreter where as cmd.exe is the newer NT command interpreter, so it might be better to use cmd.exe if you can.
Jussi
That is good newswith a little change the batch runs.

Very nice idea@echo off
command /c make -f Makefile > makefile.err 2>>&1
type Makefile.err
I have to start make in his own enviroment (command /c) otherwise make becomes the error with the duplicated handel.

Does it also work if you use cmd.exe /c instead of command.exe /c. The command.exe is the older DOS command interpreter where as cmd.exe is the newer NT command interpreter, so it might be better to use cmd.exe if you can.
Jussi
makefile
Hi Jussi,
I see no chance with cmd.exe /C because it use the handle off the first batch. I've tested it with cmd.exe /C CALL but there ist the same error.
so good old dos...
dirk
I see no chance with cmd.exe /C because it use the handle off the first batch. I've tested it with cmd.exe /C CALL but there ist the same error.
so good old dos...
dirk