--- On Wed, 12/17/08, Jason Friedman <write.to.ja...@gmail.com> wrote:

> From: Jason Friedman <write.to.ja...@gmail.com>
> Subject: make question
> To: linux-il@cs.huji.ac.il
> Date: Wednesday, December 17, 2008, 10:21 PM
> Hi all,
> 
> I have had this make question that has been bugging me for
> a long time.
> 
> I want to fix some eps files using eps2eps. This is the
> makefile I use:
> 

Your question already answered in the previous mails, so I'll wrote something 
else :)

In my Makefiles instead of
figure1_fixed.eps: figure1.eps
[tab] eps2eps $< $@

I use
figure1_fixed.eps: figure1.eps
[tab] rm -f $@
[tab] eps2eps $< $@ || { rm -f $@; exit 1; }

First line will allow Makefile to work even if for some reason target file is 
read-only.
Additional to second line "|| { rm -f $@ ...}" ensure that in case of some 
failure no target file remain. So wrong / incomplete file can't be occassionly 
used.

Regards,
Valery


> figure1_fixed.eps: figure1.eps
> [tab] eps2eps $< $@
> 
> (replace [tab] with the tab character)
> 
> This works fine, but when I have many eps files to convert,
> I have to
> repeat the command line many times. A similar problem is
> this one:
> 
> figure2.eps:
> ../../some/other/path/some_long_ugly_filename.eps
> 
> 
> After lots of googling, I have not been able to find a
> solution. Is
> there a way to do this in make, if not, can you suggest
> another tool
> that can do this? I have been running into variants of this
> problem
> several times.
> 
> Thanks,
> 
> Jason
> 
> -- 
> Jason Friedman
> Postdoctoral researcher
> Motor Control and Biomechanics laboratories
> Department of Kinesiology
> Pennsylvania State University
> Phone: +1-814-863-0354
> email: jason.fried...@psu.edu
> web: http://www.personal.psu.edu/jxf35
> 
> =================================================================
> To unsubscribe, send mail to linux-il-requ...@cs.huji.ac.il
> with
> the word "unsubscribe" in the message body, e.g.,
> run the command
> echo unsubscribe | mail linux-il-requ...@cs.huji.ac.il


      

=================================================================
To unsubscribe, send mail to linux-il-requ...@cs.huji.ac.il with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail linux-il-requ...@cs.huji.ac.il

Reply via email to