This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: C++: executing other programs
- To: Bernd Knorr <b_knorr at gmx dot de>
- Subject: Re: C++: executing other programs
- From: Mo McKinlay <mmckinlay at labs dot interopen dot org>
- Date: Sun, 12 Mar 2000 19:31:02 +0000 (GMT)
- cc: gcc-bugs at gcc dot gnu dot org
# Hi,
#
# is there any possibility to execute other programs from within my C++-program ?
# (I use the g++-compiler for Windows)
#
# Thanks and bye, Knorze
If you're using the cygwin-hosted compiler, you can use the spawn...()
variants - check out the cygwin documentation. Alternatively, you can use
the Win32 API and call WinExec() or ShellExecute() (See the Microsoft SDKs
on the MSDN website - http://msdn.microsoft.com). If you want your code to
be portable, you could use fork() and the exec...() functions, but
this impairs performance on Win32, due to the lack of a native fork()
equivalent.
Note also that this list is for reporting bugs in the gcc family, not
asking for help with programming.
Regards,
--
Mo McKinlay T: +44 (0) 709 22 55 05 x1
Chief Software Architect F: +44 (0) 709 22 55 05 x3
inter/open E: mmckinlay@labs.interopen.org
A division of Bekon Marketing Limited W: http://www.interopen.org