Bug 245401 - ports-mgmt/pkg breaks NanoBSD builds
Summary: ports-mgmt/pkg breaks NanoBSD builds
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-pkg mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-04-06 16:42 UTC by wout
Modified: 2020-04-12 09:21 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (pkg)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description wout 2020-04-06 16:42:44 UTC
After upgrading from pkg-1.13.2 to pkg-1.14.2 it seems NanoBSD builds are broken.

1) Creating the pkg package (`pkg create pkg` or `pkg create -a`) to place in Pkg directory works but returns with the following warning:

pkg: lstat(/usr/local/lib/compat/pkg): No such file or directory

2) Ignoring the above, and trying the create a NanoBSD image fails with the the following error in _.cust.cust_pkgng:

...
+ env 'BATCH=YES' 'ASSUME_ALWAYS_YES=YES' 'PKG_DBDIR=/var/db/pkg' 'SIGNATURE_TYPE=none' /usr/sbin/pkg add /_.p/pkg-1.14.2.txz
Installing pkg-1.14.2...
Extracting pkg-1.14.2: .......... done
pkg-static: Fail to set time on /usr/local/lib/compat/pkg:No such file or directory

Failed to install the following 1 package(s): /_.p/pkg-1.14.2.txz
Comment 1 wout 2020-04-12 09:21:05 UTC
I think it is caused by:

https://github.com/freebsd/pkg/commit/10920fb88a121630e1b45ae1f02fc9bba893551f

Workaround:

1) `mkdir /usr/local/lib/compat/pkg` before creating pkg package
2) Add `CR "mkdir -p /usr/local/lib/compat/pkg"` to cust_pkgng() so the required directory exists in the NanoBSD build environment