Best practice in building custom vfs modules

Giampaolo Tomassoni Giampaolo at
Wed May 19 04:04:19 MDT 2010

Hi everybody,

some months ago I developed a small and dirty VFS module (one .c file + one
Makefile) which addressed a specific user need. It was developed using
samba-3.0.33 and compiled and worked seamlessly up to samba-3.0.37.

Now, my preferred distro (Gentoo) suddenly switched to samba-3.4.6 and, of
course, my dirty module can't compile anymore on it, mostly because the
includes it was referring are not anymore where it expects them to be, or
because it includes stuff which is now not anymore available.

When I first made it, I had some troubles in figuring out which samba
include to use and which library to link with. Now I figure out things
changed, so my question.

Is there any "best practice" in referring to the needed samba includes and
libraries in order to compile and build a VFS module? I mean, my VFS module
looks more like a samba component than an external custom module: I need to
specify to gcc the needed includes directories, then include the carefully
identified include files, then identify the libraries to link against...

Is there any way to refer to samba includes and libraries for VFS modules in
a portable way? 

Thank you,


More information about the samba-technical mailing list