LoginSignup
29
24

More than 3 years have passed since last update.

How to install curl 7.37.0 with CentOS 6.5

Last updated at Posted at 2014-07-09

curl のバージョンを上げたのでメモ。

仮想 PC 上でやってるので、Guest Additions をインストールした段階で gcc とかはインストールされるんで、そういう前提で書いてます。
そうでないヒトはとりあえず yum groupinstall "Development Tools" をすればオッケーだと思います。
c.f. CentOSのDevelopment Tools - Qiita

openssl のライブラリが要ります

$ sudo yum install openssl-devel

ソースのダウンロード

http://curl.haxx.se/latest.cgi?curl=tar.bz2 から適当なミラーを選んでダウンロードします。

$ wget http://curl.haxx.se/download/curl-7.37.0.tar.bz2

configure

$ tar xf curl-7.37.0.tar.bz2
$ cd curl-7.37.0
$ ./configure --enable-libcurl-option

--enable-libcurl-option を付けることによって、libcurl もコンパイルしてくれるみたいです。

以下 configure の出力です。
ssl がサポートされていることが分かります。
ssh とか、サポートされてない機能も沢山あるけど、僕は今のところ要らないので…。

  curl version:     7.37.0
  Host setup:       x86_64-unknown-linux-gnu
  Install prefix:   /usr/local
  Compiler:         gcc
  SSL support:      enabled (OpenSSL)
  SSH support:      no      (--with-libssh2)
  zlib support:     enabled
  GSS-API support:  no      (--with-gssapi)
  SPNEGO support:   no      (--with-spnego)
  TLS-SRP support:  no      (--enable-tls-srp)
  resolver:         default (--enable-ares / --enable-threaded-resolver)
  ipv6 support:     enabled
  IDN support:      no      (--with-{libidn,winidn})
  Build libcurl:    Shared=yes, Static=yes
  Built-in manual:  enabled
  --libcurl option: enabled (--disable-libcurl-option)
  Verbose errors:   enabled (--disable-verbose)
  SSPI support:     no      (--enable-sspi)
  ca cert bundle:   /etc/pki/tls/certs/ca-bundle.crt
  ca cert path:     no
  LDAP support:     no      (--enable-ldap / --with-ldap-lib / --with-lber-lib)
  LDAPS support:    no      (--enable-ldaps)
  RTSP support:     enabled
  RTMP support:     no      (--with-librtmp)
  metalink support: no      (--with-libmetalink)
  HTTP2 support:    disabled (--with-nghttp2)
  Protocols:        DICT FILE FTP FTPS GOPHER HTTP HTTPS IMAP IMAPS POP3 POP3S RTSP SMTP SMTPS TELNET TFTP

コンパイルとインストール

$ make
$ sudo make install

バージョンチェック

$ curl --version
curl 7.37.0 (x86_64-unknown-linux-gnu) libcurl/7.37.0 OpenSSL/1.0.1e zlib/1.2.3
Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp smtp smtps telnet tftp
Features: IPv6 Largefile NTLM NTLM_WB SSL libz
29
24
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
29
24