0

I'm trying to install a tool (MyChem) using cmake on our Ubuntu EC2 instance, the tool I'm installing should utilize mysql so I installed it first. But when I tried to install the tool its says mysql atomic library is missing. What is atomic library? Anybody knows why or how to solve this?

I installed mysql first as follows:

$ sudo apt upgrade
$ sudo apt-get install build-essential
$ sudo apt-get install mysql-server mysql-client
$ sudo apt-get install libmysqlclient-dev

And the followings are the error messages:

$ cmake ..
-- The build type is RelWithDebInfo
-- Test module disabled
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE)
-- Using mysql-config: /usr/bin/mysql_config
-- MySQL Version: 5.7.29
-- MySQL Plugin Dir: /usr/lib/mysql/plugin
-- Found MySQL 5.7.29: /usr/include/mysql, /usr/lib/x86_64-linux-gnu/libmysqlclient.so;/usr/lib/x86_64-linux-gnu/libpthread.so;/usr/lib/x86_64-linux-gnu/libz.so;/usr/lib/x86_64-linux-gnu/libm.so;/usr/lib/x86_64-linux-gnu/librt.so;MYSQL_LIBRARIES_atomic-NOTFOUND;/usr/lib/x86_64-linux-gnu/libssl.so;/usr/lib/x86_64-linux-gnu/libcrypto.so;/usr/lib/x86_64-linux-gnu/libdl.so
-- Mychem installation directory: /usr/lib/mysql/plugin
-- Defining dlhandler source files
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
MYSQL_LIBRARIES_atomic
    linked by target "mychem-lib" in directory /home/ubuntu/mychem-1.0.0/src
    linked by target "modification_test" in directory /home/ubuntu/mychem-1.0.0/tests
...
-- Configuring incomplete, errors occurred!

From above, around in the middle, you should be able to see the error messages such as MYSQL_LIBRARIES_atomic-NOTFOUND and also

CMake Error: The following variables are used in this project, but they are set to NOTFOUND. Please set them or make sure they are set and tested correctly in the CMake files:  MYSQL_LIBRARIES_atomic

at the bottom.

Ike
  • 1
  • 1
  • 1
    You must not have `pkg-config` installed on your system. See [this](https://stackoverflow.com/questions/33380020/errorcould-not-find-pkgconfig-missing-pkg-config-executable) question/answer. – Kevin Feb 06 '20 at 22:23
  • It looks like [FindMySQL.cmake](https://github.com/mychem/mychem-code/blob/master/cmake/modules/FindMySQL.cmake) script, shipped with the MyChem project, incorrectly parses output of `mysql_config` utility. Report the problem to the project's developers. In that report you may show the output of `mysql_config --libs`. – Tsyvarev Feb 07 '20 at 07:35

0 Answers0