summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/corelib/io/qfilesystemwatcher_inotify.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/corelib/io/qfilesystemwatcher_inotify.cpp b/src/corelib/io/qfilesystemwatcher_inotify.cpp
index 0b4ba61..58e0707 100644
--- a/src/corelib/io/qfilesystemwatcher_inotify.cpp
+++ b/src/corelib/io/qfilesystemwatcher_inotify.cpp
@@ -138,6 +138,11 @@
# define __NR_inotify_add_watch 285
# define __NR_inotify_rm_watch 286
# define __NR_inotify_init1 328
+#elif defined (__aarch64__)
+# define __NR_inotify_init1 26
+# define __NR_inotify_add_watch 27
+# define __NR_inotify_rm_watch 28
+// no inotify_init for aarch64
#else
# error "This architecture is not supported. Please talk to qt-bugs@trolltech.com"
#endif
@@ -155,7 +160,11 @@ static inline int syscall(...) { return -1; }
static inline int inotify_init()
{
+#ifdef __NR_inotify_init
return syscall(__NR_inotify_init);
+#else
+ return syscall(__NR_inotify_init1, 0);
+#endif
}
static inline int inotify_add_watch(int fd, const char *name, __u32 mask)