Skip to content

Instantly share code, notes, and snippets.

@ncopa
Created December 24, 2016 13:50
Show Gist options
  • Save ncopa/fbc607ebe947e774d60088259e11590c to your computer and use it in GitHub Desktop.
Save ncopa/fbc607ebe947e774d60088259e11590c to your computer and use it in GitHub Desktop.
/*
* With XPG4, you must define _XOPEN_SOURCE_EXTENDED, it is redundant (or
* conflicting) when _XOPEN_SOURCE is 500 or greater. If NCURSES_WIDECHAR is
* not already defined, e.g., if the platform relies upon nonstandard feature
* test macros, define it at this point if the standard feature test macros
* indicate that it should be defined.
*/
#ifndef NCURSES_WIDECHAR
#if defined(_XOPEN_SOURCE_EXTENDED) || (defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE - 0 >= 500))
#define NCURSES_WIDECHAR 1
#else
#define NCURSES_WIDECHAR 0
#endif
#endif /* NCURSES_WIDECHAR */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment