Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 209965 - Review Request: ruby-bdb - Berkeley DB is an embedded database system that supports keyed access to data
Summary: Review Request: ruby-bdb - Berkeley DB is an embedded database system that su...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jochen Schmitt
QA Contact: Fedora Package Reviews List
URL:
Whiteboard:
Depends On:
Blocks: FE-ACCEPT
TreeView+ depends on / blocked
 
Reported: 2006-10-09 02:51 UTC by Michael Rice
Modified: 2010-04-20 13:57 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-11-01 22:41:36 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Michael Rice 2006-10-09 02:51:31 UTC
Spec URL: http://errr.fluxbox-wiki.org/fedora_stuff/bdb/1/ruby-bdb.spec
SRPM URL: http://errr.fluxbox-wiki.org/fedora_stuff/bdb/1/ruby-bdb-0.5.9-1.fc5.src.rpm

Description: Berkeley DB lib for ruby

rpmlint gives: 
W: ruby-bdb invalid-license Ruby License/GPL
W: ruby-bdb setup-not-quiet

The license is what is shown for rpm -qi ruby and this module said it was under the same terms as ruby. The second W Im not sure how to solve

Comment 1 Jochen Schmitt 2006-10-09 19:03:54 UTC
You have to write '%setup -q' thats all.


Comment 2 Jochen Schmitt 2006-10-09 19:59:08 UTC
God:
+ Local build works fine.
+ Mock build works fine.

Bad:
- Rpmlint on debuginfo package complaints:
E: ruby-bdb-debuginfo empty-debuginfo-package
- Missing SMP flags. If it doesn't build with it, please add a comment
  (wiki: PackagingGuidelines#parallelmake)
- The package should contain the text of the license






Comment 3 Michael Rice 2006-10-09 21:14:19 UTC
(In reply to comment #1)
> You have to write '%setup -q' thats all.
> 

So should I rename the package from ruby-bdb to just bdb? I used ruby-bdb and
did the %setup -n %{tarname}-%{version} because having the package named bdb
didnt seem very descriptive to me... 

comment #2 
> E: ruby-bdb-debuginfo empty-debuginfo-package
>
I have tried to get it to build with debug but Im not sure what else to do to
get it to build a debug package. Any pointers you could give?

> The package should contain the text of the license

So should I add it until upstream provides it in the package?


Comment 4 David Lutterkort 2006-10-09 21:34:15 UTC
- I believe your debuginfo problem comes from stripping bdb.so in the spec file
- if you don't strip manually, you should get a valid debuginfo package.

- The specfile should explicitly list the files to be installed instead of
generating them with find - as far as I can tell, the only thing missing is
%{ruby_sitearch}/bdb.so, since everything else is covered by the %doc directive.

- The name of the package should stay ruby-bdb; it's the right thing to do
according to the packaging guidelines

Comment 5 Michael Rice 2006-10-09 23:45:31 UTC
(In reply to comment #4)
> - I believe your debuginfo problem comes from stripping bdb.so in the spec file
You hit the nail on the head. Fixed.

> - The specfile should explicitly list the files to be installed instead of
> generating them with find - as far as I can tell, the only thing missing is
> %{ruby_sitearch}/bdb.so, since everything else is covered by the %doc directive.

Done

> 
> - The name of the package should stay ruby-bdb; it's the right thing to do
> according to the packaging guidelines

Ok so what about comment #1 What should I do about it, is this a blocker or is
this good?

Comment 6 Michael Rice 2006-10-09 23:47:07 UTC
Oh it would help to put the link to the src rpm and spec :)

http://errr.fluxbox-wiki.org/fedora_stuff/bdb/2/ruby-bdb.spec
http://errr.fluxbox-wiki.org/fedora_stuff/bdb/2/ruby-bdb-0.5.9-2.fc5.src.rpm

I do realize that the source in the src.rpm is not from spectool -g but the site
seems to be down at the moment because all my requests time out...

Comment 7 Jason Tibbitts 2006-10-10 00:31:37 UTC
To fix the two warnings, in comment #1:

Change the license to "Ruby License".  The Ruby License incorporates the GPL by
reference; there is no need to list it separately.

Add the '-q' argument to the %setup line:
   %setup -q -n %{tarname}-%{version}


Comment 8 Jason Tibbitts 2006-10-10 00:57:54 UTC
Some other notes, as I compare the spec in comment #6 against 
http://fedoraproject.org/wiki/Packaging/Ruby.

No Requires: ruby(api) = 1.8 line.

I don't understand why the ruby18 define and following conditional stuff is
there.  Even FC3 had Ruby 1.8.4; it's not possible to build an Extras package
for anything older.

No Provides: ruby(bdb) = %{version} line.  (Yes, the guidelines don't include
the version; that was an oversight which we'll be changing.)

This is Jochen's review, so approval (or disapproval, as the case may be) is up
to him.  However, I personally would see those as blockers.

Comment 9 Michael Rice 2006-10-10 02:58:01 UTC
Thanks for the close review on this one guys, yall have taught me a lot :)

I think I have all these next points from comment #7 and comment #8 fixed here
is the new spce and src.rpm:

http://errr.fluxbox-wiki.org/fedora_stuff/bdb/3/ruby-bdb.spec
http://errr.fluxbox-wiki.org/fedora_stuff/bdb/3/ruby-bdb-0.5.9-3.fc5.src.rpm

On the conditional stuff I didnt know why it was there either.. I just found
this spec file on the net and kind of took it over because I use this lib for my
rbot on IRC :)

Comment 10 Jochen Schmitt 2006-10-10 16:04:55 UTC
The tarball in your package doesn't match with the tarball from the upstream source.

Comment 11 Michael Rice 2006-10-10 16:20:21 UTC
(In reply to comment #10)
> The tarball in your package doesn't match with the tarball from the upstream
source.

see comment #6 when I was making this the site was down so I was un able to
spectool -g the source. Is that the only blocker?

Comment 12 Michael Rice 2006-10-10 16:22:35 UTC
Oh and http://errr.fluxbox-wiki.org/fedora_stuff/bdb/3/ruby-bdb-0.5.9-3.src.rpm
now that the site is online again it does.

Comment 13 Michael Rice 2006-10-17 02:19:59 UTC
Jason Tibbitts pointed out to me in IRC that I had an unneeded Require for bdb
so that has been removed.

http://errr.fluxbox-wiki.org/fedora_stuff/bdb/4/ruby-bdb-0.5.9-4.src.rpm
http://errr.fluxbox-wiki.org/fedora_stuff/bdb/4/ruby-bdb.spec

Anything else that this needs before it is approved??

Comment 14 Michael Rice 2006-10-18 19:54:38 UTC
I have contacted Jochen Schmitt via email today about the review at 14:55 CST 

Comment 15 Jochen Schmitt 2006-10-18 20:52:14 UTC
God:
+ Tarball match with upstream.
* Local build works fine.
+ No complaints from rpmlint on binary rpm.
+ No complaints for source rpm from rpmlint.

Bad:
- When I try to run a test, for example 'ruby btree.rb', I will get the
following error messages:


 21) Error:
test_21_convert(TestBtree):
NoMethodError: undefined method `to_hash' for nil:NilClass
    btree.rb:454:in `test_21_convert'

 22) Error:
test_23_sh(TestBtree):
NoMethodError: undefined method `close' for nil:NilClass
    btree.rb:485:in `test_23_sh'

23 tests, 12 assertions, 0 failures, 22 errors






Comment 16 Michael Rice 2006-10-19 03:35:22 UTC
According to Readme.en you should do "make test", and when I do this all test
run fine
(From readme)
* Tests : if you have rubyunit, or testunit

   make test

My output from this is as follows:

make test
ruby tests/log.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/log
Started
............
Finished in 0.24764 seconds.

12 tests, 2315 assertions, 0 failures, 0 errors
ruby tests/recnum.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/recnum
Started
.................
Finished in 0.855125 seconds.

17 tests, 2398 assertions, 0 failures, 0 errors
ruby tests/hash.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/hash
Started
......................
Finished in 1.954587 seconds.

22 tests, 15771 assertions, 0 failures, 0 errors
ruby tests/recno.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/recno
Started
........................
Finished in 0.165349 seconds.

24 tests, 157 assertions, 0 failures, 0 errors
ruby tests/lock.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/lock
Started
..........
Finished in 0.097599 seconds.

10 tests, 174 assertions, 0 failures, 0 errors
ruby tests/marshal.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/marshal
Started
..................
Finished in 0.339738 seconds.

18 tests, 2959 assertions, 0 failures, 0 errors
ruby tests/queue.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/queue
Started
.................
Finished in 0.134493 seconds.

17 tests, 130 assertions, 0 failures, 0 errors
ruby tests/btree.rb

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/btree
Started
.......................
Finished in 2.086127 seconds.

23 tests, 15795 assertions, 0 failures, 0 errors

Did you get your errors from running make test or did you do it from running the
test alone on one file??

Comment 17 Michael Rice 2006-10-19 03:45:04 UTC
> Bad:
> - When I try to run a test, for example 'ruby btree.rb', I will get the
> following error messages:
> 
> 
>  21) Error:
> test_21_convert(TestBtree):
> NoMethodError: undefined method `to_hash' for nil:NilClass
>     btree.rb:454:in `test_21_convert'
> 
>  22) Error:
> test_23_sh(TestBtree):
> NoMethodError: undefined method `close' for nil:NilClass
>     btree.rb:485:in `test_23_sh'
> 
> 23 tests, 12 assertions, 0 failures, 22 errors
> 

If you look at the src of btree.rb you will also see it needs to be run from
above the tests dir, its pulling in some needed stuff from src/
so if you run:

errr.org | /home/errr/src/bdb-0.5.9 | 22:43 |
ruby tests/btree.rb 

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite tests/btree
Started
.......................
Finished in 2.146135 seconds.

23 tests, 15801 assertions, 0 failures, 0 errors


But to do from tests:

errr.org | /home/errr/src/bdb-0.5.9/tests | 22:44 |
ruby btree.rb      

VERSION of BDB is Sleepycat Software: Berkeley DB 4.3.29: (September  7, 2006)
Loaded suite btree
Started
..................EEE..
Finished in 0.462519 seconds.

  1) Error:
test_18_btree_delete(TestBtree):
Errno::ENOENT: No such file or directory - examples/wordtest
    btree.rb:401:in `foreach'
    btree.rb:401:in `intern_btree_delete'
    btree.rb:424:in `test_18_btree_delete'

  2) Error:
test_19_btree_delete(TestBtree):
Errno::ENOENT: No such file or directory - examples/wordtest
    btree.rb:401:in `foreach'
    btree.rb:401:in `intern_btree_delete'
    btree.rb:436:in `test_19_btree_delete'

  3) Error:
test_20_index(TestBtree):
NoMethodError: undefined method `reverse' for nil:NilClass
    btree.rb:445:in `test_20_index'
    btree.rb:442:in `test_20_index'

23 tests, 4013 assertions, 0 failures, 3 errors


Comment 18 Jochen Schmitt 2006-10-19 17:01:01 UTC
you have mailed me, that I have to call the test scripts from the parent directory.

So I think we should to the following:

1.) Add

%check
make tests

into the source rpm.

2 Remove the tests directory from the docs directory

Comment 19 Michael Rice 2006-10-19 19:15:30 UTC
(In reply to comment #18)
> you have mailed me, that I have to call the test scripts from the parent
directory.
> 
> So I think we should to the following:
> 
> 1.) Add
> 
> %check
> make tests
> 
> into the source rpm.
> 
> 2 Remove the tests directory from the docs directory

Im not sure I understand what this will do. What will this accomplish exactly?

Comment 20 Michael Rice 2006-10-19 19:17:42 UTC
I should have been more clear (I can see why to pull out the tests/ dir) Im not
sure I understand about the %check stuff.

Comment 21 Jochen Schmitt 2006-10-19 19:50:49 UTC
The check stanza will be executed after the package is build to executed the
progresive test cases.

This will ensure, that the basic functions of the package will worked in a
proper way.

You can put it after the %build stanza.

Comment 22 Michael Rice 2006-10-19 20:18:51 UTC
(In reply to comment #21)
> The check stanza will be executed after the package is build to executed the
> progresive test cases.
> 
> This will ensure, that the basic functions of the package will worked in a
> proper way.
> 
> You can put it after the %build stanza.

OK I added this but when I build it doesnt do anything.. 

+ make tests
make: Nothing to be done for `tests'.
+ exit 0
Processing files: ruby-bdb-0.5.9-5

http://errr.fluxbox-wiki.org/fedora_stuff/bdb/5/ruby-bdb.spec

Also I tried to install this rpm via yum on a box with no ruby and the only
thing it pulled in was a ruby lib, doesnt it still need ro Require: ruby  not
just ruby(abi)= 1.8??


Comment 23 David Lutterkort 2006-10-19 22:33:41 UTC
(In reply to comment #22)
> Also I tried to install this rpm via yum on a box with no ruby and the only
> thing it pulled in was a ruby lib, doesnt it still need ro Require: ruby  not
> just ruby(abi)= 1.8??

It's a little weird at first, but ruby(abi) is provided by ruby-libs; that
package is enough if you just want to embed ruby in another program. The ruby
package adds the command line interpreter (/usr/bin/ruby) - unless ruby-bdb
depends on that, you don't need to require ruby. Presumably packages that
contain scripts using ruby-bdb will make sure that /usr/bin/ruby is installed.



Comment 24 Michael Rice 2006-10-19 23:37:31 UTC
(In reply to comment #23)
> (In reply to comment #22)
> > Also I tried to install this rpm via yum on a box with no ruby and the only
> > thing it pulled in was a ruby lib, doesnt it still need ro Require: ruby  not
> > just ruby(abi)= 1.8??
> 
> It's a little weird at first, but ruby(abi) is provided by ruby-libs; that
> package is enough if you just want to embed ruby in another program. The ruby
> package adds the command line interpreter (/usr/bin/ruby) - unless ruby-bdb
> depends on that, you don't need to require ruby. Presumably packages that
> contain scripts using ruby-bdb will make sure that /usr/bin/ruby is installed.
> 
> 
Ah ok, thanks for clearing that up for me.



Comment 25 Jochen Schmitt 2006-10-20 15:01:32 UTC
Please s/tests/test/, sorry for any inconviences.

Comment 26 Michael Rice 2006-10-20 16:27:50 UTC
(In reply to comment #25)
> Please s/tests/test/, sorry for any inconviences.

No problem, hows this look?


http://errr.fluxbox-wiki.org/fedora_stuff/bdb/6/ruby-bdb.spec
http://errr.fluxbox-wiki.org/fedora_stuff/bdb/6/ruby-bdb-0.5.9-6.src.rpm

Comment 27 Michael Rice 2006-10-30 22:22:57 UTC
Jochen, you still there??

Comment 28 Michael Rice 2006-11-01 03:49:26 UTC
I emailed Jochen on Thu, 26 Oct 2006 19:15:47 -0500 Still no word back yet..

Comment 29 Jochen Schmitt 2006-11-01 16:19:37 UTC
Good:
+ Tarball match with upstream.
+ Local build works fine.
+ No complaints on source rpm from rpmlint.
+ No complaints on installed rpm from rpmlint.
+ Local inatall/uninstall works fine.
+ Mock build works fine.

Bad:
- Package doesn't contains a varbatin copy of the license (no blocker)

You are APPROVED.



Comment 30 Michael Rice 2006-11-01 22:41:36 UTC
Thank you for the help on this one.

Comment 31 Michael Stahnke 2010-04-20 13:57:52 UTC
Is there any possibility of getting this branched for EPEL5?  If you'd like a co-maintainer for EPEL I'd be happy do it. 

stahnma


Note You need to log in before you can comment on or make changes to this bug.