4 ms·
Ask HN: How Does the FreeBSD Ports Collection Work?
I am a long-time Debian/Ubuntu user looking to get started on a FreeBSD system. I am a little confused by how the Ports Collection works because it seems like all supported ports are stored on the system. Doesn't this take up a massive amount of space? How does the FreeBSD Ports Collection package manager implementation compare to dpkg on Debian systems? I'd appreciate any resources or guides!
- jcr 12y agoOn BSD systems, the ports collection is simply a directory tree containing some fairly small text files. The various text files in a given port (subdirectory) include Makefiles, patches, description files and checksums. When you run `make` in a port subdirectory, the target software source code is downloaded, patched, built, installed into a "fake" directory tree emulating a target system, and then finally all of the stuff it just installed is gathered up into a compressed "package" archive. In short, the ports are used to create packages. If you're new to BSD systems, it's much easier to use the pre-built packages. https://www.freebsd.org/ports/ https://www.freebsd.org/ports/ https://www.freebsd.org/doc/handbook/ports-using.html https://www.freebsd.org/doc/handbook/ports-using.html
- jarcane 12y agoAlso, it's worth pointing out that the use of the ports collection is optional in modern BSD, as you can install anything that's in ports directly as a package instead using pkg.
- bsg75 12y agoThe ports give you the option to configure the build, where as pkg uses preset options, correct?