qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] PATCH: fix undefined function errors


From: Sandra Loosemore
Subject: [Qemu-devel] PATCH: fix undefined function errors
Date: Wed, 12 Nov 2008 21:59:19 -0500
User-agent: Thunderbird 2.0.0.4 (X11/20070604)

I ran into errors about undefined functions when building user-mode QEMU for ARM Linux after picking up a recent update from trunk. The attached patch fixes the problem.

As I'm not a QEMU maintainer, someone who is will have to check this in.... or some alternate fix for the same problem, maybe.

-Sandra

2008-11-12  Sandra Loosemore  <address@hidden>

        * linux-user/syscall.c (do_syscall):  Make #ifdef on
        TARGET_NR_inotify_init, TARGET_NR_inotify_add_watch, and
        TARGET_NR_inotify_rm_watch cases match that used previously 
        in the file, to avoid references to undefined symbols.
Index: linux-user/syscall.c
===================================================================
*** linux-user/syscall.c        (revision 227507)
--- linux-user/syscall.c        (working copy)
*************** abi_long do_syscall(void *cpu_env, int n
*** 6029,6047 ****
          ret = do_futex(arg1, arg2, arg3, arg4, arg5, arg6);
          break;
  #endif
! #ifdef TARGET_NR_inotify_init
      case TARGET_NR_inotify_init:
          ret = get_errno(sys_inotify_init());
          break;
  #endif
! #ifdef TARGET_NR_inotify_add_watch
      case TARGET_NR_inotify_add_watch:
          p = lock_user_string(arg2);
          ret = get_errno(sys_inotify_add_watch(arg1, path(p), arg3));
          unlock_user(p, arg2, 0);
          break;
  #endif
! #ifdef TARGET_NR_inotify_rm_watch
      case TARGET_NR_inotify_rm_watch:
          ret = get_errno(sys_inotify_rm_watch(arg1, arg2));
          break;
--- 6029,6047 ----
          ret = do_futex(arg1, arg2, arg3, arg4, arg5, arg6);
          break;
  #endif
! #if defined(TARGET_NR_inotify_init) && defined(__NR_inotify_init)
      case TARGET_NR_inotify_init:
          ret = get_errno(sys_inotify_init());
          break;
  #endif
! #if defined(TARGET_NR_inotify_add_watch) && defined(__NR_inotify_add_watch)
      case TARGET_NR_inotify_add_watch:
          p = lock_user_string(arg2);
          ret = get_errno(sys_inotify_add_watch(arg1, path(p), arg3));
          unlock_user(p, arg2, 0);
          break;
  #endif
! #if defined(TARGET_NR_inotify_rm_watch) && defined(__NR_inotify_rm_watch)
      case TARGET_NR_inotify_rm_watch:
          ret = get_errno(sys_inotify_rm_watch(arg1, arg2));
          break;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]