X-Git-Url: https://git.lttng.org/?p=lttng-tools.git;a=blobdiff_plain;f=m4%2Flttng_pthread_setname_np.m4;h=6eff705baa3b7a6d00f4c480d19f3c02f7d2b5b1;hp=a8526e8d23eac3985a3d0bcb068fafe5343ab261;hb=014d7d3b5e9d69989bf776cffb6c21ff7e1d36ff;hpb=5dee2ed25e797cc4a70a6180b7d5fc2bf0696c21 diff --git a/m4/lttng_pthread_setname_np.m4 b/m4/lttng_pthread_setname_np.m4 index a8526e8d2..6eff705ba 100644 --- a/m4/lttng_pthread_setname_np.m4 +++ b/m4/lttng_pthread_setname_np.m4 @@ -63,6 +63,18 @@ AC_LINK_IFELSE( [Have function pthread_setname_np(const char*)])], [AC_MSG_RESULT(no)]) +# FreeBSD +AC_MSG_CHECKING(for pthread_set_name_np(pthread_t, const char*)) +AC_LINK_IFELSE( + [AC_LANG_PROGRAM( + [#include + #include ], + [pthread_set_name_np(pthread_self(), "example")])], + [AC_MSG_RESULT(yes) + AC_DEFINE(HAVE_PTHREAD_SET_NAME_NP_WITH_TID,1, + [Have function pthread_set_name_np(pthread_t, const char*)])], + [AC_MSG_RESULT(no)]) + LDFLAGS=$lttng_pthread_setname_np_save_LDFLAGS LIBS=$lttng_pthread_setname_np_save_LIBS