Calling winbind from C/C++

Mike Papper mike at digitalpipe.net
Wed Oct 17 22:41:02 GMT 2001


You have hit on my problem - how to know what files to include. Do you have 
some rules for this?

I tried lots of combos. When I tried to use the next_token function, I found 
I needed the includes.h. This is what wbinfo.c did. Perhaps I just dont need 
next_token for C++ programs?

What it seems like is that the samba header files are not C++ compliant at 
all. I wonder about libsmbclient.h then.

Mike Papper

On Wednesday 17 October 2001 03:22 pm, Tim Potter wrote:
> Mike Papper writes:
> > Heres what I include:
> >
> > #include "includes.h"
> > #include "winbindd.h"
> >
> > which is the same as "wbinfo.c"
>
> I don't think including includes.h and all the associated other
> samba include files is actually necessary.  For a small winbind
> client I have written I only needed:
>
> #include "winbind_nss_config.h"
> #include "winbindd_nss.h"
>
> I then copied wb_common.c from nsswitch into the project and
> compiled and linked it with the rest of the client code.
>
>
> Tim.

-- 
Mike Papper
Digital Pipe
mike at digitalpipe.net
650-627-5100 ext. 5211




More information about the samba-technical mailing list