1 | Index: ioemu/hw/vga.c |
---|
2 | =================================================================== |
---|
3 | --- ioemu.orig/hw/vga.c 2007-05-02 16:04:46.000000000 +0100 |
---|
4 | +++ ioemu/hw/vga.c 2007-05-02 16:05:50.000000000 +0100 |
---|
5 | @@ -1622,7 +1622,9 @@ |
---|
6 | static void vga_save(QEMUFile *f, void *opaque) |
---|
7 | { |
---|
8 | VGAState *s = opaque; |
---|
9 | +#ifdef CONFIG_BOCHS_VBE |
---|
10 | int i; |
---|
11 | +#endif |
---|
12 | |
---|
13 | qemu_put_be32s(f, &s->latch); |
---|
14 | qemu_put_8s(f, &s->sr_index); |
---|
15 | @@ -1663,7 +1665,10 @@ |
---|
16 | static int vga_load(QEMUFile *f, void *opaque, int version_id) |
---|
17 | { |
---|
18 | VGAState *s = opaque; |
---|
19 | - int is_vbe, i; |
---|
20 | + int is_vbe; |
---|
21 | +#ifdef CONFIG_BOCHS_VBE |
---|
22 | + int i; |
---|
23 | +#endif |
---|
24 | |
---|
25 | if (version_id != 1) |
---|
26 | return -EINVAL; |
---|
27 | Index: ioemu/vl.c |
---|
28 | =================================================================== |
---|
29 | --- ioemu.orig/vl.c 2007-05-02 16:05:50.000000000 +0100 |
---|
30 | +++ ioemu/vl.c 2007-05-02 16:05:50.000000000 +0100 |
---|
31 | @@ -39,6 +39,7 @@ |
---|
32 | #include <sys/ioctl.h> |
---|
33 | #include <sys/socket.h> |
---|
34 | #include <netinet/in.h> |
---|
35 | +#include <arpa/inet.h> |
---|
36 | #include <dirent.h> |
---|
37 | #include <netdb.h> |
---|
38 | #ifdef _BSD |
---|
39 | @@ -2932,7 +2933,7 @@ |
---|
40 | } |
---|
41 | |
---|
42 | /* XXX: better tmp dir construction */ |
---|
43 | - snprintf(smb_dir, sizeof(smb_dir), "/tmp/qemu-smb.%d", getpid()); |
---|
44 | + snprintf(smb_dir, sizeof(smb_dir), "/tmp/qemu-smb.%ld", (long)getpid()); |
---|
45 | if (mkdir(smb_dir, 0700) < 0) { |
---|
46 | fprintf(stderr, "qemu: could not create samba server dir '%s'\n", smb_dir); |
---|
47 | exit(1); |
---|
48 | @@ -3893,7 +3894,7 @@ |
---|
49 | perror("Opening pidfile"); |
---|
50 | exit(1); |
---|
51 | } |
---|
52 | - fprintf(f, "%d\n", getpid()); |
---|
53 | + fprintf(f, "%ld\n", (long)getpid()); |
---|
54 | fclose(f); |
---|
55 | pid_filename = qemu_strdup(filename); |
---|
56 | if (!pid_filename) { |
---|
57 | @@ -5308,7 +5309,9 @@ |
---|
58 | QEMU_OPTION_d, |
---|
59 | QEMU_OPTION_hdachs, |
---|
60 | QEMU_OPTION_L, |
---|
61 | +#ifdef USE_CODE_COPY |
---|
62 | QEMU_OPTION_no_code_copy, |
---|
63 | +#endif |
---|
64 | QEMU_OPTION_k, |
---|
65 | QEMU_OPTION_localtime, |
---|
66 | QEMU_OPTION_cirrusvga, |
---|
67 | @@ -5379,7 +5382,9 @@ |
---|
68 | { "d", HAS_ARG, QEMU_OPTION_d }, |
---|
69 | { "hdachs", HAS_ARG, QEMU_OPTION_hdachs }, |
---|
70 | { "L", HAS_ARG, QEMU_OPTION_L }, |
---|
71 | +#ifdef USE_CODE_COPY |
---|
72 | { "no-code-copy", 0, QEMU_OPTION_no_code_copy }, |
---|
73 | +#endif |
---|
74 | #ifdef USE_KQEMU |
---|
75 | { "no-kqemu", 0, QEMU_OPTION_no_kqemu }, |
---|
76 | { "kernel-kqemu", 0, QEMU_OPTION_kernel_kqemu }, |
---|
77 | @@ -5853,9 +5858,11 @@ |
---|
78 | fd_bootchk = 0; |
---|
79 | break; |
---|
80 | #endif |
---|
81 | +#ifdef USE_CODE_COPY |
---|
82 | case QEMU_OPTION_no_code_copy: |
---|
83 | code_copy_enabled = 0; |
---|
84 | break; |
---|
85 | +#endif |
---|
86 | case QEMU_OPTION_net: |
---|
87 | if (nb_net_clients >= MAX_NET_CLIENTS) { |
---|
88 | fprintf(stderr, "qemu: too many network clients\n"); |
---|
89 | Index: ioemu/vl.h |
---|
90 | =================================================================== |
---|
91 | --- ioemu.orig/vl.h 2007-05-02 16:05:50.000000000 +0100 |
---|
92 | +++ ioemu/vl.h 2007-05-02 16:05:50.000000000 +0100 |
---|
93 | @@ -957,7 +957,7 @@ |
---|
94 | unsigned long vram_offset, int vram_size, int width, int height); |
---|
95 | |
---|
96 | /* slavio_intctl.c */ |
---|
97 | -void *slavio_intctl_init(); |
---|
98 | +void *slavio_intctl_init(void); |
---|
99 | void slavio_intctl_set_cpu(void *opaque, unsigned int cpu, CPUState *env); |
---|
100 | void slavio_pic_info(void *opaque); |
---|
101 | void slavio_irq_info(void *opaque); |
---|
102 | Index: ioemu/usb-linux.c |
---|
103 | =================================================================== |
---|
104 | --- ioemu.orig/usb-linux.c 2007-05-02 16:04:46.000000000 +0100 |
---|
105 | +++ ioemu/usb-linux.c 2007-05-02 16:05:50.000000000 +0100 |
---|
106 | @@ -26,7 +26,9 @@ |
---|
107 | #if defined(__linux__) |
---|
108 | #include <dirent.h> |
---|
109 | #include <sys/ioctl.h> |
---|
110 | -#include <linux/compiler.h> |
---|
111 | +/* Some versions of usbdevice_fs.h need __user to be defined for them. */ |
---|
112 | +/* This may (harmlessly) conflict with a definition in linux/compiler.h. */ |
---|
113 | +#define __user |
---|
114 | #include <linux/usbdevice_fs.h> |
---|
115 | #include <linux/version.h> |
---|
116 | |
---|