Saturday, February 15, 2014

CMake Error when compiling on AWS AMI CentOs / Fedora / RedHat family

If you are getting this error

CMake Error at /usr/local/share/cmake-2.8/Modules/FindPackageHandleStandardArgs.
  Could NOT find OpenSSL, try to set the path to OpenSSL root folder in the
  system variable OPENSSL_ROOT_DIR (missing: OPENSSL_LIBRARIES
  OPENSSL_INCLUDE_DIR) (Required is at least version "0.9.8")

it is because RedHat decided to pre-install [a stripped down version of] OpenSSL and you do not have the developers package there.

Try this:

rpm -qa | grep openssl

If you got only

openssl-1.0.1e-16.el6_5.4.x86_64

Install the development package which got the headers and the extras

sudo yum -y install openssl-devel

and then run cmake command again

No comments: