source: branches/libc-0.6/src/emx/include/sys/dirtree.h

Last change on this file was 3809, checked in by bird, 11 years ago

0.6: s/const/const/g - just use the (now) standard 'const' everywhere in emx and kLIBC code. Avoid changing external code too much. fixes #279.

  • Property cvs2svn:cvs-rev set to 1.2
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 1.2 KB
Line 
1/* sys/dirtree.h (emx+gcc) */
2
3#ifndef _SYS_DIRTREE_H
4#define _SYS_DIRTREE_H
5
6#include <sys/cdefs.h>
7#include <sys/_types.h>
8
9#if !defined(_TIME_T_DECLARED) && !defined(_TIME_T)
10typedef __time_t time_t;
11#define _TIME_T_DECLARED
12#define _TIME_T
13#endif
14
15#if !defined(_OFF_T_DECLARED) && !defined(_OFF_T)
16typedef __off_t off_t; /* file offset */
17#define _OFF_T_DECLARED
18#define _OFF_T
19#endif
20
21struct _dt_node
22{
23 struct _dt_node *next; /* Pointer to next entry of same level */
24 struct _dt_node *sub; /* Pointer to next level (child) */
25 char *name; /* Name */
26 off_t size; /* File size */
27 long user; /* Available for user */
28 time_t mtime; /* Timestamp for last update */
29 unsigned char attr; /* Attributes */
30};
31
32struct _dt_tree
33{
34 struct _dt_node *tree;
35 char *strings;
36};
37
38#define _DT_TREE 0x4000
39#define _DT_NOCPDIR 0x8000
40
41__BEGIN_DECLS
42void _dt_free (struct _dt_tree *dt);
43struct _dt_tree *_dt_read (const char *dir, const char *mask,
44 unsigned flags);
45void _dt_sort (struct _dt_tree *dt, const char *spec);
46int _dt_split (const char *src, char *dir, char *mask);
47__END_DECLS
48
49#endif /* !_SYS_DIRTREE_H */
Note: See TracBrowser for help on using the repository browser.