Closed yakotaki closed 6 years ago
Ubuntu and cmake should be fine, but gcc 7 is required
Closing for now.
I've tried building with gcc-7 but still have this error above. I ran this terminal command before making:
cmake -DCMAKE_CC_COMPILER=/usr/bin/gcc-7 -DCMAKE_CXX_COMPILER=/usr/bin/g++-7
Any updates?
Determining if the pthread_create exist failed with the following output: Change Dir: /home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make" "cmTC_8b8f8/fast" make[1]: Entering directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' /usr/bin/make -f CMakeFiles/cmTC_8b8f8.dir/build.make CMakeFiles/cmTC_8b8f8.dir/build make[2]: Entering directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_8b8f8.dir/CheckSymbolExists.c.o /usr/bin/cc -o CMakeFiles/cmTC_8b8f8.dir/CheckSymbolExists.c.o -c /home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c Linking C executable cmTC_8b8f8 /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_8b8f8.dir/link.txt --verbose=1 /usr/bin/cc CMakeFiles/cmTC_8b8f8.dir/CheckSymbolExists.c.o -o cmTC_8b8f8 -rdynamic CMakeFiles/cmTC_8b8f8.dir/CheckSymbolExists.c.o: In function
main': CheckSymbolExists.c:(.text+0x16): undefined reference to
pthread_create' collect2: error: ld returned 1 exit status CMakeFiles/cmTC_8b8f8.dir/build.make:97: recipe for target 'cmTC_8b8f8' failed make[2]: [cmTC_8b8f8] Error 1 make[2]: Leaving directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' Makefile:126: recipe for target 'cmTC_8b8f8/fast' failed make[1]: [cmTC_8b8f8/fast] Error 2 make[1]: Leaving directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp'File /home/yakotaki0202/Desktop/ELF-master/ELF-master/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: /home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp
Run Build Command:"/usr/bin/make" "cmTC_feb66/fast" make[1]: Entering directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' /usr/bin/make -f CMakeFiles/cmTC_feb66.dir/build.make CMakeFiles/cmTC_feb66.dir/build make[2]: Entering directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_feb66.dir/CheckFunctionExists.c.o /usr/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create -o CMakeFiles/cmTC_feb66.dir/CheckFunctionExists.c.o -c /usr/share/cmake-3.5/Modules/CheckFunctionExists.c Linking C executable cmTC_feb66 /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_feb66.dir/link.txt --verbose=1 /usr/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create CMakeFiles/cmTC_feb66.dir/CheckFunctionExists.c.o -o cmTC_feb66 -rdynamic -lpthreads /usr/bin/ld: cannot find -lpthreads collect2: error: ld returned 1 exit status CMakeFiles/cmTC_feb66.dir/build.make:97: recipe for target 'cmTC_feb66' failed make[2]: [cmTC_feb66] Error 1 make[2]: Leaving directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp' Makefile:126: recipe for target 'cmTC_feb66/fast' failed make[1]: [cmTC_feb66/fast] Error 2 make[1]: Leaving directory '/home/yakotaki0202/Desktop/ELF-master/ELF-master/build/CMakeFiles/CMakeTmp'