stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Black <abl...@roguewave.com>
Subject [patch] exec utility windows port
Date Wed, 09 Aug 2006 23:06:56 GMT
Greetings all.

Attached is a patch altering source for the the exec utility so that it 
should build on windows systems.  This patch does not alter the solution 
generation infrastructure to actually build the utility, but instead 
changes the source of the utility to make it compatible with windows.

Change log follows (and it's a bit long).

--Andrew Black

Log:
	* util.h (rw_snprintf): Add macro hack to work around lack of snprintf 
definition on windows.
	* cmdopt.cpp: Alter #includes to include windows.h on windows in place 
of unistd.h.
	* cmdopt.cpp (eval_options): use Sleep() on windows in place of 
sleep(), signal() on windows in place of sigaction().
	* cmdopt.cpp (split_opt_string): use '^' as escape character on windows 
in place of '\'.
	* exec.h (exec_attrs): Alter structure for windows builds.
	* exec.cpp: Alter #includes to include windows.h and process.h on 
windows in place of unistd.h and sys/wait.h
	* exec.cpp (get_signame): Use rw_snprintf in place of snprintf.
	* exec.cpp (handle_alrm, wait_for_child, open_input, replace_file, 
exec_file): Compile (existing) versions only on non-windows platforms.
	* exec.cpp (open_input, merge_argv, exec_file): Define new functions 
using windows native API, which will compile only on windows platforms.
	* output.cpp (check_example): Alter logic used to determine the 
location of the reference file to handle windows filenames.
	* runall.cpp (S_IXUSR, S_IXGRP, S_IXOTH): Define if not defined for 
windows.
	* runall.cpp (check_target_ok): Disable (unused) logic for output only 
targets.  Alter compile check on windows systems to correctly locate 
.obj file.
	* runall.cpp (process_results): Handle windows result codes correctly.
	* runall.cpp (rw_basename): Correct handling of escaping in path names, 
unix path token separators.

Mime
View raw message