This uses the function fnmatch() which is not available on all platforms (notably Windows), so import the implementation from NetBSD into src/port.