编译Python2.6为RPM

从python.org下载的源代码包,编译成为RPM包时出现错误。通过修正spec文件获得了CentOS5下面的rpm包。下面是不同点:

$ diff Python-2.6.4/Misc/RPM/python-2.6.spec ~/rpmbuild/SPECS/python-2.6.spec
38c38
< %define libver 2.6
---
> %define libvers 2.6
57c57
< Copyright: Modified CNRI Open Source License
---
> License: Modified CNRI Open Source License
258,259c258,260
<          mv -f python python"%{binsuffix}" )
<    ( cd $RPM_BUILD_ROOT%{__prefix}/man/man1; mv python.1 python%{binsuffix}.1 )
---
>          mv -f python python"%{binsuffix}";
>          mv -f python-config python%{binsuffix}-config )
>    ( cd $RPM_BUILD_ROOT%{__prefix}/share/man/man1; mv python.1 python%{binsuffix}.1 )
344c345
< %{__prefix}/man/man1/python%{binsuffix}.1*
---
> %{__prefix}/share/man/man1/python%{binsuffix}.1*
351d351
< %{__prefix}/%{libdirname}/python%{libvers}/profile.doc
360c360
< %{__prefix}/%{libdirname}/python%{libvers}/email/mime
---
> #%{__prefix}/%{libdirname}/python%{libvers}/email/mime
366a367,372
> %{__prefix}/%{libdirname}/python%{libvers}/ctypes
> %{__prefix}/%{libdirname}/python%{libvers}/json
> %{__prefix}/%{libdirname}/python%{libvers}/lib2to3
> %{__prefix}/%{libdirname}/python%{libvers}/multiprocessing
> %{__prefix}/%{libdirname}/python%{libvers}/wsgiref
>
369a376
> %{__prefix}/bin/python%{binsuffix}-config
 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值