// Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
+#include "wx/defs.h"
+
+#if wxUSE_JOYSTICK
+
 #include "wx/string.h"
 #define INCL_PM
 #define INCL_DOS
     // TODO
     return FALSE;
 }
+#endif  // wxUSE_JOYSTICK