Hi Martin, you may take a look at the "start" command in Windows, http://ss64.com/nt/start.html Unless you specify the option "/wait", it will do what you seem to need. If your program doesn't provide its own window, you may need to add a separate CMD shell, like in start cmd.exe /c "dir c:\ /P" And since "Start" seems to be a built-in command for CMD.EXE, for make to perform the operation you may need an extra CMD call in the make rule or provide a batch file for the commands in the make rule: MyRule: cmd /c "start myprogram.exe" Combinations possible, and possibly necesary.
HTH, Johan -- JB Enterprises - Johan Bezem Tel: +49 172 5463210 Software Architect - Project Manager Fax: +49 172 50 5463210 Realtime / Embedded Consultant Email: j.be...@computer.org Design - Development - Test - QA Web: http://www.bezem.de ----- original message -------- Subject: start and stop a program by make Sent: Mon, 19 Oct 2009 From: Martin Mensch Hello, I was posting this already in help-make, and Paul Smith advised me to try it here. So first my original posting and then a part of the answer of Paul which is related to UNIX. Maybe someone knows how things are with WinXP. my original posting:I would like to start a program by using a make rule. I know that compilers and so on are all programs. The ones that I want to start do not finish and so don't send an error code back and as much as I have seen make then just waits for the error code to come. Here is an example: my_rule: program1.exe arg1 arg2 program2.exe arg1 arg2 This should start program1 and leave it running and then start program2 and leave it running. But what I see is this: program1 starts and nothing else happens. When I manually stop program1 then program2 starts. Another very good thing would be to have a rule like this: my_rule: stop program1 stop program2 If they are not running it should do nothing, maybe the '-' prefix will do this? (using make 3.81 under WinXP) part of Pauls answer:There is no way for make to not wait for a program. If you had a UNIX system with a normal shell, you could put the process into the background, like this: foo: program1 & program2 & (the "&" tells the shell to put the program into the background). You mentioned you're using Windows, but I don't know if you're using Cygwin (which has, I believe, a UNIX-style shell) or MingW or whatever. I don't know how to put a program into the background on Windows. I don't use Cygwin, as much as I know my GNU stuff is based on MinGW. But I am not an expert on this. Thank you for any help Martin --- original message end ---- _______________________________________________ Make-w32 mailing list Make-w32@gnu.org http://lists.gnu.org/mailman/listinfo/make-w32