summaryrefslogtreecommitdiff
path: root/ext/dbm/dbm.c
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-02-18 03:51:52 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2012-02-18 03:51:52 +0000
commite7a1d4a309152582215fe23799491e31d802d90d (patch)
tree5188e53e998cadf63da04338ee0d80886fa82ade /ext/dbm/dbm.c
parent622769060445a2c37c3fbc09cfc6ccbe9cda7f10 (diff)
* ext/dbm/dbm.c (DBM::VERSION): define it by detecting _GDBM_H_ or
_DBM_IOERR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34672 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dbm/dbm.c')
-rw-r--r--ext/dbm/dbm.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/dbm/dbm.c b/ext/dbm/dbm.c
index cadc46446c..98de538dd0 100644
--- a/ext/dbm/dbm.c
+++ b/ext/dbm/dbm.c
@@ -1096,6 +1096,10 @@ Init_dbm(void)
rb_define_const(rb_cDBM, "VERSION", rb_sprintf("QDBM %s", dpversion));
#elif defined(_DB_H_)
rb_define_const(rb_cDBM, "VERSION", rb_str_new2("Berkeley DB (unknown)"));
+#elif defined(_GDBM_H_)
+ rb_define_const(rb_cDBM, "VERSION", rb_str_new2("GDBM (unknown)"));
+#elif defined(_DBM_IOERR)
+ rb_define_const(rb_cDBM, "VERSION", rb_str_new2("NDBM (4.3BSD)"));
#else
rb_define_const(rb_cDBM, "VERSION", rb_str_new2("unknown"));
#endif