Create manpage atomically.
authorRichard Jones <rjones@trick.home.annexia.org>
Wed, 23 Sep 2009 11:05:55 +0000 (12:05 +0100)
committerRichard Jones <rjones@trick.home.annexia.org>
Wed, 23 Sep 2009 11:05:55 +0000 (12:05 +0100)
Don't fail with a partial file if disk full, etc.

cat/Makefile.am
df/Makefile.am
edit/Makefile.am
inspector/Makefile.am
rescue/Makefile.am

index 98df337..5fe320b 100644 (file)
@@ -30,7 +30,7 @@ virt-cat.1: virt-cat.pl
          --section 1 \
          -c "Virtualization Support" \
          --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
-         $< > $@
+         $< > $@-t && mv $@-t $@
 
 $(top_builddir)/html/virt-cat.1.html: virt-cat.pl
        mkdir -p $(top_builddir)/html
index 7234eb7..08af772 100644 (file)
@@ -30,7 +30,7 @@ virt-df.1: virt-df.pl
          --section 1 \
          -c "Virtualization Support" \
          --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
-         $< > $@
+         $< > $@-t && mv $@-t $@
 
 $(top_builddir)/html/virt-df.1.html: virt-df.pl
        mkdir -p $(top_builddir)/html
index 4a2a52c..df8ddb7 100644 (file)
@@ -30,7 +30,7 @@ virt-edit.1: virt-edit.pl
          --section 1 \
          -c "Virtualization Support" \
          --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
-         $< > $@
+         $< > $@-t && mv $@-t $@
 
 $(top_builddir)/html/virt-edit.1.html: virt-edit.pl
        mkdir -p $(top_builddir)/html
index a93a1ff..6eb3b57 100644 (file)
@@ -30,7 +30,7 @@ virt-inspector.1: virt-inspector.pl
          --section 1 \
          -c "Virtualization Support" \
          --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
-         $< > $@
+         $< > $@-t && mv $@-t $@
 
 $(top_builddir)/html/virt-inspector.1.html: virt-inspector.pl
        mkdir -p $(top_builddir)/html
index 3d55728..1067c8d 100644 (file)
@@ -30,7 +30,7 @@ virt-rescue.1: virt-rescue.pl
          --section 1 \
          -c "Virtualization Support" \
          --release "$(PACKAGE_NAME)-$(PACKAGE_VERSION)" \
-         $< > $@
+         $< > $@-t && mv $@-t $@
 
 $(top_builddir)/html/virt-rescue.1.html: virt-rescue.pl
        mkdir -p $(top_builddir)/html