bd033a067c62283f4f80583ec02380ad218cec22
[platform/upstream/rpm.git] / misc / miscfn.h
1 #ifndef H_MISCFN
2 #define H_MISCFN
3
4 #include "config.h"
5
6 #if HAVE_FNMATCH_H
7 #include <fnmatch.h>
8 #else
9 #include "misc-fnmatch.h"
10 #endif
11
12 #if HAVE_GLOB_H
13 #include <glob.h>
14 #else
15 #include "misc-glob.h"
16 #endif
17
18 #if ! HAVE_REALPATH
19 char *realpath(char *path, char resolved_path[]);
20 #endif
21
22 #if ! HAVE_S_IFSOCK
23 #define S_IFSOCK (0)
24 #endif
25
26 #if ! HAVE_S_ISLNK
27 #define S_ISLNK(mode) ((mode) & S_IFLNK)
28 #endif
29
30 #if ! HAVE_S_ISSOCK
31 #define S_ISSOCK(mode) ((mode) & S_IFSOCK)
32 #endif
33
34 #if NEED_STRINGS_H
35 #include <strings.h>
36 #endif
37
38 #if ! HAVE_REALPATH
39 char *realpath(const char *path, char resolved_path []);
40 #endif
41
42 #if NEED_TIMEZONE
43 #include <sys/stdtypes.h>
44 extern time_t timezone;
45 #endif
46
47 #if NEED_MYREALLOC
48 #include <sys/stdtypes.h>
49 #define realloc(ptr,size) myrealloc(ptr,size)
50 extern void *myrealloc(void *, size_t);
51 #endif
52
53 #endif