Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am trying to build a Ruby package using git-buildpackage. I am getting this error near the end of the process:

dh clean --buildsystem=ruby --with ruby
   dh_testdir -O--buildsystem=ruby
   dh_auto_clean -O--buildsystem=ruby
/usr/lib/ruby/vendor_ruby/gem2deb.rb:17: warning: setting Encoding.default_external
  Entering dh_ruby --clean
No XS-Ruby-Versions: field found in source!
dh_auto_clean: dh_ruby --clean returned exit code 1
make: *** [clean] Error 1
dpkg-buildpackage: error: fakeroot debian/rules clean gave error exit status 2
E: Failed autobuilding of package
I: unmounting dev/pts filesystem
I: unmounting proc filesystem
 -> Cleaning COW directory
  forking: rm -rf /var/cache/pbuilder/build//cow.7268 
gbp:error: Couldn't run 'git-pbuilder': git-pbuilder returned 1

Here is the rules file:

#!/usr/bin/make -f

PACKAGE = $(shell dh_listpackages)
VERSION = $(shell dpkg-parsechangelog | grep ^Version: | cut -d' ' -f2 \
                | cut -d- -f1)
TMP := debian/$(PACKAGE)

DH_VERBOSE=1

%:
        dh $@ --buildsystem=ruby --with ruby

override_dh_auto_install:
        rsync -C --recursive --links --perms --times -v \
          --exclude-from=debian/exclude.rsync --exclude debian $(CURDIR)/ debian/$(PACKAGE)
share|improve this question
add comment

1 Answer 1

up vote 0 down vote accepted

The error is clear. Add the missing XS-Ruby-Versions field to the control file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.