Linux CentOS 下连接 SQLserver ------ freetds安装

什么是FreeTDS


简单的说FreeTDS是一个程序库,可以实现在Linux系统下访问微软的SQL数据库! FreeTDS 是一个开源(如果你喜欢可以称为自由)的程序库,是TDS(表列数据流 )协议的再次实现。它可以被用在Sybase的db-lib或者ct-lib库。它也包含一个ODBC的库。允许许多开源的应用软件比如Perl和PHP(或者你自己的c或C++程序)去连接到Sybase或 Microsoft SQL服务器。FreeTDS 以源码的形式被发布,几乎可以在任何操作系统上编译。意味着Unix和类Unix系统(包括著名的分支如Interix和QNX),还有Win32,VMS,和OSX。

FreeTDS的安装


Building FreeTDS from git

从git安装freetds


  1. 构建需要以下包

    automake (GNU Automake, generates Makefile.in from Makefile.am)
    autoconf (GNU Autoconf, generates configure from configure.ac)
    libtool (GNU Libtool, library creation support scripts)
    make (GNU or BSD Make.)
    gcc (GNU Compiler Collection, for C code compilation)
    perl (Perl, used to generate some files)

    yum install -y automake autoconf  libtool make gcc perl git
    

    通过以下命令查看高于以下版本

     (autoconf --version; automake --version; libtool --version) |grep GNU
    
    autoconf (GNU Autoconf) 2.60
    automake (GNU automake) 1.9.6
    ltmain.sh (GNU libtool) 1.5.18 (1.1220.2.245 2005/05/16 08:55:27)
    

2)下载freetds包

 git clone https://github.com/FreeTDS/freetds.git
  1. execute autogen.sh to run automake, autoconf and configure,
	./autogen.sh

Any switches provided to autogen.sh will be passed to the configure script.

  1. compile the source using make,
	make
  1. switch to a user that can write to the target installation
    directory, usually root,
	su root
  1. install the package,
	make install

参考 https://github.com/FreeTDS/freetds/blob/master/INSTALL.GIT

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值