Updated «Dependency Heck» chapter
This commit is contained in:
parent
db660ce0d0
commit
1a1ffb9406
@ -352,7 +352,7 @@ I tried installing it directly through snap using this command:
|
|||||||
/snap/okular/155/usr/bin/okular: error while loading shared libraries: libKF6Parts.so.6: cannot open shared object file: No such file or directory
|
/snap/okular/155/usr/bin/okular: error while loading shared libraries: libKF6Parts.so.6: cannot open shared object file: No such file or directory
|
||||||
\end{Verbatim}
|
\end{Verbatim}
|
||||||
|
|
||||||
This is, believe it or not, progress. What this is telling us is that Snap did not install all of the required dependencies, which in this case is \texttt{libKF6Pars.so.6}. So the issue now is: where can we can get that dependency from?
|
This is, believe it or not, progress. What this is telling us is that Snap (or possible Ubuntu—I am not entirely sure here) did not install all of the required dependencies, which in this case is \texttt{libKF6Pars.so.6}. So the issue now is: where can we can get that dependency from?
|
||||||
|
|
||||||
Time for some more command-line magic:
|
Time for some more command-line magic:
|
||||||
|
|
||||||
@ -382,7 +382,7 @@ I'm so glad you asked.
|
|||||||
|
|
||||||
The short answer is that a dependency is a collection of code that another piece of software relies on to do something. Which leads us to another question—why doesn't the software in question contain all the code that it needs to have in order to operate? Why do we bother with dependencies?
|
The short answer is that a dependency is a collection of code that another piece of software relies on to do something. Which leads us to another question—why doesn't the software in question contain all the code that it needs to have in order to operate? Why do we bother with dependencies?
|
||||||
|
|
||||||
The short answer is that a lot of different software packages all need to do the same thing. So rather than include that other thing in each software package, we bundle it into a \textit{library}—a bit of software that other software packages can rely upon if they need to. When they do that, this library is now a dependency. The software package in question can't run without it.
|
The reason is that a lot of different software packages all need to do the same thing. So rather than include that other thing in each software package, we bundle it into a \textit{library}—a bit of software that other software packages can rely upon if they need to. When they do that, this library is now a dependency. The software package in question can't run without it.
|
||||||
|
|
||||||
To make things even less clear, a dependency doesn't necessarily have to be a library. It could be something like a configuration file, a device driver, or a database.
|
To make things even less clear, a dependency doesn't necessarily have to be a library. It could be something like a configuration file, a device driver, or a database.
|
||||||
|
|
||||||
@ -404,7 +404,7 @@ Once you start to get into Linux, you inevitably hear about ``Dependency Hell''.
|
|||||||
|
|
||||||
Note that I said ``largely'' and not ``completely''. Hence, dependency \textit{heck}.
|
Note that I said ``largely'' and not ``completely''. Hence, dependency \textit{heck}.
|
||||||
|
|
||||||
Dependency hell is what happens when you try to install new software on your computer, but some of the dependencies are missing, conflict with one another, or have been deprecated.\footnote{Because this is no longer much of a problem, I don't want to get into it too much. If you are interested, Wikipedia has an excellent article on depency hell at \kref{https://en.wikipedia.org/wiki/Dependency\_hell}{https://en.wikipedia.org/wiki/Dependency\_hell}.} This problem has largely gone away due to the use of package managers, which handle the actual compiling and installation of software, because they handle issues with dependencies on their own.
|
Dependency hell is what happens when you try to install new software on your computer, but some of the dependencies are missing, conflict with one another, or have been deprecated.\footnote{Because this is no longer much of a problem, I don't want to get into it too much. If you are interested, Wikipedia has an excellent article on dependency hell at \kref{https://en.wikipedia.org/wiki/Dependency\_hell}{https://en.wikipedia.org/wiki/Dependency\_hell}.} This problem has largely gone away due to the use of package managers, which handle the actual compiling and installation of software, because they handle issues with dependencies on their own.
|
||||||
|
|
||||||
For example, on Debian/Ubuntu systems, the default package manager is \texttt{apt}. Red Hat/Fedora uses \texttt{dnf}, openSUSE uses \texttt{zypper}, Gentoo uses \texttt{emerge}, and ArchLinux uses \texttt{pacman}. In fact, the ArchLinux wiki has a page which extensively documents the difference between these different package managers.\footnote{See \kref{https://wiki.archlinux.org/title/Pacman/Rosetta}{https://wiki.archlinux.org/title/Pacman/Rosetta}.} If you've never gotten further than \texttt{sudo apt install foo}, you will find a lot of useful information there.
|
For example, on Debian/Ubuntu systems, the default package manager is \texttt{apt}. Red Hat/Fedora uses \texttt{dnf}, openSUSE uses \texttt{zypper}, Gentoo uses \texttt{emerge}, and ArchLinux uses \texttt{pacman}. In fact, the ArchLinux wiki has a page which extensively documents the difference between these different package managers.\footnote{See \kref{https://wiki.archlinux.org/title/Pacman/Rosetta}{https://wiki.archlinux.org/title/Pacman/Rosetta}.} If you've never gotten further than \texttt{sudo apt install foo}, you will find a lot of useful information there.
|
||||||
|
|
||||||
@ -439,7 +439,7 @@ This is highly useful information, so let's break this down a bit.
|
|||||||
\begin{enumerate}
|
\begin{enumerate}
|
||||||
\item First, \texttt{apt} is telling me that this is only a simulation, so I don't have to go into Karen mode when I try to run this application later and can't find it.
|
\item First, \texttt{apt} is telling me that this is only a simulation, so I don't have to go into Karen mode when I try to run this application later and can't find it.
|
||||||
\item It's also reminding me that \texttt{apt} needs root privileges to actually do anything. I didn't use \texttt{sudo} here because I don't want to get in the habit of using it all the time.\footnote{Which is the same reason I don't use the ATM at a casino. If I'm out of money, it's time to go home.}
|
\item It's also reminding me that \texttt{apt} needs root privileges to actually do anything. I didn't use \texttt{sudo} here because I don't want to get in the habit of using it all the time.\footnote{Which is the same reason I don't use the ATM at a casino. If I'm out of money, it's time to go home.}
|
||||||
\item It also tells me that I have a couple of packages that I don't really need, and it provides the command I need to remove them.
|
\item It also tells me that I have a few packages that I don't really need, and it provides the command I need to remove them.
|
||||||
\item It then tells me which packages it will install. In this case, it's only going to install the \texttt{meld} package, which means either that \texttt{meld} doesn't need any dependencies, or that all the ones that it needs to function are already on my system.
|
\item It then tells me which packages it will install. In this case, it's only going to install the \texttt{meld} package, which means either that \texttt{meld} doesn't need any dependencies, or that all the ones that it needs to function are already on my system.
|
||||||
\end{enumerate}
|
\end{enumerate}
|
||||||
|
|
||||||
@ -453,7 +453,7 @@ And yes, if it seems like we are moving backward, we are, in a way. I'm not goin
|
|||||||
|
|
||||||
\paragraph{Snap} First developed by Canonical (which is the for-profit company behind Ubuntu) this creates a new directory in your \texttt{\$HOME} directory to install snaps. (I did not like this at first, but okay, whatever.) One of the ideas behind snaps is that you can run different versions of the same program. Which would be handy, except that the people responsible for maintaining the snap packages do a pretty crap job of it, and most snaps are a version or two (or more) behind the current release version.
|
\paragraph{Snap} First developed by Canonical (which is the for-profit company behind Ubuntu) this creates a new directory in your \texttt{\$HOME} directory to install snaps. (I did not like this at first, but okay, whatever.) One of the ideas behind snaps is that you can run different versions of the same program. Which would be handy, except that the people responsible for maintaining the snap packages do a pretty crap job of it, and most snaps are a version or two (or more) behind the current release version.
|
||||||
|
|
||||||
\paragraph{Flatpak} A quick look at the Flatpak home page\footnote{\kref{https://flatpak.org/}{https://flatpak.org/}} shows that they consider themselves ``The future of apps on Linux''. That's pretty confident. But the idea is pretty much the same as a snap. You first have to install \texttt{flathub}, then you download the relevant file from \kref{https://flathub.org/}{https://flathub.org/} and install it. It's not perfect, but for the one app\footnote{Paper Clip, which allows you to quickly and easily edit a pdf file's metadata. If you need to do that, I highly recommend it. See \kref{https://flathub.org/apps/io.github.diegoivan.pdf_metadata_editor}{https://flathub.org/apps/io.github.diegoivan.pdf\_metadata\_editor} for details.} I need that is only available as a Flatpak, I suppose it works well enough. But I would hate to have to install \textit{all} of my software this way.
|
\paragraph{Flatpak} A quick look at the Flatpak home page\footnote{\kref{https://flatpak.org/}{https://flatpak.org/}} shows that they consider themselves ``The future of apps on Linux''. That's pretty confident. But the idea is pretty much the same as a snap. You first have to install \texttt{flathub}, then you download the relevant file from \kref{https://flathub.org/}{https://flathub.org/} and install it. It's not perfect, but for the one app\footnote{Paper Clip, which allows you to quickly and easily edit a pdf file's metadata. If you need to do that, I highly recommend it. See \kref{https://flathub.org/apps/io.github.diegoivan.pdf_metadata_editor}{https://flathub.org/apps/io.github.diegoivan.\\pdf\_metadata\_editor} for details.} I need that is only available as a Flatpak, I suppose it works well enough. But I would hate to have to install \textit{all} of my software this way.
|
||||||
|
|
||||||
\paragraph{AppImage} This is perhaps the simplest one I've used—you just download a file, make it executable,\footnote{You do this by updating the execute bit with \texttt{chmod +x file.AppImage}.} and then run it. I don't have too much of an issue with this one, but I only have a couple of apps that run from an AppImage. (Among them is the Cool Retro Terminal,\footnote{\hspace*{-1mm}\kref{
|
\paragraph{AppImage} This is perhaps the simplest one I've used—you just download a file, make it executable,\footnote{You do this by updating the execute bit with \texttt{chmod +x file.AppImage}.} and then run it. I don't have too much of an issue with this one, but I only have a couple of apps that run from an AppImage. (Among them is the Cool Retro Terminal,\footnote{\hspace*{-1mm}\kref{
|
||||||
https://github.com/Swordfish90/cool-retro-term}{
|
https://github.com/Swordfish90/cool-retro-term}{
|
||||||
|
Loading…
Reference in New Issue
Block a user