diff options
author | Jim Meyering <meyering@redhat.com> | 2008-08-26 18:43:52 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2008-08-26 18:43:52 +0200 |
commit | f03a67735a3143ff684fc0ddf4d4c4477019f079 (patch) | |
tree | e0f67a3236adfbfca3e31207a7e91457648e37a9 | |
parent | f325d180cf444f399f4e31aab5cbe615f4b73e65 (diff) | |
download | coreutils-f03a67735a3143ff684fc0ddf4d4c4477019f079.tar.xz |
bootstrap: preserve permissions of more copied files
* bootstrap (cp_mark_as_generated): Preserve perms of copied files.
Remove a kludge, now that this is fixed.
-rwxr-xr-x | bootstrap | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -383,9 +383,13 @@ cp_mark_as_generated() if test -z "$c1"; then cmp -s "$cp_src" "$cp_dst" || { + # Copy the file first to get proper permissions if it + # doesn't already exist. Then overwrite the copy. echo "$0: cp -f $cp_src $cp_dst" && rm -f "$cp_dst" && - sed "s!$bt_regex/!!g" "$cp_src" > "$cp_dst" + cp "$cp_src" "$cp_dst-t" && + sed "s!$bt_regex/!!g" "$cp_src" > "$cp_dst-t" && + mv -f "$cp_dst-t" "$cp_dst" } else # Copy the file first to get proper permissions if it @@ -610,7 +614,4 @@ m=gnulib-tests/gnulib.mk sed 's,\.\./\.\.,..,g' $m > $m-t mv -f $m-t $m -# Make tests executable. -chmod a+x gnulib-tests/test-*.sh - echo "$0: done. Now you can run './configure'." |