【问题标题】:Unable to install tiny_tds on Mac OS X Yosemite v10.10.2无法在 Mac OS X Yosemite v10.10.2 上安装 tiny_tds
【发布时间】:2015-12-06 17:56:33
【问题描述】:

我在 MAC OS X yosemite 上使用 RubyMine IDE。在尝试安装 tiny_tds 时出现以下错误

sudo gem install tiny_tds -v '0.6.2'

构建原生扩展。这可能需要一段时间...

错误:安装 tiny_tds 时出错:

错误:构建 gem 原生扩展失败。

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb

正在检查 iconv.h 中的 iconv_open()...否

在 -liconv 中检查 iconv_open()...是的

正在检查 sybfront.h...是的

正在检查 sybdb.h...是的

在 -lsybdb 中检查 tdsdbopen()...否

freetds 丢失。

* extconf.rb 失败 * 由于某种原因无法创建 Makefile,可能缺乏必要 库和/或标题。检查 mkmf.log 文件以获取更多详细信息。你可以 需要配置选项。

提供的配置选项:

--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

--没有制作程序

--srcdir=.

--curdir

--ruby=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby

--启用查找

--禁用查找

--with-iconv-dir

--without-iconv-dir

--with-iconv-include

--without-iconv-include=${iconv-dir}/include

--with-iconv-lib

--without-iconv-lib=${iconv-dir}/

--with-freetds-dir

--without-freetds-dir

--with-freetds-include

--without-freetds-include=${freetds-dir}/include

--with-freetds-lib

--without-freetds-lib=${freetds-dir}/

--with-iconvlib

--without-iconvlib

--with-sybdblib

--没有 sybdblib

Gem 文件将继续安装在 /Library/Ruby/Gems/2.0.0/gems/tiny_tds-0.6.2 中以供检查。 结果记录到 /Library/Ruby/Gems/2.0.0/gems/tiny_tds-0.6.2/ext/tiny_tds/gem_make.out

我已经安装了freetds

brew install freetds

当我做 brew list 时我可以看到它

但是当我再次执行 sudo gem install tiny_tds 时,由于 freetds 丢失,它给了我错误。

请帮忙。

谢谢

【问题讨论】:

    标签: macos operating-system tiny-tds


    【解决方案1】:

    gem install tiny_tds 没有用吗?

    仅供参考 - 使用 sudogem install 并不是最佳做法。

    【讨论】:

      【解决方案2】:

      正如我在Homebrew / TinyTDS / FreeTDS bundle error 上发布的那样,除了brew install freetds,您可能还需要告诉gem 在哪里可以找到freetds。

      如果您使用的是 bundler,您可以通过配置 bundler 来做到这一点。

      例如(取决于 homebrew 安装 freetds 的确切位置):

      bundle config set --global build.tiny_tds --with-freetds-dir=/opt/homebrew/Cellar/freetds/1.3.3
      

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2015-12-23
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 2014-07-24
        相关资源
        最近更新 更多