diff options
author | leot <leot@pkgsrc.org> | 2020-06-10 16:06:09 +0000 |
---|---|---|
committer | leot <leot@pkgsrc.org> | 2020-06-10 16:06:09 +0000 |
commit | 0fc9aa8fdea316d2764bb57a80e1909f11b93009 (patch) | |
tree | ed8b1befe84158a056ee7336f8e537ea67879207 /mk | |
parent | 3147d3c9c0fcb74db4cdacc4b91ba2c3c209e4e3 (diff) | |
download | pkgsrc-0fc9aa8fdea316d2764bb57a80e1909f11b93009.tar.gz |
mk/plist: Add EARLY_PRINT_PLIST_AWK
EARLY_PRINT_PLIST_AWK is like PRINT_PLIST_AWK but operates before the
file/directory lists are sorted.
Discussed on tech-pkg@ mainly to address `print-PLIST' order problems for
Python 3 packages:
<https://mail-index.NetBSD.org/tech-pkg/2020/05/27/msg023249.html>
Diffstat (limited to 'mk')
-rw-r--r-- | mk/plist/plist.mk | 7 | ||||
-rw-r--r-- | mk/plist/print-plist.mk | 8 |
2 files changed, 11 insertions, 4 deletions
diff --git a/mk/plist/plist.mk b/mk/plist/plist.mk index 6fbe6ba7852..d5a906248f2 100644 --- a/mk/plist/plist.mk +++ b/mk/plist/plist.mk @@ -1,4 +1,4 @@ -# $NetBSD: plist.mk,v 1.54 2020/03/30 22:54:24 rillig Exp $ +# $NetBSD: plist.mk,v 1.55 2020/06/10 16:06:09 leot Exp $ # # This Makefile fragment handles the creation of PLISTs for use by # pkg_create(8). @@ -147,8 +147,9 @@ _PLIST_AWK_ENV+= ${PLIST_AWK_ENV} # with the package version excluding the "nb13" extension. # # The other direction of generating the package's PLIST file from the list -# of actually installed files is covered by PRINT_PLIST_AWK. This is only -# needed when developing the package itself, for example after an update. +# of actually installed files is covered by EARLY_PRINT_PLIST_AWK and +# PRINT_PLIST_AWK. This is only needed when developing the package itself, +# for example after an update. # PLIST_SUBST+= OPSYS=${OPSYS:Q} \ OS_VERSION=${OS_VERSION:Q} \ diff --git a/mk/plist/print-plist.mk b/mk/plist/print-plist.mk index 6ed479562bb..8346f477d2f 100644 --- a/mk/plist/print-plist.mk +++ b/mk/plist/print-plist.mk @@ -1,4 +1,4 @@ -# $NetBSD: print-plist.mk,v 1.35 2020/04/18 10:54:21 rillig Exp $ +# $NetBSD: print-plist.mk,v 1.36 2020/06/10 16:06:09 leot Exp $ # # Automatic PLIST generation # - files & symlinks first @@ -94,6 +94,9 @@ print-PLIST: *) genlinks=0 ;; \ esac; \ ${_PRINT_PLIST_FILES_CMD} \ + | ${AWK} ' \ + ${EARLY_PRINT_PLIST_AWK} \ + { print $$0; }' \ | ${_PRINT_PLIST_LIBTOOLIZE_FILTER} \ | ${SORT} \ | ${AWK} ' \ @@ -124,6 +127,9 @@ print-PLIST: { print $$0; }' ${RUN}\ for i in `${_PRINT_PLIST_DIRS_CMD} \ + | ${AWK} ' \ + ${EARLY_PRINT_PLIST_AWK} \ + { print $$0; }' \ | ${SORT} -r \ | ${AWK} ' \ /emul\/linux\/proc/ { next; } \ |