[Libguestfs] [PATCH libnbd 3/3] examples: copy-libev.c: Support extents

Richard W.M. Jones rjones at redhat.com
Mon Mar 8 12:56:16 UTC 2021


On Mon, Mar 08, 2021 at 01:23:05PM +0200, Nir Soffer wrote:
> Why do we use the run script?

In this case it's optional, because libtool adds some magic to
copy/nbdcopy to ensure that it links against the built copy of libnbd
(not the installed copy).

But in general it's a useful script, for a few good reasons:

(1) You're running libnbd tools written in other programming languages
like Python.  The run script will set all the environment variables
correctly to make this just work.

(2) You want to run the nbd* tools from locally built libnbd when
doing something like running nbdkit's test suite, because the run
script sets up $PATH correctly:

  nbdkit$ ../libnbd/run make check

(3) You want to use the special features like valgrind support:

  nbdkit$ LIBNBD_VALGRIND=1 ../libnbd/run make check

See also:

  https://gitlab.com/nbdkit/libnbd/-/blob/master/run.in

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines.  Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v




More information about the Libguestfs mailing list