]> git.proxmox.com Git - qemu.git/commitdiff
BSD fix
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>
Thu, 20 May 2004 13:20:12 +0000 (13:20 +0000)
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>
Thu, 20 May 2004 13:20:12 +0000 (13:20 +0000)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@831 c046a42c-6fe2-441c-8c8c-71466251a162

vl.c
vl.h

diff --git a/vl.c b/vl.c
index baa09e58adb5bd54f0dd7a3dce7300d3bb24d2ba..84ac49d91fb348bf8600863df01d50ab7023165f 100644 (file)
--- a/vl.c
+++ b/vl.c
@@ -739,10 +739,12 @@ static void host_alarm_handler(int host_signum)
 
 #ifndef _WIN32
 
+#if defined(__linux__)
+
 #define RTC_FREQ 1024
 
 static int rtc_fd;
-    
+
 static int start_rtc_timer(void)
 {
     rtc_fd = open("/dev/rtc", O_RDONLY);
@@ -763,7 +765,16 @@ static int start_rtc_timer(void)
     return 0;
 }
 
-#endif
+#else
+
+static int start_rtc_timer(void)
+{
+    return -1;
+}
+
+#endif /* !defined(__linux__) */
+
+#endif /* !defined(_WIN32) */
 
 static void init_timers(void)
 {
diff --git a/vl.h b/vl.h
index 42a29bdcf4715903cd18cc27f46b9b2f7dab239d..ace401fbb01599dceb96c72fa63966f4d27a0f1e 100644 (file)
--- a/vl.h
+++ b/vl.h
 
 #include "cpu.h"
 
-#ifdef _BSD
-#define lseek64 lseek
-#define ftruncate64 ftruncate
-#define mkstemp64 mkstemp
-#define MAP_ANONYMOUS MAP_ANON
-#endif
-
 #ifndef glue
 #define xglue(x, y) x ## y
 #define glue(x, y) xglue(x, y)