src/dbdump.c: Shouldn't depend on HAVE_HIVEX (thanks Tao Zhou).
(cherry picked from commit 4e6bf1ed653540a8954a6a11fe5a0fb424013af9)
tests: Attach copyright and license (GPLv2+) notices to various test scripts.

For some reason these tests did not have license notices.
(cherry picked from commit a1d981edeae120a0523d0974c703f1a956202415)
recipes: Checksum file/device.  Download to stdout.
(cherry picked from commit b799bc58a84e155783afae23f64f27e23ddd06dd)
java: Fix >= 32 optargs (thanks Wanlong Gao).
(cherry picked from commit f65dee769d1fc53c5963c381bf8a1bf02654f78c)
rescue: If -v / debugging enabled, don't mask error messages.

We set the error handler to NULL in order to mask "normal" error
messages that we expect to see because of the unusual way that
virt-rescue runs the appliance.  However if the user selected -v /
enabled debugging, then it is reasonable to expect they want to see
every message, so do not mask anything.
(cherry picked from commit 6fdf1f40fa85d2e6e7a1118f4cfa532ea9831b89)
fix fuse_opt_add_opt_escaped return type

I: Program returns random data in a function
E: libguestfs no-return-in-nonvoid-function guestmount.c:75

The function fuse_opt_add_opt_escaped has only one caller and a return
code is not checked.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
(cherry picked from commit bdb5689f58c0db18de28d6a703b3af4f22eded38)
extra-tests: Don't use $QEMU as a variable.

Since 'QEMU' is set (overwritten) by the autoconf-generated Makefile,
this test would always test installed qemu, not upstream qemu,
making it pretty useless.  Use another name for this variable.
(cherry picked from commit 81c682f1295a934d18bd4dc9e42b8e843df0c207)
fish: Replace '_' with '-' in deprecation cross-refs (thanks Olaf Hering).
(cherry picked from commit 8acdc23622ea95a233ac831d67c143517aa94bba)
test-tool: Print more environment variables.

This prints LIBVIRT_*, LIBVIRTD_*, LD_* and PATH, since these are all
useful for debugging and could affect libguestfs in some way.
(cherry picked from commit 281b155800f2e62b994e59bef418ca200da8e93a)
docs: Fix documentation of syntax-check target, add extra-tests.
(cherry picked from commit 6951becfdb0b69b4defff4393f48314e884ad7c1)
syntax: Remove test for TAB indentation.

Nothing particularly wrong with using TABs for indentation,
and this test also has a lot of false positives.
(cherry picked from commit ae137124ca143e57f16d103f24cb3f21a3157b09)
lib: These optargs structures are not modified, hence const.
(cherry picked from commit 5a46eadd3dcab1b8944eabc0f21097048e0ebe13)
perl: Include <inttypes.h> and assume it always defines PRId64 and PRIu64.

If these are not defined in the header files, it's a problem on
the platform which we should fix with gnulib.  Our replacement
definitions might be wrong here.
(cherry picked from commit 188b44ee458a666bee8a18ed47cccdec25859aff)
perl: Add <stdio.h> and <stdlib.h> for printf and malloc.
(cherry picked from commit cd8976a5b52425f9d7c45249e1a593a341d91c52)
syntax: Use STREQ/STRNEQ in place of strcmp.

Found by 'make syntax-check'.
(cherry picked from commit b0cefb417d01c6dcb87cc6bafe9c19b98c690c9d)
syntax: Replace test == with = or -eq as appropriate.

Found by 'make syntax-check'.
(cherry picked from commit 6361810b53be4d5e0513b4f7c11d29cf1d6d3b45)
generator: Remove inaccurate comment.

The correct way to extend functions is documented in generator/README.
This comment was no longer accurate.
(cherry picked from commit 44a11e955b31f7c0cf463a04d640263cccdd0c4d)
syntax: Remove trailing whitespace.

Found by 'make syntax-check'.
(cherry picked from commit 2cac8d490e9884a8c7376e49fd1cda2e3d3abec1)
extra-tests: Fix libvirt URI so we can run tests with libvirt attach-method.
(cherry picked from commit eeb0c598ec8caa50998336713ed4e62902e0a74d)
extra-tests: The upstream qemu test now reruns all the extra tests.
(cherry picked from commit 509dd90c43afed75b861b7d82ebe8739d3500d54)