[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / pkgtools / pkg_alternatives

File: [cvs.NetBSD.org] / pkgsrc / pkgtools / pkg_alternatives / Makefile (download)

Revision 1.24, Fri Jan 10 12:20:50 2020 UTC (13 months, 2 weeks ago) by leot
Branch: MAIN
CVS Tags: pkgsrc-2020Q4-base, pkgsrc-2020Q4, pkgsrc-2020Q3-base, pkgsrc-2020Q3, pkgsrc-2020Q2-base, pkgsrc-2020Q2, pkgsrc-2020Q1-base, pkgsrc-2020Q1, HEAD
Changes since 1.23: +2 -2 lines

pkg_alternatives: Update to 1.7

Changes:
1.7
---
 - Adjust pkg_alternatives(8) to point to the real user configuration wrapper
   file and bump date

# $NetBSD: Makefile,v 1.24 2020/01/10 12:20:50 leot Exp $
#

PKGNAME=	pkg_alternatives-1.7
CATEGORIES=	pkgtools

MAINTAINER=	jmmv@NetBSD.org
COMMENT=	Generic wrappers for programs with similar interfaces
LICENSE=	modified-bsd

NO_BUILD=		YES
WRKSRC=			${WRKDIR}

DATADIR=		${PREFIX}/share/pkg_alternatives
DBDIR=			${PREFIX}/libdata/pkg_alternatives
EGDIR=			${PREFIX}/share/examples/pkg_alternatives

FILES_SUBST+=		PKG_ALTERNATIVES=${PREFIX}/sbin/pkg_alternatives

REQD_DIRS=		${DBDIR}
MAKE_DIRS=		${PKG_SYSCONFDIR}

PKG_SYSCONFSUBDIR=	pkg_alternatives
CONF_FILES=		${EGDIR}/filter.conf ${PKG_SYSCONFDIR}/filter.conf

SUBST_CLASSES+=		vars
SUBST_STAGE.vars=	do-configure
SUBST_MESSAGE.vars=	Configuring sources.
SUBST_FILES.vars=	pkg_alternatives.8 pkg_alternatives.sh
SUBST_SED.vars=		-e 's|@CONFDIR@|${PKG_SYSCONFDIR}|g'
SUBST_VARS.vars=	DATADIR
SUBST_VARS.vars+=	DBDIR
SUBST_VARS.vars+=	PKGMANDIR
SUBST_VARS.vars+=	PKG_DBDIR
SUBST_VARS.vars+=	PREFIX
SUBST_SED.vars+=	-e 's|@ROOT_USER@|${REAL_ROOT_USER}|g'
SUBST_VARS.vars+=	ID
SUBST_VARS.vars+=	SH

INSTALLATION_DIRS=	${PKGMANDIR}/man8 sbin

CHECK_INTERPRETER_SKIP=	${DATADIR}/wrapper.sh

do-extract:
	${CP} ${FILESDIR}/pkg_alternatives.sh ${WRKSRC}
	${CP} ${FILESDIR}/pkg_alternatives.8 ${WRKSRC}
	${CP} ${FILESDIR}/wrapper.sh ${WRKSRC}
	${CP} ${FILESDIR}/wrapper.man ${WRKSRC}
	${CP} ${FILESDIR}/filter.conf ${WRKSRC}

do-install:
	${INSTALL_SCRIPT} ${WRKSRC}/pkg_alternatives.sh \
		${DESTDIR}${PREFIX}/sbin/pkg_alternatives
	${INSTALL_MAN} ${WRKSRC}/pkg_alternatives.8 \
		${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/
	${INSTALL_DATA_DIR} ${DESTDIR}${DATADIR}
	${INSTALL_DATA} ${WRKSRC}/wrapper.sh ${DESTDIR}${DATADIR}/
	${INSTALL_DATA} ${WRKSRC}/wrapper.man ${DESTDIR}${DATADIR}/
	${INSTALL_DATA_DIR} ${DESTDIR}${EGDIR}
	${INSTALL_DATA} ${WRKSRC}/filter.conf ${DESTDIR}${EGDIR}/

.include "../../mk/bsd.pkg.mk"