Encounter cmake error in Clion


#1

Hi Mapd masters,

I just retrieve mapd-core source code from github, and I want to debug into it for learning it.
Firstly I install all the dependencies, then run “cmake -DENABLE_TSAN=on -DENABLE_CUDA=off …” and then “make -j 4”. All things going well, I can launch the mapd server and cliend successfully.
Secondly, I use Clion2017 to import the project, my OS is ubuntu16. I got CMake error:

CMake Error at /home/Soft/clion-2017.1.1/bin/cmake/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:138 (message):
Could NOT find Thrift (missing: Thrift_LIBRARY Thrift_VERSION)
Call Stack (most recent call first):
/home/Soft/clion-2017.1.1/bin/cmake/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
cmake/Modules/FindThrift.cmake:92 (find_package_handle_standard_args)
CMakeLists.txt:84 (find_package)

Seems it failed to find the Thrift library. I double-check the thrift lib path: /usr/local/mapd-deps/lib/libthrift.so, the file does exist. And its version is 0.10.0, equal to Thrifty_VERSION defined in FindThrift.cmake
Anyone can help? Thanks in advance.

Michael M


#2

Hi Michael,

The issue is most likely that the LD_LIBRARY_PATH and PATH environment variables are not being picked up by your IDE. I’m not familiar with CLion, but most IDEs have an option to define/add customer environment variables for the project. See https://github.com/mapd/mapd-core#environment-variables-1 for the list of what needs to be set.

You might also be able to get CLion to pick up the correct environment variables by starting it manually from a terminal.


#3

Really appreciate!
I manually set environment variables(by Clion Cmake configuration) according to your tips, it works now!


#4

Andrew,

I still have a question.
Just curisous. Which IDE are you using to develop Mapd? convenient to tell me?

Thanks,
Michael


#5

Truly appreciate! Thanks for response!


#6


#7

We don’t support/endorse any particular IDE - our engineers are free to use whatever tools they prefer and are familiar with.

Some of the ones in use are:

  • NetBeans

  • Eclipse

  • Xcode

  • SublimeText

  • emacs

  • vim