0

I'm trying to build cpp-netlib 0.12.0 stable in Ubuntu 18.04, but when I get to running

$ make -j4

I get a lot of errors, such as:

error: ‘SSL_R_SHORT_READ’ was not declared in this scope
         ERR_PACK(ERR_LIB_SSL, 0, SSL_R_SHORT_READ)

Google told me this was because the make variables -DOPENSSL_INCLUDE_DIR and -DOPENSSL_SSL_LIBRARY need to be defined. However, I can't find the directories/libraries I need to set them to. Examples give /usr/lib/openssl-1.0 and /usr/include/openssl-1.0, but I can't find anything like those, even though I have the latest version of openssl installed through apt-get.

My /usr/include directory contains the folder 'openssl', but usr/lib doesn't have even that, only 'openssh', which doesn't appear to contain anything relevant.

How can I fix this?

Tsyvarev
  • 60,011
  • 17
  • 110
  • 153
Isaac Middlemiss
  • 208
  • 2
  • 4
  • 13
  • Did you try with libssl-dev installed? (sudo apt install libssl-dev) Also, lack of SSL should be already reported by cmake configuration step... – Gergely Nyiri Oct 07 '18 at 07:24
  • I did indeed try with libssl-dev installed. Fixed this in the end by cloning the git repository and building from that instead, but later encountered a host more errors. Have now found an easier solution to what I needed to do. – Isaac Middlemiss Oct 08 '18 at 09:49

1 Answers1

0

Fixed by cloning latest version from git repository and building from that.

Isaac Middlemiss
  • 208
  • 2
  • 4
  • 13