Whamcloud - gitweb
LU-18630 misc: fix --without-libarchive build failure
authorLi Dongyang <dongyangli@ddn.com>
Wed, 15 Jan 2025 03:45:43 +0000 (14:45 +1100)
committerLi Dongyang <dongyangli@ddn.com>
Fri, 17 Jan 2025 02:23:16 +0000 (13:23 +1100)
configure --without-libarchive triggers the error:

./../misc/create_inode_libarchive.c: In function ‘__populate_fs_from_tar’:
./../misc/create_inode_libarchive.c:25:34: error: parameter name omitted
 errcode_t __populate_fs_from_tar(ext2_filsys, ext2_ino_t, const char *,
                                  ^~~~~~~~~~~
./../misc/create_inode_libarchive.c:25:47: error: parameter name omitted
 errcode_t __populate_fs_from_tar(ext2_filsys, ext2_ino_t, const char *,
                                               ^~~~~~~~~~
./../misc/create_inode_libarchive.c:25:59: error: parameter name omitted
 errcode_t __populate_fs_from_tar(ext2_filsys, ext2_ino_t, const char *,
                                                           ^~~~~~~~~~~~
./../misc/create_inode_libarchive.c:26:34: error: parameter name omitted
                                  ext2_ino_t, struct hdlinks_s *,
                                  ^~~~~~~~~~
./../misc/create_inode_libarchive.c:26:46: error: parameter name omitted
                                  ext2_ino_t, struct hdlinks_s *,
                                              ^~~~~~~~~~~~~~~~~~
./../misc/create_inode_libarchive.c:27:34: error: parameter name omitted
                                  struct file_info *,
                                  ^~~~~~~~~~~~~~~~~~
./../misc/create_inode_libarchive.c:28:34: error: parameter name omitted
                                  struct fs_ops_callbacks *) {
                                  ^~~~~~~~~~~~~~~~~~~~~~~~~

Fixes: ecfd4dd1217a ("Decouple --without-libarchive and HAVE_ARCHIVE_H")

Change-Id: I1d8313b5a3622eb17515f2f751a7e4dd0df7a2b1
Signed-off-by: Li Dongyang <dongyangli@ddn.com>
misc/create_inode_libarchive.c

index 9c8e53e..f89ac1e 100644 (file)
 
 /* If ./configure was run with --without-libarchive, then only
  * __populate_fs_from_tar() remains in this file and will return an error. */
-errcode_t __populate_fs_from_tar(ext2_filsys, ext2_ino_t, const char *,
-                                 ext2_ino_t, struct hdlinks_s *,
-                                 struct file_info *,
-                                 struct fs_ops_callbacks *) {
+errcode_t __populate_fs_from_tar(ext2_filsys fs, ext2_ino_t root_ino,
+                                const char *source_tar, ext2_ino_t root,
+                                struct hdlinks_s *hdlinks,
+                                struct file_info *target,
+                                struct fs_ops_callbacks *fs_callbacks) {
   com_err(__func__, 0,
           _("you need to compile e2fsprogs without --without-libarchive"
             "be able to process tarballs"));