2009-10-04
CentOS 5.3 に checkinstall を入れるの巻き
linux, centos, workaround | |
git で最新版を取得してみる
http://asic-linux.com.mx/~izto/checkinstall/checkinstall.git/
を見て、仰せの通りに取得
$ git clone http://checkinstall.izto.org/checkinstall.git
コンパイル&インストール。が・・・
INSTALL を見て、これまた(ほぼ)仰せの通りに。
$ make $ sudo make install $ sudo /usr/local/sbin/checkinstall
checkinstall すると、以下を聞かれた。特に特別なことはしなかった。
使用するパッケージ方式を選んでください。 Slackwareなら[S], RPMなら[R], Debianなら[D]を入力
入力 ===> R
変更するものの番号を入力してください。Enterで続行します:
入力 ===> Return
**********************************************************************
Done. The new package has been saved to
/usr/src/redhat/RPMS/i386/checkinstall-20091004-1.i386.rpm
You can install it in your system anytime using:
rpm -i checkinstall-20091004-1.i386.rpm
**********************************************************************
と言われたので、正直に
skomatsu@brazill ~/checkinstall-current/checkinstall $ cd /usr/src/redhat/RPMS/i386/ skomatsu@brazill /usr/src/redhat/RPMS/i386 $ ls -la 合計 152 drwxr-xr-x 2 root root 4096 10月 4 19:59 . drwxr-xr-x 9 root root 4096 10月 4 19:52 .. -rw-r--r-- 1 root root 129911 10月 4 19:59 checkinstall-20091004-1.i386.rpm skomatsu@brazill /usr/src/redhat/RPMS/i386 $ sudo rpm -ivh checkinstall-20091004-1.i386.rpm 準備中... ########################################### [100%] 1:checkinstall ########################################### [100%] エラー: アーカイブの伸長に失敗: ファイル /selinux/context;4ac88039: cpio: open失敗 - 許可がありません
しょぼーん(´・ω・)
回避策
で、ぐーぐるさんにお伺いしたところ、以下のメーリングリストの投稿を発見。
http://checkinstall.izto.org/cklist/msg00776.html
On Mon, 29 Aug 2005, Paul Smith wrote:
On 8/29/05, honey@xxxxxxxxx <honey@xxxxxxxxx> wrote:
I am using checkinstall 1.6.0 on Fedora Core 4, which creates my rpms
without any problems. However, when I go to install the rpm, I get the
following message:
# rpm -i mypackage-1.6.1-1.i386.rpm
error: unpacking of archive failed on file /selinux/context;43132312:
cpio: open failed - Permission denied
#
Any advice?
--exclude=/selinux
What for, Honey, is the line above?
Use the following command line in FC4:
checkinstall --fstrans=no --exclude=/selinux
ので、--fstrans=noは付けずに以下を実行。
skomatsu@brazill ~/checkinstall-current/checkinstall $ sudo /usr/local/sbin/checkinstall --exclude=/selinux skomatsu@brazill ~/checkinstall-current/checkinstall $ cd /usr/src/redhat/RPMS/i386/ skomatsu@brazill /usr/src/redhat/RPMS/i386 $ sudo rpm -ivh checkinstall-20091004-1.i386.rpm Preparing... ########################################### [100%] 1:checkinstall ########################################### [100%]
出来た!
補足
なお、--fstrans=noを付けると、
Some of the files created by the installation are inside the home directory: /home You probably don't want them to be included in the package. Do you want me to list them? [n]:
と言われてしまった。
対象のファイル達は、
/home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-de.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-es.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-id.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-it.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-ja.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-no.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-pt_BR.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-ru.mo /home/skomatsu/checkinstall-current/checkinstall/locale/checkinstall-zh_CN.mo
だった。
単純に n と答えればよいのかなとも思ったけど、
なんか良くなさそうだったので、--fstrans=no は外した。
ちなみに、--fstrans自体は
--fstrans=<yes|no> Enable/disable the filesystem translation code
ということで、ファイルシステム(パス?)を変換する/しない、ということみたい。
- 56 http://d.hatena.ne.jp/shiumachi/20100303/1267567785
- 38 http://www.google.co.jp/url?sa=t&source=web&cd=1&ved=0CBkQFjAA&url=http://d.hatena.ne.jp/comutt/20091004/1254660202&rct=j&q=checkinstall fstrans&ei=zyKxTe_oKYymuAPkx_SNBw&usg=AFQjCNHBqFYgWaSIr25CGU04n3g8aZFEmg
- 37 http://www.google.co.jp/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cts=1331002724758&ved=0CCcQFjAA&url=http://d.hatena.ne.jp/comutt/20091004/1254660202&ei=YX1VT52DBOWViAL0xrXhBw&usg=AFQjCNHBqFYgWaSIr25CGU04n3g8aZFEmg&sig2=phLInWWpyKGizDtm1mG-vw
- 29 http://www.google.co.jp/search?q=checkinstall+fstrans&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:ja:official&hl=ja&client=firefox-a
- 28 http://www.google.co.jp/search?q=centos+checkinstall&ie=utf-8&oe=utf-8&aq=t&rls=com.ubuntu:en-US:official&client=firefox-a
- 20 http://www.google.co.jp/search?q=fstrans&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla:ja-JP-mac:official&hl=ja&client=firefox-a
- 20 http://www.google.co.jp/search?sourceid=chrome&ie=UTF-8&q=fstrans
- 20 http://www.google.co.jp/search?sourceid=navclient&hl=ja&ie=UTF-8&rlz=1T4ADBR_jaJP298JP299&q=エラー:+アーカイブの伸長に失敗:+ファイ%e
- 20 http://www.google.co.jp/url?sa=t&rct=j&q=checkinstall fstrans&source=web&cd=1&ved=0CB4QFjAA&url=http://d.hatena.ne.jp/comutt/20091004/1254660202&ei=5aSmTqm2KaiJmQWZ58y9Dw&usg=AFQjCNHBqFYgWaSIr25CGU04n3g8aZFEmg&sig2=-Is5tCnaOf9npvOZIcio1w
- 19 http://www.google.co.jp/url?sa=t&rct=j&q=エラー:+アーカイブの伸長に失敗:+ファイル+/selinux/context&source=web&cd=1&ved=0C

