LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 09-05-2011, 03:39 AM   #1
conflicker
Member
 
Registered: Sep 2011
Posts: 92

Rep: Reputation: Disabled
*** make error


"*** make: No rule to make target `5 Sep 2011.mp3', needed by `mp3'. Stop."
This is the error when i use to run a script that convert .gsm file to .mp3..
Kindly look for the Makefile that i created:

DIRWAV = $(shell dir *.wav)
ALLWAV = $(DIRWAV:.wav=.mp3)
DIRGSM = $(shell dir *.gsm)
ALLGSM = $(DIRGSM:.gsm=.mp3)
mp3: $(ALLWAV) $(ALLGSM)
%.mp3: %.wav
nice lame --quiet --preset phone $? $@
rm -f $?
%.wav: %.gsm
nice sox $? -r 8000 -c 1 -w -s $@
rm -f $?
clean:
rm -f *.mp3
rm -f *.wav
rm -f *.raw
rm -f *.gsm
cp /dir/dir/dir/dir/*.wav .
cp /dir/dir/dir/dir/a*.gsm .
Please help on how to fix it..thanks..
 
Old 09-05-2011, 04:09 AM   #2
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Hi and Welcome to LQ!
Do you really need to use "make" on a (bash?) script?
jdk
 
Old 09-05-2011, 04:35 AM   #3
conflicker
Member
 
Registered: Sep 2011
Posts: 92

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by jdkaye View Post
Hi and Welcome to LQ!
Do you really need to use "make" on a (bash?) script?
jdk
Hi thanks for the reply..ahmm
i use to type "make" on the CLI and it gaves me the error.
It supposed to execute the nice command base on the script..
but when i try to type the script manually on the CLI
it allow me to convert .gsm to .mp3 without any error..
 
Old 09-05-2011, 04:37 AM   #4
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Don't use make with a script. Read this: http://linux.about.com/od/itl_guide/a/gdeitl55t04.htm
ciao,
jdk

Last edited by jdkaye; 09-05-2011 at 04:40 AM.
 
Old 09-05-2011, 06:30 AM   #5
conflicker
Member
 
Registered: Sep 2011
Posts: 92

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by jdkaye View Post
Don't use make with a script. Read this: http://linux.about.com/od/itl_guide/a/gdeitl55t04.htm
ciao,
jdk
I already got the problem..
this script is perfectly working on the old server but it got an error when I'am on the new server..the only reason that gives me an error is the quote..
i try to convert file with no spaces..and it works..
but when i try another file with spaces it gave me an error..

do u have any idea on how to fix the quote problem? I'm just wondering if there's an application,plugin or something like that..that allow CLI to read two words without quote..
 
Old 09-05-2011, 07:30 AM   #6
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
Sorry I don't understand you. Maybe somebody else can.
ciao,
jdk
 
Old 09-07-2011, 04:42 AM   #7
conflicker
Member
 
Registered: Sep 2011
Posts: 92

Original Poster
Rep: Reputation: Disabled
Exclamation

Quote:
Originally Posted by jdkaye View Post
Sorry I don't understand you. Maybe somebody else can.
ciao,
jdk
ahmm..what I'm trying to do is to convert .gsm file to .mp3..
for me to do that..I need to create a Makefile and that Makefile use to execute when
I type "cd /dir/dir/dir; make" command on the CLI.. It will scan the directory and look for all .gsm file and convert it into .wav and convert again into the .mp3 format, that is how the above script do..

If the .gsm filename contains spaces the shell returns me an error like this:
"dir: *.wav: No such file or directory
make: *** No rule to make target `1 3.mp3', needed by `mp3'. Stop."

But if there's no spaces in the filename of .gsm file it works perfectly and convert all the .gsm file into .mp3..

Please help..
 
Old 09-07-2011, 06:54 AM   #8
jdkaye
LQ Guru
 
Registered: Dec 2008
Location: Westgate-on-Sea, Kent, UK
Distribution: Debian Testing Amd64
Posts: 5,465

Rep: Reputation: Disabled
You mean this? http://www.cyberciti.biz/tips/handli...s-in-bash.html
Does that fix your problem?
jdk
 
Old 09-07-2011, 08:55 PM   #9
conflicker
Member
 
Registered: Sep 2011
Posts: 92

Original Poster
Rep: Reputation: Disabled
I think this one:
http://astrecipes.net/index.php?n=294
........
What I'm working on is to record a phone call using the asterisk..
but the result is .gsm and i need to convert it into .wav and .mp3 by the help of sox and lame.
and that Makefile is the solution..

the script is perfectly working when i was on the old server..
when i got a new server and transfer everything from old to new server including this project..
everything is messed up.

I'm just wondering if it is the version of the new server..or the make command..I don't know..
Any idea?..
 
  


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
make: CC: Command not found make: *** [main.o] Error 127 on opensuse 11.3 Leo89 Linux - Newbie 6 11-30-2012 05:13 PM
RH9 make menuconfig error: make[1]: *** [lxdialog] Error 1 rrochele Linux - Kernel 3 02-07-2007 03:39 PM
make bzImage failure: make[1]: *** [init/version.o] Error 1 nmainak Linux - Kernel 2 07-16-2006 05:06 PM
lopster v1.2.2 make error: No rule to make target `m4/glibc21.m4' Kropotkin Fedora 0 10-31-2004 11:19 AM
make: cc: command not found make: *** [gzip.o]error 127 zyjk Linux - Newbie 5 02-08-2002 09:58 AM

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

All times are GMT -5. The time now is 08:48 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
Open Source Consulting | Domain Registration