Question about package management (in general)

I was wondering if anyone has made any effort to port some type of binary package management system (like apt or rpm/yum) to FreeBSD. I know we have the pkg_src command to install binaries, but when it comes to updating packages pkg_src doesn't always handle things as gracefully. Also when it comes to updating applications installed with ports, this can be time consuming and not necessarily as fail safe as apt.

I of course am basing this on my own experience, and everyone's mileage may vary :)
 
I'm not sure if we would need another CLI tool to manage packages/ports, it seems there are quite a few already. But it might be a good idea to create a nice GUI (build with QT and/or GTK) to keep track of the installed packages and ideally install new ones if they are available. It would basically just need to be a GUI frontend for the build-in pkg_* tools.
 
There's one in sysutils/desktopbsd-tools (KDE GUI for straightforward FreeBSD ports/package maintenance -- which I think is a front-end for portupgrade). I guess it's bin/kdialog-ports-wrapper.
 
Interesting, I knew the pkg_ tools are pretty powerful, but I didn't know there were so many different ways to manage it.

I guess I shouldn't be comparing our package management tools to apt for instance, as we are not linux, and we have our own way of doing things.

I guess this brings up another question. If you are running a -RELEASE version of FreeBSD, and run pkg_src to install some package, will it grab a binary that is equivalent to the current ports tree? Or will it grab a binary that was compiled at the time the current version of FreeBSD was release?
 
NOTE: the tool is called pkg_add, not pkg_src.

If you are running a -RELEASE version of FreeBSD, then pkg_add -r will (by default) check the corresponding "release" directory on the package server. The packages in here are built at the time of the release, and only get updates when something major occurs (security fix for large port, major upgrade to large port like GNOME or KDE, things like that).

If you want more up-to-date packages, you have to set the PKG* environment variables to point to the "stable" directory on the server. These packages get rebuilt fairly regularly, although they will still be behind the versions on the ports tree.
 
I suggest putting a label somewhere convenient:
"ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-7-stable/"
Then if you want to install a package you can
Code:
 ncftp ftp://... ... .../lang
for example, substituting
-7- and i386 with their proper parameters,
then you can
Code:
 ls gcc
press tab, and it should
autocomplete your choices of which package you want to fetch.
you can then "get" it,
and
Code:
 pkg_add ...
locally.
..........
which might be usefull
 
jb_fvwm2 said:
I suggest putting a label somewhere convenient:
"ftp://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-7-stable/"
Then if you want to install a package you can...

I'm assuming this would fetch the same exact thing as what phoenix had noted with environment variables.

NOTE: the tool is called pkg_add, not pkg_src.

Sorry I meant pkg_add. I have a little bit of Solaris experience under my belt (though not as much as FreeBSD)... I don't know how that slipped out (which is actually pkgsrc, I'm just scatter brained) :)
 
Brentx said:
I'm assuming this would fetch the same exact thing as what phoenix had noted with environment variables.
Yes, for (t)csh: # setenv PACKAGESITE [url]http://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-7-stable/[/url]
Then you can simply use pkg_add -r and it will grab the 7-stable packages.

If you point it at http://ftp.freebsd.org/pub/FreeBSD/ports/i386/packages-7-stable/Latest/ (note the /Latest/ at the end) you can use package names without version numbers like:
# pkg_add -r xorg-minimal
 
Using the ncftp method above, one also would know
1... whether the package exists (rather than a possible "not found"
which only indicates a yes, or no, in a less recent version;
1a... whether one wants to install the less recent version
or a similar more-informative-sometimes result.
(works here at least).
 
Back
Top