[getdns-api] Placement of the library vs. the examples in the doc
Paul Wouters
paul at nohats.ca
Thu May 22 19:04:52 CEST 2014
On Thu, 22 May 2014, Paul Hoffman wrote:
> Subject: Re: [getdns-api] Placement of the library vs. the examples in the doc
>
> On May 22, 2014, at 12:50 AM, Willem Toorop <Willem at NLnetLabs.nl> wrote:
>
>> There is no getdns_libevent.h in the getdns library. In the source tar
>> ball there is a directory containing the examples ( src/example ) which
>> has wrapper include files (getdns_core_only.h and getdns_libevent.h) to
>> make the API spec examples compile.
>
> Got it. This is a reasonable way to go.
>
>> The examples themselves are not touched and are exactly how they appear
>> in the spec. You can build them simply by running make example from
>> your build directory.
>
> Yep, that seems to work.
Note that the examples/Makefile is missing -levent_core:
-LDLIBS=-lgetdns -lgetdns_ext_event -lunbound -lidn -lldns -levent_core
+LDLIBS=-lgetdns -lgetdns_ext_event -lunbound -lidn -lldns
or else you will get an error:
/usr/bin/ld: example-simple-answers.o: undefined reference to symbol 'event_base_new'
/usr/bin/ld: note: 'event_base_new' is defined in DSO /lib64/libevent_core-2.0.so.5 so try adding it to the linker command line
/lib64/libevent_core-2.0.so.5: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make: *** [example-simple-answers] Error 1
Paul
_______________________________________________
getdns-api mailing list
getdns-api at vpnc.org
More information about the spec
mailing list