Skip to content

Ship with BoringSSL #135

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

Merged
merged 5 commits into from
Oct 5, 2023

Conversation

felixschlegel
Copy link
Contributor

@felixschlegel felixschlegel commented Oct 3, 2023

Closes #123

Motivation:

No need to install libressl on machine to build project.

Modifications:

  • add dependency to swift-nio-ssl to obtain copy of BoringSSL
  • create bridging headers allowing librdkafka to build with BoringSSL copy from swift-nio-ssl

Additional Changes:

  • use swift-service-lifecycle version 2.1.0 instead of beta

Motivation:

No need to install `libressl` on machine to build project.

Modifications:

* add dependency to `swift-nio-ssl` to obtain copy of `BoringSSL`
* create bridging headers allowing `librdkafka` to build with `BoringSSL` copy from `swift-nio-ssl`

Additional Changes:

* use `swift-service-lifecycle` version `2.1.0` instead of `beta`
Copy link
Contributor

@FranzBusch FranzBusch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you take a look at the CI failures?

Modifications:

* add `_GNU_SOURCE` macro to `Crdkafka` target to fix build error
  "error: '(anonymous struct)::__fds_bits' from module 'CNIOBoringSSL'
  is not present in definition of 'fd_set' provided earlier" for Swift
  5.9 onwards
@felixschlegel
Copy link
Contributor Author

Can you take a look at the CI failures?

That's a weird one, I run into the exact issue as described here:

https://forums.swift.org/t/swift-5-9-compilation-failure-on-linux-when-using-system-modules-that-import-select-h/66275

Currently, my fix is to set the _GNU_SOURCE macro when building the Crdkafka target, which gives me a lot of duplicate macro warnings but seems to work.

Co-authored-by: Franz Busch <[email protected]>
@felixschlegel
Copy link
Contributor Author

We need to get #137 merged before we get the 5.10 test to pass

@FranzBusch FranzBusch merged commit 5dbf2fa into swift-server:main Oct 5, 2023
@FranzBusch FranzBusch deleted the fs-vendor-boring-ssl branch October 5, 2023 08:16
axelandersson added a commit to ordo-one/swift-kafka-client that referenced this pull request Oct 5, 2023
…1005

* upstream/main:
  Ship with BoringSSL (swift-server#135)
  Add CI pipeline for Swift 5.10 (swift-server#137)
FranzBusch added a commit that referenced this pull request Nov 3, 2023
FranzBusch added a commit that referenced this pull request Nov 3, 2023
blindspotbounty added a commit to ordo-one/swift-kafka-client that referenced this pull request Nov 29, 2023
blindspotbounty added a commit to ordo-one/swift-kafka-client that referenced this pull request Nov 29, 2023
mimischi added a commit that referenced this pull request Feb 24, 2025
Updates `librdkafka` to the latest release 2.8.0.

### Motivation:

The `librdkafka` version shipped by this client has gotten fairly old,
and there's been a few releases with bug fixes.

### Modifications:

A recent commit [1] added a function call that is not available in
BoringSSL. This requires us moving away from BoringSSL again.

[1]
https://github.com/confluentinc/librdkafka/blame/93877617709eb071a0f4ec7038c54e2764abefc9/src/rdkafka_ssl.c#L1533

### Result:

* Updated `librdkafka` to 2.8.0.
* Removed BoringSSL from project (introduced in
#135)
* `libssl-dev` now needs to be available during build time again.

Closes #186
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

rdkafka: SSL requirement
2 participants