qemu-e2k/osdep.h
pbrook 29b3a6627e Windows build fixes.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2959 c046a42c-6fe2-441c-8c8c-71466251a162
2007-06-07 23:09:47 +00:00

32 lines
622 B
C

#ifndef QEMU_OSDEP_H
#define QEMU_OSDEP_H
#include <stdarg.h>
#define qemu_printf printf
void *qemu_malloc(size_t size);
void *qemu_mallocz(size_t size);
void qemu_free(void *ptr);
char *qemu_strdup(const char *str);
void *qemu_vmalloc(size_t size);
void qemu_vfree(void *ptr);
void *get_mmap_addr(unsigned long size);
int qemu_create_pidfile(const char *filename);
#ifdef _WIN32
typedef struct {
long tv_sec;
long tv_usec;
} qemu_timeval;
int qemu_gettimeofday(qemu_timeval *tp);
#else
typedef struct timeval qemu_timeval;
#define qemu_gettimeofday(tp) gettimeofday(tp, NULL);
#endif /* !_WIN32 */
#endif