作者Yoxem (Yoxem)
看板LinuxDev
标题[问题] 打包 Python 3 版 SIP 的 .deb 出现错误
时间Sat Aug 27 12:58:10 2011
在下负责某个软体的 .deb 打包。因为该软体使用PyQt4 for Python3 作,而 PyQt4
以及 SIP 的 Python3 版并没有 ubuntu 的 deb 正式档。因此我想私自打包这两个
软体(或函式库)的 Python 3 版。
SIP 4.12.4 的下载点如下:
http://www.riverbankcomputing.co.uk/static/Downloads/sip4/sip-4.12.4.tar.gz
一般而言:编译 SIP 4.12.4 for Python3 的方式如下:
$ tar xvf sip-4.12.4.tar.gz
$ cd sip
$ python3 configure.py #不含参数
$ make;make install
我打包 deb 包的流程如下($ 号表示命令列):
$ tar xvf sip-4.12.4.tar.gz
$ python3 -B ./configure.py #不产生 .pyc
$ dh_make -f ../sip-4.12.4.tar.gz
Type of package: single binary, indep binary, multiple binary, library,
kernel module, kernel patch or cdbs?
[s/i/m/l/k/n/b] s
Maintainer name :
...(以下略)...
Hit <enter> to confirm:
Done. Please edit the files in the debian/ subdirectory now. You should also
check that the sip Makefiles install into $DESTDIR and not in / .
$ cd debian
debian 中的的档案,我只改 changelog, control, copyright, docs
详参附件:
http://www.badongo.com/file/25704172
(後续出现 error 後,对 debian 目录的副本)
最後的工作:
$ rm -rf README.Debian README.source
$ cd ..
$ dpkg-buildpackage -rfakeroot
最後出现了:
dpkg-buildpackage: error: fakeroot debian/rules binary gave error exit status
2
的错误,详细讯息请参:
http://paste.plurk.com/show/631607/
根据讯息中「 dpkg-gencontrol -ldebian/changelog
-Tdebian/python3-sip.substvars -Pdebian/python3-sip 」这行,我参看了
debian/python3-sip.substvars 这档案,如下:
shlibs:Depends=libc6 (>= 2.4), libgcc1 (>= 1:4.1.1), libstdc++6 (>= 4.1.1)
misc:Depends=
敝人用直接编译方式可以安装成功,只是
「$ python3 -B ./configure.py 」这行改为
$ python3 -B ./configure.py --destdir /usr/local/stow/sip
不晓得发生什麽问题或设定档出现什麽错误?
开发环境附注:
Mint Linux 10 (GNOME, 64-bit)
debhelper 8.0.0ubuntu1
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 119.15.250.155
※ 编辑: Yoxem 来自: 119.15.250.155 (08/27 12:58)