English 中文(简体)
从安装的碎块中再包装一粒
原标题:repackage an rpm from an installed rpm
  • 时间:2012-01-13 12:44:55
  •  标签:
  • linux
  • rpm

在轴心上,如果是这样的话,我们就可以重新包装安装的碎块。 我记得,装设的双筒可以产生碎块。

  rpm -??? > my.rpm

以后,即,新车的平板应当使用不同的机器。

最佳回答

这样做是可能的,但与<代码>rpm的指挥无关。 我写了这样做的手稿;它根据<代码>rpm - q的产出编造了一个光谱文档,并且是一份仅复制系统所安装的文档的“造纸”。

https://github.com/cormander/rogue-beret-tools/blob/master/scripts/rpm-re Pack”rel=“nofollow”

举例来说,重新包装<代码>x rpm:

证明:

$ rpm -ql mailx
/bin/mail
/etc/mail.rc
/usr/bin/Mail
/usr/lib/mail.help
/usr/lib/mail.tildehelp
/usr/share/man/man1/Mail.1.gz
/usr/share/man/man1/mail.1.gz

重新包装:

$ ./rpm-repack -p mailx
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.9773
+ umask 022
+ cd /usr/src/redhat/BUILD
+ /usr/lib/rpm/brp-compress
+ /usr/lib/rpm/brp-strip
+ /usr/lib/rpm/brp-strip-static-archive
+ /usr/lib/rpm/brp-strip-comment-note
Processing files: mailx-8.1.1-44.2.2
Provides: mailx
Requires(rpmlib): rpmlib(CompressedFileNames) <= 3.0.4-1 rpmlib(PayloadFilesHavePrefix) <= 4.0-1
Requires: libc.so.6 libc.so.6(GLIBC_2.0) libc.so.6(GLIBC_2.1) libc.so.6(GLIBC_2.3) libc.so.6(GLIBC_2.3.4) libc.so.6(GLIBC_2.4) rtld(GNU_HASH)
Checking for unpackaged file(s): /usr/lib/rpm/check-files /tmp/tlkN4yrYEi
Wrote: ~/rpmbuild/RPMS/i386/mailx-8.1.1-44.2.2.i386.rpm

证明新建成的一揽子计划:

$ rpm -qpl ~/rpmbuild/RPMS/i386/mailx-8.1.1-44.2.2.i386.rpm
/bin/mail
/etc/mail.rc
/usr/bin/Mail
/usr/lib/mail.help
/usr/lib/mail.tildehelp
/usr/share/man/man1/Mail.1.gz
/usr/share/man/man1/mail.1.gz

这部法典是所有的立法者,但运作正常。 它的确复制了许多胎面(从rpm-qi/code>和大部分文字)但用任何手段复制。 此外,它也可以复制全球公益物的签名,也不会像原始公债单一样有同样的制衡。

<>光> 这不是建造和分发输电包的“适当”方法,主要是为断肢和教育目的撰写的。

问题回答

There is also rpmrebuild http://rpmrebuild.sourceforge.net

Actually there is a simple but "tricky" way; it is just : rpm -e --repackage package-name It will output the RPM in /var/spool/repackage/.

例:

# rpm -e --repackage samba3x-client
# file /var/spool/repackage/samba3x-client-3.5.4-0.83.el5_7.2.i386.rpm
/var/spool/repackage/samba3x-client-3.5.4-0.83.el5_7.2.i386.rpm: RPM v3 bin i386 samba3x-client-3.5.4-0.83.el5_7

为什么欺骗? 因为实际上remove 你们知道,该方案事先包装。

I think that most rpm based distributions how have official package rpmrebuild (or in the almost official 3 rd party repos like epel, rpmfusion ... etc). I think nowadays this would be your best option for repackaging installed packages.





相关问题
Signed executables under Linux

For security reasons, it is desirable to check the integrity of code before execution, avoiding tampered software by an attacker. So, my question is How to sign executable code and run only trusted ...

encoding of file shell script

How can I check the file encoding in a shell script? I need to know if a file is encoded in utf-8 or iso-8859-1. Thanks

How to write a Remote DataModule to run on a linux server?

i would like to know if there are any solution to do this. Does anyone? The big picture: I want to access data over the web, using my delphi thin clients. But i´would like to keep my server/service ...

How can I use exit codes to run shell scripts sequentially?

Since cruise control is full of bugs that have wasted my entire week, I have decided the existing shell scripts I have are simpler and thus better. Here is what I have so far svn update /var/www/...

Good, free, easy-to-use C graphics libraries? [closed]

I was wondering if there were any good free graphics libraries for C that are easy to use? It s for plotting 2d and 3d graphs and then saving to a file. It s on a Linux system and there s no gnuplot ...