tatsuhiro-t / spdylay

The experimental SPDY protocol version 2, 3 and 3.1 implementation in C
http://tatsuhiro-t.github.io/spdylay/
MIT License
603 stars 102 forks source link

Compiling on Fedora 19 gives errors in shrpx_ssl.cc #85

Closed cpg closed 10 years ago

cpg commented 10 years ago

Any ideas what is the problem here?

However, I get this error under Fedora 19::

...
g++ -DHAVE_CONFIG_H -I. -I..  -Wall -I./../lib/includes -I./../lib/includes -I/usr/include/libxml2   -DHAVE_CONFIG_H   -g -O2 -MT shrpx_io_control.o -MD -MP -MF .deps/shrpx_io_control.Tpo -c -o shrpx_io_control.o shrpx_io_control.cc
mv -f .deps/shrpx_io_control.Tpo .deps/shrpx_io_control.Po
g++ -DHAVE_CONFIG_H -I. -I..  -Wall -I./../lib/includes -I./../lib/includes -I/usr/include/libxml2   -DHAVE_CONFIG_H   -g -O2 -MT shrpx_ssl.o -MD -MP -MF .deps/shrpx_ssl.Tpo -c -o shrpx_ssl.o shrpx_ssl.cc
shrpx_ssl.cc: In function ‘SSL_CTX* shrpx::ssl::create_ssl_context(const char*, const char*)’:
shrpx_ssl.cc:156:3: error: ‘EC_KEY’ was not declared in this scope
   EC_KEY *ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
   ^
shrpx_ssl.cc:156:11: error: ‘ecdh’ was not declared in this scope
   EC_KEY *ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
           ^
shrpx_ssl.cc:156:46: error: ‘EC_KEY_new_by_curve_name’ was not declared in this scope
   EC_KEY *ecdh = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
                                              ^
shrpx_ssl.cc:163:19: error: ‘EC_KEY_free’ was not declared in this scope
   EC_KEY_free(ecdh);
                   ^
make[2]: *** [shrpx_ssl.o] Error 1
make[2]: Leaving directory `/home/cpg/tmp/spdylay/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/cpg/tmp/spdylay'
make: *** [all] Error 2

Seemingly everything needed is available according to the instructions:

configure: summary of build options:

    Version:        1.1.0 shared 6:0:0
    Host type:      x86_64-unknown-linux-gnu
    Install prefix: /usr/local
    C compiler:     gcc
    CFLAGS:         -g -O2
    LDFLAGS:
    LIBS:           -lz
    CPPFLAGS:
    C preprocessor: gcc -E
    C++ compiler:   g++
    CXXFLAGS:       -g -O2
    CXXCPP:         g++ -E
    Library types:  Shared=yes, Static=yes
    CUnit:          no
    OpenSSL:        yes
    Libxml2:        yes
    Libevent(SSL):  yes
    Src:            yes
    Examples:       yes
tatsuhiro-t commented 10 years ago

Fedora disables ECDH support in its openssl package. I believe that this issue was fixed with the commit 6efaa1c