Date: Mon, 19 Jul 1999 12:20:02 -0700 (PDT) From: dbushong@CSUA.Berkeley.EDU (David Bushong) To: freebsd-bugs@FreeBSD.org Subject: Re: bin/12554: File to go in /usr/src/usr.bin/file/Magdir/warcraft2 Message-ID: <199907191920.MAA97769@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/12554; it has been noted by GNATS. From: dbushong@CSUA.Berkeley.EDU (David Bushong) To: sheldonh@uunet.co.za (Sheldon Hearn) Cc: dbushong@CSUA.Berkeley.EDU, freebsd-gnats-submit@freebsd.org, lyndon@orthanc.ab.ca Subject: Re: bin/12554: File to go in /usr/src/usr.bin/file/Magdir/warcraft2 Date: Mon, 19 Jul 1999 12:14:55 -0700 (PDT) That's definitely a possiblity. I'm not overly concerned whether or not this makes its way into the system magic file, I just thought some people might like it. Your ports idea is a good one; however, here are my thoughts on the matter: I think file(1) should have as "bloated" a magic database as possible. I think if file(1) recognized every possible file format on earth, that would be really cool. If the ascii format magic file is already beginning to show a speed hit from the current amount of bloat, I think file(1) should move to a database format. I assume the internal file(1) code already uses some type of tree based search which is efficient, so it's just a question of precompiling the data into a binary-format magic file. But I digress. The argument of "blah is used by the base system" is obviously pointless as there's Excel, Word, etc etc files in there. "But people deal with those all the time for one reason or another in FreeBSD and there are programs that do stuff with them under FreeBSD like StarOffice". Indeed, but those aren't in the base system. They are, however, very useful. In general being able to recognize any arbitrary piece of binary data (and not have it come up "troff macro file" like lame Unices with neutered magic files do) is a very very good thing. I'd like to see the magic file grow. But that's just my opinion. (As for the bloat of it being in the source tree, I can't see it ever, ever approaching the size of..say.. Perl 5) > > Hi David, > > I've looked at the precedent which you offered for having game file(1) > formats in the base system. I'm pretty sure that the Infocom file format > is used by a game in the base system. > > I'll tell you what's making my skin crawl, here. I worry about having a > hugely bloated src/usr.bin/file/Magdir in our source tree. Now that does > seem like a counter-productive paranoia, but I can't shake it. > > Since file(1) already has a command-line option (-m) for specifying > additional magic files, here's what I propose. I'd like to modify > file(1) so that it honours an environment variable, perhaps MAGDIRS. The > variable includes a colon-separated list of paths to additional magic > files. > > The idea is that your port would include an install-time message that > says something like "add MAGDIRS=${PREFIX}/share/misc/magic to > /etc/profile so that file(1) will recognize WarCraft2 save files". > > What do you think? > > Ciao, > Sheldon. > --David Bushong To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199907191920.MAA97769>