LinuxQuestions.org
Visit Jeremy's Blog.
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 01-18-2008, 12:19 AM   #1
Ashok_mittal
Member
 
Registered: Dec 2007
Posts: 73

Rep: Reputation: 15
Unhappy Makefile:How to use cat command


I am making a Makefile where i am doing this

empty:=
comma:=,
space:= $(empty) $(empty)
text:=a b c
all:
text1=$(subst $(space),$(comma),$(text))

Now i want to write the value of text1 in a file result in current directory so i write this
$(cat >&result<<text1)
but this is not working. What code should i write to get the result.
 
Old 01-18-2008, 07:38 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian stable
Posts: 5,908

Rep: Reputation: 356Reputation: 356Reputation: 356Reputation: 356
Something like
Code:
$(cat test1 > result)
to write the file, or
Code:
$(cat test1 >> result)
to append to the file.
 
  


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
CAT Command ouncya Linux - Newbie 11 08-25-2007 11:48 PM
Cat and Sed Command Help. vidyashankara Linux - General 22 06-23-2006 01:32 PM
cat command juanb Linux - Newbie 4 08-19-2004 11:14 AM
what are the limits to the 'cat' command? Frybyte Linux - General 12 04-22-2004 04:32 PM
cat Command Moeses Linux - General 1 06-20-2002 03:27 AM

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

All times are GMT -5. The time now is 07:33 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