LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Makefile case sensitive (https://www.linuxquestions.org/questions/linux-newbie-8/makefile-case-sensitive-4175451360/)

smaartguy 02-23-2013 01:33 AM

Makefile case sensitive
 
Hi
I am writing a make file to build files. Inside makefile, i mentioned file names in lower case. While the actual files on system are in Uppercase.

While executing makefile, i get error for different file names.

Is it possible to make makefile case insensitive and execute it.

shivaa 02-23-2013 01:41 AM

Hope you know that files in Unix are case-sensitive. So first thing is, why did you mention filenames in lower case when they are originally in Upper or mixed cases?

Anyway, you can translate lower with upper and vice-versa (but I will do it for whole file).
Code:

~$ cat makefile | tr '[[:upper:]]' '[[:lower:]]'
If you want to for only some part of the file, then share that snippet.

theNbomr 02-23-2013 01:25 PM

My friend's name is John. Whenever I call him Fed, he thinks I'm talking to someone else. How can I make him respond when I call him by some other name?

The Linux filesystem is case-sensitive. Nothing you do in the Makefile will get you around that. It is a Good Thing(TM). Embrace it.

--- rod.

John VV 02-23-2013 05:08 PM

Pick a naming convention and stick with it
fileone.cpp
FileOne.cpp ( what i use)
file_one.cpp( not recommended the "_" can be hard to read)

now some serves ( as in a mainframe ) use only UPPERCASE file names
FILEONE.CPP


All times are GMT -5. The time now is 04:23 PM.