mirror of
https://github.com/jedisct1/libsodium.git
synced 2024-12-24 12:36:01 -07:00
Merge commit '5bb26cbb9487f870a2ea8352d1b431d7f0921c88' into stable
* commit '5bb26cbb9487f870a2ea8352d1b431d7f0921c88': Compile .NET Linux targets with Zig Remove unneeded path build.zig: require at least SSE4.1 when targeting x86_64 test/default/run.sh compat with GNU find
This commit is contained in:
commit
8b348ab16c
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -50,7 +50,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Compilation with zig
|
- name: Compilation with zig
|
||||||
run: |
|
run: |
|
||||||
export PATH=/opt/zig/bin:/opt/zig:$PATH
|
export PATH=/opt/zig:$PATH
|
||||||
zig build
|
zig build
|
||||||
zig build -Dtarget=x86_64-linux
|
zig build -Dtarget=x86_64-linux
|
||||||
zig build -Dtarget=aarch64-linux
|
zig build -Dtarget=aarch64-linux
|
||||||
|
205
.github/workflows/dotnet-core.yml
vendored
205
.github/workflows/dotnet-core.yml
vendored
@ -26,146 +26,144 @@ jobs:
|
|||||||
|
|
||||||
build-linux-glibc:
|
build-linux-glibc:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
|
||||||
image: ubuntu:16.04
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up build environment
|
- name: Install Zig
|
||||||
run: |
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
apt-get update && apt-get install -y build-essential
|
with:
|
||||||
|
version: master
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: build
|
||||||
run: ./configure --disable-dependency-tracking --prefix=$PWD/.libsodium-build
|
run: |
|
||||||
- name: make
|
zig build -Drelease-fast -Dtarget=x86_64-linux-gnu.2.17
|
||||||
run: make
|
- name: tests
|
||||||
- name: make check
|
run: cd zig-out/bin && ./run.sh
|
||||||
run: make check
|
|
||||||
- name: make install
|
|
||||||
run: make install
|
|
||||||
- name: strip
|
|
||||||
run: strip --strip-all .libsodium-build/lib/libsodium.so
|
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: build-linux-x64
|
name: build-linux-x64
|
||||||
path: .libsodium-build/lib/libsodium.so
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
build-linux-glibc-arm64:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
container:
|
|
||||||
image: ubuntu:16.04
|
|
||||||
options: --privileged
|
|
||||||
steps:
|
|
||||||
- name: Set up build environment
|
|
||||||
run: |
|
|
||||||
export DEBIAN_FRONTEND=noninteractive
|
|
||||||
apt-get update && apt-get install -y build-essential qemu binfmt-support qemu-user-static qemu-system-arm gcc-aarch64-linux-gnu libc6-arm64-cross
|
|
||||||
dpkg --add-architecture arm64
|
|
||||||
update-binfmts --enable qemu-aarch64
|
|
||||||
update-binfmts --display
|
|
||||||
ln -s /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.* /lib
|
|
||||||
- uses: actions/checkout@v3
|
|
||||||
- name: configure
|
|
||||||
run: ./configure --disable-dependency-tracking --prefix=$PWD/.libsodium-build --host=aarch64-linux-gnu
|
|
||||||
- name: make
|
|
||||||
run: make -j $(nproc)
|
|
||||||
- name: make check
|
|
||||||
run: |
|
|
||||||
env LD_LIBRARY_PATH=/usr/aarch64-linux-gnu/lib make check
|
|
||||||
- name: make install
|
|
||||||
run: make install
|
|
||||||
- name: strip
|
|
||||||
run: aarch64-linux-gnu-strip --strip-all .libsodium-build/lib/libsodium.so
|
|
||||||
- uses: actions/upload-artifact@v3
|
|
||||||
with:
|
|
||||||
name: build-linux-arm64
|
|
||||||
path: .libsodium-build/lib/libsodium.so
|
|
||||||
|
|
||||||
build-linux-glibc-arm:
|
build-linux-glibc-arm:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
|
||||||
image: ubuntu:16.04
|
|
||||||
options: --privileged
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up build environment
|
- name: Install Zig
|
||||||
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
|
with:
|
||||||
|
version: master
|
||||||
|
- name: Fix ARM support
|
||||||
|
run: |
|
||||||
|
curl -L https://raw.githubusercontent.com/ziglang/zig/master/lib/libc/glibc/sysdeps/arm/arm-features.h | sudo tee /opt/hostedtoolcache/zig/zig-linux-x86_64-*/x64/lib/libc/glibc/sysdeps/arm/sysdep.h >/dev/null
|
||||||
|
- name: Set up emulation environment
|
||||||
run: |
|
run: |
|
||||||
export DEBIAN_FRONTEND=noninteractive
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
apt-get update && apt-get install -y build-essential qemu binfmt-support qemu-user-static qemu-system-arm gcc-arm-linux-gnueabihf libc6-armhf-cross
|
sudo apt-get update
|
||||||
dpkg --add-architecture armhf
|
sudo apt-get install -y build-essential qemu binfmt-support qemu-user-static qemu-system-arm gcc-arm-linux-gnueabihf libc6-armhf-cross
|
||||||
update-binfmts --enable qemu-arm
|
sudo dpkg --add-architecture armhf
|
||||||
update-binfmts --display
|
sudo update-binfmts --enable qemu-arm
|
||||||
ln -s /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.* /lib
|
sudo update-binfmts --display
|
||||||
|
sudo ln -s /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.* /lib
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: build
|
||||||
run: ./configure --disable-dependency-tracking --prefix=$PWD/.libsodium-build --host=arm-linux-gnueabihf
|
|
||||||
- name: make
|
|
||||||
run: make -j $(nproc)
|
|
||||||
- name: make check
|
|
||||||
run: |
|
run: |
|
||||||
env LD_LIBRARY_PATH=/usr/arm-linux-gnueabihf/lib make check
|
zig build -Drelease-fast -Dtarget=arm-linux-gnueabihf.2.23
|
||||||
- name: make install
|
- name: tests
|
||||||
run: make install
|
run: |
|
||||||
- name: strip
|
cd zig-out/bin && env LD_LIBRARY_PATH=/usr/arm-linux-gnueabihf/lib ./run.sh
|
||||||
run: arm-linux-gnueabihf-strip --strip-all .libsodium-build/lib/libsodium.so
|
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: build-linux-arm
|
name: build-linux-arm
|
||||||
path: .libsodium-build/lib/libsodium.so
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
|
build-linux-glibc-arm64:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Install Zig
|
||||||
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
|
with:
|
||||||
|
version: master
|
||||||
|
- name: Set up emulation environment
|
||||||
|
run: |
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y qemu binfmt-support qemu-user-static qemu-system-arm gcc-aarch64-linux-gnu libc6-arm64-cross
|
||||||
|
sudo dpkg --add-architecture arm64
|
||||||
|
sudo update-binfmts --enable qemu-aarch64
|
||||||
|
sudo update-binfmts --display
|
||||||
|
sudo ln -s /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.* /lib
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: build
|
||||||
|
run: |
|
||||||
|
zig build -Drelease-fast -Dtarget=aarch64-linux-gnu.2.23
|
||||||
|
- name: tests
|
||||||
|
run: |
|
||||||
|
cd zig-out/bin && env LD_LIBRARY_PATH=/usr/aarch64-linux-gnu/lib ./run.sh
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: build-linux-arm64
|
||||||
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
build-linux-musl:
|
build-linux-musl:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
container:
|
||||||
image: alpine:latest
|
image: alpine:3.13
|
||||||
steps:
|
steps:
|
||||||
- name: Set up build environment
|
- name: Set up build environment
|
||||||
run: |
|
run: |
|
||||||
apk update
|
apk update
|
||||||
apk add alpine-sdk ca-certificates
|
apk add alpine-sdk ca-certificates xz
|
||||||
|
- name: Install Zig
|
||||||
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
|
with:
|
||||||
|
version: master
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: build
|
||||||
run: ./configure --disable-dependency-tracking --prefix=$PWD/.libsodium-build
|
run: |
|
||||||
- name: make
|
zig build -Drelease-fast -Dtarget=x86_64-linux-musl
|
||||||
run: make
|
- name: tests
|
||||||
- name: make check
|
run: |
|
||||||
run: make check
|
cd zig-out/bin && ./run.sh
|
||||||
- name: make install
|
|
||||||
run: make install
|
|
||||||
- name: strip
|
|
||||||
run: strip --strip-all .libsodium-build/lib/libsodium.so
|
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: build-linux-musl-x64
|
name: build-linux-musl-x64
|
||||||
path: .libsodium-build/lib/libsodium.so
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
|
build-linux-musl-arm:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Install Zig
|
||||||
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
|
with:
|
||||||
|
version: master
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: build
|
||||||
|
run: |
|
||||||
|
zig build -Drelease-fast -Dtarget=arm-linux-musleabihf
|
||||||
|
- uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: build-linux-musl-arm
|
||||||
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
build-linux-musl-arm64:
|
build-linux-musl-arm64:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
|
||||||
image: alpine:latest
|
|
||||||
steps:
|
steps:
|
||||||
- name: Set up build environment
|
- name: Install Zig
|
||||||
run: |
|
uses: goto-bus-stop/setup-zig@869a4299cf8ac7db4ebffaec36ad82a682f88acb
|
||||||
apk update
|
with:
|
||||||
apk add alpine-sdk ca-certificates
|
version: master
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: build
|
||||||
run: ./configure --disable-dependency-tracking --prefix=$PWD/.libsodium-build --host=aarch64-linux-gnu
|
run: |
|
||||||
- name: make
|
zig build -Drelease-fast -Dtarget=aarch64-linux-musl
|
||||||
run: make
|
|
||||||
- name: make check
|
|
||||||
run: make check
|
|
||||||
- name: make install
|
|
||||||
run: make install
|
|
||||||
- name: strip
|
|
||||||
run: strip --strip-all .libsodium-build/lib/libsodium.so
|
|
||||||
- uses: actions/upload-artifact@v3
|
- uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: build-linux-musl-arm64
|
name: build-linux-musl-arm64
|
||||||
path: .libsodium-build/lib/libsodium.so
|
path: zig-out/lib/libsodium.so
|
||||||
|
|
||||||
build-macos-x64:
|
build-macos-x64:
|
||||||
runs-on: macos-11
|
runs-on: macos-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: configure
|
||||||
run: env CFLAGS="-Ofast -arch x86_64 -mmacosx-version-min=10.10" LDFLAGS="-arch x86_64 -mmacosx-version-min=10.10" ./configure --host=arm-apple-darwin20 --prefix=$PWD/.libsodium-build
|
run: env CFLAGS="-Ofast -arch x86_64 -mmacosx-version-min=10.13" LDFLAGS="-arch x86_64 -mmacosx-version-min=10.13" ./configure --host=arm-apple-darwin20 --prefix=$PWD/.libsodium-build
|
||||||
- name: make
|
- name: make
|
||||||
run: make
|
run: make
|
||||||
- name: make check
|
- name: make check
|
||||||
@ -178,11 +176,11 @@ jobs:
|
|||||||
path: .libsodium-build/lib/libsodium.dylib
|
path: .libsodium-build/lib/libsodium.dylib
|
||||||
|
|
||||||
build-macos-arm64:
|
build-macos-arm64:
|
||||||
runs-on: macos-11
|
runs-on: macos-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
- name: configure
|
- name: configure
|
||||||
run: env CFLAGS="-Ofast -arch arm64 -mmacosx-version-min=10.10" LDFLAGS="-arch arm64 -mmacosx-version-min=10.10" ./configure --host=arm-apple-darwin20 --prefix=$PWD/.libsodium-build
|
run: env CFLAGS="-Ofast -arch arm64 -mmacosx-version-min=10.13" LDFLAGS="-arch arm64 -mmacosx-version-min=10.13" ./configure --host=arm-apple-darwin20 --prefix=$PWD/.libsodium-build
|
||||||
- name: make
|
- name: make
|
||||||
run: make
|
run: make
|
||||||
- name: make install
|
- name: make install
|
||||||
@ -200,6 +198,7 @@ jobs:
|
|||||||
- build-linux-glibc-arm
|
- build-linux-glibc-arm
|
||||||
- build-linux-glibc-arm64
|
- build-linux-glibc-arm64
|
||||||
- build-linux-musl
|
- build-linux-musl
|
||||||
|
- build-linux-musl-arm
|
||||||
- build-linux-musl-arm64
|
- build-linux-musl-arm64
|
||||||
- build-macos-x64
|
- build-macos-x64
|
||||||
- build-macos-arm64
|
- build-macos-arm64
|
||||||
@ -235,6 +234,10 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
name: build-linux-musl-x64
|
name: build-linux-musl-x64
|
||||||
path: .libsodium-pack/runtimes/linux-musl-x64/native/
|
path: .libsodium-pack/runtimes/linux-musl-x64/native/
|
||||||
|
- uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: build-linux-musl-arm
|
||||||
|
path: .libsodium-pack/runtimes/linux-musl-arm/native/
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: build-linux-musl-arm64
|
name: build-linux-musl-arm64
|
||||||
|
Loading…
Reference in New Issue
Block a user