Skip to content

Commit

Permalink
Fix feature defaults handling
Browse files Browse the repository at this point in the history
  • Loading branch information
passcod committed Jul 30, 2022
1 parent 102ffa2 commit 5a400f9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
include:
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
debug_features: [ rustls, pkg-config, reflink ]
debug_features: [ pkg-config, reflink ]
release_features: [ reflink ]
- target: x86_64-apple-darwin
os: macos-latest
Expand All @@ -38,8 +38,8 @@ jobs:
release_features: [ reflink ]
- target: x86_64-pc-windows-msvc
os: windows-latest
debug_features: [ native-tls ]
release_features: [ static, zlib-ng, native-tls, fancy-no-backtrace, reflink ]
debug_features: [ no-defaults, static, zlib-ng, native_tls, fancy-no-backtrace ]
release_features: [ no-defaults, static, zlib-ng, native-tls, fancy-no-backtrace, reflink ]
- target: x86_64-unknown-linux-musl
os: ubuntu-latest
- target: armv7-unknown-linux-musleabihf
Expand Down
10 changes: 7 additions & 3 deletions ci-scripts/compile-settings.jq
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,17 @@ if $for_release then {
output: "debug",
profile: "dev",
args: ($matrix.debug_build_args // ""),
features: ($matrix.debug_features // ["rustls", "fancy-with-backtrace"]),
features: ($matrix.debug_features // ["fancy-with-backtrace"]),
} end
|
.features = (
if (.features | length > 0)
then "--no-default-features --features \(.features | join(","))"
else "" end
then (
if ((.features | index("no-defaults")) == null)
then "--features \(.features | join(","))"
else "--no-default-features --features \(.features | map(select(. != "no-defaults")) | join(","))"
end
) else "" end
)
|
{
Expand Down

0 comments on commit 5a400f9

Please sign in to comment.