Received: from zoo.toronto.edu ([128.100.72.1]) by gpu.utcs.utoronto.ca with SMTP id <15736>; Mon, 26 Nov 1990 23:21:48 -0500 Received: from pnet91 by generic.UUCP id aa16233; Tue, 27 Nov 90 3:30:14 GMT Date: Mon, 26 Nov 1990 22:28:19 -0500 From: ericmcg@pnet91 (Eric Mcgillicuddy) To: st6934@siucvmb Subject: Re: Re:scanf.c Message-ID: <9011270330.aa16233@generic.UUCP> cc has to be modified so that it does not erase ('rm') the scanf.o file after linking. Remove the second last line of cc and/or ccn and that should do the trick. Also be sure to specify the full pathname to the libc file (something like /csys/libs/libc). Also make sure the right flags are used (-rv I think?), it's been awhile since I installed it. I guess you wouldn't if behaves as you expected, I don't use scanf so I had t to rely on languages specs to write the thing. Hope it's what people expected. UUCP: bkj386!pnet91!ericmcg INET: ericmcg@pnet91.cts.com Upon experimenting with scanf.c the only way I've gotten it to work is to remove the #include from scanf.c and add an #include "scanf.c" to the program that has scanf in it. Eric remarked that removing the LAST TWO LINES of cc and renaming cc to compile would work so that scanf. c wouldn't link to itself but I still had trouble with that. I've been told that this is bad programming, but it works for me for now. Andy = ST6934@SIUCVMB (.BITNET if you need it) March 19, 1991 I finally was able to add scanf.c to libc. Compile scanf.c down to scanf.o by deleting the lnk and rm $1.o lines from cc or ccn and renaming the cc or ccn file cclib or something like that. Then add scanf.o to libc BEFORE atoi.o. The command would look like: lib libc -b atoi.o -r scanf.o Always do things like this on backups. You can check libc by typing: sym libc Then you'll know if scanf.o is before atoi.o. Andy Werner st6934@siucvmb.bitnet