PATCH: Make Makefile.am work in parallel

Alexandre Oliva aoliva@redhat.com
Tue May 7 11:32:00 GMT 2002


On May  7, 2002, Mark Mitchell <mark@codesourcery.com> wrote:

> I've changed write_classfile to create "foo.class.tmp" and then call
> "rename" to change it to "foo.class" after the file has been written.
> Note that "rename" is guaranteed to be atomic.

I don't think rename is really guaranteed to be atomic.  IIRC, on some
OSs/file-systems, it is implemented as link&remove, but even this
would be good enough for us.  As long as it's not copy&remove, which
`mv' would do to move between different filesystems, when rename
failed, we're safe.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist                Professional serial bug killer



More information about the Java-patches mailing list