Skip to content

Question: how to install SmartOS binary packages on non-Illumos operating system with pkgin #265

@am11

Description

@am11

apologies in advance if it is already documented somewhere, but I could not find this information, therefore asking here directly.

On Debian/Linux system, in the path where illumos/sysroot release tarball is restored, we want to install SmartOS binary packages. We have built pkgsrc tools (including pkgin) on Debian/Linux using pkgsrc (2020Q1) sources.

Now using this pkgin (Linux executable running on Debian/Linux system), is it possible to make it:

  • fetch 2020 Q1/Q2 binary packages built for SmartOS and
  • install package at location with custom path prefix

by, for example, modifying some config file or some command line switch? If so, how? :)

As an example, we compile FreeBSD's pkg tool (https://github.com/freebsd/pkg) on Debian/Linux, then modify its pkg.conf file to make it install FreeBSD packages on Debian/Linux inside the sysroot directory:

echo "ABI = \"FreeBSD:11:amd64\"; FINGERPRINTS = \"${__RootfsDir}/usr/share/keys\"; REPOS_DIR = [\"${__RootfsDir}/etc/pkg\"]; REPO_AUTOUPDATE = NO; RUN_SCRIPTS = NO;" > ${__RootfsDir}/usr/local/etc/pkg.conf

here $__RootfsDir is the root of where the sysroot files are restored. Complete working examples for various package managers and operating systems are available in this bash script: https://github.com/dotnet/arcade/blob/master/eng/common/cross/build-rootfs.sh.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions