質問編集履歴

3

考えられる原因をさらに考えてみました。

2020/12/15 07:57

投稿

qiyuren
qiyuren

スコア29

test CHANGED
File without changes
test CHANGED
@@ -74,313 +74,7 @@
74
74
 
75
75
  Provided configuration options:
76
76
 
77
- --with-opt-dir
78
-
79
- --without-opt-dir
80
-
81
- --with-opt-include
82
-
83
- --without-opt-include=${opt-dir}/include
84
-
85
- --with-opt-lib
86
-
87
- --without-opt-lib=${opt-dir}/lib
88
-
89
- --with-make-prog
90
-
91
- --without-make-prog
92
-
93
- --srcdir=.
94
-
95
- --curdir
77
+ ~~~略~~~
96
-
97
- --ruby=/Users/****/.rbenv/versions/2.6.5/bin/$(RUBY_BASE_NAME)
98
-
99
- --enable-shared
100
-
101
- --with-tk-old-extconf
102
-
103
- --without-tk-old-extconf
104
-
105
- --with-tk-old-extconf
106
-
107
- --without-tk-old-extconf
108
-
109
- --with-ActiveTcl
110
-
111
- --without-ActiveTcl
112
-
113
- --with-tk-shlib-search-path
114
-
115
- --without-tk-shlib-search-path
116
-
117
- --with-tcltkversion
118
-
119
- --without-tcltkversion
120
-
121
- --with-tcl-build-dir
122
-
123
- --without-tcl-build-dir
124
-
125
- --with-tk-build-dir
126
-
127
- --without-tk-build-dir
128
-
129
- --with-tcl-config
130
-
131
- --without-tcl-config
132
-
133
- --with-tk-config
134
-
135
- --without-tk-config
136
-
137
- --with-tclConfig-dir
138
-
139
- --without-tclConfig-dir
140
-
141
- --with-tkConfig-dir
142
-
143
- --without-tkConfig-dir
144
-
145
- --with-tclConfig-file
146
-
147
- --without-tclConfig-file
148
-
149
- --with-tkConfig-file
150
-
151
- --without-tkConfig-file
152
-
153
- --with-tcllib
154
-
155
- --without-tcllib
156
-
157
- --with-tklib
158
-
159
- --without-tklib
160
-
161
- --with-tcl-dir
162
-
163
- --without-tcl-dir
164
-
165
- --with-tk-dir
166
-
167
- --without-tk-dir
168
-
169
- --with-tcl-include
170
-
171
- --without-tcl-include
172
-
173
- --with-tk-include
174
-
175
- --without-tk-include
176
-
177
- --with-tcl-lib
178
-
179
- --without-tcl-lib
180
-
181
- --with-tk-lib
182
-
183
- --without-tk-lib
184
-
185
- --with-tcltk-framework
186
-
187
- --without-tcltk-framework
188
-
189
- --with-tcl-framework-dir
190
-
191
- --without-tcl-framework-dir
192
-
193
- --with-tk-framework-dir
194
-
195
- --without-tk-framework-dir
196
-
197
- --with-tcl-framework-header
198
-
199
- --without-tcl-framework-header
200
-
201
- --with-tk-framework-header
202
-
203
- --without-tk-framework-header
204
-
205
- --with-X11
206
-
207
- --without-X11
208
-
209
- --with-X11-dir
210
-
211
- --without-X11-dir
212
-
213
- --with-X11-include
214
-
215
- --without-X11-include
216
-
217
- --with-X11-lib
218
-
219
- --without-X11-lib
220
-
221
- --enable-tcltk-stubs
222
-
223
- --disable-tcltk-stubs
224
-
225
- --enable-tcl-h-ver-check
226
-
227
- --disable-tcl-h-ver-check
228
-
229
- --enable-tk-h-ver-check
230
-
231
- --disable-tk-h-ver-check
232
-
233
- --enable-mac-tcltk-framework
234
-
235
- --disable-mac-tcltk-framework
236
-
237
- --enable-tcltk-framework
238
-
239
- --disable-tcltk-framework
240
-
241
- --enable-pthread
242
-
243
- --disable-pthread
244
-
245
- --enable-tcl-thread
246
-
247
- --disable-tcl-thread
248
-
249
- --enable-space-on-tk-libpath
250
-
251
- --disable-space-on-tk-libpath
252
-
253
- --with-nsllib
254
-
255
- --without-nsllib
256
-
257
- --with-socketlib
258
-
259
- --without-socketlib
260
-
261
- --with-dllib
262
-
263
- --without-dllib
264
-
265
- --with-mlib
266
-
267
- --without-mlib
268
-
269
- --with-tcl-build-dir
270
-
271
- --without-tcl-build-dir
272
-
273
- --with-tk-build-dir
274
-
275
- --without-tk-build-dir
276
-
277
- --with-tcltkversion
278
-
279
- --without-tcltkversion
280
-
281
- --with-ActiveTcl
282
-
283
- --without-ActiveTcl
284
-
285
- --enable-space-on-tk-libpath
286
-
287
- --disable-space-on-tk-libpath
288
-
289
- --enable-tcltk-stubs
290
-
291
- --disable-tcltk-stubs
292
-
293
- --with-tcltk-stubs
294
-
295
- --without-tcltk-stubs
296
-
297
- --with-tcl-dir
298
-
299
- --without-tcl-dir
300
-
301
- --with-tcl-include
302
-
303
- --without-tcl-include=${tcl-dir}/include
304
-
305
- --with-tcl-lib
306
-
307
- --without-tcl-lib=${tcl-dir}/lib
308
-
309
- --with-tk-dir
310
-
311
- --without-tk-dir
312
-
313
- --with-tk-include
314
-
315
- --without-tk-include=${tk-dir}/include
316
-
317
- --with-tk-lib
318
-
319
- --without-tk-lib=${tk-dir}/lib
320
-
321
- --with-tclConfig-file
322
-
323
- --without-tclConfig-file
324
-
325
- --with-tkConfig-file
326
-
327
- --without-tkConfig-file
328
-
329
- --with-tclConfig-dir
330
-
331
- --without-tclConfig-dir
332
-
333
- --with-tkConfig-dir
334
-
335
- --without-tkConfig-dir
336
-
337
- --with-tcltk-framework
338
-
339
- --without-tcltk-framework
340
-
341
- --enable-tcltk-framework
342
-
343
- --disable-tcltk-framework
344
-
345
- --enable-tcltk-framework
346
-
347
- --disable-tcltk-framework
348
-
349
- --with-tk-shlib-search-path
350
-
351
- --without-tk-shlib-search-path
352
-
353
- --with-tklib
354
-
355
- --without-tklib
356
-
357
- --with-tcllib
358
-
359
- --without-tcllib
360
-
361
- --with-X11
362
-
363
- --without-X11
364
-
365
- --with-X11-dir
366
-
367
- --without-X11-dir
368
-
369
- --with-X11-include
370
-
371
- --without-X11-include=${X11-dir}/include
372
-
373
- --with-X11-lib
374
-
375
- --without-X11-lib=${X11-dir}/lib
376
-
377
- --with-X11-lib
378
-
379
- --without-X11-lib
380
-
381
- --with-X11lib
382
-
383
- --without-X11lib
384
78
 
385
79
 
386
80
 
@@ -418,6 +112,8 @@
418
112
 
419
113
  mdfindでtclConfig.sh, tkConfig.shを探しましたが存在しました。
420
114
 
115
+
116
+
421
117
  /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/tkConfig.sh
422
118
 
423
119
 
@@ -426,11 +122,31 @@
426
122
 
427
123
 
428
124
 
125
+ また、以下のURLを参考に、以下のように実行し、再度インストールしたら、エラーが変わりました。
126
+
127
+ tk/tclライブラリが見つからないようですが、適切なライブラリがどこにあるのか、わかりません。。
128
+
129
+
130
+
131
+ https://qiita.com/ftakao2007/items/230050be7351db49383d
132
+
133
+ https://github.com/ruby/tk/blob/master/README.tcltklib
134
+
429
- また、`Please check configure options. If your Tcl/Tk don't require X11, please try --without-X11.`とあったので、以下のように実行し、再度インストールしたら、エラーが変わりました。
135
+ http://www.mit.edu/afs.new/sipb/service/restore/ruby-lang/src/ruby-1.8.4/ext/tk/README.tcltklib
430
-
136
+
137
+
138
+
431
- ```
139
+ ```
432
-
140
+
433
- $ RUBY_CONFIGURE_OPTS="--without-X11" rbenv install 2.6.5
141
+ $ RUBY_CONFIGURE_OPTS="--with-tcltkversion=8.5 \
142
+
143
+ --with-tcl-lib=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tcl.framework/Versions/8.5 \
144
+
145
+ --with-tk-lib=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5 \
146
+
147
+ --enable-pthread --enable-shared" rbenv install 2.6.5
148
+
149
+
434
150
 
435
151
  $ gem install tk
436
152
 
@@ -444,7 +160,7 @@
444
160
 
445
161
  current directory: /Users/****/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/tk-0.3.0/ext/tk
446
162
 
447
- /Users/****/.rbenv/versions/2.6.5/bin/ruby -I /Users/****/.rbenv/versions/2.6.5/lib/ruby/2.6.0 -r ./siteconf20201215-34542-jc7u8a.rb extconf.rb
163
+ /Users/****/.rbenv/versions/2.6.5/bin/ruby -I /Users/****/.rbenv/versions/2.6.5/lib/ruby/2.6.0 -r ./siteconf20201215-15693-14ro7nf.rb extconf.rb
448
164
 
449
165
  Configure options for Ruby/Tk may be updated.
450
166
 
@@ -474,6 +190,8 @@
474
190
 
475
191
  checking for log() in -lm... yes
476
192
 
193
+ Specified Tcl/Tk version is ["8.5", "8.5"]
194
+
477
195
  Use ActiveTcl libraries (if available).
478
196
 
479
197
  Search tclConfig.sh and tkConfig.sh.
@@ -486,9 +204,17 @@
486
204
 
487
205
  Search tk.h
488
206
 
489
- checking for tk.h... no
207
+ checking for tk.h... yes
490
-
208
+
491
- Search Tcl library...Search Tk library.............*** extconf.rb failed ***
209
+ Search Tcl library.checking for Tcl_FindExecutable() in -ltclstub8.5... no
210
+
211
+ .checking for Tcl_FindExecutable() in -ltclstub8.5... no
212
+
213
+ .checking for Tcl_FindExecutable() in -ltclstub8.5... no
214
+
215
+ .checking for Tcl_FindExecutable() in -ltclstub8.5... no
216
+
217
+ *** extconf.rb failed ***
492
218
 
493
219
  Could not create Makefile due to some reason, probably lack of necessary
494
220
 
@@ -500,13 +226,11 @@
500
226
 
501
227
  Provided configuration options:
502
228
 
503
- 〜〜〜〜〜〜
229
+ ~~~略~~~
504
-
505
-
230
+
506
-
507
- 〜〜〜〜〜〜
231
+
508
-
232
+
509
- Warning:: cannot find Tk library. tcltklib will not be compiled (tcltklib is disabled on your Ruby. That is, Ruby/Tk will not work). Please check configure options.
233
+ Warning:: cannot find Tcl library. tcltklib will not be compiled (tcltklib is disabled on your Ruby. That is, Ruby/Tk will not work). Please check configure options.
510
234
 
511
235
 
512
236
 

2

configuretionを変更しました

2020/12/15 07:57

投稿

qiyuren
qiyuren

スコア29

test CHANGED
File without changes
test CHANGED
@@ -426,6 +426,120 @@
426
426
 
427
427
 
428
428
 
429
+ また、`Please check configure options. If your Tcl/Tk don't require X11, please try --without-X11.`とあったので、以下のように実行し、再度インストールしたら、エラーが変わりました。
430
+
431
+ ```
432
+
433
+ $ RUBY_CONFIGURE_OPTS="--without-X11" rbenv install 2.6.5
434
+
435
+ $ gem install tk
436
+
437
+ Building native extensions. This could take a while...
438
+
439
+ ERROR: Error installing tk:
440
+
441
+ ERROR: Failed to build gem native extension.
442
+
443
+
444
+
445
+ current directory: /Users/****/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/tk-0.3.0/ext/tk
446
+
447
+ /Users/****/.rbenv/versions/2.6.5/bin/ruby -I /Users/****/.rbenv/versions/2.6.5/lib/ruby/2.6.0 -r ./siteconf20201215-34542-jc7u8a.rb extconf.rb
448
+
449
+ Configure options for Ruby/Tk may be updated.
450
+
451
+ So, delete files which depend on old configs.
452
+
453
+ check functions.checking for ruby_native_thread_p() in ruby.h... yes
454
+
455
+ checking for rb_errinfo() in ruby.h... yes
456
+
457
+ checking for rb_hash_lookup() in ruby.h... yes
458
+
459
+ checking for rb_proc_new() in ruby.h... yes
460
+
461
+ checking for rb_sourcefile() in ruby.h... yes
462
+
463
+ checking for rb_thread_alive_p() in ruby.h... no
464
+
465
+ checking for rb_thread_check_trap_pending() in ruby.h... yes
466
+
467
+ checking for ruby_enc_find_basename() in ruby.h... yes
468
+
469
+ check libraries.checking for t_open() in -lnsl... no
470
+
471
+ checking for socket() in -lsocket... no
472
+
473
+ checking for dlopen() in -ldl... yes
474
+
475
+ checking for log() in -lm... yes
476
+
477
+ Use ActiveTcl libraries (if available).
478
+
479
+ Search tclConfig.sh and tkConfig.sh.
480
+
481
+ Fail to find [tclConfig.sh, tkConfig.sh]
482
+
483
+ Search tcl.h
484
+
485
+ checking for tcl.h... yes
486
+
487
+ Search tk.h
488
+
489
+ checking for tk.h... no
490
+
491
+ Search Tcl library...Search Tk library.............*** extconf.rb failed ***
492
+
493
+ Could not create Makefile due to some reason, probably lack of necessary
494
+
495
+ libraries and/or headers. Check the mkmf.log file for more details. You may
496
+
497
+ need configuration options.
498
+
499
+
500
+
501
+ Provided configuration options:
502
+
503
+ 〜〜〜〜〜〜
504
+
505
+
506
+
507
+ 〜〜〜〜〜〜
508
+
509
+ Warning:: cannot find Tk library. tcltklib will not be compiled (tcltklib is disabled on your Ruby. That is, Ruby/Tk will not work). Please check configure options.
510
+
511
+
512
+
513
+ Can't find proper Tcl/Tk libraries. So, can't make tcltklib.so which is required by Ruby/Tk.
514
+
515
+ If you have Tcl/Tk libraries on your environment, you may be able to use them with configure options (see ext/tk/README.tcltklib).
516
+
517
+ At present, Tcl/Tk8.6 is not supported. Although you can try to use Tcl/Tk8.6 with configure options, it will not work correctly. I recommend you to use Tcl/Tk8.5 or 8.4.
518
+
519
+
520
+
521
+ To see why this extension failed to compile, please check the mkmf.log which can be found here:
522
+
523
+
524
+
525
+ /Users/****/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/extensions/x86_64-darwin-19/2.6.0/tk-0.3.0/mkmf.log
526
+
527
+
528
+
529
+ extconf failed, exit code 1
530
+
531
+
532
+
533
+ Gem files will remain installed in /Users/****/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/tk-0.3.0 for inspection.
534
+
535
+ Results logged to /Users/****/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/extensions/x86_64-darwin-19/2.6.0/tk-0.3.0/gem_make.out
536
+
537
+
538
+
539
+ ```
540
+
541
+
542
+
429
543
  ### 補足情報(FW/ツールのバージョンなど)
430
544
 
431
545
  Ruby 2.6.5

1

tclConfig.sh, tkConfig.shを探しましたが存在しました。

2020/12/15 05:41

投稿

qiyuren
qiyuren

スコア29

test CHANGED
File without changes
test CHANGED
@@ -416,7 +416,13 @@
416
416
 
417
417
 
418
418
 
419
- mdfindでtclConfig.sh, tkConfig.shを探しましたが、見つからなかったので、そもそも存在しないのでないかと思って
419
+ mdfindでtclConfig.sh, tkConfig.shを探しましたが存在しました
420
+
421
+ /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tk.framework/Versions/8.5/tkConfig.sh
422
+
423
+
424
+
425
+ /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Tcl.framework/Versions/8.5/tclConfig.sh
420
426
 
421
427
 
422
428