Change all references to stdout/stderr to gdb_stdout/gdb_stderr.
Replace all calls to stdio output functions with calls to
corresponding _unfiltered functions (`fprintf_unfiltered')
Replaced calls to fopen for output to gdb_fopen.
Added sufficient goo to utils.c and defs.h to make the above work.
The net effect is that stdio output functions are only directly used
in utils.c. Elsewhere, the _unfiltered and _filtered functions and
GDB_FILE type are used.
In the near future, GDB_FILE will stop being equivalant to FILE.
The semantics of some commands has changed in a very subtle way:
called in the right context, they may cause new occurences of
prompt_for_continue() behavior. The testsuite doesn't notice anything
like this, though.
Please respect this change by not reintroducing stdio output
dependencies in the main body of gdb code. All output from commands
should go to a GDB_FILE.
Target-specific code can still use stdio directly to communicate with
targets.
* Makefile.in (CLIBS): Reorder to make Lynx ld happy.
* (HFILES): New file thread.h.
* (OBS): New file thread.c.
* configure.in: Host config for Lynx/386.
* fork-child.c (fork_inferior): Call init_thread_list().
* infrun.c (resume): Add pid to invocation of target_resume().
* (wait_for_inferior): Pay attention to pid from target_wait().
Multi-threading code now uses this to determine what to do.
* inftarg.c (child_wait): Conditionalize based on CHILD_WAIT macro.
Use target_pid_to_str() macro throughout when printing pid.
* inferior.h (child_resume): Add pid to prototype.
* hppab-nat.c hppah-nat.c infptrace.c (child_resume): Pass in pid as
argument, instead of using inferior_pid.
* procfs.c (procfs_resume): Pass in pid as argument. Ignored for
now. Use target_pid_to_str() macro throughout for printing process id.
* remote-adapt.c (adapt_resume): Pass in pid as argument.
* remote-eb.c (eb_resume): Pass in pid as argument.
* remote-es.c (es1800_resume): Pass in pid as argument.
* remote-hms.c (hms_resume): Pass in pid as argument.
* remote-mips.c (mips_resume): Pass in pid as argument.
* remote-mm.c (mm_resume): Pass in pid as argument.
* remote-monitor.c (monitor_resume): Pass in pid as argument.
* remote-nindy.c (nindy_resume): Pass in pid as argument.
* remote-sa.sparc.c (remote_resume): Pass in pid as argument.
* remote-sim.c (rem_resume): Pass in pid as argument.
* remote-sp64sim.c (simif_resume): Pass in pid as argument.
* remote-st.c (st2000_resume): Pass in pid as argument.
* remote-udi.c (udi_resume): Pass in pid as argument.
* remote-vx.c (vx_resume): Pass in pid as argument.
* remote-z8k.c (rem_resume): Pass in pid as argument.
* remote.c (remote_resume): Pass in pid as argument.
* solib.c (solid_create_inferior_hook): Pass inferior_pid to
target_resume().
* target.c (normal_pid_to_str): New routine to print out process
ID normally.
* target.h (struct target_ops): Add pid to prototype at
to_resume(). (target_resume): Add pid argument.
* (target_pid_to_str): Default definition for normal type pids.
* thread.c, thread.c: New modules for multi thread/process control.
({extract,store}_{signed_integer,unsigned_integer,address}):
New routines to replace SWAP_TARGET_AND_HOST.
All over: All uses of SWAP_TARGET_AND_HOST on integers replaced.
protocol.
* config/idt.mt: New file; uses remote-mips.c
* configure.in (mips-idt-ecoff): New target; uses idt.mt.
* mips-tdep.c (mips_fpu): New variable; controls use of MIPS
floating point coprocessor.
(mips_push_dummy_frame): If not mips_fpu, don't save floating
point registers.
(mips_pop_frame): If not mips_fpu, don't restore floating point
registers.
(_initialize_mips_tdep): New function; let the user reset mips_fpu
variable.
* tm-mips.h (EXTRACT_RETURN_VALUE, STORE_RETURN_VALUE): If not
mips_fpu, don't use fp0 as floating point return register.
(FIX_CALL_DUMMY): If not mips_fpu, don't save floating point
registers.
Also added remote-mips.c to .Sanitize file.