AgentD / squashfs-tools-ng

A new set of tools and libraries for working with SquashFS images
Other
196 stars 30 forks source link

Error building too few arguments to function ‘sqfs_dir_reader_open_dir’ #61

Closed olethanh closed 4 years ago

olethanh commented 4 years ago

Hello, I'm getting an error while building on Ubuntu 19.10, from git on tag v1.0.0

make  all-am
make[1]: Entering directory '/home/olivier/Projects/Workbench/squashfs-tools-ng'
  CC       bin/gensquashfs/gensquashfs-mkfs.o
  CC       bin/gensquashfs/gensquashfs-options.o
  CC       bin/gensquashfs/gensquashfs-selinux.o
  CC       bin/gensquashfs/gensquashfs-dirscan.o
  CC       bin/gensquashfs/gensquashfs-dirscan_xattr.o
  CC       lib/common/libcommon_a-serialize_fstree.o
  CC       lib/common/libcommon_a-statistics.o
  CC       lib/common/libcommon_a-inode_stat.o
  CC       lib/common/libcommon_a-hardlink.o
  CC       lib/common/libcommon_a-print_version.o
  CC       lib/common/libcommon_a-data_reader_dump.o
  CC       lib/common/libcommon_a-compress.o
  CC       lib/common/libcommon_a-comp_opt.o
  CC       lib/common/libcommon_a-data_writer.o
  CC       lib/common/libcommon_a-get_path.o
  CC       lib/common/libcommon_a-io_stdin.o
  CC       lib/common/libcommon_a-writer.o
  CC       lib/common/libcommon_a-perror.o
  CC       lib/common/libcommon_a-mkdir_p.o
  CC       lib/common/libcommon_a-parse_size.o
  CC       lib/common/libcommon_a-print_size.o
  AR       libcommon.a
ar: `u' modifier ignored since `D' is the default (see `U')
  CC       lib/sqfs/libsquashfs_la-id_table.lo
  CC       lib/sqfs/libsquashfs_la-super.lo
  CC       lib/sqfs/libsquashfs_la-readdir.lo
  CC       lib/sqfs/xattr/libsquashfs_la-xattr.lo
  CC       lib/sqfs/libsquashfs_la-write_table.lo
  CC       lib/sqfs/libsquashfs_la-meta_writer.lo
  CC       lib/sqfs/libsquashfs_la-read_super.lo
  CC       lib/sqfs/libsquashfs_la-meta_reader.lo
  CC       lib/sqfs/libsquashfs_la-read_inode.lo
  CC       lib/sqfs/libsquashfs_la-write_inode.lo
  CC       lib/sqfs/libsquashfs_la-dir_writer.lo
  CC       lib/sqfs/xattr/libsquashfs_la-xattr_reader.lo
  CC       lib/sqfs/libsquashfs_la-read_table.lo
  CC       lib/sqfs/comp/libsquashfs_la-compressor.lo
  CC       lib/sqfs/libsquashfs_la-dir_reader.lo
  CC       lib/sqfs/libsquashfs_la-read_tree.lo
  CC       lib/sqfs/libsquashfs_la-inode.lo
  CC       lib/sqfs/xattr/libsquashfs_la-xattr_writer.lo
  CC       lib/sqfs/xattr/libsquashfs_la-xattr_writer_flush.lo
  CC       lib/sqfs/xattr/libsquashfs_la-xattr_writer_record.lo
  CC       lib/sqfs/libsquashfs_la-write_super.lo
  CC       lib/sqfs/libsquashfs_la-data_reader.lo
  CC       lib/sqfs/block_processor/libsquashfs_la-common.lo
  CC       lib/sqfs/block_processor/libsquashfs_la-frontend.lo
      CC       lib/sqfs/libsquashfs_la-frag_table.lo
  CC       lib/sqfs/libsquashfs_la-block_writer.lo
^[[6~  CC       lib/util/libsquashfs_la-str_table.lo
  CC       lib/util/libsquashfs_la-alloc.lo
  CC       lib/util/libsquashfs_la-xxhash.lo
  CC       lib/util/libsquashfs_la-hash_table.lo
  CC       lib/sqfs/unix/libsquashfs_la-io_file.lo
  CC       lib/sqfs/block_processor/libsquashfs_la-winpthread.lo
  CC       lib/sqfs/comp/libsquashfs_la-gzip.lo
  CCLD     libsquashfs.la
ar: `u' modifier ignored since `D' is the default (see `U')
  CC       lib/fstree/libfstree_a-fstree.o
  CC       lib/fstree/libfstree_a-fstree_from_file.o
  CC       lib/fstree/libfstree_a-fstree_sort.o
  CC       lib/fstree/libfstree_a-hardlink.o
  CC       lib/fstree/libfstree_a-post_process.o
  CC       lib/fstree/libfstree_a-get_path.o
  CC       lib/fstree/libfstree_a-mknode.o
  CC       lib/fstree/libfstree_a-add_by_path.o
  CC       lib/fstree/libfstree_a-get_by_path.o
  CC       lib/fstree/libfstree_a-source_date_epoch.o
  CC       lib/fstree/libfstree_a-canonicalize_name.o
  CC       lib/fstree/libfstree_a-filename_sane.o
  AR       libfstree.a
ar: `u' modifier ignored since `D' is the default (see `U')
  CC       lib/compat/getline.o
  CC       lib/compat/getsubopt.o
  CC       lib/compat/strndup.o
  CC       lib/compat/mockups.o
  CC       lib/compat/chdir.o
  CC       lib/compat/path_to_windows.o
  AR       libcompat.a
ar: `u' modifier ignored since `D' is the default (see `U')
  CCLD     gensquashfs
  CC       bin/rdsquashfs/rdsquashfs-rdsquashfs.o
  CC       bin/rdsquashfs/rdsquashfs-list_files.o
  CC       bin/rdsquashfs/rdsquashfs-options.o
  CC       bin/rdsquashfs/rdsquashfs-restore_fstree.o
  CC       bin/rdsquashfs/rdsquashfs-describe.o
  CC       bin/rdsquashfs/rdsquashfs-fill_files.o
  CC       bin/rdsquashfs/rdsquashfs-dump_xattrs.o
  CCLD     rdsquashfs
  CC       bin/sqfs2tar/sqfs2tar-sqfs2tar.o
  CC       bin/sqfs2tar/sqfs2tar-options.o
  CC       bin/sqfs2tar/sqfs2tar-write_tree.o
  CC       bin/sqfs2tar/sqfs2tar-xattr.o
  CC       lib/util/libutil_a-str_table.o
  CC       lib/util/libutil_a-alloc.o
  CC       lib/util/libutil_a-rbtree.o
  CC       lib/util/libutil_a-xxhash.o
  CC       lib/util/libutil_a-hash_table.o
  AR       libutil.a
ar: `u' modifier ignored since `D' is the default (see `U')
  CC       lib/tar/libtar_a-read_header.o
  CC       lib/tar/libtar_a-write_header.o
  CC       lib/tar/libtar_a-skip.o
  CC       lib/tar/libtar_a-number.o
  CC       lib/tar/libtar_a-checksum.o
  CC       lib/tar/libtar_a-cleanup.o
  CC       lib/tar/libtar_a-read_sparse_map.o
  CC       lib/tar/libtar_a-read_sparse_map_old.o
  CC       lib/tar/libtar_a-base64.o
  CC       lib/tar/libtar_a-urldecode.o
  CC       lib/tar/libtar_a-padd_file.o
  CC       lib/tar/libtar_a-read_retry.o
  CC       lib/tar/libtar_a-write_retry.o
  CC       lib/tar/libtar_a-pax_header.o
  AR       libtar.a
ar: `u' modifier ignored since `D' is the default (see `U')
  CCLD     sqfs2tar
  CC       bin/sqfsdiff/sqfsdiff-sqfsdiff.o
  CC       bin/sqfsdiff/sqfsdiff-util.o
  CC       bin/sqfsdiff/sqfsdiff-options.o
  CC       bin/sqfsdiff/sqfsdiff-compare_dir.o
  CC       bin/sqfsdiff/sqfsdiff-node_compare.o
  CC       bin/sqfsdiff/sqfsdiff-compare_files.o
  CC       bin/sqfsdiff/sqfsdiff-super.o
  CC       bin/sqfsdiff/sqfsdiff-extract.o
  CCLD     sqfsdiff
  CC       bin/tar2sqfs/tar2sqfs-tar2sqfs.o
  CC       bin/tar2sqfs/tar2sqfs-options.o
  CC       bin/tar2sqfs/tar2sqfs-process_tarball.o
  CCLD     tar2sqfs
  CC       extras/sqfsbrowse-browse.o
extras/browse.c: In function ‘list_directory’:
extras/browse.c:66:9: error: too few arguments to function ‘sqfs_dir_reader_open_dir’
   66 |   ret = sqfs_dir_reader_open_dir(dr, working_dir);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from extras/browse.c:3:
./include/sqfs/dir_reader.h:190:14: note: declared here
  190 | SQFS_API int sqfs_dir_reader_open_dir(sqfs_dir_reader_t *rd,
      |              ^~~~~~~~~~~~~~~~~~~~~~~~
extras/browse.c:77:9: error: too few arguments to function ‘sqfs_dir_reader_open_dir’
   77 |   ret = sqfs_dir_reader_open_dir(dr, inode);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from extras/browse.c:3:
./include/sqfs/dir_reader.h:190:14: note: declared here
  190 | SQFS_API int sqfs_dir_reader_open_dir(sqfs_dir_reader_t *rd,
      |              ^~~~~~~~~~~~~~~~~~~~~~~~
extras/browse.c:87:9: error: too few arguments to function ‘sqfs_dir_reader_open_dir’
   87 |   ret = sqfs_dir_reader_open_dir(dr, inode);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~
In file included from extras/browse.c:3:
./include/sqfs/dir_reader.h:190:14: note: declared here
  190 | SQFS_API int sqfs_dir_reader_open_dir(sqfs_dir_reader_t *rd,
      |              ^~~~~~~~~~~~~~~~~~~~~~~~
extras/browse.c: In function ‘main’:
extras/browse.c:529:7: error: too few arguments to function ‘sqfs_dir_reader_create’
  529 |  dr = sqfs_dir_reader_create(&super, cmp, file);
      |       ^~~~~~~~~~~~~~~~~~~~~~
In file included from extras/browse.c:3:
./include/sqfs/dir_reader.h:168:29: note: declared here
  168 | SQFS_API sqfs_dir_reader_t *sqfs_dir_reader_create(const sqfs_super_t *super,
      |                             ^~~~~~~~~~~~~~~~~~~~~~
extras/browse.c:542:9: error: too few arguments to function ‘sqfs_data_reader_create’
  542 |  data = sqfs_data_reader_create(file, super.block_size, cmp);
      |         ^~~~~~~~~~~~~~~~~~~~~~~
In file included from extras/browse.c:1:
./include/sqfs/data_reader.h:70:30: note: declared here
   70 | SQFS_API sqfs_data_reader_t *sqfs_data_reader_create(sqfs_file_t *file,
      |                              ^~~~~~~~~~~~~~~~~~~~~~~
make[1]: *** [Makefile:3985: extras/sqfsbrowse-browse.o] Error 1
make[1]: Leaving directory '/home/olivier/Projects/Workbench/squashfs-tools-ng'
make: *** [Makefile:1663: all] Error 2

Any idea what the problem may be or how to debug it?

olethanh commented 4 years ago

I managed to build v0.9.1

mattst88 commented 4 years ago

This was resolved by 4c10a491a2ddfcdc3226431a71aefd6ca71135d4.

AgentD commented 4 years ago

This was resolved by 4c10a49.

Also, a signed patch (number 0001) is exported here: https://infraroot.at/pub/squashfs/patches-1.0.0/, and also contained in the fixes-1.0.0 branch.

olethanh commented 4 years ago

thanks