| 1 | /* Definitions for Windows process invocation.
|
|---|
| 2 | Copyright (C) 1996-2016 Free Software Foundation, Inc.
|
|---|
| 3 | This file is part of GNU Make.
|
|---|
| 4 |
|
|---|
| 5 | GNU Make is free software; you can redistribute it and/or modify it under the
|
|---|
| 6 | terms of the GNU General Public License as published by the Free Software
|
|---|
| 7 | Foundation; either version 3 of the License, or (at your option) any later
|
|---|
| 8 | version.
|
|---|
| 9 |
|
|---|
| 10 | GNU Make is distributed in the hope that it will be useful, but WITHOUT ANY
|
|---|
| 11 | WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
|
|---|
| 12 | A PARTICULAR PURPOSE. See the GNU General Public License for more details.
|
|---|
| 13 |
|
|---|
| 14 | You should have received a copy of the GNU General Public License along with
|
|---|
| 15 | this program. If not, see <http://www.gnu.org/licenses/>. */
|
|---|
| 16 |
|
|---|
| 17 | #ifndef SUB_PROC_H
|
|---|
| 18 | #define SUB_PROC_H
|
|---|
| 19 | #ifdef CONFIG_NEW_WIN_CHILDREN
|
|---|
| 20 | # error "Just checking..."
|
|---|
| 21 | #endif
|
|---|
| 22 |
|
|---|
| 23 | /*
|
|---|
| 24 | * Component Name:
|
|---|
| 25 | *
|
|---|
| 26 | * $Date$
|
|---|
| 27 | *
|
|---|
| 28 | * $Source$
|
|---|
| 29 | *
|
|---|
| 30 | * $Id$
|
|---|
| 31 | */
|
|---|
| 32 |
|
|---|
| 33 | #define EXTERN_DECL(entry, args) extern entry args
|
|---|
| 34 | #define VOID_DECL void
|
|---|
| 35 |
|
|---|
| 36 | EXTERN_DECL(HANDLE process_init, (VOID_DECL));
|
|---|
| 37 | EXTERN_DECL(HANDLE process_init_fd, (HANDLE stdinh, HANDLE stdouth,
|
|---|
| 38 | HANDLE stderrh));
|
|---|
| 39 | EXTERN_DECL(long process_begin, (HANDLE proc, char **argv, char **envp,
|
|---|
| 40 | char *exec_path, char *as_user));
|
|---|
| 41 | EXTERN_DECL(long process_pipe_io, (HANDLE proc, char *stdin_data,
|
|---|
| 42 | int stdin_data_len));
|
|---|
| 43 | #ifndef KMK /* unused */
|
|---|
| 44 | EXTERN_DECL(long process_file_io, (HANDLE proc));
|
|---|
| 45 | #endif
|
|---|
| 46 | EXTERN_DECL(void process_cleanup, (HANDLE proc));
|
|---|
| 47 | EXTERN_DECL(HANDLE process_wait_for_any, (int block, DWORD* pdwWaitStatus));
|
|---|
| 48 | EXTERN_DECL(void process_register, (HANDLE proc));
|
|---|
| 49 | EXTERN_DECL(HANDLE process_easy, (char** argv, char** env,
|
|---|
| 50 | int outfd, int errfd));
|
|---|
| 51 | EXTERN_DECL(BOOL process_kill, (HANDLE proc, int signal));
|
|---|
| 52 | EXTERN_DECL(int process_used_slots, (VOID_DECL));
|
|---|
| 53 | EXTERN_DECL(DWORD process_set_handles, (HANDLE *handles));
|
|---|
| 54 |
|
|---|
| 55 | #ifdef KMK
|
|---|
| 56 | EXTERN_DECL(int process_kmk_register_submit, (HANDLE hEvent, intptr_t clue, pid_t *pPid));
|
|---|
| 57 | EXTERN_DECL(int process_kmk_register_redirect, (HANDLE hProcess, pid_t *pPid));
|
|---|
| 58 | #endif
|
|---|
| 59 |
|
|---|
| 60 | /* support routines */
|
|---|
| 61 | EXTERN_DECL(long process_errno, (HANDLE proc));
|
|---|
| 62 | EXTERN_DECL(long process_last_err, (HANDLE proc));
|
|---|
| 63 | EXTERN_DECL(long process_exit_code, (HANDLE proc));
|
|---|
| 64 | EXTERN_DECL(long process_signal, (HANDLE proc));
|
|---|
| 65 | EXTERN_DECL(char * process_outbuf, (HANDLE proc));
|
|---|
| 66 | EXTERN_DECL(char * process_errbuf, (HANDLE proc));
|
|---|
| 67 | EXTERN_DECL(int process_outcnt, (HANDLE proc));
|
|---|
| 68 | EXTERN_DECL(int process_errcnt, (HANDLE proc));
|
|---|
| 69 | EXTERN_DECL(void process_pipes, (HANDLE proc, int pipes[3]));
|
|---|
| 70 | EXTERN_DECL(void process_noinherit, (int fildes));
|
|---|
| 71 |
|
|---|
| 72 | #endif
|
|---|