Makefile:110:设置 libsrtp 时目标“srtp/srtp.o”的配方失败

Makefile:110:设置 libsrtp 时目标“srtp/srtp.o”的配方失败

我正在按照给定的步骤从这里安装 janus 网关 -<https://github.com/meetecho/janus-gateway/tree/v0.6.0

这里我需要名为 libsrtp 的库,我遵循了与这里给出的相同的步骤

wget https://github.com/cisco/libsrtp/archive/v1.5.4.tar.gz
tar xfv v1.5.4.tar.gz
cd libsrtp-1.5.4
./configure --prefix=/usr --enable-openssl
make shared_library && sudo make install

我在最后一行遇到了错误 ->

make shared_library && sudo make install

这是错误

gcc -DHAVE_CONFIG_H -Icrypto/include -I./include -I./crypto/include -fPIC  -fPIC -Wall -O4 -fexpensive-optimizations -funroll-loops  -c srtp/srtp.c -o srtp/srtp.o
In file included from crypto/include/prng.h:53:0,
                 from crypto/include/crypto_kernel.h:50,
                 from ./include/srtp_priv.h:58,
                 from srtp/srtp.c:46:
crypto/include/aes_icm_ossl.h:75:20: error: field ‘ctx’ has incomplete type
     EVP_CIPHER_CTX ctx;
                    ^~~
In file included from srtp/srtp.c:50:0:
crypto/include/aes_gcm_ossl.h:58:18: error: field ‘ctx’ has incomplete type
   EVP_CIPHER_CTX ctx;
                  ^~~
Makefile:110: recipe for target 'srtp/srtp.o' failed
make: *** [srtp/srtp.o] Error 1

我正在使用 ubuntu 18.04 lts

答案1

这看起来类似于Stackoverflow 问题,你要么需要降级 OpenSSL(不容易),要么尝试使用较新版本的 libstrp(看起来像 v2.1.0+

相关内容