Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site burl.UUCP Path: utzoo!watmath!clyde!burl!rcj From: rcj@burl.UUCP (R. Curtis Jackson) Newsgroups: net.unix-wizards,net.bugs.usg Subject: sdb poser solved -- 5.0 sdb users read this Message-ID: <467@burl.UUCP> Date: Fri, 18-May-84 09:45:58 EDT Article-I.D.: burl.467 Posted: Fri May 18 09:45:58 1984 Date-Received: Sat, 19-May-84 00:06:24 EDT Organization: AT&T Technologies; Burlington, NC Lines: 30 Many thanks to John Haller (ihldt!jhh) for telling me the solution to this one; here was the problem: on a Vax-11/780 running Release (USG) 5.0, I suddenly could not set any breakpoints in a program I was developing. The problem lies in the fact that the -n (shared text) option of the loader write-protects the part of the program that sdb needs to write into to set breakpoints. To avoid a rash of denials, I must note here that this does not always happen; it apparently depends on where the program is loaded or some other variable. The reason for the write-protect is a possibility that someone who *really* knew what they were doing might cause a security problem by being able to write into the text segment of a system program loaded with the -n option. The way to get around the problem is to use the '-Wl,-N' option of cc, or the '-N' option of f77; these tell the compiler to pass the argument '-N' (no shared text) to the loader (l) pass of the compiler. Works like a charm. So, if you can't set breakpoints in your program, try this option and see if it fixes it. Also, (I don't know if this has come up on the net yet) if you are using sdb with f77 programs and are having problems, do NOT compile your labeled commons with -g, it screws things up. This one courtesy of Rich Whitelaw (burl!rlw), who discovered this while trying to debug a microsimulator he is developing here. -- He gave the novice a long, icy stare and quietly growled, "RTFM". The MAD Programmer -- 919-228-3313 (Cornet 291) alias: Curtis Jackson ...![ ihnp4 ulysses cbosgd we13 ]!burl!rcj ...![ ihnp4 cbosgd akgua masscomp ]!clyde!rcj