LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-23-2013, 01:33 AM   #1
smaartguy
LQ Newbie
 
Registered: Feb 2013
Posts: 2

Rep: Reputation: Disabled
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.
 
Old 02-23-2013, 01:41 AM   #2
shivaa
Senior Member
 
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
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.
 
Old 02-23-2013, 01:25 PM   #3
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,399
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
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.
 
Old 02-23-2013, 05:08 PM   #4
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
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
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
case sensitive directory moiseszaragoza Linux - Newbie 2 12-14-2010 10:53 AM
Apache 2.x case-sensitive jarias Linux - Newbie 2 05-15-2009 05:11 PM
Copying files from case-sensitive Linux to case-insensitive Windows via CIFS? SlowCoder Linux - General 4 05-07-2008 07:03 PM
is apache case-sensitive? browny_amiga Linux - Software 2 06-21-2004 01:57 PM
Why is linux case sensitive? Jestrik Linux - General 9 12-16-2003 07:05 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:49 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration