the .tar/.tgz/.tar.gz wars (was: Re: some try-ark suggestions)
Will Partain <[email protected]> Tue, 12 Jun 2001 21:20:26 +0100
| Newsgroups | gmane.comp.sysutils.ark.devel |
|---|---|
| Message-ID | <[email protected]> |
Steve T comments: > Would it be reasonable for a team's policy to *include* the "from > where"? Don't most shops generally work that way anyway? For > instance, I've often worked in shops where the (unwritten, but > generally stated) policy was one of these: > > "build everything from source obtained from the author's site > only" > > "only get stuff as binary packages from sunfreeware.com or > redhat.com; we aren't in the business of maintaining a build > environment" > > "get whatever you can find from any old mirror, doesn't > matter, whatever...". Yes, I guess I've always kinda implicitly done the first. (Or used a known trusted mirror.) I kinda sloppily maintain <pristine-homepage> and <pristine-source> attributes for packages, e.g. <pristine-homepage>http://www.gnu.org/</pristine-homepage> <pristine-source>ftp://alpha.gnu.org/gnu/gzip/</pristine-source> but these aren't particularly used yet. (NB: updates/additions always welcome.) Berto, all this stuff is more brainless than you think. The sidai:ALL proto-package (sidai/package/ALL.xml), `assemble-source' method, defaults the PKG_TGZ_FILE param to <pkgname>-<ver>.tar.gz. That's what most packages use. *If* the original site for a package distributes it with another name (or if it unpacks into something other than <pkgname>-<ver>), then you will find <param>-setting code that makes it the right thing for that package. For example, Apache is different, so its proto-package says: <param name="PKG_TGZ_FILE">@package:ark-dirs:PKGS_SRC@/apache_@param:[email protected]</param> <param name="PKG_UNPACK_DIR">apache_@param:PKG_VERSION@</param> In this way, the Right Thing usually happens. If you, at your own site, stash your sources with some other naming scheme, you can set PKG_TGZ_FILE in your own package stuff. (Not recommended, but you can.) Gzip is a bit weird, because it is traditionally distributed either as .tar or as .shar. To make any of the above cleverer, just hack on the Bourne shell script in an <assemble-source> method; even better, hassle Harlan about the <get-source> method, which will go grab the source off the 'net for you :-) [unwritten] We probably *should* make the <assemble-source> method for gzip more clever. I am not gripped with a great idea at this precise moment... One reason I am reluctant to get too clever about this ungzipping/untarring, though, is I would like the tarball-that-was-used to be readily apparent, i.e. I want it to be easy to have a webpage that says, "This package was built from <that tarball over there>", with the info from ARK-land. If that exact tarball was not specifically specified, but came out of the bowels of some shell-script logic, then that's harder to do. Again, there's kind of a philosophy thing here: Your ARK .xml files are supposed to express "this is what I used to and how I built my site", not "this is some stuff I got from sourceforge that managed to guess what I should use to build my site". Hmmm... Will