| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
This fixes commit 7786d56db8c22413949f98ef6b15fe0ea367d195.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
New API: list-disk-labels
Allow the user to pass an optional disk label when adding a drive.
This is passed through to qemu / libvirt using the disk serial field,
and from there to the appliance which exposes it through udev,
creating a special alias of the device /dev/disk/guestfs/<label>.
Partitions are named /dev/disk/guestfs/<label><partnum>.
virtio-blk and virtio-scsi limit the serial field to 20 bytes. We
further limit the name to maximum 20 ASCII characters in [a-zA-Z].
list-devices and list-partitions are not changed: these calls still
return raw block device names. However a new call, list-disk-labels,
returns a hash table allowing callers to map between disk labels, and
block device and partition names.
This commit also includes a test.
|
|
|
|
|
|
|
| |
When building supermin.d/daemon.img, use 'tmp-d' instead of 'tmp'
as the name of the temporary directory.
This is just code motion.
|
|
|
|
|
|
|
|
|
|
| |
This adds standard LICENSE and BUGS sections to all of the man pages
that are processed by podwrapper.
Modify all the calls to $(PODWRAPPER) to add the right --license
parameter according to the content. Note that this relaxes the
license on some code example pages, making them effectively BSD-style
licensed.
|
|
|
|
|
|
| |
Add proper dependencies for these files, but also use 'cmp' to ensure
they only get overwritten if the new files have actually changed, so
we don't rebuild the appliance unnecessarily.
|
|
|
|
|
| |
This will allow us to easily change the location of this
script in future.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RHEL 5-era autoconf did not define these, so define them manually
when they are missing.
Define builddir as '.' The scripts require this. It won't work
in the srcdir != builddir case, but we don't care about that for
RHEL 5.
This commit also moves the builddir / abs_srcdir variable setting
above the include of subdir-rules.mk, in case that include uses
these variables.
Useful script:
for f in $(find -name Makefile.am | xargs fgrep '$(abs_srcdir)' -l) ; do
if ! grep -q '^abs_srcdir' $f; then
echo missing in $f
fi
done
|
| |
|
| |
|
| |
|
|
|
|
| |
This lets us suppress errors in system libraries.
|
|
|
|
|
|
|
| |
Check /sbin, /usr/sbin, /bin and /usr/bin to ensure that neither the
directory nor the parent (eg. /usr) is a symlink, and use this
directory for the virtual directory used to store guestfsd in the
appliance.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit allows you to run the daemon under valgrind. You have to
enable it at configure time:
./configure --enable-valgrind-daemon
This should *not* be done for production builds.
When this feature is enabled, valgrind is added to the appliance and
the daemon is run under valgrind. Log messages from valgrind are
passed back over a virtio-serial channel into a file called
'valgrind.log.$PID' in the top build directory.
Running 'make check', 'make extra-tests' etc causes many
valgrind.log.* files to be created which must be examined by hand.
|
| |
|
| |
|
|
|
|
|
| |
Create a separate file 'excludelist.in' that contains these
regular expressions, and process it the same way as packagelist.in.
|
| |
|
|
|
|
|
|
|
|
|
| |
This removes all support for building the ordinary / old
style appliance using febootstrap 2.x, debootstrap, debirf,
fakeroot and fakechroot.
Instead this uses febootstrap 3.x to build the supermin appliance
in a simpler cross-distro manner.
|
| |
|
|
|
|
|
|
|
| |
There's no need to have the appliance filename contain the
repository name it was built from, and this change gives
downstream users more freedom to mix and match libraries
and appliances if they want to.
|
|
|
|
|
|
|
|
|
|
| |
The appliance was being completely rebuilt every time guestfsd was updated. This
was because make.sh depended on guestfsd, which it had to do because it
called update.sh to install guestfsd.
This fix removes the call to update.sh in make.sh, and therefore the dependency
on guestfsd. The Makefile already includes a rule to run update.sh when guestfsd
is updated, so this was unnecessary.
|
|
|
|
| |
This haven't been used -- and haven't worked -- for a long time.
|
| |
|
|
|
|
|
| |
This updates commit a34fadf900625f1f7359ecf3ca760820ffa20815,
removing this now non-existent script from EXTRA_DIST.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
libguestfs-supermin-helper was previously a shell script. Although
we had steadily optimized it, there were a number of intractable
hot spots:
(1) cpio still reads input files in 512 byte chunks; this is *very*
pessimal behaviour, particularly when SELinux is enabled.
(2) the hostfiles globbing was done very inefficiently by the shell,
with the shell rereading the same directory over and over again.
This is a rewrite of this shell script in C. It is approximately
3 times faster without SELinux, and has an even greater speed difference
with SELinux.
The main features are:
(a) It never frees memory, making it simpler. The program is designed
to run and exit in sub-second times, so this is acceptable.
(b) It caches directory reads, making the globbing of host files much
faster (measured this as ~ 4 x speed up).
(c) It doesn't use external cpio, but instead contains code to write
newc format cpio files, which is all that the kernel can read. Unlike
cpio, this code uses large buffers for reads and writes.
(d) Ignores missing or unreadable hostfiles, whereas cpio gave a
warning.
(e) Checks all return values from system calls.
(f) With --verbose flag, it will print messages timing itself.
This passes all tests.
Updated with feedback from Jim Meyering.
|
|
|
|
|
|
|
| |
Previously, only the update.sh rule checked the daemon had been built. update.sh
is called directly from within make.sh, so in that path the dependency was never
checked. This adds the daemon dependency explicitly to the rebuild-from-scratch
path.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change adds an explicit dependency on generator.ml for every file it
generates, except java files. Java is left for another time because it's
considerably trickier.
It also adds a build rule for src/libguestfs.la so it can be rebuilt as required
from other directories.
It does this by creating a top level make file, subdir-rules.mk, which can be
included from sub-directories. sub-directories need to define 'generator_built'
to include local files which are built by generator.ml, and they will be updated
automatically.
This fixes parallel make, and will automatically re-create generated files when
make is run from any directory.
It also fixes the problem which efad4f53 was targetting. Specifically,
src/guestfs_protocol.(c|h) had an erroneous dependency on stamp-generator, and
therefore generator.ml, despite not being directly created by it. This caused
them to be recreated every time generator.ml ran rather than only when
src/guestfs_protocol.x was updated, which cascaded into a daemon and therefore
appliance update.
This patch also changes the contents of the distribution tarball by including
files created by rpcgen.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
config.status touches make.sh each time it runs, even if the
resulting script would not change. This causes the appliance
to get rebuilt much more frequently than is necessary.
There's no way to stop configure running, but we can move the
config.status command into a Makefile rule to stop this
undesirable behaviour.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* cfg.mk (disable_temporarily): Remove sc_prohibit_trailing_blank_lines.
* appliance/Makefile.am: Remove trailing blank line(s).
* appliance/debian/modules/y0_install-guestfsd: Likewise.
* appliance/make.sh.in: Likewise.
* appliance/packagelist.in: Likewise.
* appliance/update.sh.in: Likewise.
* haskell/run-bindtests: Likewise.
* ocaml/run-bindtests: Likewise.
* python/run-python-tests: Likewise.
* recipes/squashfs.example: Likewise.
* ruby/run-ruby-tests: Likewise.
|
|
|
|
|
| |
A lot of people report these as 'errors' when they are not.
Hide the error messages.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch allows you to do:
mkdir build
cd build
../configure ...
make
This will output all generated files to the build directory. Given that
autogen automatically runs configure, you can also do:
BUILDDIR=./build ./autogen.sh
which will do the right thing.
Also:
* Fix a dependency bug which means that guestfs_protocol.h
isn't automatically rebuilt.
* Re-running autogen.sh with no arguments won't blow away your previous
configure arguments.
|
| |
|
| |
|
|
|
|
|
|
|
| |
'make dist' won't copy symlinks into the output file, so we
have to add a rule to the Makefile to copy these.
(Issue reported by Guido Gunther).
|
| |
|
|
|
|
| |
so we can preprocess packagelist.in
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|