| author | Antonio Terceiro <terceiro@softwarelivre.org> | |
| Wed, 11 May 2011 19:17:36 +0000 (12:17 -0700) | ||
| committer | Antonio Terceiro <terceiro@softwarelivre.org> | |
| Wed, 11 May 2011 19:18:42 +0000 (12:18 -0700) |
This method could be overriden by subclasses to provide different
methods of building/installing (hint hint ;-))
methods of building/installing (hint hint ;-))
| lib/gem2deb/dh_ruby.rb | patch | blob | history |
diff --git a/lib/gem2deb/dh_ruby.rb b/lib/gem2deb/dh_ruby.rb
--- a/lib/gem2deb/dh_ruby.rb
+++ b/lib/gem2deb/dh_ruby.rb
package = packages.first
+ install_files_and_build_extensions(package, supported_versions)
+
+ run_tests(supported_versions)
+
+ install_substvars(package, supported_versions)
+
+ update_shebangs(package)
+
+ check_rubygems
+
+ puts " Leaving dh_ruby --install" if @verbose
+ end
+
+ protected
+
+ def install_files_and_build_extensions(package, supported_versions)
install_files('bin', find_files('bin'), File.join(destdir_for(package), @bindir), 755) if File::directory?('bin')
install_files('lib', find_files('lib'), File.join(destdir_for(package), RUBY_CODE_DIR), 644) if File::directory?('lib')
-
if metadata.has_native_extensions?
supported_versions.each do |rubyver|
puts "Building extension for #{rubyver} ..." if @verbose
end
end
end
-
- run_tests(supported_versions)
-
- install_substvars(package, supported_versions)
-
- update_shebangs(package)
-
- # FIXME after install, check for require 'rubygems' and other stupid things, and
- # issue warnings
-
- check_rubygems
- puts " Leaving dh_ruby --install" if @verbose
end
- protected
-
def remove_duplicate_files(src, dst)
candidates = (Dir::entries(src) & Dir::entries(dst)) - ['.', '..']
candidates.each do |cand|
