On Sun, 06 May 2007 03:20:10 +0900, Brian Candler wrote: > On Sat, May 05, 2007 at 07:45:10AM +0900, Stephen Touset wrote: >> > With Pallet, you can tell it what files to bundle together to build a >> > package. But what about the initial fetch/untar/configure/build/install >> > steps? It would be very attractive to write these once in ruby (or rake), >> > but I don't think Pallet provides rules for this. Are there existing >> > libraries of rake tasks to do these steps? >> >> Not of rake tasks, but you could easily write a rake task which downloads >> the file to somewhere predictable. > > Sure, but I was thinking of using it as a generic way to package third-party > software and use it to generate, say, .deb and .rpm That's what I really aim this project to deal with. It'd be exceedingly nice if upstream developers would take it upon themselves to package their software in multiple formats, but barring that it should be easy for a distro maintainer to repackage it. Debian isn't so hot on packing gems inside of dpkgs and just having the dpkg be a frontend for "gem install foo", but I don't personally mind, and other Debian-derived distros (read: Ubuntu) might feel differently as well. > RPM is what I'm more familiar with. It has a 'spec' file which directs the > build. But it has sensible default macros for: > - untar source into a work directory > - apply patch(es) > - configure > - make > - make install > > You can override any of these, but the defaults work in the majority of > cases. I was going to try and tackle writing an RPM backend sometime the next month, but would have to first learn the entire RPM building process. If you'd like to write a Pallet::RPM class to generate and build a spec file, I'd be more than happy to accept it. Automatically downloading from remote sources, if done at all, would probably come after I start supporting more package formats and write some Pallet::Gem2(Deb|RPM|foo) classes to wrap Gems inside of OS-native packages. -- Stephen Touset <stephen / touset.org>