Hi Frank,

Apologies for the delayed response.

You wrote:

> % install -C -p x y
> install: options --compare (-C) and --preserve-timestamps are mutually 
> exclusive
> Try 'install --help' for more information.
>
> [...]
>
> I see no explanation there why these options should be mutually exclusive.
> (RTFS did not reveal any insight either.)
> 
> If the error message is unnecessary, please remove it.
> 
> Otherwise, please provide an explanation why and possible workarounds.
> 
> What I want to achieve is to preserve timestamps and to avoid doing extra 
> work.
> Both goals seem rather natural, and I see no reason why they should not be 
> combined.
> 
> (In fact it seems "-p" should make it *easier* to implement "-C" as
> timestamps will compare equal when nothing's changed. Then again,
> need_copy() doesn't seem to care about times at all, so why should
> it be incompatible with "-p"?)

The rationale for this was posted on the mailing list when the '-C'
option was introduce. Here is the relevant text [1]:

> With this option install checks an existing destination file and if it is not 
> different (by content, owner, group and mode) from source, the file is not 
> installed. Preserving destination's original mtime can significantly decrease 
> time of building when a system library is reinstalled but the header files 
> are not changed at all.

I'm not sure if that is still the case today.

I think I am okay with allowing the combination, but lets see if anyone
else has differing opinions. I might be missing some history here.

Collin

[1] https://lists.gnu.org/archive/html/bug-coreutils/2009-01/msg00122.html



Reply via email to