如何将deb转化为rpm包。
deb安装包是Debian系统和Ubuntu系统的安装包格式,而rpm则是使用在redhat和Centos上的安装方式。
下载合适的alien程序:http://ftp.de.debian.org/debian/pool/main/a/alien/
tar xf 解包,cd进入目录
出现如下安装包:
[root@7 alien]# ls Alien gendiff.txt alien.lsm GPL alien.lsm.in INSTALL alien.pl Makefile.PL alien.spec README alien.spec.in TODO debian
直接运行alien.pl,提示:
[root@7 alien]# ./alien.pl You must specify a file to convert. Usage: alien [options] file [...] file [...] Package file or files to convert. -d, --to-deb Generate a Debian deb package (default). Enables these options: --patch=<patch> Specify patch file to use instead of automatically looking for patch in /var/lib/alien. --nopatch Do not use patches. --anypatch Use even old version os patches. -s, --single Like --generate, but do not create .orig directory. --fixperms Munge/fix permissions and owners. --test Test generated packages with lintian. -r, --to-rpm Generate a Red Hat rpm package. --to-slp Generate a Stampede slp package. -l, --to-lsb Generate a LSB package. -t, --to-tgz Generate a Slackware tgz package. Enables these options: --description=<desc> Specify package description. --version=<version> Specify package version. -p, --to-pkg Generate a Solaris pkg package. -i, --install Install generated package. -g, --generate Generate build tree, but do not build package. -c, --scripts Include scripts in package. -v, --verbose Display each command alien runs. --veryverbose Be verbose, and also display output of run commands. -k, --keep-version Do not change version of generated package. --bump=number Increment package version by this number. -h, --help Display this help message. -V, --version Display alien's version number.
按照提示,运行以下命令可以执行deb转换rpm。
./alien.pl -r *.deb //在当前路径下生成一个rpm包。
发表评论