1
我想用紅寶石腳本連接到Teradata,爲此我需要teradata-cli紅寶石寶石。但創業板是沒有得到安裝和下面的錯誤是越來越拋出:Teradata-cli紅寶石寶石沒有安裝在Windows上
創業板安裝的Teradata-CLI
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing teradata-cli:
ERROR: Failed to build gem native extension.
C:/Vendor/ruby-2.0.0-p451/bin/ruby.exe extconf.rb
checking for ruby.h... yes
checking for main() in -lwincli32... no
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details.
You may need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=C:/Vendor/ruby-2.0.0-p451/bin/ruby
--with-cli-dir
--without-cli-dir
--with-cli-include
--without-cli-include=${cli-dir}/include
--with-cli-lib
--without-cli-lib=${cli-dir}/
--with-wincli32lib
--without-wincli32lib
extconf failed, exit code 1
Gem files will remain installed in C:/Vendor/ruby-2.0.0-p451/lib/ruby/gems/2.0.0/gems/teradata-cli-0.0.12 for inspection.
Results logged to C:/Vendor/ruby-2.0.0-p451/lib/ruby/gems/2.0.0/extensions/x86-mingw32/2.0.0/teradata-cli-0.0.12/gem_make.out
要解決上述問題,我在我的機器上安裝cliv2並再次嘗試安裝寶石如下:
寶石安裝的Teradata-CLI - 「--with-CLI-LIB = 「C:\ Teradata_cliv2_x64 \ Teradata的\客戶\ 14.00 \ CLIv2 \ lib中」 --with-CLI-包括=「C:\ Teradata_cliv2_x64 \ Teradata的\客戶端\ 14.0 0 \ CLIv2 \ inc「'
其中lib和include是安裝Cliv2客戶端的目錄。
現在上面顯示的沒有引發錯誤,而是顯示以下錯誤:
C:/Vendor/ruby-2.0.0-p451/bin/ruby.exe extconf.rb --with-cli-lib="C:\Teradata_cliv2_x64\Teradata\Client\14.00\CLIv2\lib" --with-cli-in
de="C:\Teradata_cliv2_x64\Teradata\Client\14.00\CLIv2\inc"
checking for ruby.h... yes
checking for main() in -lwincli32... yes
creating Makefile
make "DESTDIR=" clean
make "DESTDIR="
generating cli-i386-mingw32.def
compiling cli.c
cli.c: In function 'status_name':
cli.c:269:17: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:270:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:271:19: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:272:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:273:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:274:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:275:24: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:276:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:277:23: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:278:24: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:279:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:280:26: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:281:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:282:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:283:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:284:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:285:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:286:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:287:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c: In function 'flavor_name':
cli.c:308:18: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:309:25: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:310:19: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:311:19: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:312:23: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:313:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:314:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:315:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:316:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:317:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:318:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:319:27: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:320:25: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:321:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:322:27: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:323:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:324:24: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:325:17: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:326:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:327:24: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:328:20: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:329:21: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:330:23: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:331:22: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:332:23: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:333:24: warning: return discards 'const' qualifier from pointer target type [enabled by default]
cli.c:334:19: warning: return discards 'const' qualifier from pointer target type [enabled by default]
In file included from cli.c:20:0:
cli.c: At top level:
C:\Teradata_cliv2_x64\Teradata\Client\14.00\CLIv2\inc/dbcarea.h:270:13: warning: 'D8XIIIRX' defined but not used [-Wunused-variable]
linking shared-object teradata-cli/cli.so
cli.o: In function `logoff':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:172: undefined reference to `[email protected]'
cli.o: In function `cli_cleanup':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:194: undefined reference to `[email protected]'
cli.o: In function `cli_initialize':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:100: undefined reference to `[email protected]'
cli.o: In function `dispatch':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:258: undefined reference to `[email protected]'
cli.o: In function `logoff':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:172: undefined reference to `[email protected]'
cli.o: In function `dispatch':
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:258: undefined reference to `[email protected]'
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:258: undefined reference to `[email protected]'
C:\Vendor\ruby-2.0.0-p451\lib\ruby\gems\2.0.0\gems\teradata-cli-0.0.12\ext\teradata-cli\cli/cli.c:258: undefined reference to `[email protected]'
collect2.exe: error: ld returned 1 exit status
make: *** [cli.so] Error 1
make failed, exit code 2
Gem files will remain installed in C:/Vendor/ruby-2.0.0-p451/lib/ruby/gems/2.0.0/gems/teradata-cli-0.0.12 for inspection.
Results logged to C:/Vendor/ruby-2.0.0-p451/lib/ruby/gems/2.0.0/extensions/x86-mingw32/2.0.0/teradata-cli-0.0.12/gem_make.out
請指導這個問題如何解決。使用以下命令
您的機器上是否安裝了Ruby開發套件? –
是的,我有.... –