<html><body><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div><span id="zwchr" data-marker="__DIVIDER__">----- On Jan 29, 2018, at 8:56 AM, pedro pinto <pedro.e.pinto@gmail.com> wrote:<br></span></div><div data-marker="__QUOTED_TEXT__"><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;"><div dir="ltr"><div>Hi there. I would like to instrument a C++ statically linked application using the lttng static libraries (i.e. libllttng-ust.a, etc). To try to get this working I took the quick start example and changed it to use the following link command line: </div><br><div>gcc -o hello hello.o hello-tp.o -Wl,-Bstatic -llttng-ust -llttng-ust-tracepoint -lurcu-bp -lurcu-cds -Wl,-Bdynamic -lrt -ldl -pthread </div><br><div><div>This does not return any errors but the resulting trace is empty. I was able to get a trace using the liblttng shared object though.<br></div></div><br><div>Is it possible to statically link liblttng ? I am using v2.9.5 of lttng</div></div></blockquote><div>Static linking of lttng-ust is not supported. For a start, the library constructors are not<br></div><div>executed in a statically linked library.<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>Thanks,<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>Mathieu<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;"><div dir="ltr"><br><div>Thanks in advance!</div><br><div>-pp</div><br><br><br><br></div><br>_______________________________________________<br>lttng-dev mailing list<br>lttng-dev@lists.lttng.org<br>https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev<br></blockquote></div><div><br></div><div data-marker="__SIG_POST__">-- <br></div><div>Mathieu Desnoyers<br>EfficiOS Inc.<br>http://www.efficios.com</div></div></body></html>