diff --git a/src/distrib/sets/lists/etc/mi b/src/distrib/sets/lists/etc/mi index b4bf4b5d6f..763e50f637 100644 --- a/src/distrib/sets/lists/etc/mi +++ b/src/distrib/sets/lists/etc/mi @@ -103,6 +103,7 @@ ./etc/mail/aliases etc-postfix-etc postfix ./etc/mailer.conf etc-mailwrapper-etc ./etc/man.conf etc-man-etc +./etc/mk.conf etc-sys-etc ./etc/master.passwd etc-sys-etc ./etc/moduli etc-secsh-etc ./etc/monthly etc-sys-etc diff --git a/src/etc/Makefile b/src/etc/Makefile index c5dabb904c..c4539e6019 100644 --- a/src/etc/Makefile +++ b/src/etc/Makefile @@ -275,6 +275,12 @@ FILESDIR_makronix-xsession= /etc/dt/config/Xsession.d FILESNAME_makronix-xsession= 0000makronix FILESMODE_makronix-xsession= 755 +# pkgsrc reads /etc/mk.conf by default (mk.conf(5)). The one line in it +# points DISTDIR at the archives the source set carries in /usr/src/distfiles, +# so a package build on the installed system finds them (see the file). +CONFIGFILES+= mk.conf +FILESMODE_mk.conf= 644 + # MCDE: the sources of the projects Makronix ships (ext/src/ in the # source set) are reachable as /opt/src too, where the other trees live. CONFIGSYMLINKS+= ${TZDIR}/${LOCALTIME} /etc/localtime \ diff --git a/src/etc/mk.conf b/src/etc/mk.conf new file mode 100644 index 0000000000..0d7b0cdfed --- /dev/null +++ b/src/etc/mk.conf @@ -0,0 +1,22 @@ +# $Makronix$ +# +# makronix: where pkgsrc finds the archives, and that it is usable as shipped. +# +# pkgsrc's default is DISTDIR=${PKGSRCDIR}/distfiles, and in this tree +# PKGSRCDIR is /usr/src/pkgsrc -- a directory that the source set leaves as +# the pin has it. The archives Makronix ships are in /usr/src/distfiles, +# beside the tree, where tools/makronix-distfiles.sh stages them and where the +# build itself reads them ($TOP/distfiles). Without this line a package on an +# installed system fetches an archive it already has, or fails with no network +# (measured 2026-11-23: `make -V DISTDIR` in /usr/src/pkgsrc/wm/mcde printed +# ${PKGSRCDIR}/distfiles while the archive lay in /usr/src/distfiles). +# +# Everything else is pkgsrc's own default: PREFIX=/usr/pkg, PKG_DBDIR= +# /usr/pkg/pkgdb, and bmake and the package tools come from the base sets +# (/usr/bin/make, /usr/sbin/pkg_add) -- an installed Makronix needs no +# bootstrap of its own to build a package. +# +# A person may add to this file; it is a config file (/etc/mk.conf, mode 644) +# and is not rewritten by an update. + +DISTDIR= /usr/src/distfiles