Debian / Ubuntu / LinuxMint /Deepin … dpkg忽略相依性強制移除

用dpkg –remove (-r) 移除套件的時候如果會造成相依性問題預設就不會做處理

看了一下dpkg --help, 應該是可以透過–force來幫忙(!?)

又看了一下dpkg --force-help…有這些說明

dpkg forcing options - control behaviour when problems found:
warn but continue: --force-,,...
stop with error: --refuse-,,... | --no-force-,...
Forcing things:
[!] all Set all force options
[*] downgrade Replace a package with a lower version
configure-any Configure any package which may help this one
hold Process incidental packages even when on hold
not-root Try to (de)install things even when not root
bad-path PATH is missing important programs, problems likely
bad-verify Install a package even if it fails authenticity check
bad-version Process even packages with wrong versions
overwrite Overwrite a file from one package with another
overwrite-diverted Overwrite a diverted file with an undiverted version
[!] overwrite-dir Overwrite one package's directory with another's file
[!] unsafe-io Do not perform safe I/O operations when unpacking
[!] confnew Always use the new config files, don't prompt
[!] confold Always use the old config files, don't prompt
[!] confdef Use the default option for new config files if one
is available, don't prompt. If no default can be found,
you will be prompted unless one of the confold or
confnew options is also given
[!] confmiss Always install missing config files
[!] confask Offer to replace config files with no new versions
[!] architecture Process even packages with wrong or no architecture
[!] breaks Install even if it would break another package
[!] conflicts Allow installation of conflicting packages
[!] depends Turn all dependency problems into warnings
[!] depends-version Turn dependency version problems into warnings
[!] remove-reinstreq Remove packages which require installation
[!] remove-essential Remove an essential package

WARNING - use of options marked [!] can seriously damage your installation.
Forcing options marked [*] are enabled by default.

原先加上--force-breaks無效, 加了--force-depens就對了!

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。