Przeglądaj źródła

Set nuttx isatty definition according to CONFIG_SERIAL_TERMIOS (#1234)

The isatty definition on nuttx depends on CONFIG_SERIAL_TERMIOS
dongsheng28849455 3 lat temu
rodzic
commit
bc6eda2803
1 zmienionych plików z 7 dodań i 0 usunięć
  1. 7 0
      core/shared/platform/nuttx/platform_internal.h

+ 7 - 0
core/shared/platform/nuttx/platform_internal.h

@@ -68,6 +68,13 @@ typedef pthread_t korp_thread;
 #define O_NOFOLLOW 0
 #endif
 
+#undef CONFIG_HAS_ISATTY
+#ifdef CONFIG_SERIAL_TERMIOS
+#define CONFIG_HAS_ISATTY 1
+#else
+#define CONFIG_HAS_ISATTY 0
+#endif
+
 /*
  * NuttX doesn't have openat family.
  */