Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

quic: fixup duplicate static function name (for cmake unity) #13332

Closed
wants to merge 1 commit into from

Conversation

vszakats
Copy link
Member

@vszakats vszakats commented Apr 10, 2024

Visible in daily curl-for-win builds:
https://github.com/curl/curl-for-win/actions/runs/8621925870

lib/vquic/curl_ngtcp2.c:1916:12: error: redefinition of 'ossl_new_session_cb'
static int ossl_new_session_cb(SSL *ssl, SSL_SESSION *ssl_sessionid)
           ^
lib/vtls/openssl.c:2978:12: note: previous definition is here
static int ossl_new_session_cb(SSL *ssl, SSL_SESSION *ssl_sessionid)
           ^

https://github.com/curl/curl-for-win/actions/runs/8621925870/job/23631885439#step:3:6965

Follow-up to 3210101 #13172
Closes #13332

@vszakats vszakats added build cmake HTTP/3 h3 or quic related labels Apr 10, 2024
@vszakats
Copy link
Member Author

vszakats commented Apr 10, 2024

CMake Unity builds break when reusing a static function (or other symbol)
name between source files.

What would be a good long-term solution to avoid this?

I can add a complete curl-for-win build as part of the curl CI. It would be
another option to start using CMake more in existing or new CI jobs, and
enable Unity mode in them. It'd be useful to have at least one such job
building with HTTP/2 + HTTP/3 as this is where the issue has been
reoccuring.

/cc @bagder @icing

@vszakats vszakats changed the title quic: fixup duplicate static function name quic: fixup duplicate static function name (for cmake unity) Apr 10, 2024
Visible in daily curl-for-win builds:
https://github.com/curl/curl-for-win/actions/runs/8621925870

```
lib/vquic/curl_ngtcp2.c:1916:12: error: redefinition of 'ossl_new_session_cb'
static int ossl_new_session_cb(SSL *ssl, SSL_SESSION *ssl_sessionid)
           ^
lib/vtls/openssl.c:2978:12: note: previous definition is here
static int ossl_new_session_cb(SSL *ssl, SSL_SESSION *ssl_sessionid)
           ^
```
https://github.com/curl/curl-for-win/actions/runs/8621925870/job/23631885439#step:3:6965

Closes #xxxxx
@vszakats vszakats force-pushed the fixup-static-func-collision branch from 35bebd1 to 317a3db Compare April 10, 2024 08:26
@vszakats
Copy link
Member Author

Bringing curl-for-win to curl CI in this PR: #13335

@vszakats vszakats closed this in 4f15443 Apr 10, 2024
@vszakats vszakats deleted the fixup-static-func-collision branch April 10, 2024 10:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build cmake HTTP/3 h3 or quic related
Development

Successfully merging this pull request may close these issues.

None yet

1 participant