File: 02_use_usr_share_kvm_fixed.patch

package info (click to toggle)
qemu-kvm 1.1.2%2Bdfsg-6%2Bdeb7u12
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 43,848 kB
  • sloc: ansic: 606,321; asm: 10,684; sh: 6,663; perl: 4,223; python: 3,802; makefile: 1,076; objc: 843; xml: 409
file content (30 lines) | stat: -rw-r--r-- 828 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
--- a/os-posix.c
+++ b/os-posix.c
@@ -80,6 +80,8 @@ void os_setup_signal_handling(void)
     sigaction(SIGTERM, &act, NULL);
 }
 
+#ifdef find_datadir_dynamic
+
 /* Find a likely location for support files using the location of the binary.
    For installed binaries this will be "$bindir/../share/qemu".  When
    running from the build tree this will be "$bindir/../pc-bios".  */
@@ -143,6 +145,18 @@ char *os_find_datadir(const char *argv0)
 #undef SHARE_SUFFIX
 #undef BUILD_SUFFIX
 
+#else /* !no_find_datadir */
+
+/* for a packaged version we want to ensure data is found in a known place,
+ * which is CONFIG_QEMU_DATADIR. Can be specified on command line
+ * (-L option) */
+char *os_find_datadir(const char *argv0)
+{
+    return NULL;
+}
+
+#endif
+
 void os_set_proc_name(const char *s)
 {
 #if defined(PR_SET_NAME)