Adding dependencies for application

I am writing an application for which I need to add few libraries e.g. libxyz.so or libxyz.a. I am not sure “how to” and “where to” add these dependencies in makefile. I understand there is menuselect utility but I don’t know how to use it my for application

For example: I am creating apps/app_xyz.so application. Which requires libxyz.so as runtime library. Where to add entry of libxyz.so for app_xyz so that it will link against this library ?

I tried putting path of libxyz.so in LD_LIBRARY_PATH but its not liking it.

Please advice.

Thanks,
Kedar

You have to modify the Makefile in apps directory and add a line, at the end, to specify which shared libraries your application has to linked with:

app_xyz.so : app_xyz.o
   $(CC) $(SOLINK) -o $@ ${CYGSOLINK} $< ${CYGSOLIB} –lxyz

Be careful, use tabs and not spaces, to respect the sintax of the makefile :smile:

Hope this helps.

Cheers.

Marco Bruni

Not sure if my answer is right, better check with developers, so I suggest you to search/write a message in the Asterisk developer mailing list, for this and other questions related to development.

Cheers.

Marco Bruni