diff options
author | knu <knu@FreeBSD.org> | 2002-02-13 10:38:18 +0800 |
---|---|---|
committer | knu <knu@FreeBSD.org> | 2002-02-13 10:38:18 +0800 |
commit | 3e9da92c69be12a65b8dc76ab85911bbc281acb6 (patch) | |
tree | 4a25965cc563c8a2819f215d92314d48838755fb /databases/ruby-bdb | |
parent | 3e7cbc411c2381443983da2e6984275f37f88955 (diff) | |
download | freebsd-ports-gnome-3e9da92c69be12a65b8dc76ab85911bbc281acb6.tar.gz freebsd-ports-gnome-3e9da92c69be12a65b8dc76ab85911bbc281acb6.tar.zst freebsd-ports-gnome-3e9da92c69be12a65b8dc76ab85911bbc281acb6.zip |
Build a module with a correct combination of headers and library on a
system where db3 and db4 are both installed.
For those who have built dysfunctional modules, bump the PORTREVISION.
Diffstat (limited to 'databases/ruby-bdb')
-rw-r--r-- | databases/ruby-bdb/Makefile | 7 | ||||
-rw-r--r-- | databases/ruby-bdb/files/patch-src::extconf.rb | 58 |
2 files changed, 63 insertions, 2 deletions
diff --git a/databases/ruby-bdb/Makefile b/databases/ruby-bdb/Makefile index 1359c659e1fe..affea8a9a350 100644 --- a/databases/ruby-bdb/Makefile +++ b/databases/ruby-bdb/Makefile @@ -7,6 +7,7 @@ PORTNAME= bdb PORTVERSION= 0.3.0 +PORTREVISION= 1 CATEGORIES= databases ruby MASTER_SITES= ftp://moulon.inra.fr/pub/ruby/ PKGNAMEPREFIX= ${RUBY_PKGNAMEPREFIX} @@ -27,9 +28,11 @@ USE_RUBY= yes USE_RUBY_EXTCONF= yes .if defined(WITH_BDB4) -CONFIGURE_ARGS= --with-db-include-dir="${PREFIX}/include/db4" +CONFIGURE_ARGS= --with-db-include-dir="${PREFIX}/include/db4" \ + --with-db-version=4 .else -CONFIGURE_ARGS= --with-db-include-dir="${PREFIX}/include/db3" +CONFIGURE_ARGS= --with-db-include-dir="${PREFIX}/include/db3" \ + --with-db-version=3 .endif INSTALL_TARGET= site-install diff --git a/databases/ruby-bdb/files/patch-src::extconf.rb b/databases/ruby-bdb/files/patch-src::extconf.rb new file mode 100644 index 000000000000..70a30430c120 --- /dev/null +++ b/databases/ruby-bdb/files/patch-src::extconf.rb @@ -0,0 +1,58 @@ +--- src/extconf.rb.orig Thu Feb 7 23:02:25 2002 ++++ src/extconf.rb Wed Feb 13 08:27:48 2002 +@@ -24,13 +24,48 @@ + else + "" + end +-unless (!test && (have_library("db-4", "db_version#{unique}") || +- have_library("db4", "db_version#{unique}") || +- have_library("db3", "db_version#{unique}") || +- have_library("db2", "db_version")) || +- have_library("db", "db_version")) +- raise "libdb.a not found" +-end ++ ++catch(:done) { ++ unless test ++ with_ver = with_config('db-version') ++ ++ unless with_ver && with_ver != '4' ++ if have_library("db-4", "db_version#{unique}") || ++ have_library("db4", "db_version#{unique}") ++ throw :done ++ end ++ ++ if with_ver == '4' ++ raise "libdb-4 or libdb4 not found" ++ end ++ end ++ ++ unless with_ver && with_ver != '3' ++ if have_library("db3", "db_version#{unique}") ++ throw :done ++ end ++ ++ if with_ver == '3' ++ raise "libdb3 not found" ++ end ++ end ++ ++ unless with_ver && with_ver != '2' ++ if have_library("db2", "db_version") ++ throw :done ++ end ++ ++ if with_ver == '2' ++ raise "libdb3 not found" ++ end ++ end ++ end ++ ++ if !have_library("db", "db_version") ++ raise "libdb not found" ++ end ++} ++ + create_makefile("bdb") + begin + make = open("Makefile", "a") |