Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site brl-tgr.ARPA Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!genrad!panda!talcott!harvard!seismo!brl-tgr!gwyn From: gwyn@brl-tgr.ARPA (Doug Gwyn ) Newsgroups: net.lang.c Subject: Re: Archives Message-ID: <1403@brl-tgr.ARPA> Date: Thu, 9-Jan-86 15:03:25 EST Article-I.D.: brl-tgr.1403 Posted: Thu Jan 9 15:03:25 1986 Date-Received: Sun, 12-Jan-86 06:05:32 EST References: <1396@brl-tgr.ARPA> Organization: Ballistic Research Lab Lines: 30 The fellow with the "truncated" archive name probably has the following trouble. Note first that the linker does NOT use archive member (file) names to resolve extern references; it uses global entry points. In older UNIXes, these were found by sequentially scanning all object members of the archive; in newer versions, the archive contains a member that is a index of entry points. For the reported problem, the fellow's current compiler must support long names (FLEXNAMES, or at least longer-than-before names), and the member of the archive must date back to pre- long-names times, when all extern names were truncated to fit the limited space available in the object module format (by the assembler, not by the archiver). Because there is no way for the newer SGS to know that an older entry point name resulted from the truncation of something longer, existing names are taken as exactly what they contain. Long names compiled by the newer SGS will have their full names. These will not match the older truncated forms. You can work around this, assuming you can't just recompile the archive member from its source, by replacing the long names in you current source by their short versions. An easy way to do this is: #define nametoolong nametool (or whatever) at the beginning of the source file. AT&T SVR2 cpp is supposed to have a "truncate" option, -T, to do this for you automatically.