| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | # $NetBSD: print-plist.mk,v 1.28 2016/04/10 15:58:03 joerg Exp $ | | 1 | # $NetBSD: print-plist.mk,v 1.29 2016/05/04 11:17:41 jperkin Exp $ |
2 | | | 2 | |
3 | ### | | 3 | ### |
4 | ### Automatic PLIST generation | | 4 | ### Automatic PLIST generation |
5 | ### - files & symlinks first | | 5 | ### - files & symlinks first |
6 | ### - empty directories are handled properly | | 6 | ### - empty directories are handled properly |
7 | ### - dirs from mtree files are excluded | | 7 | ### - dirs from mtree files are excluded |
8 | ### - substitute for platform or package specifics substrings | | 8 | ### - substitute for platform or package specifics substrings |
9 | ### | | 9 | ### |
10 | ### Usage: | | 10 | ### Usage: |
11 | ### - make install | | 11 | ### - make install |
12 | ### - make print-PLIST | brain >PLIST | | 12 | ### - make print-PLIST | brain >PLIST |
13 | ### | | 13 | ### |
14 | | | 14 | |
| @@ -116,26 +116,27 @@ print-PLIST: | | | @@ -116,26 +116,27 @@ print-PLIST: |
116 | if ('$$genlinks') print $$0; \ | | 116 | if ('$$genlinks') print $$0; \ |
117 | sub("\\.[0-9]+$$", ""); \ | | 117 | sub("\\.[0-9]+$$", ""); \ |
118 | if ('$$genlinks') print $$0; \ | | 118 | if ('$$genlinks') print $$0; \ |
119 | next; \ | | 119 | next; \ |
120 | } \ | | 120 | } \ |
121 | /.*\/lib[^\/]+\.so\.[0-9]+\.[0-9]+$$/ { \ | | 121 | /.*\/lib[^\/]+\.so\.[0-9]+\.[0-9]+$$/ { \ |
122 | print $$0; \ | | 122 | print $$0; \ |
123 | sub("\\.[0-9]+$$", ""); \ | | 123 | sub("\\.[0-9]+$$", ""); \ |
124 | if ('$$genlinks') print $$0; \ | | 124 | if ('$$genlinks') print $$0; \ |
125 | sub("\\.[0-9]+$$", ""); \ | | 125 | sub("\\.[0-9]+$$", ""); \ |
126 | if ('$$genlinks') print $$0; \ | | 126 | if ('$$genlinks') print $$0; \ |
127 | next; \ | | 127 | next; \ |
128 | } \ | | 128 | } \ |
| | | 129 | /^man\// { sub("\\.gz$$", ""); } \ |
129 | { print $$0; }' | | 130 | { print $$0; }' |
130 | ${RUN}\ | | 131 | ${RUN}\ |
131 | for i in `${_PRINT_PLIST_DIRS_CMD} \ | | 132 | for i in `${_PRINT_PLIST_DIRS_CMD} \ |
132 | | ${SORT} -r \ | | 133 | | ${SORT} -r \ |
133 | | ${AWK} ' \ | | 134 | | ${AWK} ' \ |
134 | /emul\/linux\/proc/ { next; } \ | | 135 | /emul\/linux\/proc/ { next; } \ |
135 | /${DESTDIR:S|/|\\/|g:S/+/\\\\+/g}${PREFIX:S|/|\\/|g}\/\.$$/ { next; } \ | | 136 | /${DESTDIR:S|/|\\/|g:S/+/\\\\+/g}${PREFIX:S|/|\\/|g}\/\.$$/ { next; } \ |
136 | /${PKG_DBDIR:S|/|\\/|g}\// { next; } \ | | 137 | /${PKG_DBDIR:S|/|\\/|g}\// { next; } \ |
137 | { sub("${DESTDIR:S/+/\\\\\\+/g}${PREFIX}/\\\\./", ""); } \ | | 138 | { sub("${DESTDIR:S/+/\\\\\\+/g}${PREFIX}/\\\\./", ""); } \ |
138 | { sub("^${PKGINFODIR}/", "info/"); } \ | | 139 | { sub("^${PKGINFODIR}/", "info/"); } \ |
139 | { sub("^${PKGMANDIR}/", "man/"); } \ | | 140 | { sub("^${PKGMANDIR}/", "man/"); } \ |
140 | /^${PKG_DBDIR:S|^${PREFIX}/||:S|/|\\/|g}(\/|$$)/ { next; } \ | | 141 | /^${PKG_DBDIR:S|^${PREFIX}/||:S|/|\\/|g}(\/|$$)/ { next; } \ |
141 | /^${PKGINFODIR:S|/|\\/|g}$$/ { next; }'` ; \ | | 142 | /^${PKGINFODIR:S|/|\\/|g}$$/ { next; }'` ; \ |