# Installation process # Files to package are put in recipe.fake_root_directory # # Backends: # - make # pass if no Makefile class Package::Backend::Install def self.make : Backend::Building Backend::Building.new "install", "make" do |context, recipe| unless Dir.exists? recipe.dirname Baguette::Log.detail "no '#{recipe.dirname}' directory: pass" next BuildStatus::Pass end Do.cd recipe.dirname unless File.exists? "Makefile" next BuildStatus::Pass end options = [ "'DESTDIR=#{recipe.fake_root_directory}'", recipe.options["make install"]? || "" ] child = Do.sh "make install #{options.join " "}" if child.exit_status == 0 BuildStatus::Success else BuildStatus::Failed end end end end