Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.9
    • Component/s: None
    • Labels:
      None

      Description

      https://builds.apache.org/view/S-Z/view/Thrift/job/Thrift-Debian-Packages/92/console

      # Ruby library
      cd /home/jenkins/jenkins-slave/workspace/Thrift-Debian-Packages/thrift/lib/rb	&& \
      		ruby setup.rb config --installdirs=std && \
      		ruby setup.rb setup
      ruby: No such file or directory -- setup.rb (LoadError)
      make: *** [build-arch-stamp] Error 1
      dpkg-buildpackage: error: debian/rules build gave error exit status 2
      
      1. deb_ruby.patch.txt
        3 kB
        Brandon Arp
      2. thrift-1421.patch
        2 kB
        Jake Farrell

        Issue Links

          Activity

          Hide
          Jake Farrell added a comment -

          This was broken due to the switch to using bundler for the ruby gem. Attached is a patch to fix the debian build and include the gem in the debian/libthrift-ruby folder as it has handled previously.

          Since ruby is now offered as a gem I don't think we should include it as it has been, rather we should either switch to creating a ruby-thrift deb or just let gem pick the version up from rubygems.org. Thoughts?

          Show
          Jake Farrell added a comment - This was broken due to the switch to using bundler for the ruby gem. Attached is a patch to fix the debian build and include the gem in the debian/libthrift-ruby folder as it has handled previously. Since ruby is now offered as a gem I don't think we should include it as it has been, rather we should either switch to creating a ruby-thrift deb or just let gem pick the version up from rubygems.org. Thoughts?
          Hide
          Roger Meier added a comment -

          I'm not a ruby user. However, if using gem is the most common way to install a ruby library and nobody needs a debian package, then we should remove ruby completely from the debian package build.

          Show
          Roger Meier added a comment - I'm not a ruby user. However, if using gem is the most common way to install a ruby library and nobody needs a debian package, then we should remove ruby completely from the debian package build.
          Hide
          Hudson added a comment -

          Integrated in Thrift #326 (See https://builds.apache.org/job/Thrift/326/)
          Thrift-1421: Debian Packages can not be built (ruby build fails)
          Client: deb
          Patch: Jake Farrell

          Removing ruby from deb as it is now available as a gem.

          Show
          Hudson added a comment - Integrated in Thrift #326 (See https://builds.apache.org/job/Thrift/326/ ) Thrift-1421: Debian Packages can not be built (ruby build fails) Client: deb Patch: Jake Farrell Removing ruby from deb as it is now available as a gem.
          Hide
          Jake Farrell added a comment -

          Committed patch to remove ruby from debian build. CI is now failing on erlang jsx.

          Show
          Jake Farrell added a comment - Committed patch to remove ruby from debian build. CI is now failing on erlang jsx.
          Hide
          Hudson added a comment -

          Integrated in Thrift #329 (See https://builds.apache.org/job/Thrift/329/)
          Thrift-1421: Debian Packages can not be built
          Client: debian
          Patch: Jake Farrell

          Commenting out erlang from debian build until jsx can be fixed.

          Show
          Hudson added a comment - Integrated in Thrift #329 (See https://builds.apache.org/job/Thrift/329/ ) Thrift-1421: Debian Packages can not be built Client: debian Patch: Jake Farrell Commenting out erlang from debian build until jsx can be fixed.
          Hide
          Jake Farrell added a comment -

          Build of Thrift Debian Package finished successfully: https://builds.apache.org/job/Thrift-Debian-Packages/106/

          Show
          Jake Farrell added a comment - Build of Thrift Debian Package finished successfully: https://builds.apache.org/job/Thrift-Debian-Packages/106/
          Hide
          paul cannon added a comment -

          I'm not a ruby user. However, if using gem is the most common way to install a ruby library and nobody needs a debian package, then we should remove ruby completely from the debian package build.

          Strong -1 from a Debian developer here. While it's common for Ruby developers to get libraries as gems during development and testing, there are still a lot of good reasons for sticking to OS packages for deployment. Ideally, both a thrift gem and a ruby-thrift deb should be available.

          Commenting out erlang from debian build until jsx can be fixed.

          I recommend you remove the corresponding stanza from debian/control as well, or you'll get confusing empty libthrift-erlang packages lying around.

          Show
          paul cannon added a comment - I'm not a ruby user. However, if using gem is the most common way to install a ruby library and nobody needs a debian package, then we should remove ruby completely from the debian package build. Strong -1 from a Debian developer here. While it's common for Ruby developers to get libraries as gems during development and testing, there are still a lot of good reasons for sticking to OS packages for deployment. Ideally, both a thrift gem and a ruby-thrift deb should be available. Commenting out erlang from debian build until jsx can be fixed. I recommend you remove the corresponding stanza from debian/control as well, or you'll get confusing empty libthrift-erlang packages lying around.
          Hide
          Jake Farrell added a comment -

          Removed Erlang from rules and control so libthrift-erlang will not be generated. I'm fine with keeping libruby if it is easier for people than getting it from rubygems.

          Show
          Jake Farrell added a comment - Removed Erlang from rules and control so libthrift-erlang will not be generated. I'm fine with keeping libruby if it is easier for people than getting it from rubygems.
          Hide
          Hudson added a comment -

          Integrated in Thrift #344 (See https://builds.apache.org/job/Thrift/344/)
          Thrift-1421: Debian Packages can not be built

          Removing Erlang package from debian rules and control

          Show
          Hudson added a comment - Integrated in Thrift #344 (See https://builds.apache.org/job/Thrift/344/ ) Thrift-1421: Debian Packages can not be built Removing Erlang package from debian rules and control
          Hide
          Brandon Arp added a comment -

          I added ruby 1.9.1 and ruby 1.8 folders to the debian build, renamed the library ruby-thrift as per the new debian ruby packaging guidelines, set the ruby architecture to be all (just using ruby files right now, not native), and added mongrel and rake to the build deps for the deb package. Rspec is a dependency, but the build doesn't work with the latest version, so you have to install that via gem. It's not perfect, but it's a step in the right direction.

          Show
          Brandon Arp added a comment - I added ruby 1.9.1 and ruby 1.8 folders to the debian build, renamed the library ruby-thrift as per the new debian ruby packaging guidelines, set the ruby architecture to be all (just using ruby files right now, not native), and added mongrel and rake to the build deps for the deb package. Rspec is a dependency, but the build doesn't work with the latest version, so you have to install that via gem. It's not perfect, but it's a step in the right direction.
          Hide
          Roger Meier added a comment -

          Hi Brandon
          I have a question: Why do you rename libthrift-ruby to ruby-thrift ?

          -Package: libthrift-ruby
          +Package: ruby-thrift
          

          Is this the common naming scheme for ruby libraries?

          Thanks

          Show
          Roger Meier added a comment - Hi Brandon I have a question: Why do you rename libthrift-ruby to ruby-thrift ? -Package: libthrift-ruby +Package: ruby-thrift Is this the common naming scheme for ruby libraries? Thanks
          Hide
          paul cannon added a comment -

          It is for Debian, as of wheezy (the version currently in development). See:

          http://wiki.debian.org/Teams/Ruby/Packaging#Guidelines_for_Ruby_packaging

          And while I haven't seen an official statement that Ubuntu is adopting the same policy, they have packaged gem2deb and a large number of Ruby libs with the new naming scheme are already in oneiric:

          http://packages.ubuntu.com/oneiric/ruby/

          So, yeah.

          Show
          paul cannon added a comment - It is for Debian, as of wheezy (the version currently in development). See: http://wiki.debian.org/Teams/Ruby/Packaging#Guidelines_for_Ruby_packaging And while I haven't seen an official statement that Ubuntu is adopting the same policy, they have packaged gem2deb and a large number of Ruby libs with the new naming scheme are already in oneiric: http://packages.ubuntu.com/oneiric/ruby/ So, yeah.
          Hide
          Roger Meier added a comment -

          Thanks for pointing out the details Paul!

          I really like to apply your patch, but I have the following build issue on Debian Squeeze:

          make[2]: Leaving directory `/tmp/thrift/lib/rb/ext'
          <internal:lib/rubygems/custom_require>:29:in `require': no such file to load -- mongrel (LoadError)
                  from <internal:lib/rubygems/custom_require>:29:in `require'
                  from /tmp/thrift/lib/rb/lib/thrift/server/mongrel_http_server.rb:20:in `<top (required)>'
                  from <internal:lib/rubygems/custom_require>:29:in `require'
                  from <internal:lib/rubygems/custom_require>:29:in `require'
                  from spec/mongrel_http_server_spec.rb:21:in `<top (required)>'
                  from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:15:in `load'
                  from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:15:in `block in load_files'
                  from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:14:in `each'
                  from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:14:in `load_files'
                  from /usr/lib/ruby/1.9.1/spec/runner/options.rb:133:in `run_examples'
                  from /usr/lib/ruby/1.9.1/spec/runner/command_line.rb:9:in `run'
                  from /usr/bin/spec:3:in `<main>'
          rake aborted!
          Command /usr/bin/ruby1.9.1 -I"lib"  "/usr/bin/spec" "spec/base_protocol_spec.rb" "spec/base_transport_spec.rb" "spec/binary_protocol_accelerated_spec.rb" "spec/binary_protocol_spec.rb" "spec/client_spec.rb" "spec/exception_spec.rb" "spec/mongrel_http_server_spec.rb" "spec/processor_spec.rb" "spec/server_socket_spec.rb" "spec/socket_spec.rb" "spec/struct_spec.rb" "spec/union_spec.rb" "spec/compact_protocol_spec.rb" "spec/http_client_spec.rb" "spec/nonblocking_server_spec.rb" "spec/serializer_spec.rb" "spec/server_spec.rb" "spec/types_spec.rb" "spec/unix_socket_spec.rb" --color failed
          /usr/lib/ruby/1.9.1/spec/rake/spectask.rb:177:in `block (2 levels) in define'
          /usr/lib/ruby/1.9.1/rake.rb:1110:in `verbose'
          /usr/lib/ruby/1.9.1/spec/rake/spectask.rb:153:in `block in define'
          /usr/lib/ruby/1.9.1/rake.rb:634:in `call'
          /usr/lib/ruby/1.9.1/rake.rb:634:in `block in execute'
          /usr/lib/ruby/1.9.1/rake.rb:629:in `each'
          /usr/lib/ruby/1.9.1/rake.rb:629:in `execute'
          /usr/lib/ruby/1.9.1/rake.rb:595:in `block in invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
          /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `each'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
          /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `each'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
          /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `each'
          /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites'
          /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize'
          /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain'
          /usr/lib/ruby/1.9.1/rake.rb:581:in `invoke'
          /usr/lib/ruby/1.9.1/rake.rb:2041:in `invoke_task'
          /usr/lib/ruby/1.9.1/rake.rb:2019:in `block (2 levels) in top_level'
          /usr/lib/ruby/1.9.1/rake.rb:2019:in `each'
          /usr/lib/ruby/1.9.1/rake.rb:2019:in `block in top_level'
          /usr/lib/ruby/1.9.1/rake.rb:2058:in `standard_exception_handling'
          /usr/lib/ruby/1.9.1/rake.rb:2013:in `top_level'
          /usr/lib/ruby/1.9.1/rake.rb:1992:in `run'
          /usr/bin/rake:28:in `<main>'
          make[1]: *** [all-local] Error 1
          make[1]: Leaving directory `/tmp/thrift/lib/rb'
          make: *** [build-indep-stamp] Error 2
          dpkg-buildpackage: error: debian/rules build gave error exit status 2
          

          any hints?

          Show
          Roger Meier added a comment - Thanks for pointing out the details Paul! I really like to apply your patch, but I have the following build issue on Debian Squeeze: make[2]: Leaving directory `/tmp/thrift/lib/rb/ext' <internal:lib/rubygems/custom_require>:29:in `require': no such file to load -- mongrel (LoadError) from <internal:lib/rubygems/custom_require>:29:in `require' from /tmp/thrift/lib/rb/lib/thrift/server/mongrel_http_server.rb:20:in `<top (required)>' from <internal:lib/rubygems/custom_require>:29:in `require' from <internal:lib/rubygems/custom_require>:29:in `require' from spec/mongrel_http_server_spec.rb:21:in `<top (required)>' from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:15:in `load' from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:15:in `block in load_files' from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:14:in `each' from /usr/lib/ruby/1.9.1/spec/runner/example_group_runner.rb:14:in `load_files' from /usr/lib/ruby/1.9.1/spec/runner/options.rb:133:in `run_examples' from /usr/lib/ruby/1.9.1/spec/runner/command_line.rb:9:in `run' from /usr/bin/spec:3:in `<main>' rake aborted! Command /usr/bin/ruby1.9.1 -I"lib" "/usr/bin/spec" "spec/base_protocol_spec.rb" "spec/base_transport_spec.rb" "spec/binary_protocol_accelerated_spec.rb" "spec/binary_protocol_spec.rb" "spec/client_spec.rb" "spec/exception_spec.rb" "spec/mongrel_http_server_spec.rb" "spec/processor_spec.rb" "spec/server_socket_spec.rb" "spec/socket_spec.rb" "spec/struct_spec.rb" "spec/union_spec.rb" "spec/compact_protocol_spec.rb" "spec/http_client_spec.rb" "spec/nonblocking_server_spec.rb" "spec/serializer_spec.rb" "spec/server_spec.rb" "spec/types_spec.rb" "spec/unix_socket_spec.rb" --color failed /usr/lib/ruby/1.9.1/spec/rake/spectask.rb:177:in `block (2 levels) in define' /usr/lib/ruby/1.9.1/rake.rb:1110:in `verbose' /usr/lib/ruby/1.9.1/spec/rake/spectask.rb:153:in `block in define' /usr/lib/ruby/1.9.1/rake.rb:634:in `call' /usr/lib/ruby/1.9.1/rake.rb:634:in `block in execute' /usr/lib/ruby/1.9.1/rake.rb:629:in `each' /usr/lib/ruby/1.9.1/rake.rb:629:in `execute' /usr/lib/ruby/1.9.1/rake.rb:595:in `block in invoke_with_call_chain' /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize' /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain' /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:602:in `each' /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain' /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize' /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain' /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:602:in `each' /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain' /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize' /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain' /usr/lib/ruby/1.9.1/rake.rb:605:in `block in invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:602:in `each' /usr/lib/ruby/1.9.1/rake.rb:602:in `invoke_prerequisites' /usr/lib/ruby/1.9.1/rake.rb:594:in `block in invoke_with_call_chain' /usr/lib/ruby/1.9.1/monitor.rb:201:in `mon_synchronize' /usr/lib/ruby/1.9.1/rake.rb:588:in `invoke_with_call_chain' /usr/lib/ruby/1.9.1/rake.rb:581:in `invoke' /usr/lib/ruby/1.9.1/rake.rb:2041:in `invoke_task' /usr/lib/ruby/1.9.1/rake.rb:2019:in `block (2 levels) in top_level' /usr/lib/ruby/1.9.1/rake.rb:2019:in `each' /usr/lib/ruby/1.9.1/rake.rb:2019:in `block in top_level' /usr/lib/ruby/1.9.1/rake.rb:2058:in `standard_exception_handling' /usr/lib/ruby/1.9.1/rake.rb:2013:in `top_level' /usr/lib/ruby/1.9.1/rake.rb:1992:in `run' /usr/bin/rake:28:in `<main>' make[1]: *** [all-local] Error 1 make[1]: Leaving directory `/tmp/thrift/lib/rb' make: *** [build-indep-stamp] Error 2 dpkg-buildpackage: error: debian/rules build gave error exit status 2 any hints?
          Hide
          Brandon Arp added a comment -

          You'll need to install mongrel, rake and the rspec 1.3.2 gem to build the deb. I believe that you'll need to install rspec as a gem as the apt repos can only have one version, and it's the incompatible rspec 2.0.

          Show
          Brandon Arp added a comment - You'll need to install mongrel, rake and the rspec 1.3.2 gem to build the deb. I believe that you'll need to install rspec as a gem as the apt repos can only have one version, and it's the incompatible rspec 2.0.
          Hide
          Jake Farrell added a comment -

          I had looked at switching over to rspec2 since this is a source of many issues with building the ruby lib but kept rpsec 1.3.2 due to the ci servers running the older version. Since you are trying to build on ruby 1.9.x you will also have to install mongrel --pre due to an current issue with mongrel.

          Show
          Jake Farrell added a comment - I had looked at switching over to rspec2 since this is a source of many issues with building the ruby lib but kept rpsec 1.3.2 due to the ci servers running the older version. Since you are trying to build on ruby 1.9.x you will also have to install mongrel --pre due to an current issue with mongrel.
          Hide
          Roger Meier added a comment -

          Thank you all!

          I did the following minor edits and committed the patch:

          • use rm -rf for cleaning up egg-info
          • remove ruby1.9.1-dev as build dependency (=> no external mongrel required)

          -roger

          Show
          Roger Meier added a comment - Thank you all! I did the following minor edits and committed the patch: use rm -rf for cleaning up egg-info remove ruby1.9.1-dev as build dependency (=> no external mongrel required) -roger
          Hide
          Hudson added a comment -

          Integrated in Thrift #357 (See https://builds.apache.org/job/Thrift/357/)
          THRIFT-1421 Debian Packages can not be built
          Patch: Brandon Arp
          Fix: ruby build

          roger : http://svn.apache.org/viewvc/?view=rev&rev=1212324
          Files :

          • /thrift/trunk/contrib/debian/control
          • /thrift/trunk/contrib/debian/rules
          Show
          Hudson added a comment - Integrated in Thrift #357 (See https://builds.apache.org/job/Thrift/357/ ) THRIFT-1421 Debian Packages can not be built Patch: Brandon Arp Fix: ruby build roger : http://svn.apache.org/viewvc/?view=rev&rev=1212324 Files : /thrift/trunk/contrib/debian/control /thrift/trunk/contrib/debian/rules

            People

            • Assignee:
              Jake Farrell
              Reporter:
              Roger Meier
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development