d35164539b
Setting CONFSNAME directly is a little more complicated for downstream consumers, as any additional CONFS that are added here will inherit the group name by default. This is perhaps arguably a design flaw in CONFS because inheriting NAME will never give a good result when additional files are added, but this is a low-effort change. While we're here, pull FreeBSD.conf.${branch} out into a PKGCONF variable so one can just drop a new repo config in entirely with a new naming scheme. CONFSNAME gets set based on chopping anything off after ".conf", so that, e.g.: - FooBSD.conf => FooBSD.conf - FooBSD.conf.internal => FooBSD.conf Reviewed by: bapt, manu Differential Revision: https://reviews.freebsd.org/D28767
32 lines
718 B
Makefile
32 lines
718 B
Makefile
# $FreeBSD$
|
|
|
|
_BRANCH!= ${MAKE} -C ${SRCTOP}/release -V BRANCH
|
|
BRANCH?= ${_BRANCH}
|
|
.if ${BRANCH:MCURRENT} != ""
|
|
PKGCONFBRANCH?= latest
|
|
.else
|
|
. if ${BRANCH:MBETA*} || ${BRANCH:MRC*} || ${BRANCH:MRELEASE*}
|
|
PKGCONFBRANCH?= quarterly
|
|
. else
|
|
. if ${MACHINE} != "amd64" && ${MACHINE} != "i386"
|
|
PKGCONFBRANCH?= quarterly
|
|
. else
|
|
PKGCONFBRANCH?= latest
|
|
. endif
|
|
. endif
|
|
.endif
|
|
PKGCONF?= FreeBSD.conf.${PKGCONFBRANCH}
|
|
CONFS= ${PKGCONF}
|
|
CONFSNAME_${PKGCONF}= ${PKGCONF:C/\.conf.+$/.conf/}
|
|
CONFSDIR= /etc/pkg
|
|
CONFSMODE= 644
|
|
PROG= pkg
|
|
SRCS= pkg.c dns_utils.c config.c
|
|
MAN= pkg.7
|
|
|
|
CFLAGS+=-I${SRCTOP}/contrib/libucl/include
|
|
.PATH: ${SRCTOP}/contrib/libucl/include
|
|
LIBADD= archive fetch ucl crypto ssl util
|
|
|
|
.include <bsd.prog.mk>
|