Editing Debian package management
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
== APT == | == APT == | ||
* the Debian [http://en.wikipedia.org/wiki/Advanced_Packaging_Tool APT = Advanced Packaging Tool] | * the Debian [http://en.wikipedia.org/wiki/Advanced_Packaging_Tool APT = Advanced Packaging Tool] | ||
** [http://en.wikipedia.org/wiki/Advanced_Packaging_Tool#Update.2C_upgrade_and_dist-upgrade update | ** [http://en.wikipedia.org/wiki/Advanced_Packaging_Tool#Update.2C_upgrade_and_dist-upgrade update and upgrade] | ||
<pre> | <pre> | ||
$ sudo apt-get | $ sudo apt-get update # update is used to resynchronize the package index files from their sources | ||
$ sudo apt-get | $ sudo apt-get upgrade # upgrade is used to install the newest versions of all packages currently installed on the system from the sources enumerated in /etc/apt/sources.list | ||
</pre> | </pre> | ||
== | == dealing with packages files (.deb) == | ||
* https://manpages.debian.org/unstable/dpkg/dpkg.1.en.html | * https://manpages.debian.org/unstable/dpkg/dpkg.1.en.html | ||
* http://man7.org/linux/man-pages/man1/dpkg.1.html | |||
* https://www.systutorials.com/docs/linux/man/1-dpkg/ | |||
what's the official package name? | |||
<pre>$ dpkg --info PACKAGE.deb</pre> | |||
<pre>$ dpkg | |||
which files are included? will be created from this package file? | |||
<pre>$ dpkg --contents PACKAGE.deb</pre> | |||
== | == dealing with installed packages == | ||
* https://manpages.debian.org/unstable/dpkg/dpkg-query.1.en.html | * https://manpages.debian.org/unstable/dpkg/dpkg-query.1.en.html | ||
* http://man7.org/linux/man-pages/man1/dpkg-query.1.html | |||
* https://www.systutorials.com/docs/linux/man/1-dpkg-query/ | |||
which packages are installed (together with a '''couple''' of details)? | |||
<pre>$ dpkg-query --list</pre> | <pre>$ dpkg-query --list</pre> | ||
is there an installed package, that sounds like XYZ? | |||
<pre>$ dpkg-query --list | fgrep XYZ</pre> | <pre>$ dpkg-query --list | fgrep XYZ</pre> | ||
details of an installed package (that you know the name of, e.g. PACKAGE): | |||
<pre>$ dpkg-query --list PACKAGE</pre> | <pre>$ dpkg-query --list PACKAGE</pre> | ||
all details of specified package: | |||
<pre>$ dpkg-query --status PACKAGE</pre> | <pre>$ dpkg-query --status PACKAGE</pre> | ||
what's the content of an installed package (e.g. PACKAGE)? | |||
<pre>$ dpkg-query --listfiles PACKAGE</pre> | <pre>$ dpkg-query --listfiles PACKAGE</pre> | ||
=== | == rpm2deb == | ||
* https://en.wikipedia.org/wiki/Rpm_(software) | * https://en.wikipedia.org/wiki/Rpm_(software) | ||
* https://en.wikipedia.org/wiki/Alien_(software) | * https://en.wikipedia.org/wiki/Alien_(software) | ||
* https://manpages.debian.org/unstable/ | * https://manpages.debian.org/unstable/dpkg/dpkg-query.1.en.html | ||
* https:// | * https://www.howtoforge.com/converting_rpm_to_deb_with_alien : alien -k ... | ||
* https://unix.stackexchange.com/questions/9714/what-is-the-need-for-fakeroot-command-in-linux#9720 | |||
* https://manpages.debian.org/unstable/fakeroot-ng/fakeroot.1.en.html | * https://manpages.debian.org/unstable/fakeroot-ng/fakeroot.1.en.html | ||
== alien --to-deb ... == | === alien --to-deb ... === | ||
this command line creates a Debian package from an RPM package | this command line creates a Debian package from an RPM package | ||
(using that e-mail address for the (local Debian) package maintainer).<br/> | (using that e-mail address for the (local Debian) package maintainer).<br/> | ||
CAVEAT: won't actually work, because creating a Debian package requires running this as root | CAVEAT: won't actually work, because creating a Debian package requires running this as root | ||
<pre>$ env EMAIL='john.doe@COMPANY.com' alien --to-deb --keep-version ...</pre> | <pre>$ env EMAIL='john.doe@COMPANY.com' alien --to-deb --keep-version ...</pre> | ||
some command line parameters can only get | some command line parameters can only get passied to "alien" as environment variables. | ||
== fakeroot ... == | === fakeroot ... === | ||
you do not have root priviliges, | you do not have root priviliges, | ||
but you need to pretend to have them for achieving certain goals like creating a Debian package: | but you need to pretend to have them for achieving certain goals like creating a Debian package: | ||
<pre>$ fakeroot | <pre>$ fakeroot --unknown-is-real ...</pre> | ||
</pre> | |||
== open questions == | === open questions === | ||
* how to deal with dependencies specified within the RPM package? | * how to deal with dependencies specified within the RPM package? | ||
* … | * … | ||
= history of this article = | == history of this article == | ||
The blog article got created 1st, but then the content got moved here: | |||
* http://Jochen.Hayek.name/wp/blog-en/2018/04/13/rpm2deb/ | * http://Jochen.Hayek.name/wp/blog-en/2018/04/13/rpm2deb/ | ||
[[Category:ToBeExported]] | [[Category:ToBeExported]] |