Skip to content

Commit 414ca0a

Browse files
authored
Merge pull request #195 from EmbarkStudios/main
Add missing package files
2 parents d9dde9d + e3d7095 commit 414ca0a

File tree

3 files changed

+39
-9
lines changed

3 files changed

+39
-9
lines changed

.github/workflows/ci.yml

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -81,24 +81,35 @@ jobs:
8181

8282
cc:
8383
runs-on: ubuntu-22.04
84-
env:
85-
TARGET_TRIPLE: x86_64-unknown-linux-gnu
8684
steps:
8785
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
8886
with:
8987
submodules: true
9088
# Ensures --all-features builds correctly, the current logic will mean it
9189
# uses stock zlib, not cmake nor cc
9290
- run: |
93-
cargo test --target $TARGET_TRIPLE --all-features
94-
cargo run --target $TARGET_TRIPLE --manifest-path systest/Cargo.toml --all-features
91+
cargo test --all-features
92+
cargo run --manifest-path systest/Cargo.toml --all-features
9593
# Ensures zlib-ng builds and runs, though zlib-ng _could_ change internally
9694
# and not use all optimizations available to the CI runner, we do this here
9795
# just for x86_64-unknown-linux-gnu to validate a common target compiles
9896
# on a more recent compiler than the incredibly ancient one currently used by cross
9997
- run: |
100-
cargo test --target $TARGET_TRIPLE --no-default-features --features zlib-ng-no-cmake-experimental-community-maintained || echo "::warning::failed to build libz-ng with --features zlib-ng-no-cmake-experimental-community-maintained"
101-
cargo run --target $TARGET_TRIPLE --manifest-path systest/Cargo.toml --no-default-features --features zlib-ng-no-cmake-experimental-community-maintained || echo "::warning::failed to run systest with --features zlib-ng-no-cmake-experimental-community-maintained"
98+
cargo test --no-default-features --features zlib-ng-no-cmake-experimental-community-maintained || echo "::warning::failed to build libz-ng with --features zlib-ng-no-cmake-experimental-community-maintained"
99+
cargo run --manifest-path systest/Cargo.toml --no-default-features --features zlib-ng-no-cmake-experimental-community-maintained || echo "::warning::failed to run systest with --features zlib-ng-no-cmake-experimental-community-maintained"
100+
101+
102+
# ensures packaging works
103+
package:
104+
runs-on: ubuntu-22.04
105+
steps:
106+
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
107+
with:
108+
submodules: true
109+
- run: |
110+
cargo package --all-features
111+
cargo package --no-default-features --features zlib-ng-no-cmake-experimental-community-maintained
112+
cargo package --no-default-features --features zlib-ng
102113
103114
linux:
104115
runs-on: ubuntu-latest
@@ -114,6 +125,8 @@ jobs:
114125
name: cross-linux-musl
115126
path: /tmp/
116127
- run: chmod +x /tmp/cross
128+
- run: echo RUSTFLAGS=${RUSTFLAGS}\ -Zlinker-features=-lld >> $GITHUB_ENV
129+
if: matrix.channel == 'nightly'
117130
- run: ci/set_rust_version.bash ${{ matrix.channel }} ${{ matrix.target }}
118131
- run: ci/test.bash /tmp/cross ${{ matrix.target }}
119132

Cargo.toml

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "libz-sys"
3-
version = "1.1.17"
3+
version = "1.1.18"
44
authors = [
55
"Alex Crichton <[email protected]>",
66
"Josh Triplett <[email protected]>",
@@ -18,10 +18,27 @@ include = [
1818
"LICENSE*",
1919
"/README.md",
2020
"build.rs",
21+
"zng/cc.rs",
22+
"zng/cmake.rs",
2123
"src/*.rs",
2224
"src/*.c",
2325
"src/zlib/*.[ch]",
2426
"src/zlib/*.pc.in",
27+
# zlib-ng
28+
"src/zlib-ng/**.[ch]",
29+
"src/zlib-ng/arch/arm/**.[ch]",
30+
"src/zlib-ng/arch/generic/**.[ch]",
31+
"src/zlib-ng/arch/power/**.[ch]",
32+
"src/zlib-ng/arch/riscv/**.[ch]",
33+
"src/zlib-ng/arch/s390x/**.[ch]",
34+
"src/zlib-ng/arch/x86/**.[ch]",
35+
"src/zlib-ng/*.[ch].in",
36+
"src/zlib-ng/*.pc.in",
37+
"src/zlib-ng/zlib_name_mangling.h.empty",
38+
# zlib-ng cmake
39+
"src/zlib-ng/CMakeLists.txt",
40+
"src/zlib-ng/zlib.pc.cmakein",
41+
"src/zlib-ng/cmake",
2542
]
2643

2744
[workspace]
@@ -37,7 +54,7 @@ libc = { version = "0.2.43", optional = true }
3754

3855
[build-dependencies]
3956
pkg-config = "0.3.9"
40-
cc = "1.0.18"
57+
cc = "1.0.98"
4158
cmake = { version = "0.1.50", optional = true }
4259
vcpkg = "0.2"
4360

zng/cc.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ struct Build {
1111

1212
impl Build {
1313
fn new(cfg: cc::Build) -> Self {
14-
let is_msvc = cfg.get_compiler().is_like_msvc();
14+
let is_msvc = cfg.try_get_compiler().unwrap().is_like_msvc();
1515
Self { cfg, is_msvc }
1616
}
1717

0 commit comments

Comments
 (0)