1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-06 11:50:51 -08:00
Commit graph

69 commits

Author SHA1 Message Date
Richard M. Stallman
39eaa78275 (Fcall_process): Extend BUFFER arg so it can specify
a separate output file for stderr output.
(Fcall_process_region): Doc fix.
1995-02-26 07:58:52 +00:00
Richard M. Stallman
2e3dc201ba (delete_temp_file): Use internal_delete_file. 1994-11-28 19:27:41 +00:00
Richard M. Stallman
bad95d8f8d (getenv_internal) [WINDOWSNT]: Use strnicmp, not bcmp.
(child_setup): Use IS_DIRECTORY_SEP.
[WINDOWSNT]: Call prepare_standard_handles.  Use spawnve.
Use reset_standard_handles.

(Fcall_process_region): Test DOS_NT, not MSDOS.
(Fcall_process) [WINDOWSNT]: Call pipe_with_inherited_out.
Use the return value of child_setup to get the child's pid;
don't call vfork etc. explicitly.

[WINDOWSNT]: Add includes.  Defone NOMINMAX, _P_NOWAIT.
(Vbinary_process_input, Vbinary_process_output)
(Qbuffer_file_type): Test DOS_NT, not MSDOS.
(syms_of_callproc): Test DOS_NT, not MSDOS.

(init_callproc): Test DOS_NT, not MSDOS.
1994-11-01 06:49:52 +00:00
Richard M. Stallman
20b25e46b6 (child_setup): Always use _exit. 1994-10-19 19:46:05 +00:00
Karl Heuer
d50d3dc8e3 (Fcall_process, child_setup, getenv_internal): Use type test macros. 1994-09-27 03:10:43 +00:00
Richard M. Stallman
00fb3e95ef (Fcall_process) [__osf__ && __alpha]:
Don't stop reading if read returns negative.
1994-09-17 05:30:39 +00:00
Richard M. Stallman
59750d69f8 (delete_temp_file): Use Fdelete_file. 1994-09-14 09:15:46 +00:00
Karl Heuer
39323a7e46 (Fcall_process_region): gcpro filename_string. 1994-08-17 21:44:49 +00:00
Richard M. Stallman
565620a54d Put stdio.h after config.h. 1994-06-15 03:54:06 +00:00
Richard M. Stallman
1a6640ec24 (init_callproc) [MSDOS]: Exclude less code, so ../etc
is still tested for doc file.
1994-06-07 15:29:45 +00:00
Karl Heuer
00353d4f04 [MSDOS]: #include "msdos.h" for rootrelativepath template. 1994-06-04 00:15:17 +00:00
Richard M. Stallman
7fcf7f0518 (child_setup): If PWD is set, set it in the child so that
it points at the child's working directory.
1994-05-28 08:29:36 +00:00
Richard M. Stallman
68d10241fc (child_setup): PRIO_PROCESS renamed to SET_EMACS_PRIORITY.
Don't call nice if emacs_priority is positive.
1994-05-13 07:18:18 +00:00
Richard M. Stallman
7e93368366 (init_callproc): Never set Vdata_directory based on
the executable's location.  But maybe set it from source dir.
1994-05-12 06:35:19 +00:00
Richard M. Stallman
093650fe31 [MSDOS]: Rename Vbinary_process to Vbinary_process_output.
(syms_of_callproc) [MSDOS]: Rename lisp variable binary-process to
binary-process-output.
(Fcall_process, syms_of_callproc) [MSDOS]: Use new names.
(Vbinary_process_input) [MSDOS]: New variable.
(syms_of_callproc) [MSDOS]: Declare binary-process-input.
(Fcall_process_region) [MSDOS]: Bind binary-process-input temporarily
to buffer-file-type.
(init_callproc) [MSDOS]: Don't add lib-src as the wrapped binaries are in bin.
1994-05-07 21:53:28 +00:00
Richard M. Stallman
5b633aeb24 (child_setup): Test PRIO_PROCESS, as in sys_subshell. 1994-04-28 05:44:54 +00:00
Richard M. Stallman
4bb45197d8 (init_callproc): Set Vdoc_directory like Vdata_directory. 1994-04-21 08:31:39 +00:00
Richard M. Stallman
472e83febc If we include fcntl.h, define INCLUDED_FCNTL. 1994-04-12 03:25:18 +00:00
Karl Heuer
3e9367e7de (child_setup): Check out==err when relocating fds. 1994-03-31 22:19:27 +00:00
Karl Heuer
c135075247 (call_process_cleanup, getenv_internal): Use assignment, not initialization. 1994-03-23 22:26:47 +00:00
Richard M. Stallman
6b6e798bb3 (Fcall_process): Make sure to close descriptors.
(call_process_cleanup): Always close descriptor.
1994-03-22 20:17:17 +00:00
Karl Heuer
c52b0b3467 (Fcall_process): GCPRO some things. 1994-03-18 00:13:22 +00:00
Richard M. Stallman
37d5412167 Don't kill remaining processes if child exits.
(call_process_exited): New variable.
(Fcall_process): Set it.
(call_process_cleanup): Test it.
1994-03-09 22:10:08 +00:00
Karl Heuer
35a2f4b8cb (syms_of_callproc): New variable Vdoc_directory.
(init_callproc_1): Initialize it.
1994-02-22 23:50:27 +00:00
Richard M. Stallman
0af6a8312e Include stdio.h.
(init_callproc): Put non-ex-dir warnings on stderr.
1994-01-29 01:16:17 +00:00
Richard M. Stallman
05630743f9 (init_callproc): Use Vinstallation_directory. 1994-01-17 00:46:25 +00:00
Richard M. Stallman
4458cebe3c (child_setup): Call close_load_descs. 1994-01-11 22:08:49 +00:00
Roland McGrath
33abe2d96d (child_setup): Don't declare PID `register'; we later take its address. 1994-01-08 23:22:33 +00:00
Roland McGrath
826c56acc9 Don't declare sys_errlist; declare strerror instead.
(relocate_fd): Call strerror instead of using sys_errlist.
1994-01-08 21:24:35 +00:00
Richard M. Stallman
7e6c2178ef (syms_of_callproc) [MSDOS]: New lisp variable: binary-process.
(init_callproc) [MSDOS]: Initialize binary-process.
[MSDOS]: Declare binary-process.
[MSDOS]: Include <fcntl.h>, <sys/stat.h>, <sys/param.h>,
and <errno.h> needed for the next changes.
(Fcall_process) [MSDOS]: Create temporary file for process output.
Run the subprocess using `run_msdos_command' instead of forking.
Arrange for cleanup to erase temporary file.
(Fcall_process) [not subprocesses]: Barf if zero buffer argument.
(call_process_cleanup) [MSDOS]: Close and erase temporary file
instead of the pid-stuff.
(Fcall_process_region) [MSDOS]: Create temporary file in $TMP or $TEMP.
(Fchild_setup) [MSDOS]: #if 0, as it is not used.
1994-01-08 09:21:13 +00:00
Richard M. Stallman
a129418f94 Include systty.h.
(child_setup): Use EMACS_SET_TTY_PGRP.
1993-12-25 01:45:14 +00:00
Richard M. Stallman
0ad477db95 (Fcall_process): Call prepare_menu_bars.
(Fgetenv): One arg is maximum.
1993-12-23 02:00:09 +00:00
Richard M. Stallman
fdba859084 (child_setup): Test SETPGRP_RELEASES_CTTY, not IRIX.
(init_callproc): Fix previous change.
1993-11-25 21:33:31 +00:00
Richard M. Stallman
8de15d6981 (init_callproc): Maybe add ../lib-src to exec-path
and maybe store it in exec-directory.
Maybe put ../etc into data-directory.
(init_callproc_1): Part of init_callproc is split out.
1993-11-24 06:37:13 +00:00
Richard M. Stallman
5c03767e4f (Fcall_process): Clear synch_process_death and
synch_process_retcode before the vfork.
1993-11-11 04:36:02 +00:00
Roland McGrath
2a6b353709 Include <paths.h>, not "paths.h". 1993-09-12 01:34:01 +00:00
Roland McGrath
18160b98ce Include <config.h> instead of "config.h". 1993-09-10 06:15:46 +00:00
Richard M. Stallman
88a64fef30 (PRIO_PROCESS): Definition deleted. 1993-06-30 17:51:16 +00:00
Jim Blandy
5a570e3721 Changes for Irix 4.0, tested this time:
* s/irix4-0.h: Get rid of our fake definitions for setpgrp and
	getpgrp.
	* callproc.c (Fcall_process): Go ahead and use the USG calling
	convention for setpgrp.
	* ymakefile (pre-crt0.o): Add rule for this.  Perhaps it will help
	separate-source-directory compilation.
	* emacs.c (shut_down_emacs): Some USG systems #define
	EMACS_HAVE_TTY_PGRP; call getpgrp as appropriate for such systems.
	* sysdep.c (sys_suspend): Call getpgrp as appropriate for USG and
	non-USG.
	* process.c [IRIX] (create_process): Don't put child in process
	group zero before opening the tty; Irix is like USG in this
	regard.
1993-06-18 23:33:20 +00:00
Jim Blandy
1319549a9a * m/iris4d.h (LIB_STANDARD): Do *not* include -lbsd. We are
now calling the BSD[sg]etpgrp functions directly, so this library
	is not needed; it just provides the BSD[sg]etpgrp functions under
	the [sg]etpgrp names.
	* callproc.c [IRIX] (child_setup): Don't call setpgrp this time.
	It's already been called up in Fcall_process, and create_process.
1993-06-17 23:25:37 +00:00
Jim Blandy
b5aaed99d0 * callproc.c (Fcall_process, child_setup): If IRIX is #defined,
call setpgrp with arguments, even if USG is #defined.
	* process.c [IRIX] (create_process): Don't call setpgrp before
	opening the pty.  Call it after doing the TIOCNOTTY ioctl.
1993-06-17 22:03:06 +00:00
Jim Blandy
ed61592a79 * paths.h (PATH_INFO): New path, to edited by the configuration
process.
	* callproc.c (Vconfigure_info_directory): New variable, used
	internally by build process.
	(syms_of_callproc): DEFVAR it and initialize it.
1993-05-25 06:38:43 +00:00
Jim Blandy
c6c5df7f76 Updated copyright years. 1993-05-22 21:34:42 +00:00
Richard M. Stallman
cd9565badb (child_setup): Omit duplicates from new env array. 1993-05-13 00:21:47 +00:00
Jim Blandy
20c018a065 * callproc.c (relocate_fd): Make messages string literals, not
initialized arrays.
1993-04-10 07:58:30 +00:00
Jim Blandy
5437e9f97e New macros NULL_DEVICE and EXEC_SUFFIXES, to give the name of the
equivalent of /dev/null, and the suffixes used by executable
	files.  This is simple, and helps people porting Emacs to other
	operating systems.
	* process.h (NULL_DEVICE): Give this a default value.
	* process.c (Fstart_process): Pass EXEC_SUFFIXES to openp.
	(Fprocess_send_eof): Use NULL_DEVICE instead of "/dev/null".
	* callproc.c (Fcall_process): Pass EXEC_SUFFIXES to openp.
	Use NULL_DEVICE instead of "/dev/null".
1993-03-30 23:05:56 +00:00
Jim Blandy
426b37aecf * callproc.c (child_setup): Make sure that in, out, and err are
not less than three.
	(relocate_fd): New function.
1993-03-20 21:53:57 +00:00
Jim Blandy
9fefd2bacb * callproc.c (delete_temp_file): Declare this to return
Lisp_Object, to smooth type-checking.

	* callproc.c (init_callproc): Move the initialization of
	Vprocess_environment to its own function.
	(set_process_environment): This is that.
	* emacs.c (main): Call set_process_environment earlier than
	init_callproc.
1993-02-22 14:24:42 +00:00
Michael I. Bushnell
82df4891d0 * process.c (Fstart_process): Jimb's change of December 11
had a misplaced paren.  This only became apparent because of
	jimb's change on February 8 to Fexpand_file_name.
	* callproc.c (Fcall_process): Ditto.
1993-02-18 03:43:45 +00:00
Jim Blandy
58616e6755 Give subprocess creation a way to find a valid current directory
for subprocesses when the buffer's default-directory is a handled
	name.
	* fileio.c (Funhandled_file_name_directory): New function.
	(Qunhandled_file_name_directory): New file-name-handler operation.
	(syms_of_fileio): Defsubr Sunhandled_file_name_directory, and
	initialize and staticpro Qunhandled_file_name_directory.
	* callproc.c (Fcall_process): Call Funhandled_file_name_directory
	on the buffer's default directory.  Do it earlier in the function
	so there's less to GCPRO.
	* process.c (create_process): Don't check the validity of the
	buffer's default directory here...
	(Fstart_process): Instead, do it here; if we call
	Funhandled_file_name_directory here, there's less GCPROing to do.

	* callproc.c (Fcall_process_region): Return the value returned by
	Fcall_process.
1992-12-12 15:31:32 +00:00