diff options
author | rillig <rillig@pkgsrc.org> | 2007-09-13 09:44:58 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2007-09-13 09:44:58 +0000 |
commit | c7873e00e24f1836a4c46ada05fcc80c43bf3cf4 (patch) | |
tree | fcec3806fd3bd509ac0cc926b37746090fde3bac /mk/install | |
parent | 5da7af336a2f244e84551632e0498abd7d63285e (diff) | |
download | pkgsrc-c7873e00e24f1836a4c46ada05fcc80c43bf3cf4.tar.gz |
It has always annoyed be that package authors had to write ${PKGMANDIR}/
in the definition of INSTALLATION_DIRS, where a short man/ would be much
shorter. Since we already have that man-transforming magic in some other
places of pkgsrc, it's also here.
While here, documented INSTALLATION_DIRS and
INSTALLATION_DIRS_FROM_PLIST so they are found by "bmake help".
Diffstat (limited to 'mk/install')
-rw-r--r-- | mk/install/install.mk | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/mk/install/install.mk b/mk/install/install.mk index 06c31e3be27..3d344ff0e2f 100644 --- a/mk/install/install.mk +++ b/mk/install/install.mk @@ -1,4 +1,4 @@ -# $NetBSD: install.mk,v 1.46 2007/08/14 23:59:25 joerg Exp $ +# $NetBSD: install.mk,v 1.47 2007/09/13 09:44:58 rillig Exp $ # # This file provides the code for the "install" phase. # @@ -20,6 +20,20 @@ # This hook is placed _before_ switching to privileged mode # in order to install the package. # +# === Package-settable variables === +# +# INSTALLATION_DIRS +# A list of directories that should be created at the very +# beginning of the install phase. These directories are relative +# to ${PREFIX}. As a convenience, a leading man/ is transformed +# to ${PKGMANDIR}, to save package authors from typing too much. +# +# INSTALLATION_DIRS_FROM_PLIST +# In most (or even all?) cases the PLIST files in the package +# directory already contain all directories that are needed. +# When this variable is set to "yes", all directories mentioned +# in the PLIST files will be created like in INSTALLATION_DIRS. +# ###################################################################### ### install (PUBLIC) @@ -231,7 +245,7 @@ install-makedirs: .if defined(INSTALLATION_DIRS) && !empty(INSTALLATION_DIRS) @${STEP_MSG} "Creating installation directories" ${RUN} \ - for dir in ${INSTALLATION_DIRS}; do \ + for dir in ${INSTALLATION_DIRS:C,^man/,${PKGMANDIR}/,}; do \ case "$$dir" in \ ${PREFIX}/*) \ dir=`${ECHO} "$$dir" | ${SED} "s|^${PREFIX}/||"` ;; \ |