fnmatch
=======

POSIX specification:
 https://pubs.opengroup.org/onlinepubs/9699919799/functions/fnmatch.html

LSB specification:
 https://refspecs.linuxbase.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/baselib-fnmatch-3.html

Documentation:

  * Wildcard Matching (libc),

  * man fnmatch.

Gnulib module: fnmatch or fnmatch-gnu

Portability problems fixed by either Gnulib module fnmatch or fnmatch-gnu:

  * This function is missing on some platforms: mingw, MSVC 14.

  * The "?" pattern character fails to match characters outside the single-byte range on some platforms: NetBSD 9.3, Android 13.

  * The "?" pattern character fails to match characters outside the Unicode BMP on some platforms: Solaris 10, Cygwin 3.4.6, MSVC, 32-bit AIX.

  * In the pattern, negated character ranges (such as [!a-z]) are not supported on some platforms: Solaris 11.4.

  * In the pattern, character classes (such as [:alnum:]) inside bracket expressions are not supported on some platforms: FreeBSD 13.2, NetBSD 9.3, Solaris 11 OpenIndiana, Cygwin 3.4.6.

  * In the pattern, character classes (such as [:alnum:]) inside bracket expressions fail to match characters outside the single-byte range on some platforms: Android 13.

  * The character class [:cntrl:] matches the empty string on some platforms: Solaris 11.4.

  * Ranges that start or end with a backslash don't work right on some platforms: glibc 2.3.3.

  * In the pattern, an opening bracket without closing bracket does not match a literal '[' on some platforms: glibc 2.12, macOS 12.5, NetBSD 9.3.

Portability problems fixed by Gnulib module fnmatch-gnu:

  * This function does not support the flags FNM_LEADING_DIR and FNM_CASEFOLD on some platforms: AIX 7.2, HP-UX 11.31, IRIX 6.5, Solaris 10.

  * The flag FNM_CASEFOLD does not work in many situations on some platforms: NetBSD 9.3.

  * The flag FNM_CASEFOLD does not work for multibyte characters consisting of more than one byte on some platforms: Android 13.

  * This function does not support the flag FNM_EXTMATCH on all non-glibc platforms: musl libc, macOS 12.5, FreeBSD 13.2, NetBSD 9.3, OpenBSD 7.2, Minix 3.3, AIX 7.2, HP-UX 11.31, IRIX 6.5, Solaris 11.4, Cygwin 3.4.6, Android 13.

  * This function does not support the flag FNM_FILE_NAME as an alias of FNM_PATHNAME on some platforms: NetBSD 9.3, AIX 7.2, HP-UX 11.31, IRIX 6.5, Solaris 10.

Portability problems not fixed by Gnulib:

Note: Gnulib's replacement function has some limitations:

  * It does not implement patterns with collating elements (such as "[[.ch.]]") or equivalence classes (such as "[[=a=]]").