After reading the tile of this thread the first question one might ask is why not just use a distro that already has apt installed like debain, ubuntu or debiandog. The reason that I have apt on puppy is not because I actually wanted to install it but instead I was curious about whether or not I could use apt-key to add a pgp key to the keyring for the puppy package manager (see thread).
I actually do not know if the puppy package manager has it's own pgp keyring but from a security perspective it makes sense to trust different people with the authenticating the packages that you install on your system then you do to authenticate a post on some forum or blog.
Part 1.1 - An Example Shortcoming of the Puppy Package Manager
However, even though I installed apt on a whim there are some commands that I'm use to doing on apt that I don't know how to do on puppy. For instance when I tried to install unireedsolomon with pip3, I was told that I was missing a header file. This usually happens when the dev package for python isn't installed. However, I didn't know how to search for the dev package on Puppies Package Manager.
When I tried searing for "python3-dev" nothing showed up. It is easier to search for things on the command line because I can apply multiple filters using grep. For example with apt I found the missing package easily with the command
Code: Select all
apt-cache search python3 | grep dev
2. Okay, but how do I install apt?
2.1 Newer uPups and dPups
If you are running a new uPup of dpup such as dpup Strech, or Xenial, Upup Bionic Beaver, etc...then you can probably install apt directly from the package manager and you'll be most of the way there. However, you'll likely also need to:
1. Install (or re-install) coreutils because the version of mktemp used by busybox doesn't support all of the command line options that are needed by some tools in the apt package (apt-key has this issue).
2. If /var/lib/dpkg/status causes problems (e.g. if it was a directory instead of a file), then delete it. Use the touch command to create it as an empty file and then type:
Code: Select all
apt-get install --reinstall $(</var/lib/dpkg/status sed -n 's/^Package://p')
apt-get update
One also needs to create the file /etc/apt/sources.list. From strech you can use:
Code: Select all
deb http://deb.debian.org/debian stretch main
deb-src http://deb.debian.org/debian stretch main
deb http://deb.debian.org/debian-security/ stretch/updates main
deb-src http://deb.debian.org/debian-security/ stretch/updates main
deb http://deb.debian.org/debian stretch-updates main
deb-src http://deb.debian.org/debian stretch-updates main
This is where I stopped because all I wanted at this moment was to get was "apt-cache search" to work. However, at a later time I do want to learn how to sync apt with the puppy package manager and visa-versa.
3. Non debian/ubuntu variants and older version of Puppy
There is an article on the puppylinux wiki called Debianization but it is probably too old to be helpful. The keypoint to keep in mind here is that if you start downloading packages from a debian or ubuntu repo then try to pick from a repo where the core c libraries (e.g. glibc) match as close as possible to those of you current system.
This is because trying to update core c libraries will likely cause a novice to break their current system. It's better if they chose packages that don't require one to update their core c libraries. Also one may want to consider compiling the libraries themselves rather than using pre-built binaries either to ensure better comparability or because there is no pre-built binaries for their system.
Anyway, since we are assuming a non debian/ubuntu strain of linux the binaries can be downloaded from web pages if they aren't available on the package manager.
Here are some links for APT:
Debian: jessie Strech
Ubuntu: trusty,xenial, bionic
For older versions the dependency info can still be found on the internet archive:
Debian: lenny, squeez, wheezy
Ubuntu: lucid, Precice
this will let one know what version of the packages to build if they can't find a suitable repo for binaries.
Look Ahead
So far I've only used "apt-cache search" from the apt package. The reason is that I want to try syncing it with the puppy package manager before using apt. If I make progress in the front I will report the details about my progress to this thread.
Also note that there is also an in-house puppy CLI Based package manager, that I would like to try. Perhaps it has the functionality that I would like from APT. Hopefully I'll get to compare in the near future