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"
      super
    end

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.


Thanks,
Danny.

Attachment: rpm.rb
Description: application/ruby

Reply via email to