libfuse: lib/compat.c Source File

libfuse

compat.c
1/*
2 FUSE: Filesystem in Userspace
3 Copyright (C) 2001-2007 Miklos Szeredi <miklos@szeredi.hu>
4
5 Helper functions to create (simple) standalone programs. With the
6 aid of these functions it should be possible to create full FUSE
7 file system by implementing nothing but the request handlers.
8
9 This program can be distributed under the terms of the GNU LGPLv2.
10 See the file LGPL2.txt.
11*/
12
13/* Description:
14 This file has compatibility symbols for platforms that do not
15 support version symboling
16*/
17
18#include "libfuse_config.h"
19
20#include <stddef.h>
21#include <stdint.h>
22
23struct fuse_args;
24struct fuse_cmdline_opts;
25struct fuse_cmdline_opts;
26struct fuse_session;
27struct fuse_custom_io;
28struct fuse_operations;
29struct fuse_lowlevel_ops;
30
34#if (!defined(LIBFUSE_BUILT_WITH_VERSIONED_SYMBOLS))
35/* With current libfuse fuse_parse_cmdline is a macro pointing to the
36 * versioned function. Here in this file we need to provide the ABI symbol
37 * and the redirecting macro is conflicting.
38 */
39#ifdef fuse_parse_cmdline
40#undef fuse_parse_cmdline
41#endif
42int fuse_parse_cmdline_30(struct fuse_args *args,
43 struct fuse_cmdline_opts *opts);
44int fuse_parse_cmdline(struct fuse_args *args,
45 struct fuse_cmdline_opts *opts);
46int fuse_parse_cmdline(struct fuse_args *args,
47 struct fuse_cmdline_opts *opts)
48{
49 return fuse_parse_cmdline_30(args, opts);
50}
51
52int fuse_session_custom_io_30(struct fuse_session *se,
53 const struct fuse_custom_io *io, int fd);
54int fuse_session_custom_io(struct fuse_session *se,
55 const struct fuse_custom_io *io, int fd);
56int fuse_session_custom_io(struct fuse_session *se,
57 const struct fuse_custom_io *io, int fd)
58
59{
60 return fuse_session_custom_io_30(se, io, fd);
61}
62
63#endif /* LIBFUSE_BUILT_WITH_VERSIONED_SYMBOLS */
64
65int fuse_main_real_30(int argc, char *argv[], const struct fuse_operations *op,
66 size_t op_size, void *user_data);
67int fuse_main_real(int argc, char *argv[], const struct fuse_operations *op,
68 size_t op_size, void *user_data);
69int fuse_main_real(int argc, char *argv[], const struct fuse_operations *op,
70 size_t op_size, void *user_data)
71{
72 return fuse_main_real_30(argc, argv, op, op_size, user_data);
73}
74
75struct fuse_session *fuse_session_new_30(struct fuse_args *args,
76 const struct fuse_lowlevel_ops *op,
77 size_t op_size, void *userdata);
78struct fuse_session *fuse_session_new(struct fuse_args *args,
79 const struct fuse_lowlevel_ops *op,
80 size_t op_size, void *userdata);
81struct fuse_session *fuse_session_new(struct fuse_args *args,
82 const struct fuse_lowlevel_ops *op,
83 size_t op_size, void *userdata)
84{
85 return fuse_session_new_30(args, op, op_size, userdata);
86}
fuse_parse_cmdline_30
int fuse_parse_cmdline_30(struct fuse_args *args, struct fuse_cmdline_opts *opts)
Definition helper.c:237
fuse_args
Definition fuse_opt.h:109
fuse_cmdline_opts
Definition fuse_lowlevel.h:2003
fuse_lowlevel_ops
Definition fuse_lowlevel.h:206
fuse_operations
Definition fuse.h:349