aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/fstree.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/fstree.h b/include/fstree.h
index 884ff51..ac92daa 100644
--- a/include/fstree.h
+++ b/include/fstree.h
@@ -17,6 +17,12 @@
#include "sqfs/predef.h"
#include "compat.h"
+enum {
+ DIR_SCAN_KEEP_TIME = 0x01,
+
+ DIR_SCAN_ONE_FILESYSTEM = 0x02,
+};
+
#define FSTREE_MODE_HARD_LINK (0)
#define FSTREE_MODE_HARD_LINK_RESOLVED (1)
@@ -230,4 +236,11 @@ tree_node_t *fstree_add_hard_link(fstree_t *fs, const char *path,
*/
int fstree_resolve_hard_link(fstree_t *fs, tree_node_t *node);
+/*
+ Recursively scan a directory to build a file system tree.
+
+ Returns 0 on success, prints to stderr on failure.
+ */
+int fstree_from_dir(fstree_t *fs, const char *path, unsigned int flags);
+
#endif /* FSTREE_H */