<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div class="" style="">Hi,</div><div class="" style="">Looks like when used as static lib, the symbol is fully exported</div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;">nm -AC libnice.a | grep RAND</div><div class="" style="">libnice.a:rand.o:0000000000000050 T RAND_bytes</div><div class="" style=""><span class="" style=""></span></div><div class="" style="">libnice.a:stunhmac.o: U RAND_bytes</div><div class="" style=""><br></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;
font-style: normal; background-color: transparent;">(It has been built with regular autoconf/automake with --enable-static)</div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;"><br></div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;">Thanks</div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color: transparent;">Fx</div><div class="" style="color: rgb(0, 0, 0); font-size: 16px; font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-style: normal; background-color:
transparent;"><br></div><div class="" style=""><br class="" style=""></div> <div class="qtdSeparateBR"><br><br></div><div class="yahoo_quoted" style="display: block;"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" class=""> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" class=""> <div dir="ltr" class="" style=""> <font size="2" face="Arial" class="" style=""> Le Samedi 25 octobre 2014 20h10, Philip Withnall <philip@tecnocode.co.uk> a écrit :<br class="" style=""> </font> </div> <br class="" style=""><br class="" style=""> <div class="" style="">It really depends entirely on how you’re building libnice. What linker<br clear="none" class="" style="">flags are you passing in via cmake?<br clear="none" class="" style=""><br clear="none" class="" style="">Rather than reinventing the libnice build system, a
better approach is<br clear="none" class="" style="">to build libnice using its own build system for all the platforms you’re<br clear="none" class="" style="">interested in (potentially producing a static library), then link to<br clear="none" class="" style="">that from the build system of whatever final project you’re using.<br clear="none" class="" style=""><br clear="none" class="" style="">I did this recently using Cerbero[1] to build a project for multiple<br clear="none" class="" style="">desktop and mobile platforms. The project used libnice, and used its<br clear="none" class="" style="">existing automake build system without linker problems.<br clear="none" class="" style=""><br clear="none" class="" style="">Philip<br clear="none" class="" style=""><br clear="none" class="" style="">[1]: <a shape="rect" href="http://cgit.freedesktop.org/gstreamer/cerbero/" target="_blank" class=""
style="">http://cgit.freedesktop.org/gstreamer/cerbero/</a><br clear="none" class="" style=""><div class="" id="yqtfd44202" style=""><br clear="none" class="" style="">On Sat, 2014-10-25 at 18:47 +0100, Curieux Tres wrote:<br clear="none" class="" style="">> we have all the cmake based tool to build for all platforms (i.e.<br clear="none" class="" style="">> desktop & mobile).<br clear="none" class="" style="">> Won't the problem happen if libnice is used as static lib ?<br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> Thanks<br clear="none" class="" style="">> Fx<br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class=""
style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> Le Vendredi 24 octobre 2014 20h47, Philip Withnall<br clear="none" class="" style="">> <<a shape="rect" ymailto="mailto:philip@tecnocode.co.uk" href="mailto:philip@tecnocode.co.uk" class="" style="">philip@tecnocode.co.uk</a>> a écrit :<br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> It certainly will. Why are you not using automake?<br clear="none" class="" style="">> <br clear="none" class="" style="">> Philip<br clear="none" class="" style="">> <br clear="none" class="" style="">> On Fri, 2014-10-24 at 18:54 +0100, Curieux Tres wrote:<br clear="none" class=""
style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > Hi<br clear="none" class="" style="">> > Maybe my fault, i'm not using the autoconf/automake build<br clear="none" class="" style="">> > but a cmake one, it might expose things a little bit differently<br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > Le Vendredi 24 octobre 2014 17h57, Philip Withnall<br clear="none" class="" style="">> > <<a shape="rect" ymailto="mailto:philip@tecnocode.co.uk" href="mailto:philip@tecnocode.co.uk" class="" style="">philip@tecnocode.co.uk</a>> a écrit :<br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > Hi,<br clear="none" class=""
style="">> > <br clear="none" class="" style="">> > How are you encountering this symbol clash? RAND_bytes is exposed in<br clear="none" class="" style="">> > the<br clear="none" class="" style="">> > libstun.la helper library, but that is not installed, and when it’s<br clear="none" class="" style="">> > linked in to libnice.so, RAND_bytes becomes a local, non-exported<br clear="none" class="" style="">> > symbol.<br clear="none" class="" style="">> > <br clear="none" class="" style="">> > e.g.<br clear="none" class="" style="">> > $ nm -g nice/.libs/libnice.so | grep RAND<br clear="none" class="" style="">> > $ # no results<br clear="none" class="" style="">> > <br clear="none" class="" style="">> > Philip<br clear="none" class="" style="">> > <br clear="none" class="" style="">> > On Thu, 2014-10-16 at 15:10 +0100, Curieux Tres wrote:<br clear="none" class=""
style="">> > > Hi<br clear="none" class="" style="">> > > RAND_bytes is also used/exported by openSSL<br clear="none" class="" style="">> > > Small patch attached to rename it to nice_RAND_bytes<br clear="none" class="" style="">> > > <br clear="none" class="" style="">> > > <br clear="none" class="" style="">> > > Thanks<br clear="none" class="" style="">> > > Fx<br clear="none" class="" style="">> > > <br clear="none" class="" style="">> > > <br clear="none" class="" style="">> > > _______________________________________________<br clear="none" class="" style="">> > > nice mailing list<br clear="none" class="" style="">> > > <a shape="rect" ymailto="mailto:nice@lists.freedesktop.org" href="mailto:nice@lists.freedesktop.org" class="" style="">nice@lists.freedesktop.org</a><br clear="none" class="" style="">> > > <a shape="rect"
href="http://lists.freedesktop.org/mailman/listinfo/nice" target="_blank" class="" style="">http://lists.freedesktop.org/mailman/listinfo/nice</a><br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> > <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> _______________________________________________<br clear="none" class="" style="">> nice mailing list<br clear="none" class="" style="">> <a shape="rect" ymailto="mailto:nice@lists.freedesktop.org" href="mailto:nice@lists.freedesktop.org" class="" style="">nice@lists.freedesktop.org</a><br clear="none" class="" style="">> <a shape="rect" href="http://lists.freedesktop.org/mailman/listinfo/nice" target="_blank" class="" style="">http://lists.freedesktop.org/mailman/listinfo/nice</a><br clear="none" class=""
style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> <br clear="none" class="" style="">> _______________________________________________<br clear="none" class="" style="">> nice mailing list<br clear="none" class="" style="">> <a shape="rect" ymailto="mailto:nice@lists.freedesktop.org" href="mailto:nice@lists.freedesktop.org" class="" style="">nice@lists.freedesktop.org</a><br clear="none" class="" style="">> <a shape="rect" href="http://lists.freedesktop.org/mailman/listinfo/nice" target="_blank" class="" style="">http://lists.freedesktop.org/mailman/listinfo/nice</a><br clear="none" class="" style=""></div><br class="" style=""><div class="" id="yqtfd25746" style="">_______________________________________________<br clear="none" class="" style="">nice mailing list<br clear="none" class="" style=""><a shape="rect" ymailto="mailto:nice@lists.freedesktop.org"
href="mailto:nice@lists.freedesktop.org" class="" style="">nice@lists.freedesktop.org</a><br clear="none" class="" style=""><a shape="rect" href="http://lists.freedesktop.org/mailman/listinfo/nice" target="_blank" class="" style="">http://lists.freedesktop.org/mailman/listinfo/nice</a><br clear="none" class="" style=""></div><br class="" style=""><br class="" style=""></div> </div> </div> </div> </div></body></html>