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

Add unstable-no-link feature #525

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/header-translator/src/library.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ impl fmt::Display for Library {
// FIXME: We always do cfg_attr(feature = "apple", ...) to make compiling things for GNUStep easier.
writeln!(
f,
"#[cfg_attr(feature = \"apple\", link(name = \"{}\", kind = \"framework\"))]",
"#[cfg_attr(all(feature = \"apple\", not(feature = \"unstable-no-link\")), link(name = \"{}\", kind = \"framework\"))]",
self.link_name
)?;
if let Some(gnustep_library) = &self.data.gnustep_library {
Expand Down
3 changes: 3 additions & 0 deletions crates/icrate/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,9 @@ required-features = [
[features]
default = ["std", "apple"]

# Disable to link frameworks, which may not available on lower OS versions, or users don't want to load the frameworks at startup (dyld).
unstable-no-link = []

# Currently not possible to turn off, put here for forwards compatibility.
std = ["alloc", "objc2?/std", "block2?/std"]
alloc = ["objc2?/alloc", "block2?/alloc"]
Expand Down
Loading