buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Danny O'Connor <>
Subject Getting access to bin directory in packaging extension
Date Wed, 27 Jan 2010 11:31:27 GMT
Hi There,

I'm doing an rpm packaging extension,

I'm running into a problem defining the 'top dir' and 'build dir' for 
the rpm, at the moment I have:

module Buildr

   class PackageRPMTask < ArchiveTask

     def initialize(root, path)
       @temp_working_dir = File.join(Dir.tmpdir(), "buildr.#{$$}")
       @rpm_top_dir = "#{@temp_working_dir}/buildr/rpm_top_dir"
       @rpm_build_root = "#{@temp_working_dir}/buildr/rpm_build_root"
       @target = "noarch"

Instead of using a temporary directory though, it might be nicer to use 
a folder in the 'bin' directory of the local build workspace.

Does anybody know the best way to get access to it in the task definition ?

I've attached the source of what I have so far, it works at the moment, 
you can use it like any other archive packaging format:

package(:rpm).with(:spec => RPM_SPEC_STRING)
package(:rpm).include("etc/myserviceinitd", :as => 
"/etc/init.d/myservicectl") .. etc.


View raw message