svn commit: r338488 - in head/databases/ruby-bdb: . files
Steve Wills
swills at FreeBSD.org
Thu Jan 2 20:12:10 UTC 2014
Author: swills
Date: Thu Jan 2 20:12:09 2014
New Revision: 338488
URL: http://svnweb.freebsd.org/changeset/ports/338488
Log:
- Make check for bdb version ignore the patch level
PR: ports/184921
Added:
head/databases/ruby-bdb/files/patch-bdbxml1__bdbxml.cc (contents, props changed)
head/databases/ruby-bdb/files/patch-bdbxml2__bdbxml.cc (contents, props changed)
head/databases/ruby-bdb/files/patch-src__bdb.c (contents, props changed)
Modified:
head/databases/ruby-bdb/Makefile (contents, props changed)
head/databases/ruby-bdb/files/patch-extconf.rb (contents, props changed)
Modified: head/databases/ruby-bdb/Makefile
==============================================================================
--- head/databases/ruby-bdb/Makefile Thu Jan 2 20:09:36 2014 (r338487)
+++ head/databases/ruby-bdb/Makefile Thu Jan 2 20:12:09 2014 (r338488)
@@ -3,7 +3,7 @@
PORTNAME= bdb
PORTVERSION= 0.6.6
-PORTREVISION= 1
+PORTREVISION= 2
CATEGORIES= databases ruby
MASTER_SITES= ftp://ftp.idaemons.org/pub/distfiles/ruby/ \
http://idaemons.org/distfiles/ruby/ \
Added: head/databases/ruby-bdb/files/patch-bdbxml1__bdbxml.cc
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/databases/ruby-bdb/files/patch-bdbxml1__bdbxml.cc Thu Jan 2 20:12:09 2014 (r338488)
@@ -0,0 +1,48 @@
+--- ./bdbxml1/bdbxml.cc.orig 2011-04-06 19:35:39.000000000 +0000
++++ ./bdbxml1/bdbxml.cc 2013-12-18 19:00:54.663254132 +0000
+@@ -2316,7 +2316,7 @@
+
+ void Init_bdbxml()
+ {
+- int major, minor, patch;
++ int major, minor;
+ VALUE version;
+ #ifdef BDB_LINK_OBJ
+ extern void Init_bdb();
+@@ -2339,19 +2339,16 @@
+ xb_mDb = rb_const_get(rb_cObject, rb_intern("BDB"));
+ major = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_MAJOR")));
+ minor = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_MINOR")));
+- patch = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_PATCH")));
+- if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR
+- || patch != DB_VERSION_PATCH) {
+- rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of BDB\n\tyou have BDB::XML version %d.%d.%d and BDB version %d.%d.%d\n",
+- DB_VERSION_MAJOR, DB_VERSION_MINOR, DB_VERSION_PATCH,
+- major, minor, patch);
++ if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR) {
++ rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of BDB\n\tyou have BDB::XML version %d.%d and BDB version %d.%d\n",
++ DB_VERSION_MAJOR, DB_VERSION_MINOR,
++ major, minor);
+ }
+- version = rb_tainted_str_new2(dbxml_version(&major, &minor, &patch));
+- if (major != DBXML_VERSION_MAJOR || minor != DBXML_VERSION_MINOR
+- || patch != DBXML_VERSION_PATCH) {
+- rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of DbXml\n\tyou have DbXml.hpp version %d.%d.%d and libdbxml version %d.%d.%d\n",
+- DB_VERSION_MAJOR, DB_VERSION_MINOR, DB_VERSION_PATCH,
+- major, minor, patch);
++ version = rb_tainted_str_new2(dbxml_version(&major, &minor));
++ if (major != DBXML_VERSION_MAJOR || minor != DBXML_VERSION_MINOR) {
++ rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of DbXml\n\tyou have DbXml.hpp version %d.%d and libdbxml version %d.%d\n",
++ DB_VERSION_MAJOR, DB_VERSION_MINOR,
++ major, minor);
+ }
+
+ xb_eFatal = rb_const_get(xb_mDb, rb_intern("Fatal"));
+@@ -2374,7 +2371,6 @@
+ rb_define_const(xb_mXML, "VERSION", version);
+ rb_define_const(xb_mXML, "VERSION_MAJOR", INT2FIX(major));
+ rb_define_const(xb_mXML, "VERSION_MINOR", INT2FIX(minor));
+- rb_define_const(xb_mXML, "VERSION_PATCH", INT2FIX(patch));
+ #ifdef DBXML_CHKSUM_SHA1
+ rb_define_const(xb_mXML, "CHKSUM_SHA1", INT2NUM(DBXML_CHKSUM_SHA1));
+ #endif
Added: head/databases/ruby-bdb/files/patch-bdbxml2__bdbxml.cc
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/databases/ruby-bdb/files/patch-bdbxml2__bdbxml.cc Thu Jan 2 20:12:09 2014 (r338488)
@@ -0,0 +1,48 @@
+--- ./bdbxml2/bdbxml.cc.orig 2011-04-06 19:35:39.000000000 +0000
++++ ./bdbxml2/bdbxml.cc 2013-12-18 19:00:54.677253900 +0000
+@@ -5510,7 +5510,7 @@
+
+ void Init_bdbxml()
+ {
+- int major, minor, patch;
++ int major, minor;
+ VALUE version;
+ #ifdef BDB_LINK_OBJ
+ extern void Init_bdb();
+@@ -5535,19 +5535,16 @@
+ xb_mDb = rb_const_get(rb_cObject, rb_intern("BDB"));
+ major = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_MAJOR")));
+ minor = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_MINOR")));
+- patch = NUM2INT(rb_const_get(xb_mDb, rb_intern("VERSION_PATCH")));
+- if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR
+- || patch != DB_VERSION_PATCH) {
+- rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of BDB\n\tyou have BDB::XML version %d.%d.%d and BDB version %d.%d.%d\n",
+- DB_VERSION_MAJOR, DB_VERSION_MINOR, DB_VERSION_PATCH,
+- major, minor, patch);
++ if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR) {
++ rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of BDB\n\tyou have BDB::XML version %d.%d and BDB version %d.%d\n",
++ DB_VERSION_MAJOR, DB_VERSION_MINOR,
++ major, minor);
+ }
+- version = rb_tainted_str_new2(dbxml_version(&major, &minor, &patch));
+- if (major != DBXML_VERSION_MAJOR || minor != DBXML_VERSION_MINOR
+- || patch != DBXML_VERSION_PATCH) {
+- rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of DbXml\n\tyou have DbXml.hpp version %d.%d.%d and libdbxml version %d.%d.%d\n",
+- DB_VERSION_MAJOR, DB_VERSION_MINOR, DB_VERSION_PATCH,
+- major, minor, patch);
++ version = rb_tainted_str_new2(dbxml_version(&major, &minor));
++ if (major != DBXML_VERSION_MAJOR || minor != DBXML_VERSION_MINOR) {
++ rb_raise(rb_eNotImpError, "\nBDB::XML needs compatible versions of DbXml\n\tyou have DbXml.hpp version %d.%d and libdbxml version %d.%d\n",
++ DB_VERSION_MAJOR, DB_VERSION_MINOR,
++ major, minor);
+ }
+
+ xb_mObs = rb_const_get(rb_cObject, rb_intern("ObjectSpace"));
+@@ -5604,7 +5601,6 @@
+ rb_define_const(xb_mXML, "VERSION", version);
+ rb_define_const(xb_mXML, "VERSION_MAJOR", INT2FIX(major));
+ rb_define_const(xb_mXML, "VERSION_MINOR", INT2FIX(minor));
+- rb_define_const(xb_mXML, "VERSION_PATCH", INT2FIX(patch));
+ #if HAVE_DBXML_CONST_DBXML_ADOPT_DBENV
+ rb_define_const(xb_mXML, "ADOPT_DBENV", INT2NUM(DBXML_ADOPT_DBENV));
+ #endif
Modified: head/databases/ruby-bdb/files/patch-extconf.rb
==============================================================================
--- head/databases/ruby-bdb/files/patch-extconf.rb Thu Jan 2 20:09:36 2014 (r338487)
+++ head/databases/ruby-bdb/files/patch-extconf.rb Thu Jan 2 20:12:09 2014 (r338488)
@@ -1,5 +1,5 @@
---- extconf.rb.orig 2011-08-22 22:53:57.000000000 -0700
-+++ extconf.rb 2011-08-22 22:54:10.000000000 -0700
+--- ./extconf.rb.orig 2011-04-06 19:35:39.000000000 +0000
++++ ./extconf.rb 2013-12-18 19:00:54.688254572 +0000
@@ -50,7 +50,7 @@
rdoc: docs/doc/index.html
Added: head/databases/ruby-bdb/files/patch-src__bdb.c
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ head/databases/ruby-bdb/files/patch-src__bdb.c Thu Jan 2 20:12:09 2014 (r338488)
@@ -0,0 +1,26 @@
+--- ./src/bdb.c.orig 2011-04-06 19:35:39.000000000 +0000
++++ ./src/bdb.c 2013-12-18 19:04:39.134238326 +0000
+@@ -166,11 +166,10 @@
+ rb_raise(rb_eNameError, "module already defined");
+ }
+ version = rb_tainted_str_new2(db_version(&major, &minor, &patch));
+- if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR
+- || patch != DB_VERSION_PATCH) {
+- rb_raise(rb_eNotImpError, "\nBDB needs compatible versions of libdb & db.h\n\tyou have db.h version %d.%d.%d and libdb version %d.%d.%d\n",
+- DB_VERSION_MAJOR, DB_VERSION_MINOR, DB_VERSION_PATCH,
+- major, minor, patch);
++ if (major != DB_VERSION_MAJOR || minor != DB_VERSION_MINOR) {
++ rb_raise(rb_eNotImpError, "\nBDB needs compatible versions of libdb & db.h\n\tyou have db.h version %d.%d and libdb version %d.%d\n",
++ DB_VERSION_MAJOR, DB_VERSION_MINOR,
++ major, minor);
+ }
+ bdb_mMarshal = rb_const_get(rb_cObject, rb_intern("Marshal"));
+ bdb_id_current_db = rb_intern("__bdb_current_db__");
+@@ -189,7 +188,6 @@
+ rb_define_const(bdb_mDb, "VERSION", version);
+ rb_define_const(bdb_mDb, "VERSION_MAJOR", INT2FIX(major));
+ rb_define_const(bdb_mDb, "VERSION_MINOR", INT2FIX(minor));
+- rb_define_const(bdb_mDb, "VERSION_PATCH", INT2FIX(patch));
+ rb_define_const(bdb_mDb, "VERSION_NUMBER", INT2NUM(BDB_VERSION));
+ #if HAVE_CONST_DB_BTREE
+ rb_define_const(bdb_mDb, "BTREE", INT2FIX(DB_BTREE));
More information about the svn-ports-all
mailing list