Skip to content

Fix build on Windows#258

Open
sfackler wants to merge 13 commits intodevelopfrom
windows
Open

Fix build on Windows#258
sfackler wants to merge 13 commits intodevelopfrom
windows

Conversation

@sfackler
Copy link
Copy Markdown
Member

@sfackler sfackler commented Aug 6, 2025

No description provided.

@changelog-app
Copy link
Copy Markdown

changelog-app bot commented Aug 6, 2025

Generate changelog in changelog/@unreleased

Type (Select exactly one)

  • Feature (Adding new functionality)
  • Improvement (Improving existing functionality)
  • Fix (Fixing an issue with existing functionality)
  • Break (Creating a new major version by breaking public APIs)
  • Deprecation (Removing functionality in a non-breaking way)
  • Migration (Automatically moving data/functionality to a new system)

Description

Fix build on Windows

Check the box to generate changelog(s)

  • Generate changelog entry

@sfackler sfackler force-pushed the windows branch 2 times, most recently from 3cb39eb to 2149c70 Compare August 8, 2025 18:56
@sfackler sfackler marked this pull request as ready for review August 8, 2025 20:21
@sfackler sfackler requested a review from a team August 8, 2025 20:21
hyper-util = { version = "0.1", features = ["tokio"] }
hyper = "1"
libc = "0.2"
openssl = "0.10"
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Easier to just switch the ETE tests over to using rustls for their client rather than getting openssl built/linked on windows.

@@ -1,21 +1,18 @@
-----BEGIN CERTIFICATE-----
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Need a new test cert (copied from conjure-rust-runtime) since rustls doesn't allow CAs to be used as leafs. This is a self-signed non-CA cert.

witchcraft-server-macros = { version = "5.6.0", path = "../witchcraft-server-macros" }
zipkin = "1.0"

[target.'cfg(not(windows))'.dependencies]
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

tikv-jemallocator doesn't build on windows. The upstream jemalloc project is also archived, so it might be time to think about switching to mimalloc...

let ctrlc = stream::poll_fn(move |cx| ctrlc.poll_recv(cx));

let mut ctrlbreak = windows::ctrl_break().map_err(Error::internal_safe)?;
let ctrlbreak = stream::poll_fn(move |cx| ctrlbreak.poll_recv(cx));
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Using ctrl-break here for ETE tests since you apparently can't send ctrl-c to a single process group on windows.

pub fn init(metrics: &MetricRegistry) {
register_uptime_metric(metrics);
register_panic_metric(metrics);
#[cfg(unix)]
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

We may want to figure out how to port these metrics to windows in the future.

@sfackler sfackler closed this Aug 14, 2025
@sfackler sfackler deleted the windows branch August 14, 2025 19:17
@sfackler sfackler restored the windows branch August 20, 2025 16:59
@sfackler sfackler reopened this Oct 13, 2025
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.

2 participants