How to tell if pkg installed from binary or built from source?

Binary packages on FreeBSD remote repositories are build in poudriere jail servers. These packages contain Jails build information, packages installed from ports do not.

For example, package from FreeBSD remote repository:
Code:
 % pkg info -A pkg
pkg-1.21.3:
    FreeBSD_version: 1400097
    build_timestamp: 2024-05-23T01:05:38+0000
    built_by       : poudriere-git-3.4.1-30-g79e3edcd
    port_checkout_unclean: no
    port_git_hash  : 7cdaa4ba4
    ports_top_checkout_unclean: no
    ports_top_git_hash: 26c1f721b
    repo_type      : binary
    repository     : latest

/usr/ports/ports-mgmt/pkg
Code:
 % pkg info -A pkg
pkg-1.21.3:
        FreeBSD_version:  1401000

The repository information of the installed packages can also be viewed with pkg query -a "[%R] %o" | sort for example.

When installed from ports or pkg-add(8), the query will return "unknown-repository".
 
Back
Top