diff options
author | Richard Jones <rjones@trick.home.annexia.org> | 2009-07-29 18:46:55 +0100 |
---|---|---|
committer | Richard Jones <rjones@trick.home.annexia.org> | 2009-07-29 20:42:20 +0100 |
commit | 7c4f90ddb8378dcf90cb0cc219105dccaa8a9d6e (patch) | |
tree | 8469a708d692fc86025b44f3464fa4b135e79417 /images | |
parent | bf2b08560f649c22152e4138531ad0b46b4ad1b3 (diff) | |
download | libguestfs-7c4f90ddb8378dcf90cb0cc219105dccaa8a9d6e.tar.gz libguestfs-7c4f90ddb8378dcf90cb0cc219105dccaa8a9d6e.tar.xz libguestfs-7c4f90ddb8378dcf90cb0cc219105dccaa8a9d6e.zip |
tests: Use squashfs for static data where possible.
Instead of creating a new InitBasicFS for just about every test,
where a test doesn't need to write to the filesystem it is far
faster to use prepared data on an InitSquashFS instead.
This commit changes as many tests as possible to make this so,
making the tests much faster.
Diffstat (limited to 'images')
-rw-r--r-- | images/Makefile.am | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/images/Makefile.am b/images/Makefile.am index 424f5e45..3c30df5a 100644 --- a/images/Makefile.am +++ b/images/Makefile.am @@ -77,8 +77,11 @@ squash_files_build = \ squash_files = $(squash_files_src) $(squash_files_build) test.sqsh: $(squash_files) - rm -f $@ - $(MKSQUASHFS) $(squash_files) $@ + rm -f $@ $@-t + mkdir -p directory + $(MKSQUASHFS) $(squash_files) directory $@-t + rmdir directory + mv $@-t $@ $(builddir)/100kallzeroes: rm -f $@ $@-t @@ -109,7 +112,7 @@ $(builddir)/10klines: done > $@-t mv $@-t $@ -$(builddir)/initrd: empty known-1 known-2 known-3 +$(builddir)/initrd: empty known-1 known-2 known-3 known-4 known-5 rm -f $@ $@-t for f in $^; do echo $$f; done | cpio -o -H newc | gzip --best > $@-t mv $@-t $@ |