ifuse icon indicating copy to clipboard operation
ifuse copied to clipboard

build on Apple M3 with macfuse 4.10.2 faild

Open ttxs69 opened this issue 7 months ago • 1 comments

Making all in docs
make[2]: Nothing to be done for `all'.
Making all in src
gcc -DHAVE_CONFIG_H -I. -I..    -I/usr/local/include/fuse -D_FILE_OFFSET_BITS=64 -I/usr/local/include -I/usr/local/include -g -arch arm64 -arch x86_64 -isysroot /Applications/Xcode_bak.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.2.sdk -MT ifuse.o -MD -MP -MF .deps/ifuse.Tpo -c -o ifuse.o ifuse.c
ifuse.c:278:125: warning: declaration of 'enum fuse_readdir_flags' will not be visible outside of this function [-Wvisibility]
  278 | static int ifuse_readdir(const char *path, void *buf, fuse_fill_dir_t filler, off_t offset, struct fuse_file_info *fi, enum fuse_readdir_flags flags)
      |                                                                                                                             ^
ifuse.c:278:144: error: variable has incomplete type 'enum fuse_readdir_flags'
  278 | static int ifuse_readdir(const char *path, void *buf, fuse_fill_dir_t filler, off_t offset, struct fuse_file_info *fi, enum fuse_readdir_flags flags)
      |                                                                                                                                                ^
ifuse.c:278:125: note: forward declaration of 'enum fuse_readdir_flags'
  278 | static int ifuse_readdir(const char *path, void *buf, fuse_fill_dir_t filler, off_t offset, struct fuse_file_info *fi, enum fuse_readdir_flags flags)
      |                                                                                                                             ^
ifuse.c:290:33: error: too many arguments to function call, expected 4, have 5
  290 |                 filler(buf, dirs[i], NULL, 0, 0);
      |                 ~~~~~~                        ^
ifuse.c:401:54: warning: declaration of 'struct fuse_config' will not be visible outside of this function [-Wvisibility]
  401 | void *ifuse_init(struct fuse_conn_info *conn, struct fuse_config *cfg)
      |                                                      ^
ifuse.c:580:13: error: incompatible function pointer types initializing 'int (*)(const char *, struct stat *)' with an expression of type 'int (const char *, struct stat *, struct fuse_file_info *)' [-Wincompatible-function-pointer-types]
  580 |         .getattr = ifuse_getattr,
      |                    ^~~~~~~~~~~~~
ifuse.c:582:13: error: incompatible function pointer types initializing 'int (*)(const char *, void *, fuse_fill_dir_t, off_t, struct fuse_file_info *)' (aka 'int (*)(const char *, void *, int (*)(void *, const char *, const struct stat *, long long), long long, struct fuse_file_info *)') with an expression of type 'int (const char *, void *, fuse_fill_dir_t, off_t, struct fuse_file_info *, enum fuse_readdir_flags)' (aka 'int (const char *, void *, int (*)(void *, const char *, const struct stat *, long long), long long, struct fuse_file_info *, enum fuse_readdir_flags)') [-Wincompatible-function-pointer-types]
  582 |         .readdir = ifuse_readdir,
      |                    ^~~~~~~~~~~~~
ifuse.c:589:14: error: incompatible function pointer types initializing 'int (*)(const char *, off_t)' (aka 'int (*)(const char *, long long)') with an expression of type 'int (const char *, off_t, struct fuse_file_info *)' (aka 'int (const char *, long long, struct fuse_file_info *)') [-Wincompatible-function-pointer-types]
  589 |         .truncate = ifuse_truncate,
      |                     ^~~~~~~~~~~~~~
ifuse.c:594:12: error: incompatible function pointer types initializing 'int (*)(const char *, const char *)' with an expression of type 'int (const char *, const char *, unsigned int)' [-Wincompatible-function-pointer-types]
  594 |         .rename = ifuse_rename,
      |                   ^~~~~~~~~~~~
ifuse.c:595:13: error: incompatible function pointer types initializing 'int (*)(const char *, const struct timespec *)' with an expression of type 'int (const char *, const struct timespec *, struct fuse_file_info *)' [-Wincompatible-function-pointer-types]
  595 |         .utimens = ifuse_utimens,
      |                    ^~~~~~~~~~~~~
ifuse.c:598:10: error: incompatible function pointer types initializing 'void *(*)(struct fuse_conn_info *)' with an expression of type 'void *(struct fuse_conn_info *, struct fuse_config *)' [-Wincompatible-function-pointer-types]
  598 |         .init = ifuse_init,
      |                 ^~~~~~~~~~
2 warnings and 8 errors generated.
make[2]: *** [ifuse.o] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

ttxs69 avatar May 14 '25 08:05 ttxs69

it seems that the struct fuse_operations definition in macfuse is different with the source code

ttxs69 avatar May 14 '25 11:05 ttxs69