Date: Sun, 10 Jan 1999 13:32:01 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: a j cc: djgpp AT delorie DOT com Subject: Re: fileutils: MV case-sensitive..help? In-Reply-To: <19990108173509.28751.qmail@hotmail.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com On Fri, 8 Jan 1999, a j wrote: > i tried doing a > mv e.c E.C > > in win95/Dos box. > > so its the same filename, but the case is now lower... but it > reply's saying... > > /djgpp/bin/mv: `e.c' and `E.C' are the same file What did you expect? Windows 9X is a case-insensitive filesystem, so you are indeed moving a file into itself. And `mv' is documented to refuse that, so the ported version does that as well. It's not a bug, it's a feature. As far as my experience goes, doing this is ineed dangerous on some Windows 95 systems, as it screws up the short 8+3 alias. > i downloaded the src for mv.c and tried to re-compile it on my > system. Recompiling won't solve this problem, since `mv's source code explicitly checks for the source and destination being the same file, but the test is not based on the file's name, it is based on the information returned by the library function `stat'. If you disable that check, you will open a Pandora box of trouble, because other cases where the the two files are the same (not by the letter case) will not trigger the message as well. > but i get error's > > mv.c:44: config.h: No such file or directory (ENOENT) > mv.c:46: getopt.h: No such file or directory (ENOENT) Be sure to read the docs. The file djgpp/README in the source distribution includes detailed instructions on how to rebuild the package. > i can't run the makefile at > > \djgpp\GNU\FILUTIL3.16\src > > or the makefile.in You aren't supposed to do either of these. djgpp/README tells you what to do. But I really don't see what possible cause could you have for rebuilding the package. I think that there's no bug here.