diff options
author | antoine <antoine@FreeBSD.org> | 2014-09-02 01:06:19 +0800 |
---|---|---|
committer | antoine <antoine@FreeBSD.org> | 2014-09-02 01:06:19 +0800 |
commit | e44e200e66d70c8ac399c7fdfe36b029482fd6f1 (patch) | |
tree | 30b9f411ae0f09270332ca8a1c3f95470871f870 /Mk/Scripts | |
parent | d7a45dba15aa14e693a6e4d4c52b048451f3ccd0 (diff) | |
download | freebsd-ports-gnome-e44e200e66d70c8ac399c7fdfe36b029482fd6f1.tar.gz freebsd-ports-gnome-e44e200e66d70c8ac399c7fdfe36b029482fd6f1.tar.zst freebsd-ports-gnome-e44e200e66d70c8ac399c7fdfe36b029482fd6f1.zip |
- Make it possible to use sample keyword with a full path
- Prefer @dirrmtry over @unexec rmdir in makeplist
Differential Revision: https://reviews.freebsd.org/D705
Reviewed by: bapt
With hat: portmgr
Diffstat (limited to 'Mk/Scripts')
-rw-r--r-- | Mk/Scripts/check-stagedir.sh | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/Mk/Scripts/check-stagedir.sh b/Mk/Scripts/check-stagedir.sh index d7bb5f566f4c..092e38fa47b0 100644 --- a/Mk/Scripts/check-stagedir.sh +++ b/Mk/Scripts/check-stagedir.sh @@ -73,8 +73,16 @@ parse_plist() { set -- $line shift # Ignore the actual file if it is in stagedir + case "$@" in + /*) + echo "@comment ${@%.sample}" + echo "${comment}$@" + ;; + *) echo "@comment ${cwd}/${@%.sample}" echo "${comment}${cwd}/$@" + ;; + esac ;; # Handle [dirrmty] Keywords @fc\ *|@fcfontsdir\ *|@fontsdir\ *) @@ -234,13 +242,11 @@ setup_plist_seds() { ${sed_portdocsexamples} /^share\/licenses/d;" sed_dirs_gen="s!${PREFIX}/!!g; ${sed_plist_sub} s,^,@dirrmtry ,; \ ${sed_portdocsexamples} \ - s!@dirrmtry \(/.*\)!@unexec rmdir \"\1\" >/dev/null 2>\&1 || :!; \ /^@dirrmtry share\/licenses/d;" # These prevent ignoring DOCS/EXAMPLES dirs with sed_portdocsexamples sed_files="s!${PREFIX}/!!g; ${sed_plist_sub} /^share\/licenses/d;" sed_dirs="s!${PREFIX}/!!g; ${sed_plist_sub} s,^,@dirrmtry ,; \ - s!@dirrmtry \(/.*\)!@unexec rmdir \"\1\" >/dev/null 2>\&1 || :!; \ /^@dirrmtry share\/licenses/d;" } @@ -334,7 +340,7 @@ check_invalid_directories_mtree() { if [ "${PREFIX}" != "${LOCALBASE}" ]; then case "${line}" in "@dirrmtry info") continue ;; - "@unexec rmdir \"${PREFIX}\" >/dev/null 2>&1 || :") continue ;; + "@dirrmtry ${PREFIX}") continue ;; esac fi ret=1 |