在带有Homebrew的OS X上安装DBD :: Sybase无法找到freetds库 [英] Installing DBD::Sybase on OS X with Homebrew fails to find freetds libraries

查看:121
本文介绍了在带有Homebrew的OS X上安装DBD :: Sybase无法找到freetds库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在安装DBD :: Sybase

I am installing DBD::Sybase

设置后,我收到以下错误

I receive following error, after setting

export SYBASE=/usr/local/Cellar/freetds/0.95.80

并下载freetds:

and download freetds:

brew install freetds

错误:

Configuring DBD-Sybase-1.15 ... Can't find any Sybase libraries in /usr/local/Cellar/freetds/0.95.80/lib or /usr/local/Cellar/freetds/0.95.80/lib64 at Makefile.PL line 155, <IN> line 44

我认为我需要直接编辑Makefile.我需要编辑makefile吗?而且我还能使用CPANM吗? CPANM在Brew(地窖)下.

I believe I need to edit the makefile directly. Do I need to edit makefile? And could I use CPANM still. CPANM is under Brew (cellar).

/usr/local/Cellar/freetds/0.95.80/lib
├── libct.4.dylib
├── libct.a
├── libct.dylib -> libct.4.dylib
├── libsybdb.5.dylib
├── libsybdb.a
└── libsybdb.dylib -> libsybdb.5.dylib


 /usr/local/Cellar/freetds/0.95.80/
AUTHORS              ChangeLog            NEWS                 TODO                 etc                  lib
COPYING              INSTALL_RECEIPT.json README               bin                  include              share

推荐答案

There is a reported bug in DBD::Sybase on OS X which is causing your problem.

配置的一部分认为您在Windows上. Perl将OS X报告为darwin,而DBD :: Sybase正在像MSWin32cygwin中那样检查/win/.结果,它寻找一个dll目录,但错误地报告它寻找的是liblib64.

One part of the configuration thinks you're on Windows. Perl reports OS X as darwin and DBD::Sybase is checking for /win/ as in MSWin32 or maybe cygwin. As a result it looks for a dll directory, but falsely reports it's looking for lib and lib64.

快速解决方案是使用cpanm --prompt DBD::Sybase.如果失败,cpanm会问该怎么办.

The quick fix is to use cpanm --prompt DBD::Sybase. When it fails, cpanm will ask what to do.

Configuring DBD-Sybase failed.
You can s)kip, r)etry, e)xamine build log, or l)ook ? [s]

将其告知l)ook.这会将您转储到带有DBD :: Sybase解压缩源的shell中.使用编辑器删除Makefile.PL中的第143-145行.

Tell it to l)ook. This will dump you into a shell with the unpacked source for DBD::Sybase. Use an editor to delete lines 143-145 in the Makefile.PL.

if ($^O =~ /win/i) {
  @libdir = ( 'dll' );
}

然后exit外壳. cpanm会问您要再做什么,并将其告知r)etry.它应该使用您编辑过的Makefile.PL.

Then exit the shell. cpanm will ask you what to do again, tell it to r)etry. It should use your edited Makefile.PL.

这篇关于在带有Homebrew的OS X上安装DBD :: Sybase无法找到freetds库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆