LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
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 12-05-2013, 02:31 PM   #1
Linuxlearner122
LQ Newbie
 
Registered: Dec 2013
Posts: 4

Rep: Reputation: Disabled
what is the meaning of LS := /bin/ls?


Can anyone please let me know the meaning of LS := /bin/ls? Especially : in front of =, wht does this mean?
 
Old 12-05-2013, 03:23 PM   #2
mddnix
Member
 
Registered: Mar 2013
Distribution: Redhat, Ubuntu
Posts: 525

Rep: Reputation: 141Reputation: 141
Its called variable substitution. It means, use value of 'LS' if set, otherwise use value '/bin/ls' and also set it to LS.

To make you understand easily, checkout this

Code:
$ VAR1="Howdy! ya fine"
$ echo ${VAR1:="Coool Baby"}
Howdy! ya fine
$ echo $VAR1
Howdy! ya fine

$ VAR2=""
$ echo ${VAR2:="Coool Baby"}
Coool Baby
$ echo $VAR2
Coool Baby
 
1 members found this post helpful.
Old 12-05-2013, 03:31 PM   #3
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978Reputation: 1978
Well, you don't explain where did you find this line of code, but it appears the syntax of a Makefile. If this is the case you can read about the meaning of the different assigments operators here: http://www.gnu.org/software/make/man...e.html#Setting. Most likely the LS variable will be used later in the Makefile and it will be referenced as $(LS). Hope this helps.
 
1 members found this post helpful.
Old 12-05-2013, 04:05 PM   #4
Linuxlearner122
LQ Newbie
 
Registered: Dec 2013
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thanks People. Yes it is from Makefile script. i will check the link for other issue.Thanks Again !!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
What are the meaning and the relevance of #!/bin/bash? ravi_nandula Linux - Newbie 9 03-29-2012 08:31 AM
echo $PATH = /home/g3rc4n/bin:/usr/local/bin:/usr/bin:/bin:/usr/games ? i_heart_pandas Linux - Software 7 09-18-2009 09:33 AM
meaning of suid on /usr/bin/passwd raj k yadav Linux - Newbie 1 01-08-2009 11:52 AM
? meaning of /bin/ls: .: Input/output error JesseMor Linux - Newbie 11 10-28-2008 09:27 PM
sudo /usr/bin/chroot /home/chroot /bin/su - xxx| /bin/su: user xxx does not exist saavik Linux - General 3 07-04-2007 11:30 AM

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

All times are GMT -5. The time now is 03:50 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration