Skip to content

Commit 8b0d4d8

Browse files
authored
1.6.3
* musl build? * name builds * version stamp * SupportsNative should return false if library cannot be loaded * update release notes
1 parent 270eb5e commit 8b0d4d8

File tree

3 files changed

+25
-6
lines changed

3 files changed

+25
-6
lines changed

.github/workflows/build.yml

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: '🏦 Build'
22

33
env:
4-
VERSION: 1.6.2
5-
# PACKAGE_SUFFIX: '-pre.1'
6-
PACKAGE_SUFFIX: ''
4+
VERSION: 1.6.3
5+
PACKAGE_SUFFIX: '-pre.1'
6+
# PACKAGE_SUFFIX: ''
77
ASM_VERSION: 1.0.0
88
BUILD_TYPE: Release
99
VCPKG_HASH: 0f88ecb8528605f91980b90a2c5bad88e3cb565f
@@ -27,18 +27,28 @@ jobs:
2727
matrix:
2828
include:
2929
- os: ubuntu-20.04
30+
name: Linux x64
3031
arch: x64
3132
vcpkg_triplet: x64-linux
3233
vcpkg_config: RelWithDebInfo
3334
dotnet_rid: linux-x64
35+
- os: ubuntu-22.04
36+
name: Linux x64 musl
37+
arch: x64
38+
vcpkg_triplet: x64-linux
39+
vcpkg_config: RelWithDebInfo
40+
dotnet_rid: linux-musl-x64
41+
cmake_options: -D CMAKE_C_FLAGS="-static -Os"
3442
- os: ubuntu-20.04
43+
name: Linux ARM
3544
arch: arm64
3645
vcpkg_triplet: arm64-linux
3746
vcpkg_config: RelWithDebInfo
3847
dotnet_rid: linux-arm64
3948
no_native_tests: true
4049
cmake_options: -D CMAKE_SYSTEM_PROCESSOR=aarch64 -D CMAKE_C_COMPILER=$(which aarch64-linux-gnu-gcc) -D CMAKE_CXX_COMPILER=$(which aarch64-linux-gnu-g++)
4150
- os: windows-latest
51+
name: Windows x64
4252
arch: x64
4353
vcpkg_triplet: x64-windows-static
4454
vcpkg_config: Release
@@ -51,14 +61,15 @@ jobs:
5161
# dotnet_rid: win-x86
5262
# cmake_options: -D CMAKE_GENERATOR_PLATFORM=x86
5363
- os: macos-latest
64+
name: MacOS ARM
5465
arch: arm64
5566
vcpkg_triplet: arm64-osx
5667
vcpkg_config: RelWithDebInfo
5768
dotnet_rid: osx-arm64
5869
cmake_options: -D CMAKE_OSX_ARCHITECTURES=arm64
5970

6071
fail-fast: false
61-
name: 'build: ${{ matrix.os }} (${{ matrix.arch }})'
72+
name: 'build: ${{ matrix.name }}'
6273

6374
env:
6475
VCPKG_DEFAULT_VCPKG_TRIPLET: ${{ matrix.vcpkg_triplet }}

docs/release-notes.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 1.6.3
2+
3+
- Native build for Linux [musl](https://wiki.musl-libc.org/projects-using-musl.html) runtime.
4+
- Fixed regression - when native library cannot be loaded, the entire compression fails.
5+
16
## 1.6.2
27

38
- Improvement: native library can return it's version.

managed/IronCompress/Iron.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,15 @@ public static bool SupportsManaged(Codec c) {
4444
}
4545

4646
public static bool SupportsNative(Codec c) {
47+
if(!IsNativeLibraryAvailable) {
48+
return false;
49+
}
4750
return Native.iron_is_supported((int)c);
4851
}
4952

50-
public static string GetNativeVersion() {
53+
public static string? GetNativeVersion() {
5154
IntPtr ptr = Native.iron_version();
52-
string version = Marshal.PtrToStringAnsi(ptr);
55+
string? version = Marshal.PtrToStringAnsi(ptr);
5356
return version;
5457
}
5558

0 commit comments

Comments
 (0)