Solved [Solved] Running a shell command from a Makefile

Hello,

I set up this simple Makefile:

Code:
# For running tests

remove: 
	rm -f Test_1_1/*.pdf

Running make or make remove echoes the command but the files in Test_1_1 are not deleted. Can someone point out the error in the Makefile? I'm on FreeBSD10.

Thanks for any help.

sprock
 
Re: Running a shell command from a makefile

Either the path is wrong or the permissions are not sufficient.

While trouble shooting, it would be good to see the diagnostic messages of the rm(1) command. So, for the time being, remove the command line option -f. Once the Makefile is working, you can add it again.
 
Re: Running a shell command from a makefile

That was good advice, thank you. make evidently needs a path, rather than executing a command in the current directory.

Thanks again,
sprock
 
Back
Top