0

我正在尝试在 Ubuntu 16.04.6 LTS 虚拟机上安装 RDKit。

阅读安装指南,我使用了以下命令:

sudo apt-get -y install python-rdkit librdkit1 rdkit-data

sudo wget https://github.com/rdkit/rdkit/archive/Release_2019_09_3.tar.gz

tar xvzf Release_2019_09_3.tar.gz
rm -f xvzf Release_2019_09_3.tar.gz


cd  rdkit-Release_2019_09_3
mkdir build
cd build
sudo cmake .. -DPYTHON_EXECUTABLE=python3  

但我收到了消息

-- Configuring incomplete, errors occurred!
See also "/home/vagrant/rdkit-Release_2019_09_3/build/CMakeFiles/CMakeOutput.log".
See also "/home/vagrant/rdkit-Release_2019_09_3/build/CMakeFiles/CMakeError.log".

检查CMakeError.log文件,我看到:

Determining if the function pthread_create exists in the pthreads failed with the following output:
Change Dir: /home/vagrant/rdkit-Release_2019_09_3/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/make" "cmTC_7b6d6/fast"
/usr/bin/make -f CMakeFiles/cmTC_7b6d6.dir/build.make CMakeFiles/cmTC_7b6d6.dir/build
make[1]: Entering directory '/home/vagrant/rdkit-Release_2019_09_3/build/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_7b6d6.dir/CheckFunctionExists.c.o
/usr/bin/cc    -DCHECK_FUNCTION_EXISTS=pthread_create   -o CMakeFiles/cmTC_7b6d6.dir/CheckFunctionExists.c.o   -c /usr/share/cmake-3.5/Modules/CheckFunctionExists.c
Linking C executable cmTC_7b6d6
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_7b6d6.dir/link.txt --verbose=1
/usr/bin/cc   -DCHECK_FUNCTION_EXISTS=pthread_create    CMakeFiles/cmTC_7b6d6.dir/CheckFunctionExists.c.o  -o cmTC_7b6d6 -rdynamic -lpthreads 
/usr/bin/ld: cannot find -lpthreads
collect2: error: ld returned 1 exit status
CMakeFiles/cmTC_7b6d6.dir/build.make:97: recipe for target 'cmTC_7b6d6' failed
make[1]: *** [cmTC_7b6d6] Error 1
make[1]: Leaving directory '/home/vagrant/rdkit-Release_2019_09_3/build/CMakeFiles/CMakeTmp'
Makefile:126: recipe for target 'cmTC_7b6d6/fast' failed
make: *** [cmTC_7b6d6/fast] Error 2

我应该怎么做才能在 python3 上正确安装 RDKit?我不在此 VM 上使用 conda。

4

0 回答 0