blob: 95d8bab3067e9bf4751e9eb278e04cd3609dc03a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
|
# $NetBSD: Makefile,v 1.14 2003/03/29 12:42:33 jmmv Exp $
#
DISTNAME= sysbuild-1.9
WRKSRC= ${WRKDIR}
CATEGORIES= sysutils
MASTER_SITES= # empty
DISTFILES= # empty
MAINTAINER= jmmv@netbsd.org
COMMENT= Automate NetBSD system and kernel unprivileged builds
EXTRACT_ONLY= # empty
NO_CHECKSUM= yes
NO_CONFIGURE= yes
CHECK_SHLIBS= no
SHLIB_HANDLING= no
.include "../../mk/bsd.prefs.mk"
# SYSBUILD_HOME - Home directory of SYSBUILD_USER user.
SYSBUILD_HOMEDIR?= /home/sysbuild
# SYSBUILD_USER - Unpriviledged user that runs the build script.
SYSBUILD_USER?= sysbuild
# SYSBUILD_OBJGROUP - Group that owns build files (should not be shared).
SYSBUILD_OBJGROUP?= wobj
# SYSBUILD_SRCGROUP - Group that owns sources (may be shared).
SYSBUILD_SRCGROUP?= wsrc
FILES_SUBST+= SYSBUILD_HOMEDIR=${SYSBUILD_HOMEDIR}
FILES_SUBST+= SYSBUILD_USER=${SYSBUILD_USER}
FILES_SUBST+= SYSBUILD_OBJGROUP=${SYSBUILD_OBJGROUP}
FILES_SUBST+= SYSBUILD_SRCGROUP=${SYSBUILD_SRCGROUP}
FILES_SUBST+= EGDIR=${EGDIR}
MESSAGE_SUBST+= SYSBUILD_USER=${SYSBUILD_USER}
USE_PKGINSTALL= yes
DEINSTALL_EXTRA_TMPL= ${.CURDIR}/INSTALL
INSTALL_EXTRA_TMPL= ${.CURDIR}/INSTALL
PKG_GROUPS= ${SYSBUILD_OBJGROUP} ${SYSBUILD_SRCGROUP}
PKG_USERS= ${SYSBUILD_USER}:${SYSBUILD_OBJGROUP}::`hostname`\\ sysbuild\\ output:${SYSBUILD_HOMEDIR}:${SH}
EGDIR= ${PREFIX}/share/examples/sysbuild
do-build:
@${ECHO} "Generating sysbuild.sh..."
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/sysbuild.sh > \
${WRKSRC}/sysbuild.sh
@${ECHO} "Generating sysbuild.8..."
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/sysbuild.8 > \
${WRKSRC}/sysbuild.8
@${ECHO} "Generating sample default.conf..."
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/default.conf > \
${WRKSRC}/default.conf
@${ECHO} "Generating sample crontab..."
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/crontab > ${WRKSRC}/crontab
@${ECHO} "Generating sample profile..."
@${SED} ${FILES_SUBST_SED} ${FILESDIR}/profile > ${WRKSRC}/profile
do-install:
${INSTALL_DATA_DIR} ${PREFIX}/share/examples/sysbuild
${INSTALL_SCRIPT} ${WRKSRC}/sysbuild.sh ${PREFIX}/bin/sysbuild
${INSTALL_MAN} ${WRKSRC}/sysbuild.8 ${PREFIX}/man/man8/sysbuild.8
${INSTALL_DATA} ${WRKSRC}/default.conf ${EGDIR}/default.conf
${INSTALL_DATA} ${WRKSRC}/crontab ${EGDIR}/crontab
${INSTALL_DATA} ${WRKSRC}/profile ${EGDIR}/profile
.include "../../mk/bsd.pkg.mk"
|