cMake error. GMP (BIG NUM)

Hi I have the following code.

1
2
3
4
5
6
7
8
9
10
#include <iostream>
#include <gmp.h>
#include <gmpxx.h>

using namespace std;

int main() {
    cout << "Hello, World!" << endl;
    return 0;
}


and this CMakeLists.txt
1
2
3
4
5
6
7
8
9
cmake_minimum_required(VERSION 3.3)
project(someProject)
find_package(GMP REQUIRED)
add_executable(someProject main.cpp)
target_link_libraries(someProject gmp libgmp)
include_directories(${GOBJECT_INCLUDE_DIR})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
set(SOURCE_FILES main.cpp)
add_executable(someProject ${SOURCE_FILES})


and I am receiving this error message.


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/Applications/CLion.app/Contents/bin/cmake/bin/cmake --build /Users/admini/Library/Caches/clion11/cmake/generated/2f6b9cc/2f6b9cc/Debug --target all -- -j 8
CMake Error at CMakeLists.txt:5 (find_package):
  By not providing "FindGMP.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "GMP", but
  CMake did not find one.

  Could not find a package configuration file provided by "GMP" with any of
  the following names:

    GMPConfig.cmake
    gmp-config.cmake

  Add the installation prefix of "GMP" to CMAKE_PREFIX_PATH or set "GMP_DIR"
  to a directory containing one of the above files.  If "GMP" provides a
  separate development package or SDK, be sure it has been installed.


-- Configuring incomplete, errors occurred!
See also "/Users/admini/Library/Caches/clion11/cmake/generated/2f6b9cc/2f6b9cc/Debug/CMakeFiles/CMakeOutput.log".
make: *** [cmake_check_build_system] Error 1


Any ideas?
Topic archived. No new replies allowed.