| git.druid.rocks | index | druid520 | ports | template/ | pkg.conf |
template/pkg.conf
# required. pkg_name is what mp/mpx and everyone else calls this port.
pkg_name="name"
# whatever you want, not enforced or checked anywhere.
pkg_license="license"
# whatever versioning scheme upstream uses ("1.2.3", pkgsrc/FreeBSD-pkg
# style with an optional -rN revision), or just "git" to track head.
pkg_ver="ver"
# space separated, port names (optionally name>=1.2 / =1.2.3 / ~1.2 /
# name:slot) or %tag (resolves to whichever provider of that tag has the
# lowest pkg_pref, honouring any TARGET_<tag>/TAG_<tag> pin); optional.
# legacy shorthand for "needed both to build and at runtime" -- see
# pkg_bdepend/pkg_rdepend below to split the two. mp appends GLOBAL_DEPS
# by default (see mp.conf.example), so you usually do not need to list
# %libc, %shell, or %coreutils here.
pkg_deps=""
# same syntax, split by when they are needed: pkg_bdepend is build-only
# (autoconf/cmake/...), pkg_rdepend is needed at runtime too. both
# optional; leave both empty and just use pkg_deps if the split does not
# matter for this port.
pkg_bdepend=""
pkg_rdepend=""
# deps that participate in resolution/ordering but never block: if one
# has no port, or would create a cycle, it is silently skipped instead of
# failing the install. optional, rarely needed outside bootstrap-provider
# ports (see ports/coreutils, ports/shells, ports/libcs).
pkg_deps_soft=""
# optional features / USE flags. each token is 'flag:dep1,dep2' (runtime
# deps) or 'flag:b:dep1,dep2' (build-only deps); a bare flag with no colon
# is just a boolean bit. setting USE="flag ..." in mp.conf enables the
# feature, adding its deps and exporting USE_<flag>=1 to every phase; see
# mp.conf.example. optional.
pkg_use=""
# space separated tags this port provides, for %tag deps and
# mp providers <tag>; optional, e.g. pkg_tags=cc for a c compiler.
pkg_tags=""
# rank among ports sharing a tag, lower wins ties; optional, defaults to 50.
pkg_pref="50"
# space separated port names this can't coexist with, checked both ways;
# "pkg" or "!!pkg" hard-blocks, "!pkg" soft-blocks (warns, does not stop
# the install -- %tag resolution already tries a different provider
# automatically when one conflicts). optional, see ports/libcs/musl and
# ports/libcs/glibc.
pkg_conflicts=""
# lets several builds of this pkg_name coexist, each installing into
# MP_PREFIX/<name>-<slot> instead of flat (e.g. gcc:12 next to gcc:13).
# optional; unset/"0" (almost every port) installs flat as always. a
# compound string ("12-glibc-znver3-O3") works today with no extra
# code -- refer to one axis-combination as name:12-glibc-znver3-O3.
pkg_slot=""
# space separated USE flags (from pkg_use above) whose enabled/disabled
# state should each contribute a "-flag" to the *effective* slot (declared
# order, appended after pkg_slot; disabled flags contribute nothing). lets
# two installs of the *same* port differing only in USE flags coexist
# instead of colliding on one slot/prefix -- e.g. pkg_slot_use="ssl" on
# curl, installed once with USE=ssl and once without, gives you both
# curl:ssl and curl (unslotted, since a flag off contributes nothing) side
# by side. set USE under this port's *bare* name in mp.conf (e.g. "curl:
# USE=ssl") -- that's the only key knowable before the composed slot
# exists, and it's also where deps/patches/exports for the resulting slot
# look for USE state. a dependent port that needs a specific slot (however
# it came to exist) references it exactly like a static one:
# pkg_deps="curl:ssl" -- and mp automatically points that dependent
# build's CFLAGS/LDFLAGS/PKG_CONFIG_PATH at curl:ssl's own private prefix
# (mplib::resolve::dep_slot_prefixes), not whatever curl build happens to
# be on the default search path. optional; unset is a no-op.
pkg_slot_use=""
# pkgsrc/Gentoo-style KEYWORDS: "amd64 arm64 ~riscv" (bare = stable,
# ~arch = testing, absent = unsupported there). optional; only matters if
# the user sets ACCEPT_KEYWORDS, which most do not.
pkg_keywords=""
# after remove: (or del.sh) finishes, mp sweeps whatever this port's own
# install manifest still lists and deletes anything left over -- so
# remove: only needs to handle what genuinely needs its own logic (a
# service to deregister, a config to read before it goes), not hand-
# mirror every file install: touched. set to "no" to disable this for a
# port that already manages its own complete removal (upstream
# "make uninstall", cmake's install_manifest.txt via classes/cmake.mp) or
# that deliberately leaves specific files behind on purpose (see
# meta/mp/pkg.conf). optional; defaults to enabled.
pkg_manifest_cleanup=""
# declarative fetch: git:<url>[@<ref-template>] or tar:<url>,<extractdir>,
# both cloning/extracting into a dir named after pkg_name. a <ref-template>
# may contain <VER_>, substituted with the resolved pkg_ver -- this is what
# makes "mp install name=1.2.3" pin an exact version. optional; write your
# own fetch: phase below instead for anything fancier (svn/hg/auth/etc).
pkg_fetch=""
# inherit="classname ..." pulls in classes/classname.mp from the ports
# tree root (autotools/cmake/meson/configure-make/plain-make/bootstrap-make
# ship today) for its phases and any pkg_deps it declares; your own phase
# blocks below override the same-named inherited one. optional -- most
# ports just inherit one class and declare nothing but metadata above.
#inherit="autotools"
# the autotools/configure-make/bootstrap-make classes' ./configure line
# ends with $CONFIGURE_FLAGS, meson's "meson setup" line ends with
# $MESON_FLAGS, and cmake's "cmake" line ends with $CMAKE_FLAGS -- all
# empty unless set, so a user can append extra flags to any port
# inheriting one of these classes without editing the port at all, via a
# per-package "<name>:" section in mp.conf (see mp.conf.example):
# somepkg:
# CONFIGURE_FLAGS="--enable-foo --without-bar"
# a hand-written build: phase can use the same env vars the same way.
# phases, each an unindented "name:" header with an indented shell body
# (same rules as add.sh/del.sh always had: runs via "$SHELL -e", one
# process per phase, auto-cd'd into the fetched source dir except fetch
# itself). only fetch/build/install/remove are shown; patch and check
# (opt-in via RUN_TESTS=yes) work the same way. all optional if inherit=
# already provides them; a port with NO phases at all and an add.sh/del.sh
# instead still works exactly as before (the pre-phases port format).
# a patches/ directory next to this file auto-synthesizes a patch: phase
# (patch -p1 < each file, sorted) unless you write your own patch: below.
# three kinds, all combinable:
# patches/*.patch always applied
# patches/use-<flag>/*.patch applied only when USE flag <flag> is ON
# patches/nouse-<flag>/*.patch applied only when <flag> is OFF (or never
# declared) -- e.g. a port whose pkg_use
# gates %ssl off still has SSL-only code
# paths in its source; a
# patches/nouse-ssl/*.patch can strip them
# instead of leaving that build broken.
# new-format ports only (same as every phase); ignored for a legacy
# add.sh/del.sh port.
#
#fetch:
# git clone https://example.com/name.git name
#
#build:
# ./configure --prefix=$MP_PREFIX
# make -j$MP_JOBS
#
#install:
# make install
#
#remove:
# make uninstall