This diff adds the following pkgbase packages:
- zfs
- ctf
- dtrace
- libdrti
- libavl
- libctf
- libdtrace
- libnvpair
- libumem
- libuutil
- libzfs
Differential D8097
Create pkgbase packages for CDDL libraries and binaries rogiel_rogiel.com on Sep 30 2016, 3:53 PM. Authored by Tags None Referenced Files
Details
Diff Detail
Event TimelineComment Actions I'd like a reference to what these will actually do. It seems that each library is now a package but that may not make sense based on the structure of those libraries. Comment Actions All libraries are individual packages with the exception of libzfs which in fact includes three: libzfs, libzfs_core and libzpool which are directly related. I did this way because it seemed to be pattern on the lib subdir where all libraries are in lib${LIB} package, with the exception of C and C++ standard libraries which reside in a clibs package. It seems that libraries like nvpair, uutil and umem seem to only be required by ZFS, but I still see them as different packages because they are not libzfs, but dependencies of it. The same could be said for libctf which is required by dtrace and ctf* tools. As for the binaries, I packaged them in a zfs package, a dtrace package and a ctf package which I think is a pretty straight forward packaging. Comment Actions Do we have a document on how the packaging for base works? I'd like to understand the process a bit better before approving this review. Comment Actions Here is a presentation from bapt in BSDCan 2015: http://pres.gandi.net/downloads/FreeBSD-packaging-base.pdf From what I could tell, the PACKAGE= is enough to tell <bsd.prog.mk>/<bsd.lib.mk> to create a package with that name. It will also generate a plist (a metadata file which lists all files that belong to that package) from the installed files by that prog/lib. Also, when no PACKAGE name is available, it will default to runtime. Currently, all zfs and dtrace stuff are being packaged in runtime because theres no PACKAGE for them. To give a practical example, heres zfs.ucl, the package metadata file generated by the "package" target. # # $FreeBSD$ # name = "FreeBSD-zfs" origin = "base" version = "20161001" comment = "zfs package" categories = [ base ] maintainer = "re@FreeBSD.org" www = "https://www.FreeBSD.org" prefix = "/" licenselogic = "single" licenses = [ BSD2CLAUSE ] desc = <<EOD zfs package EOD Notice that I manually override the version string to match the date so that the system will create a daily-snapshot version. In a regular build that should be 12-CURRENT or something like that. And here is zfs.plist, which list files installed by that package: @(root,wheel,0555,) /etc/rc.d//zfs @(root,wheel,0555,) /etc/rc.d//zfsd @(root,wheel,0555,) /etc/rc.d//zvol @(root,wheel,0555,) /sbin/zfs @(root,wheel,0555,) /sbin/zpool @(root,wheel,0555,) /usr/bin/zinject @(root,wheel,0555,) /usr/bin/zstreamdump @(root,wheel,0555,) /usr/bin/ztest @(root,wheel,0555,) /usr/sbin/zdb @(root,wheel,0555,) /usr/sbin/zfsd @(root,wheel,0555,) /usr/sbin/zhack |