Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | Fix build with musl by ensuring CTRL is defined. |
| 2 | |
| 3 | musl does not define CTRL in <termios.h>, we could include <sys/ttydefaults.h> |
| 4 | explicitly but it's easier just to ensure CTRL is defined. |
| 5 | |
| 6 | This patch is taken from Sabotage Linux, the license statement for patches and |
| 7 | build scripts in Sabotage Linux says: |
| 8 | |
| 9 | To the extent possible under law, Christian Neukirchen has waived |
| 10 | all copyright and related or neighboring rights to this work. |
| 11 | |
| 12 | http://creativecommons.org/publicdomain/zero/1.0/ |
| 13 | |
| 14 | Therefore this should be good to include in OpenEmbedded. |
| 15 | |
| 16 | Signed-off-by: Paul Barker <paul@paulbarker.me.uk> |
| 17 | |
| 18 | Upstream-Status: Accepted (should be included in v4.8.14) |
| 19 | |
| 20 | diff -u mc-4.8.1.7.org/lib/tty/tty-ncurses.c mc-4.8.1.7/lib/tty/tty-ncurses.c |
| 21 | --- mc-4.8.1.7.org/lib/tty/tty-ncurses.c |
| 22 | +++ mc-4.8.1.7/lib/tty/tty-ncurses.c |
| 23 | @@ -65,7 +65,7 @@ |
| 24 | |
| 25 | /*** file scope macro definitions ****************************************************************/ |
| 26 | |
| 27 | -#if defined(_AIX) && !defined(CTRL) |
| 28 | +#if !defined(CTRL) |
| 29 | #define CTRL(x) ((x) & 0x1f) |
| 30 | #endif |
| 31 | |