{"id":815,"date":"2016-04-26T01:33:36","date_gmt":"2016-04-26T05:33:36","guid":{"rendered":"http:\/\/www.rfdm.com\/blog\/?p=815"},"modified":"2016-04-26T01:34:27","modified_gmt":"2016-04-26T05:34:27","slug":"creating-freebsd-packages-without-ports-part-2","status":"publish","type":"post","link":"https:\/\/www.rfdm.com\/blog\/?p=815","title":{"rendered":"creating FreeBSD packages without ports: part 2"},"content":{"rendered":"<p>I believe I now have an effective FreeBSD package manifest creator.  It will be included in the next release of libDwm.<\/p>\n<p>I need this for the cases where I want to build a FreeBSD package for distribution without using ports.  I have my own needs for this, but there are other cases where it makes sense to have this kind of functionality.  For example, when you need to distribute data or configuration files.  Heck, even packaging your shell initialization and other rc files from your home directory.  Or in my case, packaging small things on a Raspberry Pi where I don&#8217;t have ports installed.<\/p>\n<p>The program inside libDwm is called &#8216;mkfbsdmnfst&#8217;.  It&#8217;s in libDwm because I intend to use it for packaging libDwm and the support classes are in libDwm.<\/p>\n<p>It will read a template manifest file before reading files from a staging directory.  This template file is in manifest format, though it also allows comments.  Having the template allows the stuff that doesn&#8217;t change to be put in one place.  Another benefit is that you can prepopulate parts of the &#8216;files:&#8217; section.  For example, when you have a binary that you want to be setuid root when the package is installed, you can use a line like this in the &#8216;files:&#8217; section:<\/p>\n<pre style=\"font-size: 12px;\">\r\n\/usr\/local\/sbin\/evilsetuidprog:{uname:root,gname:wheel,perm:04555}\r\n<\/pre>\n<p>I check that all files in the manifest exist in the staging directory, so that you will receive an error message if you have a manifest with files that don&#8217;t exist.<\/p>\n<p>More in a later post after I&#8217;ve written the manpage.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I believe I now have an effective FreeBSD package manifest creator. It will be included in the next release of libDwm. I need this for the cases where I want to build a FreeBSD package for distribution without using ports. I have my own needs for this, but there are other cases where it makes &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.rfdm.com\/blog\/?p=815\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;creating FreeBSD packages without ports: part 2&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-815","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/815","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=815"}],"version-history":[{"count":2,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/815\/revisions"}],"predecessor-version":[{"id":817,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=\/wp\/v2\/posts\/815\/revisions\/817"}],"wp:attachment":[{"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=815"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=815"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rfdm.com\/blog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=815"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}