Martin Krischik wrote: >> He said it was 13MB. So my guess is that some script did a >> >> cp foo /usr/local >> >> expected that /usr/local already existed as a directory. >> > This is why the "--target-directory" was invented (at least for gnu's > cp). Very helpful for scripts. Also very helpful is "setopt > Err_Exit" (Z-Shell - for bash some obscure command with "-e"). Just > imagine the cd goes wrong in: > > cd /tmp > grm --force --recursive *(U) > > and Err_Exit is off. (Again Z-Shell - bash does not know about "(U)" - > which would make the command combination even more disastrous).
The Portable Paranoid's version is to use e.g. "cp foo /usr/local/" That will complain if not existing, and use /usr/local// otherwise. But one can't get carried away and use that workaround everywhere... http://trac.macports.org/ticket/13789 (problems with prefix slash) The best is usually if the installation scripts make sure that the directories are created first, which also helps when using DESTDIR: mkdir -p /usr/local cp foo /usr/local --anders _______________________________________________ macports-users mailing list macports-users@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macports-users