alibaba / xquic

XQUIC Library released by Alibaba is a cross-platform implementation of QUIC and HTTP/3 protocol.
Apache License 2.0
1.65k stars 326 forks source link

[Bug]: compile failed due to BabaSSL break change? #222

Closed Luffbee closed 1 year ago

Luffbee commented 1 year ago

What happened?

Seems BabaSSL has break changes, they renamed to Tongsuo.

/extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c: In function ‘xqc_gen_reset_token’:
/extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:1300:5: error: ‘HMAC_CTX_new’ is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
     HMAC_CTX *ctx = HMAC_CTX_new();
     ^~~~~~~~
In file included from /extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:9:0:
/extern_disk/home/lyf/xquic/third_party/babassl/include/openssl/hmac.h:33:33: note: declared here
 OSSL_DEPRECATEDIN_3_0 HMAC_CTX *HMAC_CTX_new(void);
                                 ^~~~~~~~~~~~
/extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:1301:5: error: ‘HMAC_CTX_reset’ is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
     HMAC_CTX_reset(ctx);
     ^~~~~~~~~~~~~~
In file included from /extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:9:0:
/extern_disk/home/lyf/xquic/third_party/babassl/include/openssl/hmac.h:34:27: note: declared here
 OSSL_DEPRECATEDIN_3_0 int HMAC_CTX_reset(HMAC_CTX *ctx);
                           ^~~~~~~~~~~~~~
/extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:1302:5: error: ‘HMAC_Init_ex’ is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
     HMAC_Init_ex(ctx, key, keylen, engine, NULL);
     ^~~~~~~~~~~~
In file included from /extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:9:0:
/extern_disk/home/lyf/xquic/third_party/babassl/include/openssl/hmac.h:43:27: note: declared here
 OSSL_DEPRECATEDIN_3_0 int HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int len,
                           ^~~~~~~~~~~~
/extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:1303:5: error: ‘HMAC_Update’ is deprecated: Since OpenSSL 3.0 [-Werror=deprecated-declarations]
     HMAC_Update(ctx, input, input_len);
     ^~~~~~~~~~~
In file included from /extern_disk/home/lyf/xquic/src/transport/xqc_packet_parser.c:9:0:
/extern_disk/home/lyf/xquic/third_party/babassl/include/openssl/hmac.h:45:27: note: declared here
 OSSL_DEPRECATEDIN_3_0 int HMAC_Update(HMAC_CTX *ctx, const unsigned char *data,
                           ^~~~~~~~~~~
.......
.......

Steps To Reproduce

just compile xquic following the build doc.

Relevant log output

No response

KudoWu commented 1 year ago

Want to ask if you have solved the problem?I'm having the same problem.

Luffbee commented 1 year ago

Want to ask if you have solved the problem?I'm having the same problem.

I solve it by using branch 8.3.1 of Tongsuo.

KudoWu commented 1 year ago

Want to ask if you have solved the problem?I'm having the same problem.

I solve it by using branch 8.3.1 of Tongsuo. Thank you very much, I have succeeded according to your method.