Debian package management: Difference between revisions
imported>Johayek m (→rpm2deb) |
imported>Johayek |
||
Line 87: | Line 87: | ||
== history of this article == | == history of this article == | ||
This blog article got created 1st, but then the content got moved here to the wiki: | |||
* 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]] |
Revision as of 15:51, 25 April 2018
APT
- the Debian APT = Advanced Packaging Tool
$ sudo apt-get update # update is used to resynchronize the package index files from their sources $ 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
dealing with packages files (dpkg ... .deb)
- 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?
$ dpkg --info PACKAGE.deb
which files are included? will be created from this package file?
$ dpkg --contents PACKAGE.deb
install the Debian package:
$ sudo dpkg --install PACKAGE.deb
dealing with installed packages (dpkg-query)
- 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)?
$ dpkg-query --list
is there an installed package, that sounds like XYZ?
$ dpkg-query --list | fgrep XYZ
details of an installed package (that you know the name of, e.g. PACKAGE):
$ dpkg-query --list PACKAGE
all details of specified package:
$ dpkg-query --status PACKAGE
what's the content of an installed package (e.g. PACKAGE)?
$ dpkg-query --listfiles PACKAGE
which installed package includes a certain FILE (utility, ...)?
$ dpkg-query --search FILE
... (dpkg-source)
...
$ dpkg-source --extract ....dsc
needs a:
- *.dsc
- *.debian.tar.*
- *.orig.tar.*
rpm2deb
- https://en.wikipedia.org/wiki/Rpm_(software)
- https://en.wikipedia.org/wiki/Alien_(software)
- https://manpages.debian.org/unstable/alien/alien.1p.en.html
- https://manpages.debian.org/unstable/pseudo/fakeroot.1.en.html
- https://manpages.debian.org/unstable/fakeroot-ng/fakeroot.1.en.html
- https://www.howtoforge.com/converting_rpm_to_deb_with_alien : alien -k ... (important)
- https://unix.stackexchange.com/questions/9714/what-is-the-need-for-fakeroot-command-in-linux#9720 (important)
alien --to-deb ...
this command line creates a Debian package from an RPM package
(using that e-mail address for the (local Debian) package maintainer).
CAVEAT: won't actually work, because creating a Debian package requires running this as root
$ env EMAIL='john.doe@COMPANY.com' alien --to-deb --keep-version ...
some command line parameters can only get passied to "alien" as environment variables.
fakeroot ...
you do not have root priviliges, but you need to pretend to have them for achieving certain goals like creating a Debian package:
$ fakeroot --unknown-is-real ...
open questions
- how to deal with dependencies specified within the RPM package?
- …
history of this article
This blog article got created 1st, but then the content got moved here to the wiki: