Revision 821601ea vl.c
b/vl.c | ||
---|---|---|
206 | 206 |
int max_cpus = 0; |
207 | 207 |
int smp_cores = 1; |
208 | 208 |
int smp_threads = 1; |
209 |
#ifdef CONFIG_VNC |
|
209 | 210 |
const char *vnc_display; |
211 |
#endif |
|
210 | 212 |
int acpi_enabled = 1; |
211 | 213 |
int no_hpet = 0; |
212 | 214 |
int fd_bootchk = 1; |
... | ... | |
1612 | 1614 |
exit(1); |
1613 | 1615 |
#endif |
1614 | 1616 |
} else if (strstart(p, "vnc", &opts)) { |
1617 |
#ifdef CONFIG_VNC |
|
1615 | 1618 |
display_remote++; |
1616 | 1619 |
|
1617 | 1620 |
if (*opts) { |
... | ... | |
1625 | 1628 |
fprintf(stderr, "VNC requires a display argument vnc=<display>\n"); |
1626 | 1629 |
exit(1); |
1627 | 1630 |
} |
1631 |
#else |
|
1632 |
fprintf(stderr, "VNC support is disabled\n"); |
|
1633 |
exit(1); |
|
1634 |
#endif |
|
1628 | 1635 |
} else if (strstart(p, "curses", &opts)) { |
1629 | 1636 |
#ifdef CONFIG_CURSES |
1630 | 1637 |
display = DT_CURSES; |
... | ... | |
2026 | 2033 |
int tb_size; |
2027 | 2034 |
const char *pid_file = NULL; |
2028 | 2035 |
const char *incoming = NULL; |
2036 |
#ifdef CONFIG_VNC |
|
2029 | 2037 |
int show_vnc_port = 0; |
2038 |
#endif |
|
2030 | 2039 |
int defconfig = 1; |
2031 | 2040 |
const char *trace_file = NULL; |
2032 | 2041 |
|
... | ... | |
2684 | 2693 |
} |
2685 | 2694 |
break; |
2686 | 2695 |
case QEMU_OPTION_vnc: |
2696 |
#ifdef CONFIG_VNC |
|
2687 | 2697 |
display_remote++; |
2688 |
vnc_display = optarg; |
|
2689 |
break; |
|
2698 |
vnc_display = optarg; |
|
2699 |
#else |
|
2700 |
fprintf(stderr, "VNC support is disabled\n"); |
|
2701 |
exit(1); |
|
2702 |
#endif |
|
2703 |
break; |
|
2690 | 2704 |
case QEMU_OPTION_no_acpi: |
2691 | 2705 |
acpi_enabled = 0; |
2692 | 2706 |
break; |
... | ... | |
3142 | 3156 |
if (display_type == DT_DEFAULT && !display_remote) { |
3143 | 3157 |
#if defined(CONFIG_SDL) || defined(CONFIG_COCOA) |
3144 | 3158 |
display_type = DT_SDL; |
3145 |
#else
|
|
3159 |
#elif defined(CONFIG_VNC)
|
|
3146 | 3160 |
vnc_display = "localhost:0,to=99"; |
3147 | 3161 |
show_vnc_port = 1; |
3162 |
#else |
|
3163 |
display_type = DT_NONE; |
|
3148 | 3164 |
#endif |
3149 | 3165 |
} |
3150 |
|
|
3166 |
|
|
3151 | 3167 |
|
3152 | 3168 |
/* init local displays */ |
3153 | 3169 |
switch (display_type) { |
... | ... | |
3171 | 3187 |
break; |
3172 | 3188 |
} |
3173 | 3189 |
|
3190 |
#ifdef CONFIG_VNC |
|
3174 | 3191 |
/* init remote displays */ |
3175 | 3192 |
if (vnc_display) { |
3176 | 3193 |
vnc_display_init(ds); |
... | ... | |
3181 | 3198 |
printf("VNC server running on `%s'\n", vnc_display_local_addr(ds)); |
3182 | 3199 |
} |
3183 | 3200 |
} |
3201 |
#endif |
|
3184 | 3202 |
#ifdef CONFIG_SPICE |
3185 | 3203 |
if (using_spice && !qxl_enabled) { |
3186 | 3204 |
qemu_spice_display_init(ds); |
Also available in: Unified diff