00001 /* $NetBSD: fnmatch.h,v 1.12 2005/02/03 04:39:32 perry Exp $ */ 00002 00003 /*- 00004 * Copyright (c) 1992, 1993 00005 * The Regents of the University of California. All rights reserved. 00006 * 00007 * Redistribution and use in source and binary forms, with or without 00008 * modification, are permitted provided that the following conditions 00009 * are met: 00010 * 1. Redistributions of source code must retain the above copyright 00011 * notice, this list of conditions and the following disclaimer. 00012 * 2. Redistributions in binary form must reproduce the above copyright 00013 * notice, this list of conditions and the following disclaimer in the 00014 * documentation and/or other materials provided with the distribution. 00015 * 3. Neither the name of the University nor the names of its contributors 00016 * may be used to endorse or promote products derived from this software 00017 * without specific prior written permission. 00018 * 00019 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 00020 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 00021 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 00022 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 00023 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 00024 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 00025 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 00026 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 00027 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 00028 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 00029 * SUCH DAMAGE. 00030 * 00031 * @(#)fnmatch.h 8.1 (Berkeley) 6/2/93 00032 */ 00033 00034 #ifndef _LIBU_FNMATCH_H_ 00035 #define _LIBU_FNMATCH_H_ 00036 #include <u/libu_conf.h> 00037 00038 #ifdef HAVE_FNMATCH 00039 #include <fnmatch.h> 00040 #else 00041 00042 #ifdef __cplusplus 00043 extern "C" { 00044 #endif 00045 00046 #define FNM_NOMATCH 1 /* Match failed. */ 00047 #define FNM_NOSYS 2 /* Function not implemented. */ 00048 00049 #define FNM_NOESCAPE 0x01 /* Disable backslash escaping. */ 00050 #define FNM_PATHNAME 0x02 /* Slash must be matched by slash. */ 00051 #define FNM_PERIOD 0x04 /* Period must be matched by period. */ 00052 00053 #define FNM_CASEFOLD 0x08 /* Pattern is matched case-insensitive */ 00054 #define FNM_LEADING_DIR 0x10 /* Ignore /<tail> after Imatch. */ 00055 00056 int fnmatch(const char *, const char *, int); 00057 00058 #ifdef __cplusplus 00059 } 00060 #endif 00061 00062 #endif /* ! HAVE_FNMATCH */ 00063 00064 #endif /* ! _LIBU_FNMATCH_H_ */