<div><br></div><div class="gmail_quote">On Tue, Jan 3, 2012 at 8:31 AM, Adam Chlipala <span dir="ltr"><<a href="mailto:adamc@impredicative.com">adamc@impredicative.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">Steve Sims wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
steve@truman:~/simsnet$ gcc -Werror -lm -pthread -L/usr/local/lib/urweb/.. -lurweb -lurweb_http -lssl -lcrypto /usr/local/lib/liburweb.a<br>
/tmp/webapp.o -o /home/steve/simsnet/simsnet.<u></u>exe -g<br>
/usr/local/lib/liburweb.a(<u></u>urweb.o): In function `uw_Basis_rand':<br>
/home/steve/urweb/src/c/urweb.<u></u>c:3821: undefined reference to `RAND_bytes'<br>
</blockquote>
<br></div>
If I remember correctly, libraries must be referenced on the command line in _reverse_ dependency order, so this message is probably telling you that you included liburweb after libssl, while it should have been included before.<br>
</blockquote><div><br></div><div>Initially I just copy and pasted the output of urweb -debug. That placed liburweb before libssl as expected. When explicitly including liburweb.a in the command line, if I try to move it before -lssl, I get the initial missing symbols (from liburweb) not the missing ssl symbols. </div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Another interesting test would involve running the urweb compilation with the '-static' flag.</blockquote><div><br></div><div>steve@truman:~/simsnet$ urweb -static simsnet</div><div>/usr/local/lib/urweb/../liburweb.a(urweb.o): In function `uw_Basis_ceil':</div>
<div>/home/steve/urweb/src/c/urweb.c:3966: undefined reference to `ceil'</div><div>/usr/local/lib/urweb/../liburweb.a(urweb.o): In function `uw_Basis_round':</div><div>/home/steve/urweb/src/c/urweb.c:3974: undefined reference to `llround'</div>
<div>collect2: ld returned 1 exit status</div><div><br></div><div><span style="font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">>Oh, and one more thing: are you sure 'ldconfig' ran successfully as part of >'make install'?</span>
</div><div><span style="font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)">I believe so. I searched the output for the string "error" and it does not appear. ldconfig looks like it ran and produced no output which I assume means it was successful:</span></div>
<div><span style="font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><br></span></div><div><span style="font-family:arial,sans-serif;font-size:13px;background-color:rgb(255,255,255)"><div>cp config.h /usr/local/include/urweb/</div>
<div>cp include/*.h /usr/local/include/urweb/</div><div>mkdir -p /usr/local/share/emacs/site-lisp/urweb-mode</div><div>cp src/elisp/*.el /usr/local/share/emacs/site-lisp/urweb-mode/</div><div>ldconfig</div><div>make[2]: Nothing to be done for `install-data-am'.</div>
<div>make[2]: Leaving directory `/home/steve/urweb'</div><div>make[1]: Leaving directory `/home/steve/urweb'</div><div><br></div><div>Thanks again for your help.</div><div><br></div><div>Steve</div></span></div><div>
</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">
<br>
______________________________<u></u>_________________<br>
Ur mailing list<br>
<a href="mailto:Ur@impredicative.com" target="_blank">Ur@impredicative.com</a><br>
<a href="http://www.impredicative.com/cgi-bin/mailman/listinfo/ur" target="_blank">http://www.impredicative.com/<u></u>cgi-bin/mailman/listinfo/ur</a><br>
</div></div></blockquote></div><br>