LoginSignup
3
2

More than 5 years have passed since last update.

`--with-ssl=openssl`を指定したneonを作る

Posted at

環境

  • CentOS 6.5
  • neon 0.29.3-3.el6_4
$ yum list neon
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: www.ftp.ne.jp
 * extras: www.ftp.ne.jp
 * updates: www.ftp.ne.jp
Installed Packages
neon.i686                             0.29.3-3.el6_4                             @base

手順

ソースrpmを取得する

rpmfindで探す(neonの場合)

yumdownloaderを使ってダウンロードしてもできるっぽい(参考)

# yum install yum-utils
# yumdownloader --source httpd

作業前の注意

システムを誤って壊さないように、rootではなく一般ユーザーで実行したほうがいいらしい。

ソースrpmを展開する

rpmコマンドを使う(参考)

$ rpm -ivh neon-0.29.3-3.el6_4.src.rpm

ファイルの展開先はrpmbuildコマンドで確認できる。

$ rpmbuild --showrc | grep topdir
-14: _builddir  %{_topdir}/BUILD
-14: _buildrootdir      %{_topdir}/BUILDROOT
-14: _rpmdir    %{_topdir}/RPMS
-14: _sourcedir %{_topdir}/SOURCES
-14: _specdir   %{_topdir}/SPECS
-14: _srcrpmdir %{_topdir}/SRPMS
-14: _topdir    %{getenv:HOME}/rpmbuild

rpm2cpioコマンドでもできる(参考)

$ rpm2cpio neon-0.29.3-3.el6_4.src.rpm | cpio -id

ただ、rpm2cpioだと展開後ファイルを、RPMお決まりのディレクトリに自分で配置しないといけないので、rpmコマンドでやるほうがよさげ。

SPECファイルを変更する

$ diff -c neon.spec neon.spec.new
*** neon.spec   2013-08-26 21:36:18.000000000 +0900
--- neon.spec.new       2014-06-14 12:55:42.396682235 +0900
***************
*** 46,52 ****
  %define cabundle %{_sysconfdir}/pki/tls/certs/ca-bundle.crt
  %configure --with-expat --enable-shared --disable-static \
          --enable-warnings --with-ca-bundle=%{cabundle} \
!         --with-ssl=gnutls --enable-threadsafe-ssl=posix \
          --with-libproxy
  make %{?_smp_mflags}

--- 46,52 ----
  %define cabundle %{_sysconfdir}/pki/tls/certs/ca-bundle.crt
  %configure --with-expat --enable-shared --disable-static \
          --enable-warnings --with-ca-bundle=%{cabundle} \
!         --with-ssl=openssl --enable-threadsafe-ssl=posix \
          --with-libproxy
  make %{?_smp_mflags}

再ビルドする

rpmbuildコマンドでビルドする。(参考)

$ rpmbuild -ba ~/rpmbuild/SPECS/neon.spec

いろいろ足りないって言われた場合は、yumで入れる。

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