This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: Filename case-sensitivity of make


Hi Erik,

Unix has case-sensitive file names, NT/2000 has case-sensitive file names,
just 95/98/Me is incapable of it. So what would you expect using a Unix tool
? Cygwin make *has to be* case-sensitive!

>A am jusing Cygwin make (in UNIX mode) on a WinNT platform. 
>Until now I a
>have defined all rules explicitly like
>
>main.o: main.c
>      gcc -c main.c
>
>which is case-insensitive regarding the source file.

This makes *me* nervous ...

> However, 
>an implicit
>rule like
>
>%.o: %.c
>      gcc -c $*.c
>
>seems to be case-sensitive. This gives problems when sharing 
>source files
>between computers with WinNT and Win95, as Win95 sometimes 
>changes the case
>of the filenames. Is there any particular reason for this 
>strange behaviour?

This is what I would have expectet in *any* case.

I reproduced following effects with 2000:
Having the files main.c, HELLO.C, and this.c and your makefile above
make main.o => Compiles with explicit rule
make this.o => Compiles with implicit rule
make hello.o => No rule
make HELLO.o => Compiles with *predefined* implicit rule
make -r HELLO.o => No rule

IMHO this differences are by chance. It may depend whether make checks its
files with fstat to compare the time stamp or by name using the directory
entry. I am sure that both variants are used in make (no, I have not looked
at the source). With Unix it does not make any difference, while ftstat will
find the file in NT/2000 independent of the case.

Greetings,
Jörg

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]