Determining if the pthread_create exist failed with the following output: Change Dir: /var/tmp/portage/app-admin/conky-1.10.0/work/conky-1.10.0_build/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/ninja" "cmTC_f35d2" [1/2] Building C object CMakeFiles/cmTC_f35d2.dir/CheckSymbolExists.c.o [2/2] Linking C executable cmTC_f35d2 FAILED: : && /usr/bin/x86_64-pc-linux-gnu-gcc -march=native -O2 -pipe -Wl,-O1 -Wl,--as-needed CMakeFiles/cmTC_f35d2.dir/CheckSymbolExists.c.o -o cmTC_f35d2 -rdynamic && : CMakeFiles/cmTC_f35d2.dir/CheckSymbolExists.c.o: In function `main': CheckSymbolExists.c:(.text.startup+0x6): undefined reference to `pthread_create' collect2: error: ld returned 1 exit status ninja: build stopped: subcommand failed. File /var/tmp/portage/app-admin/conky-1.10.0/work/conky-1.10.0_build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: /* */ #include int main(int argc, char** argv) { (void)argv; #ifndef pthread_create return ((int*)(&pthread_create))[argc]; #else (void)argc; return 0; #endif } Determining if the function pthread_create exists in the pthreads failed with the following output: Change Dir: /var/tmp/portage/app-admin/conky-1.10.0/work/conky-1.10.0_build/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/ninja" "cmTC_aae62" [1/2] Building C object CMakeFiles/cmTC_aae62.dir/CheckFunctionExists.c.o [2/2] Linking C executable cmTC_aae62 FAILED: : && /usr/bin/x86_64-pc-linux-gnu-gcc -march=native -O2 -pipe -DCHECK_FUNCTION_EXISTS=pthread_create -Wl,-O1 -Wl,--as-needed CMakeFiles/cmTC_aae62.dir/CheckFunctionExists.c.o -o cmTC_aae62 -rdynamic -lpthreads && : /usr/lib/gcc/x86_64-pc-linux-gnu/4.9.3/../../../../x86_64-pc-linux-gnu/bin/ld: cannot find -lpthreads collect2: error: ld returned 1 exit status ninja: build stopped: subcommand failed. Determining if the pipe2 exist failed with the following output: Change Dir: /var/tmp/portage/app-admin/conky-1.10.0/work/conky-1.10.0_build/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/ninja" "cmTC_287ae" [1/2] Building C object CMakeFiles/cmTC_287ae.dir/CheckSymbolExists.c.o FAILED: /usr/bin/x86_64-pc-linux-gnu-gcc -D_LARGEFILE64_SOURCE -D_POSIX_C_SOURCE=200809L -DNDEBUG -std=c99 -o CMakeFiles/cmTC_287ae.dir/CheckSymbolExists.c.o -c CheckSymbolExists.c CheckSymbolExists.c: In function ‘main’: CheckSymbolExists.c:8:19: error: ‘pipe2’ undeclared (first use in this function) return ((int*)(&pipe2))[argc]; ^ CheckSymbolExists.c:8:19: note: each undeclared identifier is reported only once for each function it appears in ninja: build stopped: subcommand failed. File /var/tmp/portage/app-admin/conky-1.10.0/work/conky-1.10.0_build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: /* */ #include int main(int argc, char** argv) { (void)argv; #ifndef pipe2 return ((int*)(&pipe2))[argc]; #else (void)argc; return 0; #endif }