I recently installed Solaris 8 on a Pentium machine and tried to use gcc 2.95.2
and gdb
4.18 as they were set up by the default installation process. gcc runs fine, but
gdb
insists that it can't access the /proc files for whatever program I try to
debug. The
programs I've tried run fine from the command line, it's just gdb that can't run
them.

I've tried "debugging" system commands (e.g. echo) as well as programs I
compiled
myself. I've tried from root as well as from other userids. I've tried letting
gdb start the
program and I've tried connecting gdb to an existing process. I've tried
different shells.
I downloaded a fresh copy of gdb-4.18 source and rebuilt gdb (ran "configure"
with no
options). I tried rebuilding gdb as root and as other userids. I get the same
type of error
under all conditions (see below) except that when I'm root I get
"/proc/7656/ctl:
Inappropriate ioctl for device" while when I'm some other user I get
"/proc/7656/ctl:
Permission denied". I thought of trying to change the default permissions for
the /proc
directory, but the system wouldn't allow that (wisely no doubt!).

Does anyone know of any system settings that might be causing this or has
something
changed in Solaris 8 that gdb isn't handling? I'm new to UNIX, new to GNU tools,
 and
fresh out of ideas. I'll appreciate any help anyone can offer!

------------------------------------------------------------------------------
GNU gdb 4.18
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-pc-solaris2.8".
(gdb) target exec ./helloworld
(gdb) run
Starting program: ./helloworld
/proc/7656/ctl: Permission denied
/proc/7656/status: No such file or directory.
can't open process file
(gdb) $
------------------------------------------------------------------------------


Reply via email to