From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fcfb9,9f5c1c8d844fc69e X-Google-Attributes: gidfcfb9,public X-Google-Thread: 111c93,9f5c1c8d844fc69e X-Google-Attributes: gid111c93,public X-Google-Thread: 1025b4,9f5c1c8d844fc69e X-Google-Attributes: gid1025b4,public X-Google-Thread: 10d0a1,9f5c1c8d844fc69e X-Google-Attributes: gid10d0a1,public X-Google-Thread: 1125fa,9f5c1c8d844fc69e X-Google-Attributes: gid1125fa,public From: sean@forget.about.it (Se�n � Donnchadha) Subject: Re: DLL mess Re: "No-one gets fired for buying Microsoft" Date: 1999/09/13 Message-ID: <37e10e48.351577842@news.shore.net>#1/1 X-Deja-AN: 524486638 Content-Transfer-Encoding: 7bit References: <37D81FE1.E90C3B1F@winkinc.com> <37d93940.34897269@news.shore.net> <7ra5gg$cm1@dfw-ixnews15.ix.netcom.com> <37dc0c92.88995578@news.shore.net> <37ddff0d.347678675@news.shore.net> <87hfkylxa5.fsf@foobar.orion.no> Content-Type: text/plain; charset=us-ascii X-Complaints-To: abuse@shore.net X-Trace: news.shore.net 937235609 207.244.116.3 (Mon, 13 Sep 1999 11:13:29 EDT) Organization: Shore.Net/Eco Software, Inc; (info@shore.net) MIME-Version: 1.0 NNTP-Posting-Date: Mon, 13 Sep 1999 11:13:29 EDT Newsgroups: comp.os.linux.alpha,comp.os.linux.advocacy,comp.os.ms-windows.advocacy,comp.os.ms-windows.nt.advocacy,gnu.misc.discuss Raymond Wiker wrote: >> >> That's great, but it's a totally unrelated issue. Here's the real >> question: What is the installer to do when a new program requires >> libfoo-1.2.3, and libfoo-1.2.2 is already installed and in use by >> dozens of other programs? > > Simple. You copy libfoo-1.2.3 to the appropriate place, where >it will peacefully coexist with libfoo-1.2.2. The file names are not >identical, so they *can* be in the same directory. > It doesn't matter whether the files can coexist. As long as apps use only one of them, the other one may as well not be there. > > The installation will (probably(???)) also update a symlink for >libfoo-1.2, so that it points to libfoo-1.2.3 instead of >libfoo-1.2.2. *No* programs should break from this, as there should be >no visible differences between 1.2.2 and 1.2.3 - if there were, the >new version would be called 1.3.0, or something. > You're not seeing the real problem, Raymond. What you're saying (that library authors simply bump the major version number if the library introduces incompatible changes) is only true when the authors actually realize that they've made such changes. Shared library conflicts happen when the authors *DON'T* realize it, usually because they didn't have the ability to test their updated library against every app that uses it. Because they don't realize that a compatibility glitch exists, they issue a minor update instead of a major one, and things blow up. And this isn't even always the library authors' fault. No matter how well-written the documentation, there is always room for interpretation when it comes to software behavior. A library update may actually be 100% back-compatible in terms of the authors' own understanding of the required behavior, while app authors may have their own ideas - ones that lead to their apps depending on behavior that the library author would consider incorrect or unspecified. > >I suspect that an >application would also be able to request a particular minor version, >as well. > No. This would eliminate the field-ugradability of shared libraries. > > Compare this with DLLs. There are several versions of >MFC42.DLL, and they all expect to reside in the same directory, with >the same name. There is *no* major/minor version information >available, although you can kludge this by using different file names >for different major numbers. > Incorrect. In Windows, the major version number is in the filename, and the minor version number is in the VERSIONINFO resource embedded into the file. At app installation time, this resource is compared against the one in the file already installed to determine whether an update should occur. But instead of installing multiple files and using a link to select one of them, Windows simply installs only one. The end result is the same - apps use the latest version installed. The Unix approach has the advantage that a library update is easy to back out - you just revert the link instead of having to reinstall the original library from the distribution media. But this is something the average user wouldn't have the ability to take advantage of, and it has the (minor) disadvantage of wasting disk space in the general case. > >In practice, this is seldom >done. MFC42.DLL may appear to have a major version encoded in the >filename, but that is not the case - there have been versions of this >DLL that has been incompatible with programs written for earlier >versions. There are other cases like this. > Right, but this is precisely what I was talking about before. The library authors (Microsoft in this case) believed that their MFC42 update was 100% back-compatible, so they didn't change the major version number (by renaming the library to MFC43 or something). Had they realized that compatibility glitches existed, they would have renamed the library and everything would have been peachy keen. As I hope I've convinced you, the Unix approach wouldn't have helped at all. >> >> You must not have been around in the early days when HJ Lu included a >> list of known broken programs with each libc revision. > > So? The state of the art in Linux libraries is improving, >which is *not* something you can say about Microsoft libraries. > Huh? Would you care to elaborate? >> >> This problem really has little to do with versioning. The whole point >> of shared libraries (aside from disk/memory usage) is independent >> field-ugradability, which results in the runtime coupling of two >> binary components that may not have been lab-tested in combination. In >> this particular case, there's no way to eliminate the risk without >> also eliminating the benefit. > > You *can* get around this, as long as it is possible for the >application to request a particular version (major version, minor >version, directory...) > Again, what you're suggesting would sacrifice the major advantage of shared libraries - field-upgradability.