Changes

Jump to: navigation, search

Package managers

535 bytes added, 15:25, 21 March 2011
Add the start of a column for pacman
! DEB<br/><small>Debian, Ubuntu</small>
! Ebuild<br/><small>Gentoo, Sabayon</small>
! Pacman<br/><small>Arch Linux</small>
|-
! colspan="4" align="center" | <big>'''Basic queries'''</big>
|| <code>dpkg -l</code>
|| <code>equery list</code>
|| <code>pacman -Qi</code>
|-
! List of installed packages matching ''substr''
|| <code>dpkg -l ''\*substr\*''</code>
|| <code>equery list ''substr''</code>
||
|-
! Basic information about an installed ''package''
|| <code>dpkg -p ''package''</code>
|| <code>eix ''package''</code>
|| <code>pacman -Qi ''package''</code>
|-
! List of files in a given ''package''
|| <code>dpkg -L ''package''</code>
|| <code>equery files ''package''</code>
|| <code>pacman -Ql ''package''</code>
|-
! colspan="4" align="center" | <big>'''Advanced queries'''</big>
|| <code>dpkg -S ''file''</code>
|| <code>equery belongs ''file''</code>
|| <code>pacman -Qo ''file''</code>
|-
! Check the hash (i.e. MD5 etc.) sums of an installed package
|| <code>debsums -ca ''package''</code>
|| <code>equery check ''package''</code>
||
|-
! Show pre/post install/uninstall scripts from a ''package''
|| <code>less /var/lib/dpkg/info/''package''.{pre,post,config}*</code>
|| <code>cat `equery which ''package''`</code>
||
|-
! Show change log for a ''package''
|| <code>zcat /usr/share/doc/package/changelog.Debian.gz</code><br/><code>aptitude [-t release] changelog package</code>
|| <code>view /usr/portage/''category''/''package''/ChangeLog</code>
||
|-
! colspan="4" align="center" | <big>'''Local package installation/upgrade/removal'''</big>
|| <code>dpkg -i ''package_file*.deb'' <ref name="apt">Usually it is not necessary to download packages manually and install them. Use apt-cache search ''name'' to search for package in configured repositories and apt-get install ''package'' to install package and all it's dependencies</ref></code>
|| <code>emerge --usepkg|-k ''package''<ref name="emerge-usepkg">Use a binary package if it is available from $PKGDIR, otherwise emerge from source as usual.</ref></code><br/><code>emerge --usepkgonly|-K ''package''<ref name="emerge-usepkgonly">Use a binary package if it is available from $PKGDIR, otherwise abort.</ref></code>
|| <code>pacman -U ''package''</code>
|-
! Upgrade a package from local ''package_file''
|| <code>emerge --update --usepkg|-k ''package''<ref name="emerge-usepkg"/></code><br/>
<code>emerge --update --usepkgonly|-K ''package''<ref name="emerge-usepkgonly"/></code>
|| <code>pacman -U ''package''</code>
|-
! Remove an installed ''package''
|| <code>emerge --unmerge ''package''</code><br/>
<code>emerge --prune ''package''</code>
|| <code>pacman -R ''package''</code>
|-
! colspan="4" align="center" | <big>'''Package installation from repositories'''</big>
<code>aptitude update && aptitude install ''package''</code>
|| <code>emerge -av ''package''</code>
|| <code>pacman -S ''package''</code>
|-
! Install a debug information files for a ''package''
|| <code>???</code>
|| <code>FEATURES="splitdebug installsources" emerge -av ''package''</code>
||
|-
! Only download a ''package'' from repository, do not install
|| <code>apt-get install --download-only --reinstall ''package''</code><ref name="dpkgdir">Package will reside in /var/cache/apt/archives.</ref><br/><code>aptitude download ''package''</code>
|| <code>emerge -avf ''package''</code><ref name="distfiles">Package sources will reside in /usr/portage/distfiles.</ref>
|| <code>pacman -Sw ''package''</code>
|-
! colspan="4" align="center" | <big>'''Get information about package interdependencies'''</big>
|| <code>dpkg-query -W -f='${Provides}\n' ''package''</code>
|| <code>equery files ''package'' (package must be installed first)</code>
||
|-
! What a given ''package'' requires?
|| <code>dpkg-query -W -f='${Depends}\n' ''package''</code>
|| <code>equery depgraph --depth=1 ''package''</code>
||
|-
! Which installed package(s) provide a given ''dependency''<ref name="dep">In rpm world, a ''dependency'' can be a package name, a file, or a special atom like <code>perl(IO::Zlib)</code> for a perl module. In deb world, this can be either real or virtual package name.</ref>?
|| <code>dpkg-query -W -f='${Package}: ${Provides}\n' '*' | grep ': .*package'</code>
|| <code>equery belongs ''dependency''</code>
||
|-
! Which installed package(s) require a given ''dependency''<ref name="dep"/>?
|| <code>dpkg-query -W -f='${Package}: ${Depends}\n' '*' | grep ': .*package'</code><br><code>aptitude why package</code><ref name="why">Actualy shows the whole dpendency situation that leads to install this package</ref>
|| <code>equery depends ''package''</code>
||
|-
! Show what prevents installation of a package
|| <code>aptitude why-not package</code>
|| <code>emerge -pv ''package''</code>
||
|-
! Get package source files
|| <code>apt-get source ''package''</code>
|| <code>emerge -f ''package''</code>
|| <code>abs ''repository''/''package''</code>
|-
! colspan="4" align="center" | <big>'''Working with package files'''</big>
|| <code>dpkg -x ''file.deb'' .</code>
|| N/A
||
|-
! Check package file integrity (checksums, signatures...)
|| <code>debsums ''package''</code>
|| <code>emerge -f ''package''</code>
||
|-
! colspan="4" align="center" | <big>'''Repository queries'''</big>
|| First run: <br/><code>apt-file update</code><br/>and then:<br/><code>apt-file search ''/some/file''</code>
|| N/A
||
|-
! Find a package based on some string or part of the string descriping it
|| <code>apt-cache search ''\*substr\*''</code>
|| <code>eix -S ''substr''</code>
|| <code>pacman -Ss ''substr''</code>
|-
! Shows the full description of ''package''
|| <code>apt-cache show ''package''</code>
|| <code>eix ''package''</code>
|| <code>pacman -Si ''package''</code>
|}
Anonymous user

Navigation menu