qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] win32: Add missing function setenv


From: Stefan Weil
Subject: Re: [Qemu-devel] [PATCH] win32: Add missing function setenv
Date: Thu, 01 Jul 2010 15:22:19 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100620 Iceowl/1.0b1 Icedove/3.0.5

Am 01.07.2010 13:50, schrieb Jes Sorensen:
On 07/01/10 12:47, Stefan Weil wrote:
Mingw32 does not provide a declaration and implementation of function
setenv (which is used in sdl.c), so this patch adds both.

Signed-off-by: Stefan Weil<address@hidden>
[snip]
diff --git a/osdep.h b/osdep.h
index 75b5816..1cdc7e2 100644
--- a/osdep.h
+++ b/osdep.h
@@ -95,6 +95,8 @@ int qemu_create_pidfile(const char *filename);
  #ifdef _WIN32
  int ffs(int i);

+int setenv(const char *name, const char *value, int overwrite);
+
  typedef struct {
      long tv_sec;
      long tv_usec;
Please move this to qemu-os-win32.h instead, otherwise the build will
fail on POSIX systems due to setenv being redefined.

Thanks,
Jes

It won't fail for two reasons:

* It is not redefined (at least for linux systems) because I used the POSIX declaration.

* It is compiled only for _WIN32 (see line 95).

Regards
Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]