summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2022-07-05 15:50:09 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2022-07-08 19:17:35 +0200
commit62753ec36958c40f151fa223605aea5e6a50bd89 (patch)
tree9d07d8f920efca95d7d74b2d72bdc90c87e64fe0
parenta412425bca4bb90a7c1b35acac6b185158f3cd4f (diff)
Cleanup: Get rid of libfstree "internal.h" header
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
-rw-r--r--include/fstree.h2
-rw-r--r--lib/fstree/Makemodule.am3
-rw-r--r--lib/fstree/fstree.c4
-rw-r--r--lib/fstree/fstree_from_dir.c2
-rw-r--r--lib/fstree/internal.h15
-rw-r--r--lib/fstree/mknode.c3
-rw-r--r--lib/fstree/post_process.c3
-rw-r--r--tests/libfstree/Makemodule.am1
-rw-r--r--tests/libfstree/fstree_init.c1
9 files changed, 10 insertions, 24 deletions
diff --git a/include/fstree.h b/include/fstree.h
index 7bdbddf..1c5e5ef 100644
--- a/include/fstree.h
+++ b/include/fstree.h
@@ -269,4 +269,6 @@ int fstree_from_subdir(fstree_t *fs, tree_node_t *root,
int fstree_sort_files(fstree_t *fs, istream_t *sortfile);
+void fstree_insert_sorted(tree_node_t *root, tree_node_t *n);
+
#endif /* FSTREE_H */
diff --git a/lib/fstree/Makemodule.am b/lib/fstree/Makemodule.am
index a72b820..4388bde 100644
--- a/lib/fstree/Makemodule.am
+++ b/lib/fstree/Makemodule.am
@@ -3,8 +3,7 @@ libfstree_a_SOURCES += lib/fstree/hardlink.c
libfstree_a_SOURCES += lib/fstree/post_process.c lib/fstree/get_path.c
libfstree_a_SOURCES += lib/fstree/mknode.c lib/fstree/fstree_from_dir.c
libfstree_a_SOURCES += lib/fstree/add_by_path.c lib/fstree/get_by_path.c
-libfstree_a_SOURCES += include/fstree.h lib/fstree/internal.h
-libfstree_a_SOURCES += lib/fstree/sort_by_file.c
+libfstree_a_SOURCES += include/fstree.h lib/fstree/sort_by_file.c
libfstree_a_CFLAGS = $(AM_CFLAGS)
libfstree_a_CPPFLAGS = $(AM_CPPFLAGS)
diff --git a/lib/fstree/fstree.c b/lib/fstree/fstree.c
index 2ea5fa2..d44a8ae 100644
--- a/lib/fstree/fstree.c
+++ b/lib/fstree/fstree.c
@@ -4,7 +4,9 @@
*
* Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
*/
-#include "internal.h"
+#include "config.h"
+#include "fstree.h"
+
#include "util/util.h"
#include <string.h>
diff --git a/lib/fstree/fstree_from_dir.c b/lib/fstree/fstree_from_dir.c
index a11f383..01f331d 100644
--- a/lib/fstree/fstree_from_dir.c
+++ b/lib/fstree/fstree_from_dir.c
@@ -5,7 +5,7 @@
* Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
*/
#include "config.h"
-#include "internal.h"
+#include "fstree.h"
#include <dirent.h>
#include <stdlib.h>
diff --git a/lib/fstree/internal.h b/lib/fstree/internal.h
deleted file mode 100644
index b876e45..0000000
--- a/lib/fstree/internal.h
+++ /dev/null
@@ -1,15 +0,0 @@
-/* SPDX-License-Identifier: GPL-3.0-or-later */
-/*
- * internal.h
- *
- * Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
- */
-#ifndef FSTREE_INTERNAL_H
-#define FSTREE_INTERNAL_H
-
-#include "config.h"
-#include "fstree.h"
-
-void fstree_insert_sorted(tree_node_t *root, tree_node_t *n);
-
-#endif /* FSTREE_INTERNAL_H */
diff --git a/lib/fstree/mknode.c b/lib/fstree/mknode.c
index 2b1f89d..2faf901 100644
--- a/lib/fstree/mknode.c
+++ b/lib/fstree/mknode.c
@@ -5,8 +5,7 @@
* Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
*/
#include "config.h"
-
-#include "internal.h"
+#include "fstree.h"
#include <string.h>
#include <stdlib.h>
diff --git a/lib/fstree/post_process.c b/lib/fstree/post_process.c
index 93a7664..088916b 100644
--- a/lib/fstree/post_process.c
+++ b/lib/fstree/post_process.c
@@ -4,7 +4,8 @@
*
* Copyright (C) 2019 David Oberhollenzer <goliath@infraroot.at>
*/
-#include "internal.h"
+#include "config.h"
+#include "fstree.h"
#include <stdlib.h>
#include <string.h>
diff --git a/tests/libfstree/Makemodule.am b/tests/libfstree/Makemodule.am
index 2e22967..7826cf8 100644
--- a/tests/libfstree/Makemodule.am
+++ b/tests/libfstree/Makemodule.am
@@ -40,7 +40,6 @@ test_fstree_from_dir_CPPFLAGS += -DTESTPATH=$(top_srcdir)/tests/libtar/data
test_fstree_from_dir_LDADD = libfstree.a libutil.a libcompat.a
test_fstree_init_SOURCES = tests/libfstree/fstree_init.c
-test_fstree_init_CPPFLAGS = $(AM_CPPFLAGS) -I$(top_srcdir)/lib/fstree
test_fstree_init_LDADD = libfstree.a libio.a libutil.a libcompat.a
test_sort_file_SOURCES = tests/libfstree/sort_file.c
diff --git a/tests/libfstree/fstree_init.c b/tests/libfstree/fstree_init.c
index 47c24ae..186f25b 100644
--- a/tests/libfstree/fstree_init.c
+++ b/tests/libfstree/fstree_init.c
@@ -7,7 +7,6 @@
#include "config.h"
#include "fstree.h"
-#include "internal.h"
#include "util/test.h"
#include "util/util.h"