mirror of https://github.com/xemu-project/xemu.git
Merge remote-tracking branch 'mdroth/qga-pull-5-24-12' into staging
* mdroth/qga-pull-5-24-12: qemu-ga: Fix missing environ declaration configure: check if environ is declared
This commit is contained in:
commit
422831fc81
|
@ -2831,6 +2831,21 @@ if compile_prog "" "" ; then
|
||||||
linux_magic_h=yes
|
linux_magic_h=yes
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
########################################
|
||||||
|
# check if environ is declared
|
||||||
|
|
||||||
|
has_environ=no
|
||||||
|
cat > $TMPC << EOF
|
||||||
|
#include <unistd.h>
|
||||||
|
int main(void) {
|
||||||
|
environ = environ;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
if compile_prog "" "" ; then
|
||||||
|
has_environ=yes
|
||||||
|
fi
|
||||||
|
|
||||||
##########################################
|
##########################################
|
||||||
# End of CC checks
|
# End of CC checks
|
||||||
# After here, no more $cc or $ld runs
|
# After here, no more $cc or $ld runs
|
||||||
|
@ -3342,6 +3357,10 @@ if test "$linux_magic_h" = "yes" ; then
|
||||||
echo "CONFIG_LINUX_MAGIC_H=y" >> $config_host_mak
|
echo "CONFIG_LINUX_MAGIC_H=y" >> $config_host_mak
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if test "$has_environ" = "yes" ; then
|
||||||
|
echo "CONFIG_HAS_ENVIRON=y" >> $config_host_mak
|
||||||
|
fi
|
||||||
|
|
||||||
# USB host support
|
# USB host support
|
||||||
case "$usb" in
|
case "$usb" in
|
||||||
linux)
|
linux)
|
||||||
|
|
|
@ -14,12 +14,17 @@
|
||||||
#include <glib.h>
|
#include <glib.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
|
#include <sys/wait.h>
|
||||||
#include "qga/guest-agent-core.h"
|
#include "qga/guest-agent-core.h"
|
||||||
#include "qga-qmp-commands.h"
|
#include "qga-qmp-commands.h"
|
||||||
#include "qerror.h"
|
#include "qerror.h"
|
||||||
#include "qemu-queue.h"
|
#include "qemu-queue.h"
|
||||||
#include "host-utils.h"
|
#include "host-utils.h"
|
||||||
|
|
||||||
|
#ifndef CONFIG_HAS_ENVIRON
|
||||||
|
extern char **environ;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(__linux__)
|
#if defined(__linux__)
|
||||||
#include <mntent.h>
|
#include <mntent.h>
|
||||||
#include <linux/fs.h>
|
#include <linux/fs.h>
|
||||||
|
@ -27,7 +32,6 @@
|
||||||
#include <arpa/inet.h>
|
#include <arpa/inet.h>
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <net/if.h>
|
#include <net/if.h>
|
||||||
#include <sys/wait.h>
|
|
||||||
|
|
||||||
#if defined(__linux__) && defined(FIFREEZE)
|
#if defined(__linux__) && defined(FIFREEZE)
|
||||||
#define CONFIG_FSFREEZE
|
#define CONFIG_FSFREEZE
|
||||||
|
|
Loading…
Reference in New Issue