]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Make support for the FBIOGET ioctls conditional on linux/fb.h being
authorTom Hughes <tom@compton.nu>
Thu, 22 Apr 2004 07:28:43 +0000 (07:28 +0000)
committerTom Hughes <tom@compton.nu>
Thu, 22 Apr 2004 07:28:43 +0000 (07:28 +0000)
present at compile time.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2382

configure.in
coregrind/vg_syscalls.c
coregrind/vg_unsafe.h

index 8842f8a2bbfc79b8e704cb4c7796975f2d04768d..9df9883e1baa2bfeef26f3049e353c81daa1cb63 100644 (file)
@@ -331,7 +331,7 @@ AC_SUBST(PREFERRED_STACK_BOUNDARY)
 
 # Checks for header files.
 AC_HEADER_STDC
-AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/socket.h sys/statfs.h sys/time.h sys/endian.h endian.h termios.h unistd.h utime.h])
+AC_CHECK_HEADERS([fcntl.h stdlib.h string.h sys/socket.h sys/statfs.h sys/time.h sys/endian.h endian.h termios.h unistd.h utime.h linux/fb.h])
 
 # Checks for typedefs, structures, and compiler characteristics.
 AC_TYPE_UID_T
index 31f5d491610a5e9b1bc273094df973e4c1787f94..d0ffca7ac11dcaa5d698a64bbe6b8f74a49a8a30 100644 (file)
@@ -3231,6 +3231,7 @@ PRE(ioctl)
    case CDROM_CLEAR_OPTIONS: /* 0x5321 */
       break;
       
+#ifdef HAVE_LINUX_FB_H
    case FBIOGET_VSCREENINFO: /* 0x4600 */
       SYSCALL_TRACK( pre_mem_write,tid,
                      "ioctl(FBIOGET_VSCREENINFO)", arg3,
@@ -3241,6 +3242,7 @@ PRE(ioctl)
                      "ioctl(FBIOGET_FSCREENINFO)", arg3,
                      sizeof(struct fb_fix_screeninfo));
       break;
+#endif
 
       /* We don't have any specific information on it, so
         try to do something reasonable based on direction and
@@ -3595,6 +3597,7 @@ POST(ioctl)
    case CDROM_CLEAR_OPTIONS: /* 0x5321 */
       break;
 
+#ifdef HAVE_LINUX_FB_H
    case FBIOGET_VSCREENINFO: //0x4600
       if (res == 0)
          VG_TRACK( post_mem_write,arg3, sizeof(struct fb_var_screeninfo));
@@ -3603,6 +3606,7 @@ POST(ioctl)
       if (res == 0)
          VG_TRACK( post_mem_write,arg3, sizeof(struct fb_fix_screeninfo));
       break;
+#endif
 
       /* We don't have any specific information on it, so
         try to do something reasonable based on direction and
index 2e86f252bdddfc72847d4a805f6ea8e2d9cb010a..cfeac81f4ca845e906832d95b0117f89cb7a7574 100644 (file)
@@ -63,7 +63,9 @@
 #include <linux/cdrom.h>  /* for cd-rom ioctls */
 #include <signal.h>       /* for siginfo_t */
 #include <linux/timex.h>  /* for adjtimex */
+#ifdef HAVE_LINUX_FB_H
 #include <linux/fb.h>     /* for fb_* structs */
+#endif
 
 #define __USE_LARGEFILE64
 #include <sys/stat.h>     /* for struct stat */