pexecute.c: Use spawn if __CYGWIN32__.

* pexecute.c: Use spawn if __CYGWIN32__.

        * pexecute.c: Include "config.h" first, as per autoconf manual
	(from Paul Eggert  <eggert@twinsun.com>).

From-SVN: r15825
This commit is contained in:
Ian Lance Taylor 1997-10-01 15:15:06 +00:00 committed by Ian Lance Taylor
parent 0d9011fd81
commit 281de624e3
2 changed files with 21 additions and 3 deletions

View File

@ -1,3 +1,10 @@
Wed Oct 1 11:13:25 1997 Ian Lance Taylor <ian@cygnus.com>
* pexecute.c: Use spawn if __CYGWIN32__.
* pexecute.c: Include "config.h" first, as per autoconf manual
(from Paul Eggert <eggert@twinsun.com>).
Wed Oct 1 01:44:36 1997 Philippe De Muyter <phdm@info.ucl.ac.be>
* m68k/x-mot3300 (XCFLAGS): Disable as's long/short jump

View File

@ -23,11 +23,14 @@ Boston, MA 02111-1307, USA. */
/* This file lives in at least two places: libiberty and gcc.
Don't change one without the other. */
#ifdef IN_GCC
#include "config.h"
#endif
#include <stdio.h>
#include <errno.h>
#ifdef IN_GCC
#include "config.h"
#include "gansidecl.h"
/* ??? Need to find a suitable header file. */
#define PEXECUTE_FIRST 1
@ -217,12 +220,18 @@ pwait (pid, status, flags)
#endif /* MSDOS */
#if defined (_WIN32) && !defined (__CYGWIN32__)
#if defined (_WIN32)
#include <process.h>
extern int _spawnv ();
extern int _spawnvp ();
#ifdef __CYGWIN32__
#define fix_argv(argvec) (argvec)
#else
/* This is a kludge to get around the Microsoft C spawn functions' propensity
to remove the outermost set of double quotes from all arguments. */
@ -260,6 +269,8 @@ fix_argv (argvec)
return (const char * const *) argvec;
}
#endif /* ! defined (__CYGWIN32__) */
int
pexecute (program, argv, this_pname, temp_base, errmsg_fmt, errmsg_arg, flags)
const char *program;
@ -478,7 +489,7 @@ pfinish ()
/* include for Unix-like environments but not for Dos-like environments */
#if ! defined (__MSDOS__) && ! defined (OS2) && ! defined (MPW) \
&& (defined (__CYGWIN32__) || ! defined (_WIN32))
&& ! defined (_WIN32)
#ifdef VMS
#define vfork() (decc$$alloc_vfork_blocks() >= 0 ? \