1、首次安装deb (dkpg -i)
调用顺序:
preinst -> postinst
各调用程序$1对应参数:
preinst: install
postinst: configure
2、卸载 (dpkg -r)
调用顺序:
prerm -> postrm
各调用程序$1对应参数:
prerm : remove
postrm : remove
3、卸载 (dpkg -P) 调用顺序:prerm -> postrm -> postrm
各调用程序$1对应参数:
prerm : remove
postrm : remove
postrm : purge
4、升级 (dpkg -i 同一个软件包)
调用顺序:
prerm -> preinst -> postrm -> postinst
各调用程序$1对应参数:
prerm : update newversion (e.g.: ****** prerm upgrade 2.7.1-22 )
preinst: upgrade oldversion newversion (e.g.: ****** preinst upgrade 2.7.1-21 2.7.1-22)
postrm: upgrade newversion (e.g.: ****** postrm upgrade 2.7.1-22)
postinst: configure oldversion (e.g.: ****** postinst configure 2.7.1-21)
标签:包中,upgrade,调用,postrm,preinst,prerm,postinst From: https://www.cnblogs.com/amoy9812/p/17469309.html