Add dconf database management support fragments.

This commit is contained in:
obache 2014-05-25 06:06:00 +00:00
parent 227aca6633
commit b65e5deb58
2 changed files with 40 additions and 0 deletions

23
devel/dconf/database.mk Normal file
View file

@ -0,0 +1,23 @@
# $NetBSD: database.mk,v 1.1 2014/05/25 06:06:00 obache Exp $
#
# This Makefile fragment is intended to be included by packages that install
# dconf database. It takes care of update the corresponding databases
# at (de)installation time.
#
.if !defined(DCONF_DATABASE_MK)
DCONF_DATABASE_MK= # defined
EVAL_PREFIX+= BUILDLINK_PREFIX.dconf=dconf
DCONF= ${BUILDLINK_PREFIX.dconf}/bin/dconf
FILES_SUBST+= DCONF=${DCONF:Q}
INSTALL_TEMPLATES+= ../../devel/dconf/files/database.tmpl
DEINSTALL_TEMPLATES+= ../../devel/dconf/files/database.tmpl
TOOLS_NOOP+= dconf
DEPENDS+= dconf-[0-9]*:../../devel/dconf
.endif # DCONF_DATABASE_MK

View file

@ -0,0 +1,17 @@
# $NetBSD: database.tmpl,v 1.1 2014/05/25 06:06:00 obache Exp $
#
# Update the dconf database.
#
DCONF="@DCONF@"
case "${STAGE}" in
POST-INSTALL)
${DCONF} update
;;
POST-DEINSTALL)
${DCONF} update
;;
*)
;;
esac