Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!bobmon From: bobmon@iuvax.cs.indiana.edu (RAMontante) Newsgroups: comp.lang.c Subject: Question about linking files Message-ID: <18925@iuvax.cs.indiana.edu> Date: 26 Mar 89 04:52:31 GMT Reply-To: bobmon@iuvax.cs.indiana.edu (RAMontante) Organization: malkaryotic Lines: 17 Hey, gurus and standards freekz... A question is going around comp.sys.ibm.pc just now, to wit: somebody has noticed that (TurboC's) linker links all the routines in a file into his object file, whether a particular routine is actually called or not. This bothers him, because the resulting executable is larger than it really needs to be. Among the flurry of LIBrarian tricks to defeat this, a couple of people are saying that this isn't (TurobC/MSC/whoever)'s fault, because C requires that all routines (all symbols, maybe?) in a file be linked in if any of them are. Are there any nuggets of correctness in all this? Would someone care to shine some light on it all? (disclaimer: I may have oversimplified the discussion. If you have a good answer, it's probably worth crossposting to comp.sys.ibm.pc.)