X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=tools%2Fvirt-make-fs;h=833c8a5145fc4280afdd628b5b85ae5314873b7a;hb=371eabfae3790588ed97c0017d2882799c7ea871;hp=1a6aee4fa7e14a417cbf656d68b8a39c69faa8cb;hpb=a80177cc847102d5a6e43a8ff87769e86f30bd6c;p=libguestfs.git diff --git a/tools/virt-make-fs b/tools/virt-make-fs index 1a6aee4..833c8a5 100755 --- a/tools/virt-make-fs +++ b/tools/virt-make-fs @@ -84,7 +84,7 @@ store something in it. Don't forget that you can also use local commands including L and L to resize existing filesystems, -or rerun virt-make-resize to build another image from scratch. +or rerun virt-make-fs to build another image from scratch. =head3 EXAMPLE @@ -393,10 +393,15 @@ if (!defined $size) { } } +$size = int ($size); + # Create the output disk. # Take the unusual step of invoking qemu-img here. my @cmd = ("qemu-img", "create", "-f", $format, $output, $size); +if ($debug) { + print STDERR ("running: ", join (" ", @cmd), "\n"); +} system (@cmd) == 0 or die __"qemu-img create: failed to create disk image, see earlier error messages\n"; @@ -405,7 +410,7 @@ eval { # Run libguestfs. my $g = Sys::Guestfs->new (); - $g->add_drive ($output); + $g->add_drive_opts ($output, format => $format); $g->launch (); if ($type eq "ntfs" && !feature_available ($g, "ntfs3g", "ntfsprogs")) { @@ -535,7 +540,7 @@ manual page L for details. L, L, -L, +L, L, L, L,