Share your knowledge at the LQ Wiki.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 02-18-2004, 02:16 PM   #1
Registered: Jul 2003
Distribution: Slackware 9.1
Posts: 195

Rep: Reputation: 30
Shell commands in GNU make

Was wondering, how can you put a for loop etc. into a makefile so it works?

Something like:

sub:    $(HEADERS)
          for dir in $(SUBDIRS); do @echo $$dir done
Doesn't seem to work for me although i've seen the syntax used elsewhere, all I get is an "unexpected end of file" error from bash.

Anyone got any clues?
Old 02-18-2004, 02:32 PM   #2
Senior Member
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Rep: Reputation: 60
i am sorry i don't have an answer for you, but what i do want to say to you is that you already have this thread going at the below link
and its not against the rules to bump it as its been 24 hours since you posted it, but it is against the rules
to double post ...
just wanted to make you aware of this ...
Old 02-19-2004, 04:36 AM   #3
Registered: Jul 2003
Distribution: Slackware 9.1
Posts: 195

Original Poster
Rep: Reputation: 30
No probs, I just thought this forum was a beter place for it!


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 is GNU and what are the commands? anjum Linux - Software 9 08-03-2005 02:32 PM
make c-program that accepts shell commands and execute them boeroe Programming 4 02-18-2005 08:41 AM
'make' & 'make install commands not recognised by shell gilbertt Linux - Software 4 05-04-2004 08:04 AM
'make' and 'make install' commands dont work on my system? ginda Linux - Newbie 9 04-18-2004 11:17 AM
Shell commands in GNU make? MadCactus Linux - Software 0 02-17-2004 03:11 PM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 04:31 AM.

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