pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Wip/rc.subr, was: pkgtools/rc.subr doesn't honour the RCD_SCRIPTS_DIR option
[added reed%NetBSD.org@localhost to the conversation]
---------- Original message ----------
From: Ottavio Caruso <ottavio2006-degen%yahoo.com@localhost>
Date: 11 January 2018 at 11:59
Subject: pkgtools/rc.subr doesn't honour the RCD_SCRIPTS_DIR optionE
To: pkgsrc-users%netbsd.org@localhost, sbd%netbsd.org@localhost
On a LMDE2 system with pkgsrc bootstrapped as --unprivileged (maybe
that is the reason?) I want the package to be installed in
/home/oc/pkg/etc/rc.d, not the canonical /etc/rc.cd
--------------------------------------------------------------------
<skip>
I have reached a slightly better outcome with rc.subr from wip:
$ ~/pkgsrc-current/wip/rc.subr $ bmake install
===> Skipping vulnerability checks.
WARNING: No /home/oc/pkg/pkgdb/pkg-vulnerabilities file found.
WARNING: To fix run: `/home/oc/pkg/sbin/pkg_admin -K
/home/oc/pkg/pkgdb fetch-pkg-vulnerabilities'.
===> Installing dependencies for rc.subr-20030912
=> Build dependency cwrappers>=20150314: found cwrappers-20171108
===> Overriding tools for rc.subr-20030912
===> Extracting for rc.subr-20030912
/bin/sed -e s!@NICE@!!g -e s!@OPSYS@!Linux!g -e s!@PS@!/bin/ps!g
-e s!@PS_ARG@!\"ax\"!g -e s!@PS_FORMAT@!\"-o\ pid,command\"!g -e
s!@WHOAMI@!/usr/bin/whoami!g -e s!@PREFIX@!/home/oc/pkg!g -e
s!@LOCALBASE@!/home/oc/pkg!g -e s!@X11BASE@!/home/oc/pkg!g -e
s!@VARBASE@!/home/oc/pkg/var!g -e
s!@PKG_SYSCONFBASE@!/home/oc/pkg/etc!g -e
s!@PKG_SYSCONFBASEDIR@!/home/oc/pkg/etc!g -e
s!@PKG_SYSCONFDIR@!/home/oc/pkg/etc!g -e s!@CONF_DEPENDS@!!g -e
s!@PKGBASE@!rc.subr!g -e s!@PKG_USER_HOME@!/nonexistent!g -e
s!@PKG_USER_SHELL@!/bin/false!g -e s!@RCD_SCRIPTS_SHELL@!/bin/bash!g
-e s!@LDCONFIG_ADD_CMD@!/sbin/ldconfig!g -e
s!@LDCONFIG_REMOVE_CMD@!/sbin/ldconfig!g -e
s!@X11_ENCODINGSDIR@!/home/oc/pkg/share/fonts/X11/encodings!g -e
s!@PKG_CREATE_USERGROUP@!NO!g -e s!@PKG_CONFIG@!YES!g -e
s!@PKG_CONFIG_PERMS@!NO!g -e s!@PKG_RCD_SCRIPTS@!NO!g -e
s!@PKG_REGISTER_SHELLS@!NO!g -e s!@PKG_UPDATE_FONTS_DB@!YES!g -e
s!@FONTS_VERBOSE@!NO!g -e s!@INFO_FILES_VERBOSE@!NO!g -e
s!@OCAML_FINDLIB_REGISTER_VERBOSE@!NO!g -e
s!@AWK@!/home/oc/pkg/bin/nawk!g -e s!@BASENAME@!/usr/bin/basename!g
-e s!@CAT@!/bin/cat!g -e s!@CHGRP@!true!g -e s!@CHMOD@!/bin/chmod!g
-e s!@CHOWN@!true!g -e s!@CMP@!/usr/bin/cmp!g -e s!@CP@!/bin/cp!g
-e s!@DIRNAME@!/usr/bin/dirname!g -e s!@ECHO@!echo!g -e
s!@ECHO_N@!echo\ -n!g -e s!@EGREP@!/bin/egrep!g -e
s!@EXPR@!/usr/bin/expr!g -e s!@FALSE@!false!g -e
s!@FIND@!/usr/bin/find!g -e s!@GREP@!/bin/grep!g -e
s!@GROUPADD@!/usr/sbin/groupadd!g -e s!@GTAR@!!g -e
s!@HEAD@!/usr/bin/head!g -e s!@ID@!/usr/bin/id!g -e
s!@INSTALL_INFO@!!g -e s!@LINKFARM@!/home/oc/pkg/sbin/linkfarm!g -e
s!@LN@!/bin/ln!g -e s!@LS@!/bin/ls!g -e s!@MKDIR@!/bin/mkdir\ -p!g
-e s!@MV@!/bin/mv!g -e s!@OCAML_FINDLIB_DIRS@!!g -e
s!@OCAML_SITELIBDIR@!!g -e s!@PERL5@!/home/oc/pkg/bin/perl!g -e
s!@PKG_ADMIN@!/home/oc/pkg/sbin/pkg_admin!g -e
s!@PKG_INFO@!/home/oc/pkg/sbin/pkg_info!g -e s!@PW@!!g -e
s!@PWD_CMD@!/bin/pwd!g -e s!@RM@!/bin/rm!g -e s!@RMDIR@!/bin/rmdir!g
-e s!@SED@!/bin/sed!g -e s!@SETENV@!/usr/bin/env!g -e
s!@SH@!/bin/bash!g -e s!@SORT@!/usr/bin/sort!g -e s!@SU@!/bin/su!g
-e s!@TEST@!test!g -e s!@TOUCH@!/bin/touch!g -e s!@TR@!/usr/bin/tr!g
-e s!@TRUE@!true!g -e s!@USERADD@!/usr/sbin/useradd!g -e
s!@XARGS@!/usr/bin/xargs\ -r!g
/home/oc/pkgsrc-current/wip/rc.subr/files/rc.subr >
/home/oc/pkgsrc-current/wip/rc.subr/work/rc.subr
===> Patching for rc.subr-20030912
===> Creating toolchain wrappers for rc.subr-20030912
=> Creating /home/oc/pkgsrc-current/wip/rc.subr/work/.rc.d/DAEMON
=> Creating /home/oc/pkgsrc-current/wip/rc.subr/work/.rc.d/LOGIN
=> Creating /home/oc/pkgsrc-current/wip/rc.subr/work/.rc.d/NETWORKING
=> Creating /home/oc/pkgsrc-current/wip/rc.subr/work/.rc.d/SERVERS
===> Installing for rc.subr-20030912
=> Generating pre-install file lists
/usr/bin/install -d -o oc -g oc -m 755
/home/oc/pkgsrc-current/wip/rc.subr/work/.destdir/home/oc/pkg/share/examples/rc.subr
/usr/bin/install -c -o oc -g oc -m 644
/home/oc/pkgsrc-current/wip/rc.subr/files/rc.conf.example
/home/oc/pkgsrc-current/wip/rc.subr/work/.destdir/home/oc/pkg/share/examples/rc.subr
/usr/bin/install -c -o oc -g oc -m 644
/home/oc/pkgsrc-current/wip/rc.subr/work/rc.subr
/home/oc/pkgsrc-current/wip/rc.subr/work/.destdir/home/oc/pkg/share/examples/rc.subr
=> Automatic manual page handling
=> Generating post-install file lists
=> Checking file-check results for rc.subr-20030912
=> Creating binary package
/home/oc/pkgsrc-current/wip/rc.subr/work/.packages/rc.subr-20030912.tgz
===> Building binary package for rc.subr-20030912
=> Creating binary package
/home/oc/pkgsrc-current/packages/All/rc.subr-20030912.tgz
===> Installing binary package of rc.subr-20030912
/bin/mkdir: cannot create directory ‘/etc/rc.d’: Permission denied
rc.subr-20030912: copying
/home/oc/pkg/share/examples/rc.subr/rc.conf.example to
/home/oc/pkg/etc/rc.conf
===========================================================================
The following directories should be created for rc.subr-20030912:
/etc/rc.d
===========================================================================
===========================================================================
The following files should be created for rc.subr-20030912:
/etc/rc.d/SERVERS (m=0755)
[/home/oc/pkg/share/examples/rc.d/SERVERS]
/etc/rc.d/NETWORKING (m=0755)
[/home/oc/pkg/share/examples/rc.d/NETWORKING]
/etc/rc.d/LOGIN (m=0755)
[/home/oc/pkg/share/examples/rc.d/LOGIN]
/etc/rc.d/DAEMON (m=0755)
[/home/oc/pkg/share/examples/rc.d/DAEMON]
===========================================================================
The package still wants to write to /etc/rc.d, but this time all other
files are in pkg/share/examples/rc.d/, which in my opinion is a
cleaner option, especially on Linux.
--
Ottavio Caruso
Home |
Main Index |
Thread Index |
Old Index