dynomite icon indicating copy to clipboard operation
dynomite copied to clipboard

make Comamnd fails

Open mzubairsaleem opened this issue 5 years ago • 9 comments

Hi,

While Installing Dynomite On Linux Server Ubuntu: 16.04 x86_64 GNU/Linux

Having This Error.

make[2]: Entering directory '/root/dynomite/src/hashkit' gcc -DHAVE_CONFIG_H -I. -I../.. -I ../../src -I ../../contrib/murmur3 -Wall -Wshadow -Wpointer-arith -Winline -Wunused-function -Wunused-variable -Wunused-value -Wno-unused-parameter -Wno-unused-value -Wno-missing-prototypes -Wno-missing-declarations -Wconversion -Wsign-compare -Wstrict-prototypes -Wredundant-decls -Werror=implicit-function-declaration -g -O2 -MT dyn_crc16.o -MD -MP -MF .deps/dyn_crc16.Tpo -c -o dyn_crc16.o dyn_crc16.c In file included from ../../src/dyn_connection.h:41:0, from ../../src/dyn_core.h:28, from dyn_crc16.c:23: ../../src/dyn_message.h:249:1: warning: function declaration isn’t a prototype [-Wstrict-prototypes] typedef void (*func_init_datastore_t)(); ^ In file included from ../../src/dyn_core.h:30:0, from dyn_crc16.c:23: ../../src/dyn_crypto.h:13:25: fatal error: openssl/bio.h: No such file or directory compilation terminated. Makefile:393: recipe for target 'dyn_crc16.o' failed make[2]: *** [dyn_crc16.o] Error 1 make[2]: Leaving directory '/root/dynomite/src/hashkit' Makefile:689: recipe for target 'install-recursive' failed make[1]: *** [install-recursive] Error 1 make[1]: Leaving directory '/root/dynomite/src' Makefile:483: recipe for target 'install-recursive' failed make: *** [install-recursive] Error 1

mzubairsaleem avatar Apr 30 '20 15:04 mzubairsaleem

fatal error: openssl/bio.h: No such file or directory

@mzubairsaleem: Are you sure you have installed libssl-dev?

m-ueberall avatar May 01 '20 08:05 m-ueberall

Yes I did Install but doesn’t work.

mzubairsaleem avatar May 01 '20 08:05 mzubairsaleem

Which branch are you on? I successfully compiled branches v0.6/v0.7 on Xenial.

m-ueberall avatar May 01 '20 08:05 m-ueberall

Correct, this is a dependent library missing.

ipapapa avatar Jul 09 '20 05:07 ipapapa

I'm seeing the same result on macOS 10.14 with 46c75201bfaca02b656c44bcf39ca68bba3a54c7 — I have [email protected] installed via Homebrew.

$ ./configure --with-openssl=/usr/local/Cellar/[email protected]/1.1.1g
$ make
...
In file included from dyn_crc16.c:23:
In file included from ../../src/dyn_core.h:30:
../../src/dyn_crypto.h:13:10: fatal error: 'openssl/bio.h' file not found
#include <openssl/bio.h>
...

Note that I do have openssl/bio.h:

$ ls -l /usr/local/Cellar/[email protected]/1.1.1g/include/openssl/bio.h
-rw-r--r--  1 rsms  staff  34907 Apr 21 05:22 /usr/local/Cellar/[email protected]/1.1.1g/include/openssl/bio.h

Note: I've also tried running configure without the --with-openssl with the same result. Is it possible that the make setup does not honor the autoconf with flag? I don't see it for -I to gcc: (line from make)

gcc -DHAVE_CONFIG_H -I. -I../..  -I ../../src -I ../../contrib/murmur3  -Wall -Wshadow -Wpointer-arith -Winline -Wunused-function -Wunused-variable -Wunused-value -Wno-unused-parameter -Wno-unused-value -Wno-missing-prototypes -Wno-missing-declarations -Wconversion -Wsign-compare -Wstrict-prototypes -Wredundant-decls -Werror=implicit-function-declaration -g -O2 -MT dyn_crc16.o -MD -MP -MF .deps/dyn_crc16.Tpo -c -o dyn_crc16.o dyn_crc16.c

rsms avatar Jul 30 '20 19:07 rsms

Here's how I got it to compile on macOS 10.14: (bash, in the dynomite source root directory)

brew install [email protected]
OPENSSL_ROOT=$(brew --cellar openssl)/$(brew list --versions openssl | tr ' ' '\n' | tail -1)
./configure "--with-openssl=$OPENSSL_ROOT"
ln -s $OPENSSL_ROOT/include/openssl openssl
LIBRARY_PATH=$LIBRARY_PATH:$OPENSSL_ROOT/lib make

The issue seems to be that the build relies on the compiler's built-in search paths for headers and libraries, ignoring --with arguments to the configure script.

rsms avatar Jul 30 '20 19:07 rsms

Thanks RSMS, you're a saviour! :)

paulolellis avatar Feb 16 '21 00:02 paulolellis

real life legend right here

abhinav0101 avatar Mar 12 '21 06:03 abhinav0101

Since others may have the same problem, why don't you folks open a PR to briefly update the documentation?

ipapapa avatar Mar 12 '21 16:03 ipapapa