# HG changeset patch # User Aleksej Bobylev # Date 1522459356 -10800 # Node ID 25e91fd33194350c62af400ce146611593d78ea3 # Parent 9ea2c08af3efa0c5d8de3235b95e04c2c0262e29 cook: copy(): better way to copy empty folders, exclude *.la from @dev; lighttpd/index.cgi: exclude *.la from @dev diff -r 9ea2c08af3ef -r 25e91fd33194 cook --- a/cook Mon Mar 26 23:46:58 2018 +0300 +++ b/cook Sat Mar 31 04:22:36 2018 +0300 @@ -1482,7 +1482,7 @@ ;; @dev) # Copy "developer files" - sed -n '/\.h$/p; /\.hxx$/p; /\.a$/p; /\.la$/p; /\.pc$/p; /\.pri$/p; /bin\/.*-config$/p; + sed -n '/\.h$/p; /\.hxx$/p; /\.a$/p; /\.pc$/p; /\.pri$/p; /bin\/.*-config$/p; /\.m4$/p; /\.gir$/p; /\.typelib$/p; /\.vapi$/p; /\.deps$/p; /\.cmake$/p; /\/Makefile.*/p; /\.inc$/p; /\/include\//p; /\.so\.dbg$/p; @@ -1520,8 +1520,7 @@ @std) while read j; do case $j in - # always skip empty man & doc folders, because this will end up - # copying all the man pages and docs to the package + # skip empty man & doc folders */man/*|*/doc/*) continue;; esac [ -z "$(ls -A "$install$j")" ] || continue @@ -1536,8 +1535,14 @@ done \ | tac \ | while read k; do - # copy dir with its original ownership/permissions if it does not exist - [ -d "$fs$k" ] || cp -a "$install$k" "$fs$k" + # make dir if it does not exist + if [ ! -d "$fs$k" ]; then + # It's like "copy the directory without it's underlying content". + # keep original ownership/permissions, access: + install -d $(stat -c'-o%u -g%g -m%a' "$install$k") "$fs$k" + # keep last-modified date: + touch -r "$install$k" "$fs$k" + fi done done < $folderlist ;; diff -r 9ea2c08af3ef -r 25e91fd33194 lighttpd/index.cgi --- a/lighttpd/index.cgi Mon Mar 26 23:46:58 2018 +0300 +++ b/lighttpd/index.cgi Sat Mar 31 04:22:36 2018 +0300 @@ -1641,7 +1641,7 @@ printf("%s\n", $0); } /\/perllocal.pod$/ || /\/\.packlist$/ || /\/share\/bash-completion\// || - /\/lib\/systemd\// || /\.pyc$/ || /\.pyo$/ || /\/fonts\.scale$/ || /\/fonts\.dir$/ { + /\/lib\/systemd\// || /\.pyc$/ || /\.pyo$/ || /\/fonts\.scale$/ || /\/fonts\.dir$/ || /\.la$/ { tag("---", 0); next } /\.pod$/ { tag("pod", 5); next } /\/share\/man\// { tag("man", 5); next } @@ -1649,7 +1649,7 @@ /\/share\/devhelp\// { tag("doc", 5); next } /\/share\/icons\// { tag("ico", 2); next } /\/share\/locale\// { tag("loc", 4); next } - /\.h$/ || /\.a$/ || /\.la$/ || /\.pc$/ || /\/bin\/.*-config$/ || + /\.h$/ || /\.a$/ || /\.pc$/ || /\/bin\/.*-config$/ || /\/Makefile.*$/ { tag("dev", 3); next } /\/share\/help\// || /\/share\/appdata\// { tag("gnm", 6); next } { tag("???", 1) }