summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-02-20 11:05:31 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-02-20 11:05:31 +0000
commitfaf4c9db80b12e590c38863604889032ea097711 (patch)
tree2883e46a2406977280eca343ecb96e3636bba632
parentf8015c23c48bb65cf057480e6436aa0c9cad1f4f (diff)
* ext/dbm/extconf.rb: weaken header/library consistency check if db is
"ndbm". It seems several (possibly historical) distributions provide libndbm. However the content of libndbm vary: Berkeley DB, GDBM or even 4.3BSD NDBM. (Mandriva, Tru64 UNIX, OpenSuSE, SCO OpenServer, ...) "ndbm" is not searched automatically now (dblib doesn't contain it) but configure --with-dbm-type=ndbm choose libndbm and ndbm.h. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34703 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog10
-rw-r--r--ext/dbm/extconf.rb2
2 files changed, 11 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 0d15c93d67..62d3c83873 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+Mon Feb 20 19:57:26 2012 Tanaka Akira <akr@fsij.org>
+
+ * ext/dbm/extconf.rb: weaken header/library consistency check if db is
+ "ndbm". It seems several (possibly historical) distributions
+ provide libndbm. However the content of libndbm vary: Berkeley DB,
+ GDBM or even 4.3BSD NDBM. (Mandriva, Tru64 UNIX, OpenSuSE,
+ SCO OpenServer, ...)
+ "ndbm" is not searched automatically now (dblib doesn't contain it)
+ but configure --with-dbm-type=ndbm choose libndbm and ndbm.h.
+
Mon Feb 20 19:15:57 2012 Tanaka Akira <akr@fsij.org>
* ext/dbm/extconf.rb: refine variable names.
diff --git a/ext/dbm/extconf.rb b/ext/dbm/extconf.rb
index f6263f8f15..ea6a4a9118 100644
--- a/ext/dbm/extconf.rb
+++ b/ext/dbm/extconf.rb
@@ -182,7 +182,7 @@ def headers.db_check2(db, hdr)
# ndbm compatibility layer of gdbm.
# So, try to check header/library mismatch.
#
- if hdr == 'ndbm.h' && db != 'libc'
+ if hdr == 'ndbm.h' && db != 'libc' && db != 'ndbm'
if /\Adb\d?\z/ !~ db && have_db_header
return false
end