summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/dbm/dbm.c10
-rw-r--r--ext/tcltklib/extconf.rb2
-rw-r--r--ext/tk/lib/tkfont.rb15
3 files changed, 23 insertions, 4 deletions
diff --git a/ext/dbm/dbm.c b/ext/dbm/dbm.c
index 4d83cec1b1..1240f4b9ab 100644
--- a/ext/dbm/dbm.c
+++ b/ext/dbm/dbm.c
@@ -72,12 +72,16 @@ fdbm_s_open(argc, argv, klass)
Check_SafeStr(file);
dbm = 0;
- if (mode >= 0)
+ if (mode >= 0) {
dbm = dbm_open(RSTRING(file)->ptr, O_RDWR|O_CREAT, mode);
- if (!dbm)
+ }
+ if (!dbm) {
+ mode = 0666;
dbm = dbm_open(RSTRING(file)->ptr, O_RDWR, mode);
- if (!dbm)
+ }
+ if (!dbm) {
dbm = dbm_open(RSTRING(file)->ptr, O_RDONLY, mode);
+ }
if (!dbm) {
if (mode == -1) return Qnil;
diff --git a/ext/tcltklib/extconf.rb b/ext/tcltklib/extconf.rb
index e1086855ba..713cc811e5 100644
--- a/ext/tcltklib/extconf.rb
+++ b/ext/tcltklib/extconf.rb
@@ -21,6 +21,7 @@ def find_tcl(tcllib)
find_library(tcllib, func, *paths)
else
find_library("tcl", func, *paths) or
+ find_library("tcl8.2", func, *paths) or
find_library("tcl8.0", func, *paths) or
find_library("tcl7.6", func, *paths)
end
@@ -33,6 +34,7 @@ def find_tk(tklib)
find_library(tklib, func, *paths)
else
find_library("tk", func, *paths) or
+ find_library("tk8.2", func, *paths) or
find_library("tk8.0", func, *paths) or
find_library("tk4.2", func, *paths)
end
diff --git a/ext/tk/lib/tkfont.rb b/ext/tk/lib/tkfont.rb
index c680d166e7..2683260d69 100644
--- a/ext/tk/lib/tkfont.rb
+++ b/ext/tk/lib/tkfont.rb
@@ -667,7 +667,20 @@ class TkFont
alias measure_core measure_core_tk8x
alias metrics_core metrics_core_tk8x
- when /^8\.1/
+ when /^8\.[12]/
+ alias create_latinfont create_latinfont_tk8x
+ alias create_kanjifont create_kanjifont_tk81
+ alias create_compoundfont create_compoundfont_tk81
+ alias actual_core actual_core_tk8x
+ alias configure_core configure_core_tk8x
+ alias configinfo_core configinfo_core_tk8x
+ alias delete_core delete_core_tk8x
+ alias latin_replace_core latin_replace_core_tk8x
+ alias kanji_replace_core kanji_replace_core_tk81
+ alias measure_core measure_core_tk8x
+ alias metrics_core metrics_core_tk8x
+
+ when /^8\.*/
alias create_latinfont create_latinfont_tk8x
alias create_kanjifont create_kanjifont_tk81
alias create_compoundfont create_compoundfont_tk81