#include "wx/joystick.h"
+#ifndef WX_PRECOMP
+ #include "wx/event.h"
+ #include "wx/window.h"
+#endif //WX_PRECOMP
+
#include <linux/joystick.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <unistd.h>
-#include "wx/event.h"
-#include "wx/window.h"
+#ifdef HAVE_SYS_SELECT_H
+# include <sys/select.h>
+#endif
+
#include "wx/unix/private.h"
enum {