[Bug 255123] cmake compiler test fails with pthread
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Sat Apr 24 13:22:37 BST 2021
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255123
--- Comment #3 from Mohammad S. Babaei <info at babaei.net> ---
I just tested it, and the results are the same:
Performing C SOURCE FILE Test CMAKE_HAVE_LIBC_PTHREAD failed with the following
output:
Change Dir: /home/mamadou/blog-subscription-service/build/CMakeFiles/CMakeTmp
Run Build Command(s):/usr/local/bin/ninja cmTC_e063f && [1/2] Building C object
CMakeFiles/cmTC_e063f.dir/src.c.o
[2/2] Linking C executable cmTC_e063f
FAILED: cmTC_e063f
: && /usr/bin/cc CMakeFiles/cmTC_e063f.dir/src.c.o -o cmTC_e063f && :
ld: error: undefined symbol: pthread_create
>>> referenced by src.c
>>> CMakeFiles/cmTC_e063f.dir/src.c.o:(main)
cc: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Source file was:
#include <pthread.h>
static void* test_func(void* data)
{
return data;
}
int main(void)
{
pthread_t thread;
pthread_create(&thread, NULL, test_func, NULL);
pthread_detach(thread);
pthread_cancel(thread);
pthread_join(thread, NULL);
pthread_atfork(NULL, NULL, NULL);
pthread_exit(NULL);
return 0;
}
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the kde-freebsd
mailing list