aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/fstree.h7
-rw-r--r--lib/fstree/Makemodule.am1
-rw-r--r--unpack/Makemodule.am2
-rw-r--r--unpack/optimize_unpack_order.c (renamed from lib/fstree/optimize_unpack_order.c)2
-rw-r--r--unpack/rdsquashfs.h2
5 files changed, 4 insertions, 10 deletions
diff --git a/include/fstree.h b/include/fstree.h
index 05e1ebe..426964d 100644
--- a/include/fstree.h
+++ b/include/fstree.h
@@ -293,13 +293,6 @@ void tree_node_sort_recursive(tree_node_t *root);
tree_node_t *fstree_node_from_path(fstree_t *fs, const char *path);
/*
- Optimize the order of the fstree file list for unpacking as to avoid
- unpacking fragment blocks more than once and to improve locality when
- fetching data from disk.
- */
-file_info_t *optimize_unpack_order(fstree_t *fs);
-
-/*
Convert back to forward slashed, remove all preceeding and trailing slashes,
collapse all sequences of slashes, remove all path components that are '.'
and returns failure state if one of the path components is '..'.
diff --git a/lib/fstree/Makemodule.am b/lib/fstree/Makemodule.am
index c3c56fb..00150fd 100644
--- a/lib/fstree/Makemodule.am
+++ b/lib/fstree/Makemodule.am
@@ -5,7 +5,6 @@ libfstree_a_SOURCES += lib/fstree/node_stat.c lib/fstree/mknode.c
libfstree_a_SOURCES += lib/fstree/add_by_path.c lib/fstree/xattr.c
libfstree_a_SOURCES += lib/fstree/node_from_path.c include/fstree.h
libfstree_a_SOURCES += lib/fstree/gen_file_list.c
-libfstree_a_SOURCES += lib/fstree/optimize_unpack_order.c
libfstree_a_SOURCES += lib/fstree/canonicalize_name.c
libfstree_a_SOURCES += lib/fstree/source_date_epoch.c
libfstree_a_CFLAGS = $(AM_CFLAGS) $(LIBSELINUX_CFLAGS)
diff --git a/unpack/Makemodule.am b/unpack/Makemodule.am
index b60292d..964cc05 100644
--- a/unpack/Makemodule.am
+++ b/unpack/Makemodule.am
@@ -1,7 +1,7 @@
rdsquashfs_SOURCES = unpack/rdsquashfs.c unpack/rdsquashfs.h
rdsquashfs_SOURCES += unpack/list_files.c unpack/options.c
rdsquashfs_SOURCES += unpack/restore_fstree.c unpack/describe.c
-rdsquashfs_SOURCES += unpack/fill_files.c
+rdsquashfs_SOURCES += unpack/fill_files.c unpack/optimize_unpack_order.c
rdsquashfs_LDADD = libsqfshelper.a libsquashfs.la libfstree.a libutil.la
bin_PROGRAMS += rdsquashfs
diff --git a/lib/fstree/optimize_unpack_order.c b/unpack/optimize_unpack_order.c
index 972d4b3..a76dd51 100644
--- a/lib/fstree/optimize_unpack_order.c
+++ b/unpack/optimize_unpack_order.c
@@ -5,7 +5,7 @@
* Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
*/
#include "config.h"
-#include "fstree.h"
+#include "rdsquashfs.h"
static bool has_fragment(const fstree_t *fs, const file_info_t *file)
{
diff --git a/unpack/rdsquashfs.h b/unpack/rdsquashfs.h
index b5570dd..065f4aa 100644
--- a/unpack/rdsquashfs.h
+++ b/unpack/rdsquashfs.h
@@ -74,4 +74,6 @@ int describe_tree(tree_node_t *root, const char *unpack_root);
void process_command_line(options_t *opt, int argc, char **argv);
+file_info_t *optimize_unpack_order(fstree_t *fs);
+
#endif /* RDSQUASHFS_H */