← Back to team overview

mosquitto-users team mailing list archive

Re: compiling auth plugin

 

Argh, instead of linking the final binary against hiredis I was doing it
with the plugin. All works now. Thanks a lot!

Artjom


On Fri, Apr 12, 2013 at 3:39 PM, Jan-Piet Mens <jpmens@xxxxxxxxx> wrote:

> > I'm compiling it with the following command:
> > gcc -c -fPIC example.c hiredis.c -o plugin.o
> > gcc -shared -o plugin.so plugin.o
> >
> > However when I try to use it with Mosquitto (or a sample program which is
> > using dlopen to open .so) it gives me an error about undefined symbols
> and
> > lists all redis functions.
>
> It seems to me you haven't linked against Redis; add -lhiredis go the
> second command, and make sure (ldconfig) Mosquitto can find the plugin.
>
>         -JP
>
> --
> Mailing list: https://launchpad.net/~mosquitto-users
> Post to     : mosquitto-users@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~mosquitto-users
> More help   : https://help.launchpad.net/ListHelp
>

Follow ups

References