processone / fast_tls

TLS / SSL OpenSSL-based native driver for Erlang / Elixir
https://www.ejabberd.im
Other
83 stars 37 forks source link

configure: error: OpenSSL 'ssl' library was not found #39

Closed shubham1164 closed 5 years ago

shubham1164 commented 5 years ago

Using: Mac Os 10.14

I am getting the below error while trying to build fast_tls:

$ sudo ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether make sets $(MAKE)... yes
checking for an ANSI C-conforming const... yes
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible malloc... yes
checking for ANSI C header files... (cached) yes
checking for erl... /usr/local/bin/erl
checking for erlc... /usr/local/bin/erlc
checking for SSL_free in -lssl... no
checking for SHA1_Init in -lcrypto... no
checking openssl/ssl.h usability... yes
checking openssl/ssl.h presence... yes
checking for openssl/ssl.h... yes
checking openssl/err.h usability... yes
checking openssl/err.h presence... yes
checking for openssl/err.h... yes
checking openssl/sha.h usability... yes
checking openssl/sha.h presence... yes
checking for openssl/sha.h... yes
checking openssl/opensslv.h usability... yes
checking openssl/opensslv.h presence... yes
checking for openssl/opensslv.h... yes
configure: error: OpenSSL 'ssl' library was not found
shubham1164 commented 5 years ago

I have installed openSSL and used all 3 flags mentioned in the desc.

$ which openssl /usr/local/opt/openssl/bin/openssl

mremond commented 5 years ago

I cannot reproduce this. For me it works fine following the doc: https://docs.ejabberd.im/admin/installation/#macos

I did:

brew install erlang elixir openssl expat libyaml libiconv libgd sqlite rebar rebar3 automake autoconf 

export LDFLAGS="-L/usr/local/opt/openssl/lib -L/usr/local/lib -L/usr/local/opt/expat/lib"
export CFLAGS="-I/usr/local/opt/openssl/include/ -I/usr/local/include -I/usr/local/opt/expat/include"
export CPPFLAGS="-I/usr/local/opt/openssl/include/ -I/usr/local/include -I/usr/local/opt/expat/include"

./configure
make

This is the instructions to build ejabberd, but it works as well for fast_tls.

shubham1164 commented 5 years ago

yes, it must be working but I don't know how to correct it. Openssl seems to install correctly but still showing error I am frustrated with MAC. Please help

shubham1164 commented 5 years ago

Is it possible to forcefully give the path of openssl during ./configure?

zinid commented 5 years ago

Is it possible to forcefully give the path of openssl during ./configure?

Did you read the above comment? You can set the paths with the flags.