commit e9b2e4b963719adaff9ea1cbc64f228f363f9d77 parent 21e5918c3bcc4d8d9193caea7c56d1ffc298e8dc Author: Iván Ávalos <avalos@disroot.org> Date: Tue, 19 Aug 2025 16:22:50 +0200 update libsodium to 1.0.20 Diffstat:
302 files changed, 30501 insertions(+), 16811 deletions(-)
diff --git a/subprojects/libsodium/.github/workflows/autocloser.yml b/subprojects/libsodium/.github/workflows/autocloser.yml @@ -0,0 +1,12 @@ +name: Autocloser +on: [issues] +jobs: + autoclose: + runs-on: ubuntu-latest + steps: + - name: Autoclose issues that did not follow issue template + uses: roots/issue-closer@v1.2 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + issue-close-message: "This issue was automatically closed because it did not follow the issue template. We use the issue tracker exclusively for bug reports and feature additions that have been previously discussed. However, this issue appears to be a support request. Please use the discussion forums for support requests." + issue-pattern: ".*(do we replicate the issue|Expected behavior|raised as discussion|# Impact).*" diff --git a/subprojects/libsodium/.github/workflows/ci.yml b/subprojects/libsodium/.github/workflows/ci.yml @@ -0,0 +1,180 @@ +name: CI + +on: + push: + branches: [master, stable, next] + pull_request: + branches: [master, stable, next] + + workflow_dispatch: + +jobs: + tcc: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install dependencies + run: | + sudo apt-get install -y build-essential libtool autoconf automake tcc + + - name: Autogen + run: ./autogen.sh -s + + - name: Compilation with tcc + run: | + env CC=tcc CFLAGS='-w' CPPFLAGS="-DDEV_MODE=1" ./configure --prefix=/tmp --disable-dependency-tracking --disable-shared || cat config.log + make -j $(nproc) && make check && make install + env CC=tcc CPPFLAGS='-I/tmp/include' LDFLAGS='-L/tmp/lib' LD_LIBRARY_PATH='/tmp/lib' ./test/constcheck.sh + make uninstall + make distclean + + zig: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install Zig + uses: mlugg/setup-zig@v2 + with: + version: 0.14.0 + + - name: Autogen + run: ./autogen.sh -s + + - name: Compilation with zig + run: | + zig build + zig build -Dtarget=x86_64-linux + zig build -Dtarget=aarch64-linux + zig build -Dtarget=x86-windows + zig build -Dtarget=x86_64-windows + zig build -Dtarget=aarch64-windows + zig build -Dtarget=x86_64-macos + zig build -Dtarget=aarch64-macos + zig build -Dtarget=wasm32-wasi + zig build -Doptimize=ReleaseFast + rm -fr zig-cache zig-out + + regular: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install dependencies + run: sudo apt-get install -y build-essential libtool autoconf automake + + - name: Autogen + run: ./autogen.sh -s + + - name: C99 compat check + run: | + env CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking + make -j $(nproc) CFLAGS='-g0' > /dev/null && cp src/libsodium/.libs/libsodium.so lib.so && make clean > /dev/null && make CFLAGS='-g0' CPPFLAGS='-DDEV_MODE=1 -DSODIUM_C99\(X\)=' > /dev/null && cp src/libsodium/.libs/libsodium.so lib-oldc.so && cmp lib.so lib-oldc.so && echo No binary changes && make clean > /dev/null + make distcheck + make distclean > /dev/null + + - name: Regular compilation + run: | + env CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking --enable-minimal + make -j $(nproc) + make check + ( echo '#include <sodium.h>' ; echo 'int main(void) { return sodium_init(); }' ) > /tmp/main.c && gcc -DDEV_MODE=1 -Isrc/libsodium/include -Isrc/libsodium/include/sodium $(find src -name '*.c' -o -name '*.S') /tmp/main.c + make distclean > /dev/null + + check-globals: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install dependencies + run: sudo apt-get install -y build-essential libtool autoconf automake + + - name: Autogen + run: ./autogen.sh -s + + - name: Check globals + run: | + if [ -x test/rename-globals.sh ]; then test/rename-globals.sh; fi + + other-comp: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install dependencies + run: sudo apt-get install -y build-essential libtool autoconf automake clang + + - name: Autogen + run: ./autogen.sh -s + + - name: Compilation with g++ + run: | + env CC=g++ CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking + make -j $(nproc) check + make clean > /dev/null + + - name: Compilation with clang + run: | + env CC=clang CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking + make -j $(nproc) check + make clean > /dev/null + + other-arch: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install dependencies + run: sudo apt-get install -y build-essential libtool autoconf automake gcc-powerpc-linux-gnu + + - name: Autogen + run: ./autogen.sh -s + + - name: Big-Endian PowerPC compilation + run: | + env CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking --host=powerpc-linux-gnu + make -j $(nproc) + make clean > /dev/null + + android: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Update packages list + run: sudo apt-get update + + - name: Install base dependencies + run: sudo apt-get install -y libtool autoconf automake unzip + + - name: Autogen + run: ./autogen.sh -s + + - name: Install Android NDK + run: | + mkdir /tmp/android && cd /tmp/android + curl -o ndk.zip -L https://dl.google.com/android/repository/android-ndk-r27c-linux.zip + unzip ndk.zip && rm -f *.zip && mv android-ndk* ndk + + - name: Android compilation + run: | + env ANDROID_NDK_HOME=/tmp/android/ndk ./dist-build/android-aar.sh diff --git a/subprojects/libsodium/.github/workflows/cifuzz.yml b/subprojects/libsodium/.github/workflows/cifuzz.yml @@ -0,0 +1,32 @@ +name: CIFuzz + +on: + push: + branches: [stable, next] + pull_request: + branches: [stable, next] + +jobs: + Fuzzing: + runs-on: ubuntu-latest + steps: + - name: Build Fuzzers + id: build + uses: google/oss-fuzz/infra/cifuzz/actions/build_fuzzers@master + with: + oss-fuzz-project-name: "libsodium" + dry-run: false + language: c++ + - name: Run Fuzzers + uses: google/oss-fuzz/infra/cifuzz/actions/run_fuzzers@master + with: + oss-fuzz-project-name: "libsodium" + fuzz-seconds: 300 + dry-run: false + language: c++ + - name: Upload Crash + uses: actions/upload-artifact@v4 + if: failure() && steps.build.outcome == 'success' + with: + name: artifacts + path: ./out/artifacts diff --git a/subprojects/libsodium/.github/workflows/codeql-analysis.yml b/subprojects/libsodium/.github/workflows/codeql-analysis.yml @@ -0,0 +1,48 @@ +name: "CodeQL scan" + +on: + push: + branches: [ "master stable next" ] + pull_request: + # The branches below must be a subset of the branches above + branches: [ "master stable next" ] + schedule: + - cron: '0 17 * * 2' + +jobs: + analyze: + name: Analyze + runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }} + timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }} + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'c-cpp' ] + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 2 + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v2 + with: + languages: ${{ matrix.language }} + + - run: | + echo "Run, Build Application using script" + ./autogen.sh -s + env CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking + make -j $(nproc) check + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v2 + with: + category: "/language:${{matrix.language}}" diff --git a/subprojects/libsodium/.github/workflows/dotnet-core.yml b/subprojects/libsodium/.github/workflows/dotnet-core.yml @@ -0,0 +1,388 @@ +name: .NET Package + +on: + push: + branches: + - stable + - next + +permissions: + id-token: write + attestations: write + contents: read + +jobs: + build-windows-msvc: + runs-on: windows-latest + steps: + - uses: actions/checkout@v4 + - name: buildbase.bat + run: buildbase.bat ..\vs2022\libsodium.sln 17 + working-directory: builds/msvc/build/ + shell: cmd + - uses: actions/upload-artifact@v4 + with: + name: build-win-x64 + path: bin/x64/Release/v143/dynamic/libsodium.dll + - uses: actions/upload-artifact@v4 + with: + name: build-win-x86 + path: bin/Win32/Release/v143/dynamic/libsodium.dll + - uses: actions/upload-artifact@v4 + with: + name: build-win-arm64 + path: bin/ARM64/Release/v143/dynamic/libsodium.dll + + build-others: + runs-on: ubuntu-latest + steps: + - name: Install Zig + uses: mlugg/setup-zig@v2 + with: + version: master + - uses: actions/checkout@v4 + + - name: Build Android AAR + run: sh ./dist-build/android-aar.sh + + - name: Extract android AAR file + run: | + mkdir -p extracted-aar + unzip libsodium-*.aar -d extracted-aar + + - name: Upload Android arm64 + uses: actions/upload-artifact@v4 + with: + name: build-android-arm64 + path: extracted-aar/prefab/modules/sodium/libs/android.arm64-v8a/libsodium.so + + - name: Upload Android arm + uses: actions/upload-artifact@v4 + with: + name: build-android-arm + path: extracted-aar/prefab/modules/sodium/libs/android.armeabi-v7a/libsodium.so + + - name: Upload Android x64 + uses: actions/upload-artifact@v4 + with: + name: build-android-x64 + path: extracted-aar/prefab/modules/sodium/libs/android.x86_64/libsodium.so + + - name: Upload Android x86 + uses: actions/upload-artifact@v4 + with: + name: build-android-x86 + path: extracted-aar/prefab/modules/sodium/libs/android.x86/libsodium.so + + - name: build-linux-x64 + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -Dtarget=x86_64-linux-gnu.2.17 + - name: tests + run: cd zig-out/bin && ./run.sh + - uses: actions/upload-artifact@v4 + with: + name: build-linux-x64 + path: zig-out/lib/libsodium.so + + - name: Set up arm and aarch64 emulation environment + run: | + export DEBIAN_FRONTEND=noninteractive + sudo apt-get update + sudo apt-get install -y build-essential qemu-system binfmt-support qemu-user-static qemu-system-arm gcc-arm-linux-gnueabihf libc6-armhf-cross gcc-aarch64-linux-gnu libc6-arm64-cross + sudo dpkg --add-architecture armhf + sudo update-binfmts --enable qemu-arm + sudo update-binfmts --display + sudo ln -s /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.* /lib + 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 + + - name: build-linux-arm + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -Dtarget=arm-linux-gnueabihf.2.23 + - name: tests + run: | + cd zig-out/bin && env LD_LIBRARY_PATH=/usr/arm-linux-gnueabihf/lib ./run.sh + - uses: actions/upload-artifact@v4 + with: + name: build-linux-arm + path: zig-out/lib/libsodium.so + + - name: build-linux-arm64 + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -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@v4 + with: + name: build-linux-arm64 + path: zig-out/lib/libsodium.so + + - name: build-linux-musl-x64 + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -Dtarget=x86_64-linux-musl + - uses: actions/upload-artifact@v4 + with: + name: build-linux-musl-x64 + path: zig-out/lib/libsodium.so + + - name: build-linux-musl-arm + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -Dtarget=arm-linux-musleabihf + - uses: actions/upload-artifact@v4 + with: + name: build-linux-musl-arm + path: zig-out/lib/libsodium.so + + - name: build-linux-musl-arm64 + run: | + rm -fr zig-out .zig-cache; zig build -Doptimize=ReleaseFast -Dtarget=aarch64-linux-musl + - uses: actions/upload-artifact@v4 + with: + name: build-linux-musl-arm64 + path: zig-out/lib/libsodium.so + + build-apple: + runs-on: macos-latest + steps: + - uses: actions/checkout@v4 + - name: configure + run: ./configure + - name: build-xcframework + run: env LIBSODIUM_FULL_BUILD=1 LIBSODIUM_SKIP_SIMULATORS=1 dist-build/apple-xcframework.sh + - uses: actions/upload-artifact@v4 + with: + name: build-macos + path: libsodium-apple/macos/lib/libsodium.dylib + - uses: actions/upload-artifact@v4 + with: + name: build-ios + path: libsodium-apple/ios/lib/libsodium.a + - uses: actions/upload-artifact@v4 + with: + name: build-tvos + path: libsodium-apple/tvos/lib/libsodium.a + - uses: actions/upload-artifact@v4 + with: + name: build-maccatalyst + path: libsodium-apple/catalyst/lib/libsodium.a + pack: + runs-on: ubuntu-latest + needs: + - build-windows-msvc + - build-apple + - build-others + container: + image: mcr.microsoft.com/dotnet/sdk:6.0 + env: + DOTNET_CLI_TELEMETRY_OPTOUT: 1 + DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 + DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: 1 + steps: + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v4 + with: + name: build-win-x64 + path: .libsodium-pack/runtimes/win-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-win-x86 + path: .libsodium-pack/runtimes/win-x86/native/ + - uses: actions/download-artifact@v4 + with: + name: build-win-arm64 + path: .libsodium-pack/runtimes/win-arm64/native/ + + - uses: actions/download-artifact@v4 + with: + name: build-linux-x64 + path: .libsodium-pack/runtimes/linux-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-linux-arm64 + path: .libsodium-pack/runtimes/linux-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-linux-arm + path: .libsodium-pack/runtimes/linux-arm/native/ + - uses: actions/download-artifact@v4 + with: + name: build-linux-musl-x64 + path: .libsodium-pack/runtimes/linux-musl-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-linux-musl-arm + path: .libsodium-pack/runtimes/linux-musl-arm/native/ + - uses: actions/download-artifact@v4 + with: + name: build-linux-musl-arm64 + path: .libsodium-pack/runtimes/linux-musl-arm64/native/ + + - uses: actions/download-artifact@v4 + with: + name: build-macos + path: .libsodium-pack/runtimes/osx-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-macos + path: .libsodium-pack/runtimes/osx-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-ios + path: .libsodium-pack/runtimes/ios-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-tvos + path: .libsodium-pack/runtimes/tvos-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-maccatalyst + path: .libsodium-pack/runtimes/maccatalyst-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-maccatalyst + path: .libsodium-pack/runtimes/maccatalyst-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-android-arm64 + path: .libsodium-pack/runtimes/android-arm64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-android-arm + path: .libsodium-pack/runtimes/android-arm/native/ + - uses: actions/download-artifact@v4 + with: + name: build-android-x64 + path: .libsodium-pack/runtimes/android-x64/native/ + - uses: actions/download-artifact@v4 + with: + name: build-android-x86 + path: .libsodium-pack/runtimes/android-x86/native/ + + - name: Copy files + run: cp AUTHORS ChangeLog LICENSE packaging/dotnet-core/libsodium.pkgproj .libsodium-pack/ + + - name: Create NuGet package + run: dotnet pack -c Release .libsodium-pack/libsodium.pkgproj + - uses: actions/upload-artifact@v4 + with: + name: nuget-package + path: .libsodium-pack/bin/Release/*.nupkg + + - name: Attest Build Provenance + uses: actions/attest-build-provenance@897ed5eab6ed058a474202017ada7f40bfa52940 + with: + subject-path: .libsodium-pack/bin/Release/*.nupkg + + build-test-binaries: + runs-on: ubuntu-latest + needs: + - pack + container: + image: mcr.microsoft.com/dotnet/sdk:6.0 + env: + DOTNET_CLI_TELEMETRY_OPTOUT: 1 + DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1 + DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: 1 + steps: + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v4 + with: + name: nuget-package + path: .libsodium-pack/ + - name: dotnet new + run: dotnet new console -n Tests -o .libsodium-test/ + + - name: dotnet add package libsodium + run: dotnet add .libsodium-test/Tests.csproj package libsodium -s $PWD/.libsodium-pack + - name: Copy files + run: cp -f packaging/dotnet-core/test.cs .libsodium-test/Program.cs + - name: dotnet publish linux-x64 + run: dotnet publish -c Release -r linux-x64 --self-contained true -p:PublishTrimmed=true + working-directory: .libsodium-test/ + - name: dotnet publish linux-arm + run: dotnet publish -c Release -r linux-arm --self-contained true -p:PublishTrimmed=true + working-directory: .libsodium-test/ + - name: dotnet publish linux-arm64 + run: dotnet publish -c Release -r linux-arm64 --self-contained true -p:PublishTrimmed=true + working-directory: .libsodium-test/ + - name: Move Build Output + run: | + mkdir .libsodium-builds + mv .libsodium-test/bin/Release/net6.0/linux-arm/publish .libsodium-builds/linux-arm + mv .libsodium-test/bin/Release/net6.0/linux-arm64/publish .libsodium-builds/linux-arm64 + mv .libsodium-test/bin/Release/net6.0/linux-x64/publish .libsodium-builds/linux-x64 + - uses: actions/upload-artifact@v4 + with: + name: test-builds + path: .libsodium-builds/* + include-hidden-files: true + + run-test-binaries-os-versions: + runs-on: ubuntu-latest + needs: + - build-test-binaries + strategy: + matrix: + arch: [ 'centos:8', 'debian:10' ] + container: + image: ${{ matrix.arch }} + env: + DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: 1 + steps: + - uses: actions/download-artifact@v4 + with: + name: test-builds + path: .libsodium-builds/ + - name: Run x64 tests + run: | + chmod +x .libsodium-builds/linux-x64/Tests + .libsodium-builds/linux-x64/Tests + + run-test-binaries-cross-plat: + runs-on: ubuntu-22.04 + needs: + - build-test-binaries + env: + DOTNET_SYSTEM_GLOBALIZATION_INVARIANT: 1 + strategy: + matrix: + include: + - arch: x64 + libs: /usr/lib + - arch: arm + libs: /usr/arm-linux-gnueabihf/lib + - arch: arm64 + libs: /usr/aarch64-linux-gnu/lib + arch: [x64, arm, arm64] + steps: + - name: Set up build environment + run: | + export DEBIAN_FRONTEND=noninteractive + + # On virtualization systems such as the one used by WSL2, the ARM crypto extensions + # don't work as expected. As a result, installing on Ubuntu fails during integrity + # checks. As a workaround, the following command disables hardware acceleration for + # gcrypt, which the apt-get command relies on. + sudo mkdir -p /etc/gcrypt && echo all | sudo tee /etc/gcrypt/hwf.deny + + sudo apt-get update && sudo apt-get install -y qemu-system binfmt-support qemu-user-static qemu-system-arm gcc-arm-linux-gnueabihf gcc-aarch64-linux-gnu libc6-armhf-cross libc6-arm64-cross + sudo dpkg --add-architecture armhf + sudo dpkg --add-architecture arm64 + sudo update-binfmts --enable qemu-aarch64 + sudo update-binfmts --enable qemu-arm + sudo update-binfmts --display + sudo ln -s /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.* /lib + sudo ln -s /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.* /lib + + - uses: actions/download-artifact@v4 + with: + name: test-builds + path: .libsodium-builds/ + + - name: Run ${{ matrix.arch }} + run: | + chmod +x .libsodium-builds/linux-${{ matrix.arch }}/Tests + env LD_LIBRARY_PATH=${{ matrix.libs }} .libsodium-builds/linux-${{ matrix.arch }}/Tests diff --git a/subprojects/libsodium/.gitignore b/subprojects/libsodium/.gitignore @@ -80,6 +80,8 @@ test-driver test/default/*.asm.js test/default/*.res test/default/*.trs +test/default/aead_aegis128l +test/default/aead_aegis256 test/default/aead_aes256gcm test/default/aead_aes256gcm2 test/default/aead_chacha20poly1305 @@ -117,6 +119,7 @@ test/default/generichash3 test/default/hash test/default/hash3 test/default/kdf +test/default/kdf_hkdf test/default/keygen test/default/kx test/default/metamorphic @@ -143,7 +146,7 @@ test/default/secretbox7 test/default/secretbox8 test/default/secretbox_easy test/default/secretbox_easy2 -test/default/secretstream +test/default/secretstream_xchacha20poly1305 test/default/shorthash test/default/sign test/default/siphashx24 @@ -160,3 +163,6 @@ test/default/verify1 test/default/xchacha20 test/js.done testing +.zig-cache +zig-cache +zig-out diff --git a/subprojects/libsodium/.travis.yml b/subprojects/libsodium/.travis.yml @@ -1,43 +0,0 @@ -sudo: false - -language: c - -os: - - linux - -compiler: - - clang - - gcc - - g++ - -install: - - ./autogen.sh - - env CC=tcc CFLAGS='-w' CPPFLAGS="-DDEV_MODE=1" ./configure --prefix=/tmp --disable-dependency-tracking --disable-shared || cat config.log - - make -j $(nproc) && make check && make install - - env CC=tcc CPPFLAGS='-I/tmp/include' LDFLAGS='-L/tmp/lib' LD_LIBRARY_PATH='/tmp/lib' ./test/constcheck.sh - - make uninstall - - make distclean - -script: - - env CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking - - if [ "$TRAVIS_OS_NAME" = 'linux' -a "$CC" = 'gcc' ]; then make -j $(nproc) CFLAGS='-g0' > /dev/null && cp src/libsodium/.libs/libsodium.so lib.so && make clean > /dev/null && make CFLAGS='-g0' CPPFLAGS='-DSODIUM_C99\(X\)=' > /dev/null && cp src/libsodium/.libs/libsodium.so lib-oldc.so && cmp lib.so lib-oldc.so && echo No binary changes && make clean > /dev/null ; fi - - make distcheck - - make distclean > /dev/null - - CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking --enable-minimal - - make -j $(nproc) - - make check - - ( echo '#include <sodium.h>' ; echo 'int main(void) { return sodium_init(); }' ) > /tmp/main.c && gcc -Isrc/libsodium/include -Isrc/libsodium/include/sodium $(find src -name '*.c' -o -name '*.S') /tmp/main.c - - make distclean > /dev/null - -after_success: - - CPPFLAGS="-DDEV_MODE=1" ./configure --disable-dependency-tracking --host=powerpc-linux-gnu - - make -j $(nproc) - - env QEMU_LD_PREFIX=/usr/powerpc-linux-gnu make check - - make clean > /dev/null - -addons: - apt: - packages: - - tcc - - qemu-user-static - - gcc-powerpc-linux-gnu diff --git a/subprojects/libsodium/AUTHORS b/subprojects/libsodium/AUTHORS @@ -45,8 +45,7 @@ siphash Jean-Philippe Aumasson Implementors ============ -crypto_aead/aes256gcm/aesni Romain Dolbeau - Frank Denis +crypto_aead/aes256gcm/aesni Frank Denis crypto_aead/chacha20poly1305 Frank Denis diff --git a/subprojects/libsodium/CITATION.cff b/subprojects/libsodium/CITATION.cff @@ -0,0 +1,18 @@ +cff-version: 1.2.0 +title: libsodium +message: >- + If you use this software, please cite it using the + metadata from this file. +type: software +authors: + - given-names: Frank + family-names: Denis + orcid: 'https://orcid.org/0009-0008-4417-1713' +repository-code: 'https://github.com/jedisct1/libsodium' +url: 'https://libsodium.org' +abstract: 'A modern, portable, easy-to-use cryptographic library.' +keywords: + - cryptography + - library + - nacl +license: ISC diff --git a/subprojects/libsodium/ChangeLog b/subprojects/libsodium/ChangeLog @@ -1,10 +1,118 @@ +* Version 1.0.20-stable + - Performance of AES256-GCM and AEGIS on ARM has been improved. + - Android binaries have been added to the NuGet package + - Windows ARM binaries have been added to the NuGet package + - The Android build script has been improved. The base SDK is +now 27c, and the default platform is 21 + - The library can now be compiled with Zig 0.14+ + - arm64e builds have been added to the XCFramework packages + - XCFramework packages are now full builds instead of minimal +builds + - MSVC builds have been enabled for ARM64 + - A cross-compilation issue with old clang versions has been +fixed + - 16K page sizes are now supported on Android + - JavaScript: support for Cloudflare Workers has been added + - A compilation issue with old toolchains on Solaris has been +fixed + - `crypto_aead_aes256gcm_is_available` is exported to JavaScript + +* Version 1.0.20 + This point release includes all the changes from 1.0.19-stable, +mainly addressing compilation issues and improvements to the .NET +packages. + +* Version 1.0.19-stable + - Building with `zig build` now requires Zig 0.12. + - When using the traditional build system, -O3 is used instead of -Ofast. + - Improved detection of the compiler flags required on aarch64. + - Improved compatibility with custom build systems on aarch64. + - apple-xcframework: VisionOS packages are not built if Xcode doesn't +include that SDK. + - `crypto_kdf_hkdf_sha512_statebytes()` was added. + - When using Visual Studio, runtime CPU feature detection is now enabled +on Windows/aarch64. + - There were issues with C++ guards affecting usage of libsodium +using Swift on Windows. This has been fixed. + - Emscripten: `crypto_aead_aegis*()` functions are now exported in +JavaScript builds + - Emscripten: unsupported `--memory-init-file` option has been removed. + - apple-xcframework: the minimal deployment target can be set to iOS 11+. + - .NET packages now include precompiled libraries for Windows/arm64, +iOS, TvOS and Catalyst. + - .NET precompiled libraries now work on any CPUs, using only runtime +feature detection. + - SYSV assembly should not be used when targeting Windows (reported by +@meiyese, thanks!) + - Compatibility issues with LLVM 18 and AVX512 have been addressed. + - GitHub attestation build provenance are now added to NuGet packages. + - JavaScript tests can now use Bun as an alternative to Node. + +* Version 1.0.19 + This release includes all the changes from 1.0.18-stable, as well as two +additions: + + - New AEADs: AEGIS-128L and AEGIS-256 are now available in the +`crypto_aead_aegis128l_*()` and `crypto_aead_aegis256_*()` namespaces. +AEGIS is a family of authenticated ciphers for high-performance applications, +leveraging hardware AES acceleration on `x86_64` and `aarch64`. In addition +to performance, AEGIS ciphers have unique properties making them easier and +safer to use than AES-GCM. They can also be used as high-performance MACs. + - The HKDF key derivation mechanism, required by many standard protocols, is +now available in the `crypto_kdf_hkdf_*()` namespace. It is implemented for +the SHA-256 and SHA-512 hash functions. + - The `osx.sh` build script was renamed to `macos.sh`. + - Support for android-mips was removed. + +* Version 1.0.18-stable + - Visual Studio: support for Windows/ARM64 builds has been added. + - Visual Studio: AVX512 implementations are enabled on supported CPUs. + - Visual Studio: an MSVC 2022 solution was added. + - Apple XCFramework: support for VisionOS was added. + - Apple XCFramework: support for Catalyst was added. + - Apple XCFramework: building the simulators is now optional. + - iOS: bitcode is not generated any more, as it was deprecated by Apple. + - watchOS: support for arm64 was added. + - The Zig toolchain can now be used as a modern build system to replace +autoconf/automake/libtool/make/ccache and the compiler. This enables faster +compilation times, easier cross compilation, and static libraries optimized +for any CPU. + - The Zig toolchain is now the recommended way to compile `libsodium` +to WebAssembly/WASI(X). + - libsodium can now be added as a dependency to Zig projects. + - Memory fences were added to remove some gadgets that could be used +alongside speculative loads. + - The AES-GCM implementation was completely rewritten. It is now faster, +and also available on aarch64, including Windows/ARM64. + - Compatibility with CET instrumentation / IBT / Shadow Stack was added. + - Emscripten: the `crypto_pwhash_*()` functions have been removed from Sumo +builds, as they reserve a substantial amount of JavaScript memory, even when +not used. + - Benchmarks now use `CLOCK_MONOTONIC` if possible. + - WebAssembly: tests can now run using Bun, WasmEdge, Wazero, wasm3 and +wasmer-js. Support for WAVM and Lucet have been removed, as these projects +have reached EOL. + - .NET: the minimum supported macOS version is now 1.0.15; this matches +Microsoft guidelines. + - .NET: all the packages are now built using Zig, on all platforms. This +allows us to easily match Microsoft's requirements, including supported glibc +versions. However, on x86_64, targets are expected to support at least the +AVX instruction set. + - .NET: packages for ARM64 are now available. + - C23 `memset_explicit()` is now used, when available. + - Compilation now uses `-Ofast` or `-O3` instead of `-O2` by default. + - Portability improvements to help compile libsodium to modern game consoles. + - JavaScript: a default `unhandledRejection` handler is not set any more. + - Slightly faster 25519 operations. + - OpenBSD: leverage `MAP_CONCEAL`. * Version 1.0.18 - - The Enterprise versions of Visual Studio are now supported. + - Enterprise versions of Visual Studio are now supported. - Visual Studio 2019 is now supported. - 32-bit binaries for Visual Studio 2010 are now provided. - - A test that didn't work properly on Linux systems with overcommit -memory turned on has been removed. This fixes Ansible builds. + - A test designed to trigger an OOM condition didn't work on Linux systems +with memory overcommit turned on. It has been removed in order to fix +Ansible builds. - Emscripten: `print` and `printErr` functions are overridden to send errors to the console, if there is one. - Emscripten: `UTF8ToString()` is now exported since `Pointer_stringify()` @@ -14,20 +122,26 @@ has been deprecated. - New target: WebAssembly/WASI (compile with `dist-builds/wasm32-wasi.sh`). - New functions to map a hash to an edwards25519 point or get a random point: `core_ed25519_from_hash()` and `core_ed25519_random()`. - - `crypto_core_ed25519_scalar_mul()` has been implemented for `scalar*scalar` -`(mod L)` multiplication. - - Support for the Ristretto group has been implemented, for compatibility + - `crypto_core_ed25519_scalar_mul()` has been implemented for +`scalar*scalar (mod L)` multiplication. + - Support for the Ristretto group has been implemented for interoperability with wasm-crypto. - Improvements have been made to the test suite. - - Portability improvements has been made. + - Portability improvements have been made. - `getentropy()` is now used on systems providing this system call. - - `randombytes_salsa20 has been renamed to `randombytes_internal`. - - Support for (p)nacl has been removed. + - `randombytes_salsa20` has been renamed to `randombytes_internal`. + - Support for NativeClient has been removed. - Most `((nonnull))` attributes have been relaxed to allow 0-length inputs to be `NULL`. - The `-ftree-vectorize` and `-ftree-slp-vectorize` compiler switches are now used, if available, for optimized builds. +* Version 1.0.17-stable + - AVX512 detection has been improved. + - A compilation option was added to enable retpoline support. + - `-ftls-model=global-dynamic` is now set, if available. + - Portability and documentation improvements. + * Version 1.0.17 - Bug fix: `sodium_pad()` didn't properly support block sizes >= 256 bytes. - JS/WebAssembly: some old iOS versions can't instantiate the WebAssembly diff --git a/subprojects/libsodium/LICENSE b/subprojects/libsodium/LICENSE @@ -1,7 +1,7 @@ /* * ISC License * - * Copyright (c) 2013-2019 + * Copyright (c) 2013-2025 * Frank Denis <j at pureftpd dot org> * * Permission to use, copy, modify, and/or distribute this software for any diff --git a/subprojects/libsodium/Makefile.am b/subprojects/libsodium/Makefile.am @@ -2,9 +2,9 @@ ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = \ autogen.sh \ - libsodium.sln \ - libsodium.vcxproj \ - libsodium.vcxproj.filters \ + build.zig \ + ChangeLog \ + CITATION.cff \ LICENSE \ README.markdown \ THANKS @@ -13,7 +13,6 @@ SUBDIRS = \ builds \ contrib \ dist-build \ - msvc-scripts \ src \ test diff --git a/subprojects/libsodium/Makefile.in b/subprojects/libsodium/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -70,6 +70,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -88,9 +90,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -160,10 +164,9 @@ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ + { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \ } am__installdirs = "$(DESTDIR)$(pkgconfigdir)" DATA = $(pkgconfig_DATA) @@ -175,6 +178,10 @@ am__recursive_targets = \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ cscope distdir distdir-am dist dist-all distcheck +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -192,9 +199,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags -CSCOPE = cscope DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in \ $(srcdir)/libsodium-uninstalled.pc.in \ @@ -206,16 +210,15 @@ am__DIST_COMMON = $(srcdir)/Makefile.in \ $(top_srcdir)/build-aux/missing \ $(top_srcdir)/src/libsodium/include/sodium/version.h.in \ AUTHORS ChangeLog THANKS build-aux/compile \ - build-aux/config.guess build-aux/config.sub \ - build-aux/install-sh build-aux/ltmain.sh build-aux/missing \ - compile depcomp install-sh ltmain.sh missing + build-aux/config.guess build-aux/config.sub build-aux/depcomp \ + build-aux/install-sh build-aux/ltmain.sh build-aux/missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ if test -d "$(distdir)"; then \ - find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ - && rm -rf "$(distdir)" \ + find "$(distdir)" -type d ! -perm -700 -exec chmod u+rwx {} ';' \ + ; rm -rf "$(distdir)" \ || { sleep 5 && rm -rf "$(distdir)"; }; \ else :; fi am__post_remove_distdir = $(am__remove_distdir) @@ -245,18 +248,21 @@ am__relativize = \ done; \ reldir="$$dir2" DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 -GZIP_ENV = --best +GZIP_ENV = -9 DIST_TARGETS = dist-bzip2 dist-gzip +# Exists only to be overridden by the user if desired. +AM_DISTCHECK_DVI_TARGET = dvi distuninstallcheck_listfiles = find . -type f -print am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' -distcleancheck_listfiles = find . -type f -print +distcleancheck_listfiles = \ + find . \( -type f -a \! \ + \( -name .nfs* -o -name .smb* -o -name .__afs* \) \) -print ACLOCAL = @ACLOCAL@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -268,6 +274,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -280,6 +287,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -296,8 +305,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -340,6 +351,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -365,8 +377,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -400,11 +414,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -413,9 +432,9 @@ valgrind_tools = @valgrind_tools@ ACLOCAL_AMFLAGS = -I m4 EXTRA_DIST = \ autogen.sh \ - libsodium.sln \ - libsodium.vcxproj \ - libsodium.vcxproj.filters \ + build.zig \ + ChangeLog \ + CITATION.cff \ LICENSE \ README.markdown \ THANKS @@ -424,7 +443,6 @@ SUBDIRS = \ builds \ contrib \ dist-build \ - msvc-scripts \ src \ test @@ -537,6 +555,11 @@ $(am__recursive_targets): if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -615,7 +638,7 @@ distdir: $(BUILT_SOURCES) distdir-am: $(DISTFILES) $(am__remove_distdir) - test -d "$(distdir)" || mkdir "$(distdir)" + $(AM_V_at)$(MKDIR_P) "$(distdir)" @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ @@ -684,6 +707,10 @@ dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 $(am__post_remove_distdir) +dist-bzip3: distdir + tardir=$(distdir) && $(am__tar) | bzip3 -c >$(distdir).tar.bz3 + $(am__post_remove_distdir) + dist-lzip: distdir tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz $(am__post_remove_distdir) @@ -692,6 +719,10 @@ dist-xz: distdir tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz $(am__post_remove_distdir) +dist-zstd: distdir + tardir=$(distdir) && $(am__tar) | zstd -c $${ZSTD_CLEVEL-$${ZSTD_OPT--19}} >$(distdir).tar.zst + $(am__post_remove_distdir) + dist-tarZ: distdir @echo WARNING: "Support for distribution archives compressed with" \ "legacy program 'compress' is deprecated." >&2 @@ -721,9 +752,11 @@ dist dist-all: distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\ + eval GZIP= gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ + *.tar.bz3*) \ + bzip3 -dc $(distdir).tar.bz3 | $(am__untar) ;;\ *.tar.lz*) \ lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ *.tar.xz*) \ @@ -731,9 +764,11 @@ distcheck: dist *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ - eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\ + eval GZIP= gzip -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ + *.tar.zst*) \ + zstd -dc $(distdir).tar.zst | $(am__untar) ;;\ esac chmod -R a-w $(distdir) chmod u+w $(distdir) @@ -749,7 +784,7 @@ distcheck: dist $(DISTCHECK_CONFIGURE_FLAGS) \ --srcdir=../.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ - && $(MAKE) $(AM_MAKEFLAGS) dvi \ + && $(MAKE) $(AM_MAKEFLAGS) $(AM_DISTCHECK_DVI_TARGET) \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ @@ -832,13 +867,33 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-recursive + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-recursive + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-recursive + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-recursive + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-recursive + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am @@ -912,21 +967,26 @@ uninstall-am: uninstall-pkgconfigDATA .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--refresh check check-am clean clean-cscope clean-generic \ + am--refresh check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-cscope clean-generic \ clean-libtool cscope cscopelist-am ctags ctags-am dist \ - dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \ - dist-xz dist-zip distcheck distclean distclean-generic \ - distclean-libtool distclean-tags distcleancheck distdir \ - distuninstallcheck dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-pkgconfigDATA install-ps \ - install-ps-am install-strip installcheck installcheck-am \ - installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-generic \ - mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \ - uninstall-am uninstall-pkgconfigDATA + dist-all dist-bzip2 dist-bzip3 dist-gzip dist-lzip dist-shar \ + dist-tarZ dist-xz dist-zip dist-zstd distcheck distclean \ + distclean-generic distclean-libtool distclean-tags \ + distcleancheck distdir distuninstallcheck dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-pkgconfigDATA install-ps install-ps-am install-strip \ + installcheck installcheck-am installdirs installdirs-am \ + maintainer-clean maintainer-clean-generic mostlyclean \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-am uninstall uninstall-am uninstall-pkgconfigDATA .PRECIOUS: Makefile @@ -934,3 +994,10 @@ uninstall-am: uninstall-pkgconfigDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/README.markdown b/subprojects/libsodium/README.markdown @@ -1,47 +1,76 @@ -[](https://travis-ci.org/jedisct1/libsodium?branch=master) +[](https://github.com/jedisct1/libsodium/actions) [](https://ci.appveyor.com/project/jedisct1/libsodium) [](https://scan.coverity.com/projects/2397) [](https://jedisct1.visualstudio.com/Libsodium/_build/latest?definitionId=3&branchName=stable) +[](https://github.com/jedisct1/libsodium/actions) - -============ +#  -Sodium is a new, easy-to-use software library for encryption, -decryption, signatures, password hashing and more. +Sodium is an easy-to-use software library that provides a wide range of cryptographic operations including encryption, decryption, digital signatures, and secure password hashing. -It is a portable, cross-compilable, installable, packageable -fork of [NaCl](http://nacl.cr.yp.to/), with a compatible API, and an -extended API to improve usability even further. +It is a portable, cross-compilable, installable, and packageable fork of [NaCl](http://nacl.cr.yp.to/). While maintaining API compatibility, libsodium extends functionality to improve usability and simplify the development of secure applications. -Its goal is to provide all of the core operations needed to build -higher-level cryptographic tools. +--- -Sodium supports a variety of compilers and operating systems, -including Windows (with MingW or Visual Studio, x86 and x64), iOS, Android, -as well as Javascript and Webassembly. +## Key Features + +- **Encryption & Decryption:** Securely encrypt and decrypt data with modern algorithms. +- **Digital Signatures:** Create and verify signatures to ensure data authenticity. +- **Cross-Platform Compatibility:** Supported on Windows (MinGW and Visual Studio, both x86 and x64), iOS, Android, JavaScript, and WebAssembly. +- **User-Friendly API:** Designed to provide all core cryptographic operations while remaining easy to integrate into your projects. + +--- ## Documentation -The documentation is available on Gitbook and built from the [libsodium-doc](https://github.com/jedisct1/libsodium-doc) repository: +Detailed documentation is available online. It is generated from the [libsodium-doc](https://github.com/jedisct1/libsodium-doc) repository and requires JavaScript for full functionality: -* [libsodium documentation](https://download.libsodium.org/doc/) - -online, requires Javascript. -* [offline documentation](https://www.gitbook.com/book/jedisct1/libsodium/details) -in PDF format. +- [libsodium Documentation](https://doc.libsodium.org) + +--- ## Integrity Checking -The integrity checking instructions (including the signing key for libsodium) -are available in the [installation](https://download.libsodium.org/doc/installation#integrity-checking) -section of the documentation. +For security and authenticity, please review the integrity checking instructions. These include the signing keys and methods to verify your installation: + +- [Integrity Checking Instructions](https://download.libsodium.org/doc/installation#integrity-checking) + +--- + +## Contributors + +### Code Contributors + +This project thrives thanks to the valuable contributions from our community. View all the [contributors](https://github.com/jedisct1/libsodium/graphs/contributors): + +<a href="https://github.com/jedisct1/libsodium/graphs/contributors"> + <img src="https://opencollective.com/libsodium/contributors.svg?width=890&button=false" alt="Contributors"> +</a> + +### Financial Contributors + +Your financial support helps us sustain and further develop libsodium. + +- [Become a Financial Contributor](https://opencollective.com/libsodium/contribute) + +#### Individuals + +<a href="https://opencollective.com/libsodium"> + <img src="https://opencollective.com/libsodium/individuals.svg?width=890" alt="Individual Contributors"> +</a> + +#### Organizations + +Support libsodium with your organization and gain visibility through your logo and website link. -## Community +- [Support with Your Organization](https://opencollective.com/libsodium/contribute) -A mailing-list is available to discuss libsodium. +<a href="https://opencollective.com/libsodium/organization/0/website"> + <img src="https://opencollective.com/libsodium/organization/0/avatar.svg" alt="Organization Contributor"> +</a> -In order to join, just send a random mail to `sodium-subscribe` {at} -`pureftpd` {dot} `org`. +--- ## License -[ISC license](https://en.wikipedia.org/wiki/ISC_license). +This project is distributed under the [ISC license](https://en.wikipedia.org/wiki/ISC_license). diff --git a/subprojects/libsodium/aclocal.m4 b/subprojects/libsodium/aclocal.m4 @@ -1,6 +1,6 @@ -# generated automatically by aclocal 1.16.1 -*- Autoconf -*- +# generated automatically by aclocal 1.18.1 -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2025 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -14,13 +14,13 @@ m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, -[m4_warning([this file was generated for autoconf 2.69. +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.72],, +[m4_warning([this file was generated for autoconf 2.72. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically 'autoreconf'.])]) -# Copyright (C) 2002-2018 Free Software Foundation, Inc. +# Copyright (C) 2002-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -32,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.]) # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], -[am__api_version='1.16' +[am__api_version='1.18' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.16.1], [], +m4_if([$1], [1.18.1], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -51,14 +51,14 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.16.1])dnl +[AM_AUTOMAKE_VERSION([1.18.1])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # Figure out how to run the assembler. -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -78,7 +78,7 @@ _AM_IF_OPTION([no-dependencies],, [_AM_DEPENDENCIES([CCAS])])dnl # AM_AUX_DIR_EXPAND -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -130,7 +130,7 @@ am_aux_dir=`cd "$ac_aux_dir" && pwd` # AM_CONDITIONAL -*- Autoconf -*- -# Copyright (C) 1997-2018 Free Software Foundation, Inc. +# Copyright (C) 1997-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -161,7 +161,7 @@ AC_CONFIG_COMMANDS_PRE( Usually this means the macro was only invoked conditionally.]]) fi])]) -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -293,7 +293,7 @@ AC_CACHE_CHECK([dependency style of $depcc], # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: + # When given -MP, icc 7.0 and 7.1 complain thus: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported @@ -352,7 +352,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl # Generate code to set up dependency tracking. -*- Autoconf -*- -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -391,7 +391,9 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], done if test $am_rc -ne 0; then AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. Try re-running configure with the + for automatic dependency tracking. If GNU make was not used, consider + re-running the configure script with MAKE="gmake" (or whatever is + necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking).]) fi @@ -416,9 +418,26 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) +# AM_EXTRA_RECURSIVE_TARGETS -*- Autoconf -*- + +# Copyright (C) 2012-2025 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# AM_EXTRA_RECURSIVE_TARGETS +# -------------------------- +# Define the list of user recursive targets. This macro exists only to +# be traced by Automake, which will ensure that a proper definition of +# user-defined recursive targets (and associated rules) is propagated +# into all the generated Makefiles. +# TODO: We should really reject non-literal arguments here... +AC_DEFUN([AM_EXTRA_RECURSIVE_TARGETS], []) + # Do all the work for Automake. -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -446,6 +465,10 @@ m4_defn([AC_PROG_CC]) # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.65])dnl +m4_ifdef([_$0_ALREADY_INIT], + [m4_fatal([$0 expanded multiple times +]m4_defn([_$0_ALREADY_INIT]))], + [m4_define([_$0_ALREADY_INIT], m4_expansion_stack)])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl @@ -482,7 +505,7 @@ m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. m4_if( - m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), + m4_ifset([AC_PACKAGE_NAME], [ok]):m4_ifset([AC_PACKAGE_VERSION], [ok]), [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl @@ -514,8 +537,9 @@ AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], - [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], - [_AM_PROG_TAR([v7])])]) + [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], + [_AM_IF_OPTION([tar-v7], [_AM_PROG_TAR([v7])], + [_AM_PROG_TAR([ustar])])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES([CC])], @@ -534,7 +558,21 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], [m4_define([AC_PROG_OBJCXX], m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) -AC_REQUIRE([AM_SILENT_RULES])dnl +# Variables for tags utilities; see am/tags.am +if test -z "$CTAGS"; then + CTAGS=ctags +fi +AC_SUBST([CTAGS]) +if test -z "$ETAGS"; then + ETAGS=etags +fi +AC_SUBST([ETAGS]) +if test -z "$CSCOPE"; then + CSCOPE=cscope +fi +AC_SUBST([CSCOPE]) + +AC_REQUIRE([_AM_SILENT_RULES])dnl dnl The testsuite driver may need to know about EXEEXT, so add the dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. @@ -542,47 +580,9 @@ AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! - -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> - -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. +AC_REQUIRE([_AM_PROG_RM_F]) +AC_REQUIRE([_AM_PROG_XARGS_N]) -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. - -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: <https://www.gnu.org/software/coreutils/>. - -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. - -END - AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) - fi -fi dnl The trailing newline in this macro's definition is deliberate, for dnl backward compatibility and to allow trailing 'dnl'-style comments dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. @@ -615,7 +615,7 @@ for _am_header in $config_headers :; do done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -636,7 +636,7 @@ if test x"${install_sh+set}" != xset; then fi AC_SUBST([install_sh])]) -# Copyright (C) 2003-2018 Free Software Foundation, Inc. +# Copyright (C) 2003-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -658,7 +658,7 @@ AC_SUBST([am__leading_dot])]) # Add --enable-maintainer-mode option to configure. -*- Autoconf -*- # From Jim Meyering -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -693,7 +693,7 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles]) # Check to see how 'make' treats includes. -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -736,7 +736,7 @@ AC_SUBST([am__quote])]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- -# Copyright (C) 1997-2018 Free Software Foundation, Inc. +# Copyright (C) 1997-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -757,12 +757,7 @@ AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac + MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then @@ -775,7 +770,7 @@ fi # Helper functions for option handling. -*- Autoconf -*- -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -804,7 +799,7 @@ AC_DEFUN([_AM_SET_OPTIONS], AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -836,7 +831,10 @@ AC_CACHE_CHECK( break fi done - rm -f core conftest* + # aligned with autoconf, so not including core; see bug#72225. + rm -f -r a.out a.exe b.out conftest.$ac_ext conftest.$ac_objext \ + conftest.dSYM conftest1.$ac_ext conftest1.$ac_objext conftest1.dSYM \ + conftest2.$ac_ext conftest2.$ac_objext conftest2.dSYM unset am_i]) if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. @@ -851,7 +849,23 @@ AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2022-2025 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_RM_F +# --------------- +# Check whether 'rm -f' without any arguments works. +# https://bugs.gnu.org/10828 +AC_DEFUN([_AM_PROG_RM_F], +[am__rm_f_notfound= +AS_IF([(rm -f && rm -fr && rm -rf) 2>/dev/null], [], [am__rm_f_notfound='""']) +AC_SUBST(am__rm_f_notfound) +]) + +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -870,26 +884,181 @@ AC_DEFUN([AM_RUN_LOG], # Check to make sure that the build environment is sane. -*- Autoconf -*- -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# Copyright (C) 1996-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. +# _AM_SLEEP_FRACTIONAL_SECONDS +# ---------------------------- +AC_DEFUN([_AM_SLEEP_FRACTIONAL_SECONDS], [dnl +AC_CACHE_CHECK([whether sleep supports fractional seconds], + am_cv_sleep_fractional_seconds, [dnl +AS_IF([sleep 0.001 2>/dev/null], [am_cv_sleep_fractional_seconds=yes], + [am_cv_sleep_fractional_seconds=no]) +])]) + +# _AM_FILESYSTEM_TIMESTAMP_RESOLUTION +# ----------------------------------- +# Determine the filesystem's resolution for file modification +# timestamps. The coarsest we know of is FAT, with a resolution +# of only two seconds, even with the most recent "exFAT" extensions. +# The finest (e.g. ext4 with large inodes, XFS, ZFS) is one +# nanosecond, matching clock_gettime. However, it is probably not +# possible to delay execution of a shell script for less than one +# millisecond, due to process creation overhead and scheduling +# granularity, so we don't check for anything finer than that. (See below.) +AC_DEFUN([_AM_FILESYSTEM_TIMESTAMP_RESOLUTION], [dnl +AC_REQUIRE([_AM_SLEEP_FRACTIONAL_SECONDS]) +AC_CACHE_CHECK([filesystem timestamp resolution], + am_cv_filesystem_timestamp_resolution, [dnl +# Default to the worst case. +am_cv_filesystem_timestamp_resolution=2 + +# Only try to go finer than 1 sec if sleep can do it. +# Don't try 1 sec, because if 0.01 sec and 0.1 sec don't work, +# - 1 sec is not much of a win compared to 2 sec, and +# - it takes 2 seconds to perform the test whether 1 sec works. +# +# Instead, just use the default 2s on platforms that have 1s resolution, +# accept the extra 1s delay when using $sleep in the Automake tests, in +# exchange for not incurring the 2s delay for running the test for all +# packages. +# +am_try_resolutions= +if test "$am_cv_sleep_fractional_seconds" = yes; then + # Even a millisecond often causes a bunch of false positives, + # so just try a hundredth of a second. The time saved between .001 and + # .01 is not terribly consequential. + am_try_resolutions="0.01 0.1 $am_try_resolutions" +fi + +# In order to catch current-generation FAT out, we must *modify* files +# that already exist; the *creation* timestamp is finer. Use names +# that make ls -t sort them differently when they have equal +# timestamps than when they have distinct timestamps, keeping +# in mind that ls -t prints the *newest* file first. +rm -f conftest.ts? +: > conftest.ts1 +: > conftest.ts2 +: > conftest.ts3 + +# Make sure ls -t actually works. Do 'set' in a subshell so we don't +# clobber the current shell's arguments. (Outer-level square brackets +# are removed by m4; they're present so that m4 does not expand +# <dollar><star>; be careful, easy to get confused.) +if ( + set X `[ls -t conftest.ts[12]]` && + { + test "$[]*" != "X conftest.ts1 conftest.ts2" || + test "$[]*" != "X conftest.ts2 conftest.ts1"; + } +); then :; else + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + _AS_ECHO_UNQUOTED( + ["Bad output from ls -t: \"`[ls -t conftest.ts[12]]`\""], + [AS_MESSAGE_LOG_FD]) + AC_MSG_FAILURE([ls -t produces unexpected output. +Make sure there is not a broken ls alias in your environment.]) +fi + +for am_try_res in $am_try_resolutions; do + # Any one fine-grained sleep might happen to cross the boundary + # between two values of a coarser actual resolution, but if we do + # two fine-grained sleeps in a row, at least one of them will fall + # entirely within a coarse interval. + echo alpha > conftest.ts1 + sleep $am_try_res + echo beta > conftest.ts2 + sleep $am_try_res + echo gamma > conftest.ts3 + + # We assume that 'ls -t' will make use of high-resolution + # timestamps if the operating system supports them at all. + if (set X `ls -t conftest.ts?` && + test "$[]2" = conftest.ts3 && + test "$[]3" = conftest.ts2 && + test "$[]4" = conftest.ts1); then + # + # Ok, ls -t worked. If we're at a resolution of 1 second, we're done, + # because we don't need to test make. + make_ok=true + if test $am_try_res != 1; then + # But if we've succeeded so far with a subsecond resolution, we + # have one more thing to check: make. It can happen that + # everything else supports the subsecond mtimes, but make doesn't; + # notably on macOS, which ships make 3.81 from 2006 (the last one + # released under GPLv2). https://bugs.gnu.org/68808 + # + # We test $MAKE if it is defined in the environment, else "make". + # It might get overridden later, but our hope is that in practice + # it does not matter: it is the system "make" which is (by far) + # the most likely to be broken, whereas if the user overrides it, + # probably they did so with a better, or at least not worse, make. + # https://lists.gnu.org/archive/html/automake/2024-06/msg00051.html + # + # Create a Makefile (real tab character here): + rm -f conftest.mk + echo 'conftest.ts1: conftest.ts2' >conftest.mk + echo ' touch conftest.ts2' >>conftest.mk + # + # Now, running + # touch conftest.ts1; touch conftest.ts2; make + # should touch ts1 because ts2 is newer. This could happen by luck, + # but most often, it will fail if make's support is insufficient. So + # test for several consecutive successes. + # + # (We reuse conftest.ts[12] because we still want to modify existing + # files, not create new ones, per above.) + n=0 + make=${MAKE-make} + until test $n -eq 3; do + echo one > conftest.ts1 + sleep $am_try_res + echo two > conftest.ts2 # ts2 should now be newer than ts1 + if $make -f conftest.mk | grep 'up to date' >/dev/null; then + make_ok=false + break # out of $n loop + fi + n=`expr $n + 1` + done + fi + # + if $make_ok; then + # Everything we know to check worked out, so call this resolution good. + am_cv_filesystem_timestamp_resolution=$am_try_res + break # out of $am_try_res loop + fi + # Otherwise, we'll go on to check the next resolution. + fi +done +rm -f conftest.ts? +# (end _am_filesystem_timestamp_resolution) +])]) + # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], -[AC_MSG_CHECKING([whether build environment is sane]) +[AC_REQUIRE([_AM_FILESYSTEM_TIMESTAMP_RESOLUTION]) +# This check should not be cached, as it may vary across builds of +# different projects. +AC_MSG_CHECKING([whether build environment is sane]) # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[[\\\"\#\$\&\'\`$am_lf]]*) + AC_MSG_RESULT([no]) AC_MSG_ERROR([unsafe absolute working directory name]);; esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) + AC_MSG_RESULT([no]) AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac @@ -898,49 +1067,40 @@ esac # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$[*]" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$[*]" != "X $srcdir/configure conftest.file" \ - && test "$[*]" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken - alias in your environment]) - fi - if test "$[2]" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$[2]" = conftest.file - ) -then - # Ok. - : -else - AC_MSG_ERROR([newly created file is older than distributed files! +am_build_env_is_sane=no +am_has_slept=no +rm -f conftest.file +for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + if ( + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$[]*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + test "$[]2" = conftest.file + ); then + am_build_env_is_sane=yes + break + fi + # Just in case. + sleep "$am_cv_filesystem_timestamp_resolution" + am_has_slept=yes +done + +AC_MSG_RESULT([$am_build_env_is_sane]) +if test "$am_build_env_is_sane" = no; then + AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi -AC_MSG_RESULT([yes]) + # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & +AS_IF([test -e conftest.file || grep 'slept: no' conftest.file >/dev/null 2>&1],, [dnl + ( sleep "$am_cv_filesystem_timestamp_resolution" ) & am_sleep_pid=$! -fi +]) AC_CONFIG_COMMANDS_PRE( [AC_MSG_CHECKING([that generated files are newer than configure]) if test -n "$am_sleep_pid"; then @@ -951,18 +1111,18 @@ AC_CONFIG_COMMANDS_PRE( rm -f conftest.file ]) -# Copyright (C) 2009-2018 Free Software Foundation, Inc. +# Copyright (C) 2009-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. -# AM_SILENT_RULES([DEFAULT]) -# -------------------------- -# Enable less verbose build rules; with the default set to DEFAULT -# ("yes" being less verbose, "no" or empty being verbose). -AC_DEFUN([AM_SILENT_RULES], -[AC_ARG_ENABLE([silent-rules], [dnl +# _AM_SILENT_RULES +# ---------------- +# Enable less verbose build rules support. +AC_DEFUN([_AM_SILENT_RULES], +[AM_DEFAULT_VERBOSITY=1 +AC_ARG_ENABLE([silent-rules], [dnl AS_HELP_STRING( [--enable-silent-rules], [less verbose build output (undo: "make V=1")]) @@ -970,11 +1130,6 @@ AS_HELP_STRING( [--disable-silent-rules], [verbose build output (undo: "make V=0")])dnl ]) -case $enable_silent_rules in @%:@ ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; -esac dnl dnl A few 'make' implementations (e.g., NonStop OS and NextStep) dnl do not support nested variable expansions. @@ -993,14 +1148,6 @@ am__doit: else am_cv_make_support_nested_variables=no fi]) -if test $am_cv_make_support_nested_variables = yes; then - dnl Using '$V' instead of '$(V)' breaks IRIX make. - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi AC_SUBST([AM_V])dnl AM_SUBST_NOTMAKE([AM_V])dnl AC_SUBST([AM_DEFAULT_V])dnl @@ -1009,9 +1156,37 @@ AC_SUBST([AM_DEFAULT_VERBOSITY])dnl AM_BACKSLASH='\' AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl +dnl Delay evaluation of AM_DEFAULT_VERBOSITY to the end to allow multiple calls +dnl to AM_SILENT_RULES to change the default value. +AC_CONFIG_COMMANDS_PRE([dnl +case $enable_silent_rules in @%:@ ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; +esac +if test $am_cv_make_support_nested_variables = yes; then + dnl Using '$V' instead of '$(V)' breaks IRIX make. + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi +])dnl +]) + +# AM_SILENT_RULES([DEFAULT]) +# -------------------------- +# Set the default verbosity level to DEFAULT ("yes" being less verbose, "no" or +# empty being verbose). +AC_DEFUN([AM_SILENT_RULES], +[AC_REQUIRE([_AM_SILENT_RULES]) +AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1])m4_newline +dnl We intentionally force a newline after the assignment, since a) nothing +dnl good can come of more text following, and b) that was the behavior +dnl before 1.17. See https://bugs.gnu.org/72267. ]) -# Copyright (C) 2001-2018 Free Software Foundation, Inc. +# Copyright (C) 2001-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1039,7 +1214,7 @@ fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) -# Copyright (C) 2006-2018 Free Software Foundation, Inc. +# Copyright (C) 2006-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1058,7 +1233,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- -# Copyright (C) 2004-2018 Free Software Foundation, Inc. +# Copyright (C) 2004-2025 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -1104,15 +1279,19 @@ m4_if([$1], [v7], am_uid=`id -u || echo unknown` am_gid=`id -g || echo unknown` AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) - if test $am_uid -le $am_max_uid; then - AC_MSG_RESULT([yes]) + if test x$am_uid = xunknown; then + AC_MSG_WARN([ancient id detected; assuming current UID is ok, but dist-ustar might not work]) + elif test $am_uid -le $am_max_uid; then + AC_MSG_RESULT([yes]) else - AC_MSG_RESULT([no]) - _am_tools=none + AC_MSG_RESULT([no]) + _am_tools=none fi AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) - if test $am_gid -le $am_max_gid; then - AC_MSG_RESULT([yes]) + if test x$gm_gid = xunknown; then + AC_MSG_WARN([ancient id detected; assuming current GID is ok, but dist-ustar might not work]) + elif test $am_gid -le $am_max_gid; then + AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none @@ -1189,6 +1368,27 @@ AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR +# Copyright (C) 2022-2025 Free Software Foundation, Inc. +# +# This file is free software; the Free Software Foundation +# gives unlimited permission to copy and/or distribute it, +# with or without modifications, as long as this notice is preserved. + +# _AM_PROG_XARGS_N +# ---------------- +# Check whether 'xargs -n' works. It should work everywhere, so the fallback +# is not optimized at all as we never expect to use it. +AC_DEFUN([_AM_PROG_XARGS_N], +[AC_CACHE_CHECK([xargs -n works], am_cv_xargs_n_works, [dnl +AS_IF([test "`echo 1 2 3 | xargs -n2 echo`" = "1 2 +3"], [am_cv_xargs_n_works=yes], [am_cv_xargs_n_works=no])]) +AS_IF([test "$am_cv_xargs_n_works" = yes], [am__xargs_n='xargs -n'], [dnl + am__xargs_n='am__xargs_n () { shift; sed "s/ /\\n/g" | while read am__xargs_n_arg; do "$@" "$am__xargs_n_arg"; done; }' +])dnl +AC_SUBST(am__xargs_n) +]) + +m4_include([m4/ax_add_fortify_source.m4]) m4_include([m4/ax_check_catchable_abrt.m4]) m4_include([m4/ax_check_catchable_segv.m4]) m4_include([m4/ax_check_compile_flag.m4]) diff --git a/subprojects/libsodium/appveyor.yml b/subprojects/libsodium/appveyor.yml @@ -1,4 +1,4 @@ -version: 1.0.18.{build} +version: 1.0.20.{build} os: Visual Studio 2017 @@ -20,5 +20,5 @@ init: msbuild /version build: parallel: true - project: libsodium.vcxproj - verbosity: minimal + project: ci/appveyor/libsodium.vcxproj + verbosity: normal diff --git a/subprojects/libsodium/autogen.sh b/subprojects/libsodium/autogen.sh @@ -1,5 +1,55 @@ #! /bin/sh +args=$(getopt bfos "$@") +if [ $? -ne 0 ]; then + echo "Usage: autogen.sh [-b] [-f] [-o] [-s] [--]" + echo + echo "> -b: do not update the system detection scripts" + echo "> -f: force the recreation of all autoconf scripts" + echo "> -o: overwrite/downgrade system detection scripts" + echo "> -s: setup an environment for developers" + exit 2 +fi + +force=false +update_config=true +overwrite_config=false +dev_setup=false + +eval set -- "$args" + +while [ $# -ne 0 ]; do + case $1 in + -b) + update_config=false + ;; + -f) + force=true + ;; + -o) + overwrite_config=true + ;; + -s) + dev_setup=true + ;; + --) + shift + break + ;; + esac + shift +done + +if [ -s configure ]; then + if [ "$force" != true ]; then + echo "autoconf scripts already exist." >&2 + exit 0 + fi +elif [ "$dev_setup" != true ]; then + echo "A development environment was not created." + exit 0 +fi + if glibtoolize --version >/dev/null 2>&1; then LIBTOOLIZE='glibtoolize' else @@ -26,25 +76,39 @@ command -v automake >/dev/null 2>&1 || { exit 1 } -if autoreconf --version >/dev/null 2>&1; then - autoreconf -ivf -else - $LIBTOOLIZE && - aclocal && - automake --add-missing --force-missing --include-deps && - autoconf +if [ "$overwrite_config" = false ]; then + if [ -f build-aux/config.guess ]; then + mv build-aux/config.guess build-aux/config.guess.stable + fi + if [ -f build-aux/config.sub ]; then + mv build-aux/config.sub build-aux/config.sub.stable + fi +fi +$LIBTOOLIZE --copy --install && + aclocal && + automake --add-missing --copy --force-missing --include-deps && + autoconf && echo Done. +if [ "$overwrite_config" = false ]; then + if [ -f build-aux/config.guess.stable ]; then + mv build-aux/config.guess.stable build-aux/config.guess + fi + if [ -f build-aux/config.sub.stable ]; then + mv build-aux/config.sub.stable build-aux/config.sub + fi fi -[ -z "$DO_NOT_UPDATE_CONFIG_SCRIPTS" ] && +[ "$update_config" = true ] && [ -z "$DO_NOT_UPDATE_CONFIG_SCRIPTS" ] && command -v curl >/dev/null 2>&1 && { echo "Downloading config.guess and config.sub..." - curl -sL -o config.guess \ + curl -sSL --fail -o config.guess \ 'https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD' && - mv -f config.guess build-aux/config.guess + chmod +x config.guess && + chmod +x build-aux/config.guess - curl -sL -o config.sub \ + curl -sSL --fail -o config.sub \ 'https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD' && + chmod +x build-aux/config.sub && mv -f config.sub build-aux/config.sub echo "Done." diff --git a/subprojects/libsodium/azure-pipelines.yml b/subprojects/libsodium/azure-pipelines.yml @@ -5,40 +5,13 @@ trigger: pr: none jobs: - - job: "wasi" - pool: - vmImage: "ubuntu-16.04" - steps: - - script: | - sudo apt-get install build-essential curl cmake - displayName: Install system packages - - script: | - curl https://sh.rustup.rs -sSf | sh -s -- -y - source ${HOME}/.cargo/env - git clone --recursive https://github.com/wasmerio/wasmer.git - (cd wasmer && cargo install --path .) - displayName: Install wasmer - - script: | - curl -sL -o wasi-sdk.deb https://github.com/CraneStation/wasi-sdk/releases/download/wasi-sdk-5/wasi-sdk_5.0_amd64.deb - sudo dpkg -i wasi-sdk.deb && rm -f wasi-sdk.deb - sudo ln -s /opt/wasi-sdk/share/*sysroot* /opt/wasi-sysroot - displayName: Install the WASI SDK - - script: | - env PATH=/opt/wasi-sdk/bin:${HOME}/.cargo/bin:$PATH dist-build/wasm32-wasi.sh - displayName: Compile libsodium - - task: PublishBuildArtifacts@1 - condition: not(canceled()) - inputs: - pathToPublish: libsodium-wasm32-wasi - artifactName: libsodium-wasm32-wasi - - job: "windows" pool: - vmImage: "windows-2019" + vmImage: "windows-2022" steps: - powershell: | cd builds\msvc\build - & .\buildbase.bat ..\vs2019\libsodium.sln 16 + & .\buildbase.bat ..\vs2022\libsodium.sln 17 displayName: Compile it all - powershell: | mkdir bin\include\sodium @@ -51,31 +24,19 @@ jobs: pathToPublish: bin artifactName: libsodium - - job: "windows_old" + - job: "windows_2019" pool: - vmImage: "vs2017-win2016" + vmImage: "windows-2019" steps: - powershell: | cd builds\msvc\build - & .\buildbase.bat ..\vs2017\libsodium.sln 15 + & .\buildbase.bat ..\vs2019\libsodium.sln 16 displayName: Compile it all - - task: PublishBuildArtifacts@1 - condition: not(canceled()) - inputs: - pathToPublish: bin - artifactName: libsodium - - - job: "windows_reallyold" - pool: - vmImage: "vs2015-win2012r2" - steps: - powershell: | - cd builds\msvc\build - & .\buildbase.bat ..\vs2015\libsodium.sln 14 - & .\buildbase.bat ..\vs2013\libsodium.sln 12 - & .\buildbase.bat ..\vs2012\libsodium.sln 11 - & .\buildbase.bat ..\vs2010\libsodium.sln 10 - displayName: Compile it all + mkdir bin\include\sodium + Copy-Item "src\libsodium\include\sodium\*.h" -Destination "bin\include\sodium" -Recurse + Copy-Item "src\libsodium\include\*.h" -Destination "bin\include\" + displayName: Copy header files - task: PublishBuildArtifacts@1 condition: not(canceled()) inputs: @@ -86,14 +47,17 @@ jobs: pool: vmImage: "windows-2019" steps: - - script: | - git clone https://github.com/msys2/msys2-ci-base.git %CD:~0,2%\msys64 - %CD:~0,2%\msys64\usr\bin\rm -rf %CD:~0,2%\msys64\.git + - powershell: | + (New-Object Net.WebClient).DownloadFile("https://github.com/msys2/msys2-installer/releases/download/2025-02-21/msys2-base-x86_64-20250221.sfx.exe", "sfx.exe") + .\sfx.exe -y -o\ + del sfx.exe displayName: Install MSYS2 - script: | set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem - %CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syyuu - %CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu + %CD:~0,2%\msys64\usr\bin\bash -lc + %CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Sydd filesystem" + %CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' + %CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' displayName: Update MSYS2 - script: | set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem @@ -105,6 +69,7 @@ jobs: set PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\bin set MSYS2_ROOT=%CD:~0,2%\msys64 set MSYSTEM=MINGW64 + set CHERE_INVOKING=yes %MSYS2_ROOT%\cmd\msystem MINGW64 %CD:~0,2%\msys64\usr\bin\bash -lc dist-build/msys2-win64.sh env: @@ -121,14 +86,17 @@ jobs: pool: vmImage: "windows-2019" steps: - - script: | - git clone https://github.com/msys2/msys2-ci-base.git %CD:~0,2%\msys64 - %CD:~0,2%\msys64\usr\bin\rm -rf %CD:~0,2%\msys64\.git + - powershell: | + (New-Object Net.WebClient).DownloadFile("https://github.com/msys2/msys2-installer/releases/download/2025-02-21/msys2-base-x86_64-20250221.sfx.exe", "sfx.exe") + .\sfx.exe -y -o\ + del sfx.exe displayName: Install MSYS2 - script: | set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem - %CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syyuu - %CD:~0,2%\msys64\usr\bin\pacman --noconfirm -Syuu + %CD:~0,2%\msys64\usr\bin\bash -lc + %CD:~0,2%\msys64\usr\bin\bash -lc "pacman --noconfirm -Sydd filesystem" + %CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' + %CD:~0,2%\msys64\usr\bin\bash -lc 'pacman --noconfirm -Syuu' displayName: Update MSYS2 - script: | set PATH=%CD:~0,2%\msys64\usr\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem @@ -140,6 +108,7 @@ jobs: set PATH=C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;%CD:~0,2%\msys64\usr\bin;%CD:~0,2%\msys64\bin set MSYS2_ROOT=%CD:~0,2%\msys64 set MSYSTEM=MINGW32 + set CHERE_INVOKING=yes %MSYS2_ROOT%\cmd\msystem MINGW32 %CD:~0,2%\msys64\usr\bin\bash -lc dist-build/msys2-win32.sh env: diff --git a/subprojects/libsodium/build-aux/compile b/subprojects/libsodium/build-aux/compile @@ -1,9 +1,9 @@ #! /bin/sh # Wrapper for compilers which do not understand '-c -o'. -scriptversion=2018-03-07.03; # UTC +scriptversion=2025-06-18.21; # UTC -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2025 Free Software Foundation, Inc. # Written by Tom Tromey <tromey@cygnus.com>. # # This program is free software; you can redistribute it and/or modify @@ -37,11 +37,11 @@ IFS=" "" $nl" file_conv= -# func_file_conv build_file lazy +# func_file_conv build_file unneeded_conversions # Convert a $build file to $host form and store it in $file # Currently only supports Windows hosts. If the determined conversion -# type is listed in (the comma separated) LAZY, no conversion will -# take place. +# type is listed in (the comma separated) UNNEEDED_CONVERSIONS, no +# conversion will take place. func_file_conv () { file=$1 @@ -51,9 +51,20 @@ func_file_conv () # lazily determine how to convert abs files case `uname -s` in MINGW*) - file_conv=mingw + if test -n "$MSYSTEM" && (cygpath --version) >/dev/null 2>&1; then + # MSYS2 environment. + file_conv=cygwin + else + # Original MinGW environment. + file_conv=mingw + fi + ;; + MSYS*) + # Old MSYS environment, or MSYS2 with 32-bit MSYS2 shell. + file_conv=cygwin ;; CYGWIN*) + # Cygwin environment. file_conv=cygwin ;; *) @@ -63,12 +74,14 @@ func_file_conv () fi case $file_conv/,$2, in *,$file_conv,*) + # This is the optimization mentioned above: + # If UNNEEDED_CONVERSIONS contains $file_conv, don't convert. ;; mingw/*) file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` ;; cygwin/*) - file=`cygpath -m "$file" || echo "$file"` + file=`cygpath -w "$file" || echo "$file"` ;; wine/*) file=`winepath -w "$file" || echo "$file"` @@ -143,7 +156,7 @@ func_cl_wrapper () # configure might choose to run compile as 'compile cc -o foo foo.c'. eat=1 case $2 in - *.o | *.[oO][bB][jJ]) + *.o | *.lo | *.[oO][bB][jJ]) func_file_conv "$2" set x "$@" -Fo"$file" shift @@ -248,14 +261,17 @@ If you are trying to build a whole package this is not the right script to run: please start by reading the file 'INSTALL'. Report bugs to <bug-automake@gnu.org>. +GNU Automake home page: <https://www.gnu.org/software/automake/>. +General help using GNU software: <https://www.gnu.org/gethelp/>. EOF exit $? ;; -v | --v*) - echo "compile $scriptversion" + echo "compile (GNU Automake) $scriptversion" exit $? ;; cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \ + clang-cl | *[/\\]clang-cl | clang-cl.exe | *[/\\]clang-cl.exe | \ icl | *[/\\]icl | icl.exe | *[/\\]icl.exe ) func_cl_wrapper "$@" # Doesn't return... ;; @@ -340,9 +356,9 @@ exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-format: "%Y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: diff --git a/subprojects/libsodium/build-aux/config.guess b/subprojects/libsodium/build-aux/config.guess @@ -1,12 +1,14 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2019 Free Software Foundation, Inc. +# Copyright 1992-2024 Free Software Foundation, Inc. -timestamp='2019-05-28' +# shellcheck disable=SC2006,SC2268 # see below for rationale + +timestamp='2024-07-27' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or +# the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but @@ -27,17 +29,25 @@ timestamp='2019-05-28' # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess +# https://git.savannah.gnu.org/cgit/config.git/plain/config.guess # # Please send patches to <config-patches@gnu.org>. +# The "shellcheck disable" line above the timestamp inhibits complaints +# about features and limitations of the classic Bourne shell that were +# superseded or lifted in POSIX. However, this script identifies a wide +# variety of pre-POSIX systems that do not have POSIX shells at all, and +# even some reasonably current systems (Solaris 10 as case-in-point) still +# have a pre-POSIX /bin/sh. + + me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] -Output the configuration name of the system \`$me' is run on. +Output the configuration name of the system '$me' is run on. Options: -h, --help print this help, then exit @@ -50,13 +60,13 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2019 Free Software Foundation, Inc. +Copyright 1992-2024 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -84,13 +94,16 @@ if test $# != 0; then exit 1 fi +# Just in case it came from the environment. +GUESS= + # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. +# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still +# use 'HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. @@ -99,8 +112,10 @@ tmp= trap 'test -z "$tmp" || rm -fr "$tmp"' 0 1 2 13 15 set_cc_for_build() { + # prevent multiple calls if $tmp is already set + test "$tmp" && return 0 : "${TMPDIR=/tmp}" - # shellcheck disable=SC2039 + # shellcheck disable=SC2039,SC3028 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir "$tmp" 2>/dev/null) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir "$tmp" 2>/dev/null) && echo "Warning: creating insecure temp directory" >&2 ; } || @@ -108,9 +123,9 @@ set_cc_for_build() { dummy=$tmp/dummy case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in ,,) echo "int x;" > "$dummy.c" - for driver in cc gcc c89 c99 ; do + for driver in cc gcc c17 c99 c89 ; do if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then - CC_FOR_BUILD="$driver" + CC_FOR_BUILD=$driver break fi done @@ -131,40 +146,57 @@ fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown -UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown +UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown -case "$UNAME_SYSTEM" in +case $UNAME_SYSTEM in Linux|GNU|GNU/*) - # If the system lacks a compiler, then just pick glibc. - # We could probably try harder. - LIBC=gnu + LIBC=unknown set_cc_for_build cat <<-EOF > "$dummy.c" + #if defined(__ANDROID__) + LIBC=android + #else #include <features.h> #if defined(__UCLIBC__) LIBC=uclibc #elif defined(__dietlibc__) LIBC=dietlibc - #else + #elif defined(__GLIBC__) LIBC=gnu + #elif defined(__LLVM_LIBC__) + LIBC=llvm + #else + #include <stdarg.h> + /* First heuristic to detect musl libc. */ + #ifdef __DEFINED_va_list + LIBC=musl + #endif + #endif #endif EOF - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`" + cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` + eval "$cc_set_libc" - # If ldd exists, use it to detect musl libc. - if command -v ldd >/dev/null && \ - ldd --version 2>&1 | grep -q ^musl - then - LIBC=musl + # Second heuristic to detect musl libc. + if [ "$LIBC" = unknown ] && + command -v ldd >/dev/null && + ldd --version 2>&1 | grep -q ^musl; then + LIBC=musl + fi + + # If the system lacks a compiler, then just pick glibc. + # We could probably try harder. + if [ "$LIBC" = unknown ]; then + LIBC=gnu fi ;; esac # Note: order is significant - the case branches are not exclusive. -case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in +case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, @@ -176,12 +208,12 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". - sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ - "/sbin/$sysctl" 2>/dev/null || \ - "/usr/sbin/$sysctl" 2>/dev/null || \ + /sbin/sysctl -n hw.machine_arch 2>/dev/null || \ + /usr/sbin/sysctl -n hw.machine_arch 2>/dev/null || \ echo unknown)` - case "$UNAME_MACHINE_ARCH" in + case $UNAME_MACHINE_ARCH in + aarch64eb) machine=aarch64_be-unknown ;; armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; @@ -190,13 +222,13 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in earmv*) arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` - machine="${arch}${endian}"-unknown + machine=${arch}${endian}-unknown ;; - *) machine="$UNAME_MACHINE_ARCH"-unknown ;; + *) machine=$UNAME_MACHINE_ARCH-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. - case "$UNAME_MACHINE_ARCH" in + case $UNAME_MACHINE_ARCH in earm*) os=netbsdelf ;; @@ -217,7 +249,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in ;; esac # Determine ABI tags. - case "$UNAME_MACHINE_ARCH" in + case $UNAME_MACHINE_ARCH in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` @@ -228,7 +260,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. - case "$UNAME_VERSION" in + case $UNAME_VERSION in Debian*) release='-gnu' ;; @@ -239,45 +271,57 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. - echo "$machine-${os}${release}${abi-}" - exit ;; + GUESS=$machine-${os}${release}${abi-} + ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE_ARCH-unknown-bitrig$UNAME_RELEASE + ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE_ARCH-unknown-openbsd$UNAME_RELEASE + ;; + *:SecBSD:*:*) + UNAME_MACHINE_ARCH=`arch | sed 's/SecBSD.//'` + GUESS=$UNAME_MACHINE_ARCH-unknown-secbsd$UNAME_RELEASE + ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` - echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE_ARCH-unknown-libertybsd$UNAME_RELEASE + ;; *:MidnightBSD:*:*) - echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-midnightbsd$UNAME_RELEASE + ;; *:ekkoBSD:*:*) - echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-ekkobsd$UNAME_RELEASE + ;; *:SolidBSD:*:*) - echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-solidbsd$UNAME_RELEASE + ;; + *:OS108:*:*) + GUESS=$UNAME_MACHINE-unknown-os108_$UNAME_RELEASE + ;; macppc:MirBSD:*:*) - echo powerpc-unknown-mirbsd"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-unknown-mirbsd$UNAME_RELEASE + ;; *:MirBSD:*:*) - echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-mirbsd$UNAME_RELEASE + ;; *:Sortix:*:*) - echo "$UNAME_MACHINE"-unknown-sortix - exit ;; + GUESS=$UNAME_MACHINE-unknown-sortix + ;; + *:Twizzler:*:*) + GUESS=$UNAME_MACHINE-unknown-twizzler + ;; *:Redox:*:*) - echo "$UNAME_MACHINE"-unknown-redox - exit ;; + GUESS=$UNAME_MACHINE-unknown-redox + ;; mips:OSF1:*.*) - echo mips-dec-osf1 - exit ;; + GUESS=mips-dec-osf1 + ;; alpha:OSF1:*:*) + # Reset EXIT trap before exiting to avoid spurious non-zero exit code. + trap '' 0 case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` @@ -291,7 +335,7 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` - case "$ALPHA_CPU_TYPE" in + case $ALPHA_CPU_TYPE in "EV4 (21064)") UNAME_MACHINE=alpha ;; "EV4.5 (21064)") @@ -328,117 +372,121 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. - echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`" - # Reset EXIT trap before exiting to avoid spurious non-zero exit code. - exitcode=$? - trap '' 0 - exit $exitcode ;; + OSF_REL=`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` + GUESS=$UNAME_MACHINE-dec-osf$OSF_REL + ;; Amiga*:UNIX_System_V:4.0:*) - echo m68k-unknown-sysv4 - exit ;; + GUESS=m68k-unknown-sysv4 + ;; *:[Aa]miga[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-amigaos - exit ;; + GUESS=$UNAME_MACHINE-unknown-amigaos + ;; *:[Mm]orph[Oo][Ss]:*:*) - echo "$UNAME_MACHINE"-unknown-morphos - exit ;; + GUESS=$UNAME_MACHINE-unknown-morphos + ;; *:OS/390:*:*) - echo i370-ibm-openedition - exit ;; + GUESS=i370-ibm-openedition + ;; *:z/VM:*:*) - echo s390-ibm-zvmoe - exit ;; + GUESS=s390-ibm-zvmoe + ;; *:OS400:*:*) - echo powerpc-ibm-os400 - exit ;; + GUESS=powerpc-ibm-os400 + ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) - echo arm-acorn-riscix"$UNAME_RELEASE" - exit ;; + GUESS=arm-acorn-riscix$UNAME_RELEASE + ;; arm*:riscos:*:*|arm*:RISCOS:*:*) - echo arm-unknown-riscos - exit ;; + GUESS=arm-unknown-riscos + ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) - echo hppa1.1-hitachi-hiuxmpp - exit ;; + GUESS=hppa1.1-hitachi-hiuxmpp + ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. - if test "`(/bin/universe) 2>/dev/null`" = att ; then - echo pyramid-pyramid-sysv3 - else - echo pyramid-pyramid-bsd - fi - exit ;; + case `(/bin/universe) 2>/dev/null` in + att) GUESS=pyramid-pyramid-sysv3 ;; + *) GUESS=pyramid-pyramid-bsd ;; + esac + ;; NILE*:*:*:dcosx) - echo pyramid-pyramid-svr4 - exit ;; + GUESS=pyramid-pyramid-svr4 + ;; DRS?6000:unix:4.0:6*) - echo sparc-icl-nx6 - exit ;; + GUESS=sparc-icl-nx6 + ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in - sparc) echo sparc-icl-nx7; exit ;; - esac ;; + sparc) GUESS=sparc-icl-nx7 ;; + esac + ;; s390x:SunOS:*:*) - echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=$UNAME_MACHINE-ibm-solaris2$SUN_REL + ;; sun4H:SunOS:5.*:*) - echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-hal-solaris2$SUN_REL + ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) - echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-sun-solaris2$SUN_REL + ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) - echo i386-pc-auroraux"$UNAME_RELEASE" - exit ;; + GUESS=i386-pc-auroraux$UNAME_RELEASE + ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) set_cc_for_build SUN_ARCH=i386 # If there is a compiler, see if it is configured for 64-bit objects. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. # This test works for both compilers. - if [ "$CC_FOR_BUILD" != no_compiler_found ]; then + if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ - (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ + (CCOPTS="" $CC_FOR_BUILD -m64 -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then SUN_ARCH=x86_64 fi fi - echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=$SUN_ARCH-pc-solaris2$SUN_REL + ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. - echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=sparc-sun-solaris3$SUN_REL + ;; sun4*:SunOS:*:*) - case "`/usr/bin/arch -k`" in + case `/usr/bin/arch -k` in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac - # Japanese Language versions have a version number like `4.1.3-JL'. - echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`" - exit ;; + # Japanese Language versions have a version number like '4.1.3-JL'. + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` + GUESS=sparc-sun-sunos$SUN_REL + ;; sun3*:SunOS:*:*) - echo m68k-sun-sunos"$UNAME_RELEASE" - exit ;; + GUESS=m68k-sun-sunos$UNAME_RELEASE + ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 - case "`/bin/arch`" in + case `/bin/arch` in sun3) - echo m68k-sun-sunos"$UNAME_RELEASE" + GUESS=m68k-sun-sunos$UNAME_RELEASE ;; sun4) - echo sparc-sun-sunos"$UNAME_RELEASE" + GUESS=sparc-sun-sunos$UNAME_RELEASE ;; esac - exit ;; + ;; aushp:SunOS:*:*) - echo sparc-auspex-sunos"$UNAME_RELEASE" - exit ;; + GUESS=sparc-auspex-sunos$UNAME_RELEASE + ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor @@ -448,41 +496,41 @@ case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) - echo m68k-atari-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-atari-mint$UNAME_RELEASE + ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) - echo m68k-milan-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-milan-mint$UNAME_RELEASE + ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) - echo m68k-hades-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-hades-mint$UNAME_RELEASE + ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) - echo m68k-unknown-mint"$UNAME_RELEASE" - exit ;; + GUESS=m68k-unknown-mint$UNAME_RELEASE + ;; m68k:machten:*:*) - echo m68k-apple-machten"$UNAME_RELEASE" - exit ;; + GUESS=m68k-apple-machten$UNAME_RELEASE + ;; powerpc:machten:*:*) - echo powerpc-apple-machten"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-apple-machten$UNAME_RELEASE + ;; RISC*:Mach:*:*) - echo mips-dec-mach_bsd4.3 - exit ;; + GUESS=mips-dec-mach_bsd4.3 + ;; RISC*:ULTRIX:*:*) - echo mips-dec-ultrix"$UNAME_RELEASE" - exit ;; + GUESS=mips-dec-ultrix$UNAME_RELEASE + ;; VAX*:ULTRIX*:*:*) - echo vax-dec-ultrix"$UNAME_RELEASE" - exit ;; + GUESS=vax-dec-ultrix$UNAME_RELEASE + ;; 2020:CLIX:*:* | 2430:CLIX:*:*) - echo clipper-intergraph-clix"$UNAME_RELEASE" - exit ;; + GUESS=clipper-intergraph-clix$UNAME_RELEASE + ;; mips:*:*:UMIPS | mips:*:*:RISCos) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" @@ -510,82 +558,84 @@ EOF dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } - echo mips-mips-riscos"$UNAME_RELEASE" - exit ;; + GUESS=mips-mips-riscos$UNAME_RELEASE + ;; Motorola:PowerMAX_OS:*:*) - echo powerpc-motorola-powermax - exit ;; + GUESS=powerpc-motorola-powermax + ;; Motorola:*:4.3:PL8-*) - echo powerpc-harris-powermax - exit ;; + GUESS=powerpc-harris-powermax + ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) - echo powerpc-harris-powermax - exit ;; + GUESS=powerpc-harris-powermax + ;; Night_Hawk:Power_UNIX:*:*) - echo powerpc-harris-powerunix - exit ;; + GUESS=powerpc-harris-powerunix + ;; m88k:CX/UX:7*:*) - echo m88k-harris-cxux7 - exit ;; + GUESS=m88k-harris-cxux7 + ;; m88k:*:4*:R4*) - echo m88k-motorola-sysv4 - exit ;; + GUESS=m88k-motorola-sysv4 + ;; m88k:*:3*:R3*) - echo m88k-motorola-sysv3 - exit ;; + GUESS=m88k-motorola-sysv3 + ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` - if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ] + if test "$UNAME_PROCESSOR" = mc88100 || test "$UNAME_PROCESSOR" = mc88110 then - if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \ - [ "$TARGET_BINARY_INTERFACE"x = x ] + if test "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx || \ + test "$TARGET_BINARY_INTERFACE"x = x then - echo m88k-dg-dgux"$UNAME_RELEASE" + GUESS=m88k-dg-dgux$UNAME_RELEASE else - echo m88k-dg-dguxbcs"$UNAME_RELEASE" + GUESS=m88k-dg-dguxbcs$UNAME_RELEASE fi else - echo i586-dg-dgux"$UNAME_RELEASE" + GUESS=i586-dg-dgux$UNAME_RELEASE fi - exit ;; + ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) - echo m88k-dolphin-sysv3 - exit ;; + GUESS=m88k-dolphin-sysv3 + ;; M88*:*:R3*:*) # Delta 88k system running SVR3 - echo m88k-motorola-sysv3 - exit ;; + GUESS=m88k-motorola-sysv3 + ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) - echo m88k-tektronix-sysv3 - exit ;; + GUESS=m88k-tektronix-sysv3 + ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) - echo m68k-tektronix-bsd - exit ;; + GUESS=m68k-tektronix-bsd + ;; *:IRIX*:*:*) - echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`" - exit ;; + IRIX_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/g'` + GUESS=mips-sgi-irix$IRIX_REL + ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. - echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id - exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' + GUESS=romp-ibm-aix # uname -m gives an 8 hex-code CPU id + ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) - echo i386-ibm-aix - exit ;; + GUESS=i386-ibm-aix + ;; ia64:AIX:*:*) - if [ -x /usr/bin/oslevel ] ; then + if test -x /usr/bin/oslevel ; then IBM_REV=`/usr/bin/oslevel` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi - echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" - exit ;; + GUESS=$UNAME_MACHINE-ibm-aix$IBM_REV + ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" #include <sys/systemcfg.h> - main() + int + main () { if (!__power_pc()) exit(1); @@ -595,16 +645,16 @@ EOF EOF if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then - echo "$SYSTEM_NAME" + GUESS=$SYSTEM_NAME else - echo rs6000-ibm-aix3.2.5 + GUESS=rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then - echo rs6000-ibm-aix3.2.4 + GUESS=rs6000-ibm-aix3.2.4 else - echo rs6000-ibm-aix3.2 + GUESS=rs6000-ibm-aix3.2 fi - exit ;; + ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then @@ -612,56 +662,56 @@ EOF else IBM_ARCH=powerpc fi - if [ -x /usr/bin/lslpp ] ; then - IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | + if test -x /usr/bin/lslpp ; then + IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | \ awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else - IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" + IBM_REV=$UNAME_VERSION.$UNAME_RELEASE fi - echo "$IBM_ARCH"-ibm-aix"$IBM_REV" - exit ;; + GUESS=$IBM_ARCH-ibm-aix$IBM_REV + ;; *:AIX:*:*) - echo rs6000-ibm-aix - exit ;; + GUESS=rs6000-ibm-aix + ;; ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) - echo romp-ibm-bsd4.4 - exit ;; + GUESS=romp-ibm-bsd4.4 + ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and - echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to - exit ;; # report: romp-ibm BSD 4.3 + GUESS=romp-ibm-bsd$UNAME_RELEASE # 4.3 with uname added to + ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) - echo rs6000-bull-bosx - exit ;; + GUESS=rs6000-bull-bosx + ;; DPX/2?00:B.O.S.:*:*) - echo m68k-bull-sysv3 - exit ;; + GUESS=m68k-bull-sysv3 + ;; 9000/[34]??:4.3bsd:1.*:*) - echo m68k-hp-bsd - exit ;; + GUESS=m68k-hp-bsd + ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) - echo m68k-hp-bsd4.4 - exit ;; + GUESS=m68k-hp-bsd4.4 + ;; 9000/[34678]??:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` - case "$UNAME_MACHINE" in + HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` + case $UNAME_MACHINE in 9000/31?) HP_ARCH=m68000 ;; 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) - if [ -x /usr/bin/getconf ]; then + if test -x /usr/bin/getconf; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` - case "$sc_cpu_version" in + case $sc_cpu_version in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 - case "$sc_kernel_bits" in + case $sc_kernel_bits in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi - if [ "$HP_ARCH" = "" ]; then + if test "$HP_ARCH" = ""; then set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" @@ -669,7 +719,8 @@ EOF #include <stdlib.h> #include <unistd.h> - int main () + int + main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); @@ -700,7 +751,7 @@ EOF test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac - if [ "$HP_ARCH" = hppa2.0w ] + if test "$HP_ARCH" = hppa2.0w then set_cc_for_build @@ -721,12 +772,12 @@ EOF HP_ARCH=hppa64 fi fi - echo "$HP_ARCH"-hp-hpux"$HPUX_REV" - exit ;; + GUESS=$HP_ARCH-hp-hpux$HPUX_REV + ;; ia64:HP-UX:*:*) - HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` - echo ia64-hp-hpux"$HPUX_REV" - exit ;; + HPUX_REV=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*.[0B]*//'` + GUESS=ia64-hp-hpux$HPUX_REV + ;; 3050*:HI-UX:*:*) set_cc_for_build sed 's/^ //' << EOF > "$dummy.c" @@ -756,36 +807,36 @@ EOF EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } - echo unknown-hitachi-hiuxwe2 - exit ;; + GUESS=unknown-hitachi-hiuxwe2 + ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) - echo hppa1.1-hp-bsd - exit ;; + GUESS=hppa1.1-hp-bsd + ;; 9000/8??:4.3bsd:*:*) - echo hppa1.0-hp-bsd - exit ;; + GUESS=hppa1.0-hp-bsd + ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) - echo hppa1.0-hp-mpeix - exit ;; + GUESS=hppa1.0-hp-mpeix + ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) - echo hppa1.1-hp-osf - exit ;; + GUESS=hppa1.1-hp-osf + ;; hp8??:OSF1:*:*) - echo hppa1.0-hp-osf - exit ;; + GUESS=hppa1.0-hp-osf + ;; i*86:OSF1:*:*) - if [ -x /usr/sbin/sysversion ] ; then - echo "$UNAME_MACHINE"-unknown-osf1mk + if test -x /usr/sbin/sysversion ; then + GUESS=$UNAME_MACHINE-unknown-osf1mk else - echo "$UNAME_MACHINE"-unknown-osf1 + GUESS=$UNAME_MACHINE-unknown-osf1 fi - exit ;; + ;; parisc*:Lites*:*:*) - echo hppa1.1-hp-lites - exit ;; + GUESS=hppa1.1-hp-lites + ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) - echo c1-convex-bsd - exit ;; + GUESS=c1-convex-bsd + ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd @@ -793,17 +844,18 @@ EOF fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) - echo c34-convex-bsd - exit ;; + GUESS=c34-convex-bsd + ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) - echo c38-convex-bsd - exit ;; + GUESS=c38-convex-bsd + ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) - echo c4-convex-bsd - exit ;; + GUESS=c4-convex-bsd + ;; CRAY*Y-MP:*:*:*) - echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=ymp-cray-unicos$CRAY_REL + ;; CRAY*[A-Z]90:*:*:*) echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ @@ -811,114 +863,155 @@ EOF -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) - echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=t90-cray-unicos$CRAY_REL + ;; CRAY*T3E:*:*:*) - echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=alphaev5-cray-unicosmk$CRAY_REL + ;; CRAY*SV1:*:*:*) - echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=sv1-cray-unicos$CRAY_REL + ;; *:UNICOS/mp:*:*) - echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' - exit ;; + CRAY_REL=`echo "$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/'` + GUESS=craynv-cray-unicosmp$CRAY_REL + ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` - echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + GUESS=${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} + ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` - echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" - exit ;; + GUESS=sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL} + ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) - echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-pc-bsdi$UNAME_RELEASE + ;; sparc*:BSD/OS:*:*) - echo sparc-unknown-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=sparc-unknown-bsdi$UNAME_RELEASE + ;; *:BSD/OS:*:*) - echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-bsdi$UNAME_RELEASE + ;; arm:FreeBSD:*:*) UNAME_PROCESSOR=`uname -p` set_cc_for_build if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabi + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabi else - echo "${UNAME_PROCESSOR}"-unknown-freebsd"`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`"-gnueabihf + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL-gnueabihf fi - exit ;; + ;; *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` - case "$UNAME_PROCESSOR" in + UNAME_PROCESSOR=`uname -p` + case $UNAME_PROCESSOR in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac - echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" - exit ;; + FREEBSD_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_PROCESSOR-unknown-freebsd$FREEBSD_REL + ;; i*:CYGWIN*:*) - echo "$UNAME_MACHINE"-pc-cygwin - exit ;; + GUESS=$UNAME_MACHINE-pc-cygwin + ;; *:MINGW64*:*) - echo "$UNAME_MACHINE"-pc-mingw64 - exit ;; + GUESS=$UNAME_MACHINE-pc-mingw64 + ;; *:MINGW*:*) - echo "$UNAME_MACHINE"-pc-mingw32 - exit ;; + GUESS=$UNAME_MACHINE-pc-mingw32 + ;; *:MSYS*:*) - echo "$UNAME_MACHINE"-pc-msys - exit ;; + GUESS=$UNAME_MACHINE-pc-msys + ;; i*:PW*:*) - echo "$UNAME_MACHINE"-pc-pw32 - exit ;; + GUESS=$UNAME_MACHINE-pc-pw32 + ;; + *:SerenityOS:*:*) + GUESS=$UNAME_MACHINE-pc-serenity + ;; *:Interix*:*) - case "$UNAME_MACHINE" in + case $UNAME_MACHINE in x86) - echo i586-pc-interix"$UNAME_RELEASE" - exit ;; + GUESS=i586-pc-interix$UNAME_RELEASE + ;; authenticamd | genuineintel | EM64T) - echo x86_64-unknown-interix"$UNAME_RELEASE" - exit ;; + GUESS=x86_64-unknown-interix$UNAME_RELEASE + ;; IA64) - echo ia64-unknown-interix"$UNAME_RELEASE" - exit ;; + GUESS=ia64-unknown-interix$UNAME_RELEASE + ;; esac ;; i*:UWIN*:*) - echo "$UNAME_MACHINE"-pc-uwin - exit ;; + GUESS=$UNAME_MACHINE-pc-uwin + ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) - echo x86_64-pc-cygwin - exit ;; + GUESS=x86_64-pc-cygwin + ;; prep*:SunOS:5.*:*) - echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" - exit ;; + SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'` + GUESS=powerpcle-unknown-solaris2$SUN_REL + ;; *:GNU:*:*) # the GNU system - echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`" - exit ;; + GNU_ARCH=`echo "$UNAME_MACHINE" | sed -e 's,[-/].*$,,'` + GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's,/.*$,,'` + GUESS=$GNU_ARCH-unknown-$LIBC$GNU_REL + ;; *:GNU/*:*:*) # other systems with GNU libc and userland - echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" - exit ;; + GNU_SYS=`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"` + GNU_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_MACHINE-unknown-$GNU_SYS$GNU_REL-$LIBC + ;; + x86_64:[Mm]anagarm:*:*|i?86:[Mm]anagarm:*:*) + GUESS="$UNAME_MACHINE-pc-managarm-mlibc" + ;; + *:[Mm]anagarm:*:*) + GUESS="$UNAME_MACHINE-unknown-managarm-mlibc" + ;; *:Minix:*:*) - echo "$UNAME_MACHINE"-unknown-minix - exit ;; + GUESS=$UNAME_MACHINE-unknown-minix + ;; aarch64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __ARM_EABI__ + #ifdef __ARM_PCS_VFP + ABI=eabihf + #else + ABI=eabi + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;; + esac + fi + GUESS=$CPU-unknown-linux-$LIBCABI + ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; alpha:Linux:*:*) - case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in + case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' /proc/cpuinfo 2>/dev/null` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; @@ -929,60 +1022,72 @@ EOF esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; - arc:Linux:*:* | arceb:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + arc:Linux:*:* | arceb:Linux:*:* | arc32:Linux:*:* | arc64:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; arm*:Linux:*:*) set_cc_for_build if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi + GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabi else - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf + GUESS=$UNAME_MACHINE-unknown-linux-${LIBC}eabihf fi fi - exit ;; + ;; avr32*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; cris:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-axis-linux-$LIBC + ;; crisv32:Linux:*:*) - echo "$UNAME_MACHINE"-axis-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-axis-linux-$LIBC + ;; e2k:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; frv:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; hexagon:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; i*86:Linux:*:*) - echo "$UNAME_MACHINE"-pc-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-pc-linux-$LIBC + ;; ia64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; k1om:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:cos:*:*) + GUESS=$UNAME_MACHINE-unknown-cos + ;; + kvx:mbr:*:*) + GUESS=$UNAME_MACHINE-unknown-mbr + ;; + loongarch32:Linux:*:* | loongarch64:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; m32r*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; m68*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; mips:Linux:*:* | mips64:Linux:*:*) set_cc_for_build IS_GLIBC=0 @@ -1027,113 +1132,135 @@ EOF #endif #endif EOF - eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'`" + cc_set_vars=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU\|^MIPS_ENDIAN\|^LIBCABI'` + eval "$cc_set_vars" test "x$CPU" != x && { echo "$CPU${MIPS_ENDIAN}-unknown-linux-$LIBCABI"; exit; } ;; mips64el:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; openrisc*:Linux:*:*) - echo or1k-unknown-linux-"$LIBC" - exit ;; + GUESS=or1k-unknown-linux-$LIBC + ;; or32:Linux:*:* | or1k*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; padre:Linux:*:*) - echo sparc-unknown-linux-"$LIBC" - exit ;; + GUESS=sparc-unknown-linux-$LIBC + ;; parisc64:Linux:*:* | hppa64:Linux:*:*) - echo hppa64-unknown-linux-"$LIBC" - exit ;; + GUESS=hppa64-unknown-linux-$LIBC + ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in - PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; - PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; - *) echo hppa-unknown-linux-"$LIBC" ;; + PA7*) GUESS=hppa1.1-unknown-linux-$LIBC ;; + PA8*) GUESS=hppa2.0-unknown-linux-$LIBC ;; + *) GUESS=hppa-unknown-linux-$LIBC ;; esac - exit ;; + ;; ppc64:Linux:*:*) - echo powerpc64-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc64-unknown-linux-$LIBC + ;; ppc:Linux:*:*) - echo powerpc-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc-unknown-linux-$LIBC + ;; ppc64le:Linux:*:*) - echo powerpc64le-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpc64le-unknown-linux-$LIBC + ;; ppcle:Linux:*:*) - echo powerpcle-unknown-linux-"$LIBC" - exit ;; - riscv32:Linux:*:* | riscv64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=powerpcle-unknown-linux-$LIBC + ;; + riscv32:Linux:*:* | riscv32be:Linux:*:* | riscv64:Linux:*:* | riscv64be:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; s390:Linux:*:* | s390x:Linux:*:*) - echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-ibm-linux-$LIBC + ;; sh64*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; sh*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; sparc:Linux:*:* | sparc64:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; tile*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; vax:Linux:*:*) - echo "$UNAME_MACHINE"-dec-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-dec-linux-$LIBC + ;; x86_64:Linux:*:*) - echo "$UNAME_MACHINE"-pc-linux-"$LIBC" - exit ;; + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __i386__ + ABI=x86 + #else + #ifdef __ILP32__ + ABI=x32 + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + x86) CPU=i686 ;; + x32) LIBCABI=${LIBC}x32 ;; + esac + fi + GUESS=$CPU-pc-linux-$LIBCABI + ;; xtensa*:Linux:*:*) - echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" - exit ;; + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. - echo i386-sequent-sysv4 - exit ;; + GUESS=i386-sequent-sysv4 + ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. - echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" - exit ;; + GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION + ;; i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility + # If we were able to find 'uname', then EMX Unix compatibility # is probably installed. - echo "$UNAME_MACHINE"-pc-os2-emx - exit ;; + GUESS=$UNAME_MACHINE-pc-os2-emx + ;; i*86:XTS-300:*:STOP) - echo "$UNAME_MACHINE"-unknown-stop - exit ;; + GUESS=$UNAME_MACHINE-unknown-stop + ;; i*86:atheos:*:*) - echo "$UNAME_MACHINE"-unknown-atheos - exit ;; + GUESS=$UNAME_MACHINE-unknown-atheos + ;; i*86:syllable:*:*) - echo "$UNAME_MACHINE"-pc-syllable - exit ;; + GUESS=$UNAME_MACHINE-pc-syllable + ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) - echo i386-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=i386-unknown-lynxos$UNAME_RELEASE + ;; i*86:*DOS:*:*) - echo "$UNAME_MACHINE"-pc-msdosdjgpp - exit ;; + GUESS=$UNAME_MACHINE-pc-msdosdjgpp + ;; i*86:*:4.*:*) UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then - echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" + GUESS=$UNAME_MACHINE-univel-sysv$UNAME_REL else - echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" + GUESS=$UNAME_MACHINE-pc-sysv$UNAME_REL fi - exit ;; + ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in @@ -1141,12 +1268,12 @@ EOF *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac - echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}" - exit ;; + GUESS=$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} + ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name` - echo "$UNAME_MACHINE"-pc-isc"$UNAME_REL" + GUESS=$UNAME_MACHINE-pc-isc$UNAME_REL elif /bin/uname -X 2>/dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 @@ -1156,11 +1283,11 @@ EOF && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 - echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" + GUESS=$UNAME_MACHINE-pc-sco$UNAME_REL else - echo "$UNAME_MACHINE"-pc-sysv32 + GUESS=$UNAME_MACHINE-pc-sysv32 fi - exit ;; + ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about @@ -1168,31 +1295,31 @@ EOF # Note: whatever this is, it MUST be the same as what config.sub # prints for the "djgpp" host, or else GDB configure will decide that # this is a cross-build. - echo i586-pc-msdosdjgpp - exit ;; + GUESS=i586-pc-msdosdjgpp + ;; Intel:Mach:3*:*) - echo i386-pc-mach3 - exit ;; + GUESS=i386-pc-mach3 + ;; paragon:*:*:*) - echo i860-intel-osf1 - exit ;; + GUESS=i860-intel-osf1 + ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then - echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 + GUESS=i860-stardent-sysv$UNAME_RELEASE # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. - echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 + GUESS=i860-unknown-sysv$UNAME_RELEASE # Unknown i860-SVR4 fi - exit ;; + ;; mini*:CTIX:SYS*5:*) # "miniframe" - echo m68010-convergent-sysv - exit ;; + GUESS=m68010-convergent-sysv + ;; mc68k:UNIX:SYSTEM5:3.51m) - echo m68k-convergent-sysv - exit ;; + GUESS=m68k-convergent-sysv + ;; M680?0:D-NIX:5.3:*) - echo m68k-diab-dnix - exit ;; + GUESS=m68k-diab-dnix + ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) @@ -1217,113 +1344,119 @@ EOF /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) - echo m68k-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=m68k-unknown-lynxos$UNAME_RELEASE + ;; mc68030:UNIX_System_V:4.*:*) - echo m68k-atari-sysv4 - exit ;; + GUESS=m68k-atari-sysv4 + ;; TSUNAMI:LynxOS:2.*:*) - echo sparc-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=sparc-unknown-lynxos$UNAME_RELEASE + ;; rs6000:LynxOS:2.*:*) - echo rs6000-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=rs6000-unknown-lynxos$UNAME_RELEASE + ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) - echo powerpc-unknown-lynxos"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-unknown-lynxos$UNAME_RELEASE + ;; SM[BE]S:UNIX_SV:*:*) - echo mips-dde-sysv"$UNAME_RELEASE" - exit ;; + GUESS=mips-dde-sysv$UNAME_RELEASE + ;; RM*:ReliantUNIX-*:*:*) - echo mips-sni-sysv4 - exit ;; + GUESS=mips-sni-sysv4 + ;; RM*:SINIX-*:*:*) - echo mips-sni-sysv4 - exit ;; + GUESS=mips-sni-sysv4 + ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` - echo "$UNAME_MACHINE"-sni-sysv4 + GUESS=$UNAME_MACHINE-sni-sysv4 else - echo ns32k-sni-sysv + GUESS=ns32k-sni-sysv fi - exit ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + ;; + PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort # says <Richard.M.Bartel@ccMail.Census.GOV> - echo i586-unisys-sysv4 - exit ;; + GUESS=i586-unisys-sysv4 + ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes <hewes@openmarket.com>. # How about differentiating between stratus architectures? -djm - echo hppa1.1-stratus-sysv4 - exit ;; + GUESS=hppa1.1-stratus-sysv4 + ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. - echo i860-stratus-sysv4 - exit ;; + GUESS=i860-stratus-sysv4 + ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. - echo "$UNAME_MACHINE"-stratus-vos - exit ;; + GUESS=$UNAME_MACHINE-stratus-vos + ;; *:VOS:*:*) # From Paul.Green@stratus.com. - echo hppa1.1-stratus-vos - exit ;; + GUESS=hppa1.1-stratus-vos + ;; mc68*:A/UX:*:*) - echo m68k-apple-aux"$UNAME_RELEASE" - exit ;; + GUESS=m68k-apple-aux$UNAME_RELEASE + ;; news*:NEWS-OS:6*:*) - echo mips-sony-newsos6 - exit ;; + GUESS=mips-sony-newsos6 + ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) - if [ -d /usr/nec ]; then - echo mips-nec-sysv"$UNAME_RELEASE" + if test -d /usr/nec; then + GUESS=mips-nec-sysv$UNAME_RELEASE else - echo mips-unknown-sysv"$UNAME_RELEASE" + GUESS=mips-unknown-sysv$UNAME_RELEASE fi - exit ;; + ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. - echo powerpc-be-beos - exit ;; + GUESS=powerpc-be-beos + ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. - echo powerpc-apple-beos - exit ;; + GUESS=powerpc-apple-beos + ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. - echo i586-pc-beos - exit ;; + GUESS=i586-pc-beos + ;; BePC:Haiku:*:*) # Haiku running on Intel PC compatible. - echo i586-pc-haiku - exit ;; - x86_64:Haiku:*:*) - echo x86_64-unknown-haiku - exit ;; + GUESS=i586-pc-haiku + ;; + ppc:Haiku:*:*) # Haiku running on Apple PowerPC + GUESS=powerpc-apple-haiku + ;; + *:Haiku:*:*) # Haiku modern gcc (not bound by BeOS compat) + GUESS=$UNAME_MACHINE-unknown-haiku + ;; SX-4:SUPER-UX:*:*) - echo sx4-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx4-nec-superux$UNAME_RELEASE + ;; SX-5:SUPER-UX:*:*) - echo sx5-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx5-nec-superux$UNAME_RELEASE + ;; SX-6:SUPER-UX:*:*) - echo sx6-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx6-nec-superux$UNAME_RELEASE + ;; SX-7:SUPER-UX:*:*) - echo sx7-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx7-nec-superux$UNAME_RELEASE + ;; SX-8:SUPER-UX:*:*) - echo sx8-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx8-nec-superux$UNAME_RELEASE + ;; SX-8R:SUPER-UX:*:*) - echo sx8r-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sx8r-nec-superux$UNAME_RELEASE + ;; SX-ACE:SUPER-UX:*:*) - echo sxace-nec-superux"$UNAME_RELEASE" - exit ;; + GUESS=sxace-nec-superux$UNAME_RELEASE + ;; Power*:Rhapsody:*:*) - echo powerpc-apple-rhapsody"$UNAME_RELEASE" - exit ;; + GUESS=powerpc-apple-rhapsody$UNAME_RELEASE + ;; *:Rhapsody:*:*) - echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-apple-rhapsody$UNAME_RELEASE + ;; + arm64:Darwin:*:*) + GUESS=aarch64-apple-darwin$UNAME_RELEASE + ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` case $UNAME_PROCESSOR in @@ -1338,7 +1471,7 @@ EOF else set_cc_for_build fi - if [ "$CC_FOR_BUILD" != no_compiler_found ]; then + if test "$CC_FOR_BUILD" != no_compiler_found; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null @@ -1359,109 +1492,122 @@ EOF # uname -m returns i386 or x86_64 UNAME_PROCESSOR=$UNAME_MACHINE fi - echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_PROCESSOR-apple-darwin$UNAME_RELEASE + ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = x86; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi - echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_PROCESSOR-$UNAME_MACHINE-nto-qnx$UNAME_RELEASE + ;; *:QNX:*:4*) - echo i386-pc-qnx - exit ;; + GUESS=i386-pc-qnx + ;; NEO-*:NONSTOP_KERNEL:*:*) - echo neo-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=neo-tandem-nsk$UNAME_RELEASE + ;; NSE-*:NONSTOP_KERNEL:*:*) - echo nse-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nse-tandem-nsk$UNAME_RELEASE + ;; NSR-*:NONSTOP_KERNEL:*:*) - echo nsr-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsr-tandem-nsk$UNAME_RELEASE + ;; NSV-*:NONSTOP_KERNEL:*:*) - echo nsv-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsv-tandem-nsk$UNAME_RELEASE + ;; NSX-*:NONSTOP_KERNEL:*:*) - echo nsx-tandem-nsk"$UNAME_RELEASE" - exit ;; + GUESS=nsx-tandem-nsk$UNAME_RELEASE + ;; *:NonStop-UX:*:*) - echo mips-compaq-nonstopux - exit ;; + GUESS=mips-compaq-nonstopux + ;; BS2000:POSIX*:*:*) - echo bs2000-siemens-sysv - exit ;; + GUESS=bs2000-siemens-sysv + ;; DS/*:UNIX_System_V:*:*) - echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-$UNAME_SYSTEM-$UNAME_RELEASE + ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. - # shellcheck disable=SC2154 - if test "$cputype" = 386; then + if test "${cputype-}" = 386; then UNAME_MACHINE=i386 - else - UNAME_MACHINE="$cputype" + elif test "x${cputype-}" != x; then + UNAME_MACHINE=$cputype fi - echo "$UNAME_MACHINE"-unknown-plan9 - exit ;; + GUESS=$UNAME_MACHINE-unknown-plan9 + ;; *:TOPS-10:*:*) - echo pdp10-unknown-tops10 - exit ;; + GUESS=pdp10-unknown-tops10 + ;; *:TENEX:*:*) - echo pdp10-unknown-tenex - exit ;; + GUESS=pdp10-unknown-tenex + ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) - echo pdp10-dec-tops20 - exit ;; + GUESS=pdp10-dec-tops20 + ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) - echo pdp10-xkl-tops20 - exit ;; + GUESS=pdp10-xkl-tops20 + ;; *:TOPS-20:*:*) - echo pdp10-unknown-tops20 - exit ;; + GUESS=pdp10-unknown-tops20 + ;; *:ITS:*:*) - echo pdp10-unknown-its - exit ;; + GUESS=pdp10-unknown-its + ;; SEI:*:*:SEIUX) - echo mips-sei-seiux"$UNAME_RELEASE" - exit ;; + GUESS=mips-sei-seiux$UNAME_RELEASE + ;; *:DragonFly:*:*) - echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" - exit ;; + DRAGONFLY_REL=`echo "$UNAME_RELEASE" | sed -e 's/[-(].*//'` + GUESS=$UNAME_MACHINE-unknown-dragonfly$DRAGONFLY_REL + ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` - case "$UNAME_MACHINE" in - A*) echo alpha-dec-vms ; exit ;; - I*) echo ia64-dec-vms ; exit ;; - V*) echo vax-dec-vms ; exit ;; + case $UNAME_MACHINE in + A*) GUESS=alpha-dec-vms ;; + I*) GUESS=ia64-dec-vms ;; + V*) GUESS=vax-dec-vms ;; esac ;; *:XENIX:*:SysV) - echo i386-pc-xenix - exit ;; + GUESS=i386-pc-xenix + ;; i*86:skyos:*:*) - echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`" - exit ;; + SKYOS_REL=`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'` + GUESS=$UNAME_MACHINE-pc-skyos$SKYOS_REL + ;; i*86:rdos:*:*) - echo "$UNAME_MACHINE"-pc-rdos - exit ;; - i*86:AROS:*:*) - echo "$UNAME_MACHINE"-pc-aros - exit ;; + GUESS=$UNAME_MACHINE-pc-rdos + ;; + i*86:Fiwix:*:*) + GUESS=$UNAME_MACHINE-pc-fiwix + ;; + *:AROS:*:*) + GUESS=$UNAME_MACHINE-unknown-aros + ;; x86_64:VMkernel:*:*) - echo "$UNAME_MACHINE"-unknown-esx - exit ;; + GUESS=$UNAME_MACHINE-unknown-esx + ;; amd64:Isilon\ OneFS:*:*) - echo x86_64-unknown-onefs - exit ;; + GUESS=x86_64-unknown-onefs + ;; *:Unleashed:*:*) - echo "$UNAME_MACHINE"-unknown-unleashed"$UNAME_RELEASE" - exit ;; + GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE + ;; + *:Ironclad:*:*) + GUESS=$UNAME_MACHINE-unknown-ironclad + ;; esac +# Do we have a guess based on uname results? +if test "x$GUESS" != x; then + echo "$GUESS" + exit +fi + # No uname command or uname output not recognized. set_cc_for_build cat > "$dummy.c" <<EOF @@ -1477,6 +1623,7 @@ cat > "$dummy.c" <<EOF #endif #endif #endif +int main () { #if defined (sony) @@ -1593,7 +1740,7 @@ main () } EOF -$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`$dummy` && +$CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. @@ -1601,7 +1748,7 @@ test -d /usr/apollo && { echo "$ISP-apollo-$SYSTYPE"; exit; } echo "$0: unable to guess system type" >&2 -case "$UNAME_MACHINE:$UNAME_SYSTEM" in +case $UNAME_MACHINE:$UNAME_SYSTEM in mips:Linux | mips64:Linux) # If we got here on MIPS GNU/Linux, output extra information. cat >&2 <<EOF @@ -1618,9 +1765,17 @@ This script (version $timestamp), has failed to recognize the operating system you are using. If your script is old, overwrite *all* copies of config.guess and config.sub with the latest versions from: - https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess + https://git.savannah.gnu.org/cgit/config.git/plain/config.guess and - https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub + https://git.savannah.gnu.org/cgit/config.git/plain/config.sub +EOF + +our_year=`echo $timestamp | sed 's,-.*,,'` +thisyear=`date +%Y` +# shellcheck disable=SC2003 +script_age=`expr "$thisyear" - "$our_year"` +if test "$script_age" -lt 3 ; then + cat >&2 <<EOF If $0 has already been updated, send the following data and any information you think might be pertinent to config-patches@gnu.org to @@ -1648,6 +1803,7 @@ UNAME_RELEASE = "$UNAME_RELEASE" UNAME_SYSTEM = "$UNAME_SYSTEM" UNAME_VERSION = "$UNAME_VERSION" EOF +fi exit 1 diff --git a/subprojects/libsodium/build-aux/config.sub b/subprojects/libsodium/build-aux/config.sub @@ -1,12 +1,14 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright 1992-2019 Free Software Foundation, Inc. +# Copyright 1992-2025 Free Software Foundation, Inc. -timestamp='2019-05-23' +# shellcheck disable=SC2006,SC2268,SC2162 # see below for rationale + +timestamp='2025-07-10' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or +# the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but @@ -33,7 +35,7 @@ timestamp='2019-05-23' # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: -# https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub +# https://git.savannah.gnu.org/cgit/config.git/plain/config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases @@ -50,6 +52,13 @@ timestamp='2019-05-23' # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. +# The "shellcheck disable" line above the timestamp inhibits complaints +# about features and limitations of the classic Bourne shell that were +# superseded or lifted in POSIX. However, this script identifies a wide +# variety of pre-POSIX systems that do not have POSIX shells at all, and +# even some reasonably current systems (Solaris 10 as case-in-point) still +# have a pre-POSIX /bin/sh. + me=`echo "$0" | sed -e 's,.*/,,'` usage="\ @@ -67,13 +76,13 @@ Report bugs and patches to <config-patches@gnu.org>." version="\ GNU config.sub ($timestamp) -Copyright 1992-2019 Free Software Foundation, Inc. +Copyright 1992-2025 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -111,75 +120,154 @@ case $# in esac # Split fields of configuration type -# shellcheck disable=SC2162 +saved_IFS=$IFS IFS="-" read field1 field2 field3 field4 <<EOF $1 EOF +IFS=$saved_IFS # Separate into logical components for further validation case $1 in *-*-*-*-*) - echo Invalid configuration \`"$1"\': more than four components >&2 + echo "Invalid configuration '$1': more than four components" >&2 exit 1 ;; *-*-*-*) basic_machine=$field1-$field2 - os=$field3-$field4 + basic_os=$field3-$field4 ;; *-*-*) # Ambiguous whether COMPANY is present, or skipped and KERNEL-OS is two # parts maybe_os=$field2-$field3 case $maybe_os in - nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc \ - | linux-newlib* | linux-musl* | linux-uclibc* | uclinux-uclibc* \ - | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ - | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ - | storm-chaos* | os2-emx* | rtmk-nova*) + cloudabi*-eabi* \ + | kfreebsd*-gnu* \ + | knetbsd*-gnu* \ + | kopensolaris*-gnu* \ + | ironclad-* \ + | linux-* \ + | managarm-* \ + | netbsd*-eabi* \ + | netbsd*-gnu* \ + | nto-qnx* \ + | os2-emx* \ + | rtmk-nova* \ + | storm-chaos* \ + | uclinux-gnu* \ + | uclinux-uclibc* \ + | windows-* ) basic_machine=$field1 - os=$maybe_os + basic_os=$maybe_os ;; android-linux) basic_machine=$field1-unknown - os=linux-android + basic_os=linux-android ;; *) basic_machine=$field1-$field2 - os=$field3 + basic_os=$field3 ;; esac ;; *-*) - # A lone config we happen to match not fitting any pattern case $field1-$field2 in + # Shorthands that happen to contain a single dash + convex-c[12] | convex-c3[248]) + basic_machine=$field2-convex + basic_os= + ;; decstation-3100) basic_machine=mips-dec - os= + basic_os= ;; *-*) # Second component is usually, but not always the OS case $field2 in - # Prevent following clause from handling this valid os + # Do not treat sunos as a manufacturer sun*os*) basic_machine=$field1 - os=$field2 + basic_os=$field2 ;; # Manufacturers - dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ - | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ - | unicom* | ibm* | next | hp | isi* | apollo | altos* \ - | convergent* | ncr* | news | 32* | 3600* | 3100* \ - | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ - | ultra | tti* | harris | dolphin | highlevel | gould \ - | cbm | ns | masscomp | apple | axis | knuth | cray \ - | microblaze* | sim | cisco \ - | oki | wec | wrs | winbond) + 3100* \ + | 32* \ + | 3300* \ + | 3600* \ + | 7300* \ + | acorn \ + | altos* \ + | apollo \ + | apple \ + | atari \ + | att* \ + | axis \ + | be \ + | bull \ + | cbm \ + | ccur \ + | cisco \ + | commodore \ + | convergent* \ + | convex* \ + | cray \ + | crds \ + | dec* \ + | delta* \ + | dg \ + | digital \ + | dolphin \ + | encore* \ + | gould \ + | harris \ + | highlevel \ + | hitachi* \ + | hp \ + | ibm* \ + | intergraph \ + | isi* \ + | knuth \ + | masscomp \ + | microblaze* \ + | mips* \ + | motorola* \ + | ncr* \ + | news \ + | next \ + | ns \ + | oki \ + | omron* \ + | pc533* \ + | rebel \ + | rom68k \ + | rombug \ + | semi \ + | sequent* \ + | sgi* \ + | siemens \ + | sim \ + | sni \ + | sony* \ + | stratus \ + | sun \ + | sun[234]* \ + | tektronix \ + | tti* \ + | ultra \ + | unicom* \ + | wec \ + | winbond \ + | wrs) basic_machine=$field1-$field2 - os= + basic_os= + ;; + tock* | zephyr*) + basic_machine=$field1-unknown + basic_os=$field2 ;; *) basic_machine=$field1 - os=$field2 + basic_os=$field2 ;; esac ;; @@ -191,450 +279,431 @@ case $1 in case $field1 in 386bsd) basic_machine=i386-pc - os=bsd + basic_os=bsd ;; a29khif) basic_machine=a29k-amd - os=udi + basic_os=udi ;; adobe68k) basic_machine=m68010-adobe - os=scout + basic_os=scout ;; alliant) basic_machine=fx80-alliant - os= + basic_os= ;; altos | altos3068) basic_machine=m68k-altos - os= + basic_os= ;; am29k) basic_machine=a29k-none - os=bsd + basic_os=bsd ;; amdahl) basic_machine=580-amdahl - os=sysv + basic_os=sysv ;; amiga) basic_machine=m68k-unknown - os= + basic_os= ;; amigaos | amigados) basic_machine=m68k-unknown - os=amigaos + basic_os=amigaos ;; amigaunix | amix) basic_machine=m68k-unknown - os=sysv4 + basic_os=sysv4 ;; apollo68) basic_machine=m68k-apollo - os=sysv + basic_os=sysv ;; apollo68bsd) basic_machine=m68k-apollo - os=bsd + basic_os=bsd ;; aros) basic_machine=i386-pc - os=aros + basic_os=aros ;; aux) basic_machine=m68k-apple - os=aux + basic_os=aux ;; balance) basic_machine=ns32k-sequent - os=dynix + basic_os=dynix ;; blackfin) basic_machine=bfin-unknown - os=linux + basic_os=linux ;; cegcc) basic_machine=arm-unknown - os=cegcc - ;; - convex-c1) - basic_machine=c1-convex - os=bsd - ;; - convex-c2) - basic_machine=c2-convex - os=bsd - ;; - convex-c32) - basic_machine=c32-convex - os=bsd - ;; - convex-c34) - basic_machine=c34-convex - os=bsd - ;; - convex-c38) - basic_machine=c38-convex - os=bsd + basic_os=cegcc ;; cray) basic_machine=j90-cray - os=unicos + basic_os=unicos ;; crds | unos) basic_machine=m68k-crds - os= + basic_os= ;; da30) basic_machine=m68k-da30 - os= + basic_os= ;; decstation | pmax | pmin | dec3100 | decstatn) basic_machine=mips-dec - os= + basic_os= ;; delta88) basic_machine=m88k-motorola - os=sysv3 + basic_os=sysv3 ;; dicos) basic_machine=i686-pc - os=dicos + basic_os=dicos ;; djgpp) basic_machine=i586-pc - os=msdosdjgpp + basic_os=msdosdjgpp ;; ebmon29k) basic_machine=a29k-amd - os=ebmon + basic_os=ebmon ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson - os=ose + basic_os=ose ;; gmicro) basic_machine=tron-gmicro - os=sysv + basic_os=sysv ;; go32) basic_machine=i386-pc - os=go32 + basic_os=go32 ;; h8300hms) basic_machine=h8300-hitachi - os=hms + basic_os=hms ;; h8300xray) basic_machine=h8300-hitachi - os=xray + basic_os=xray ;; h8500hms) basic_machine=h8500-hitachi - os=hms + basic_os=hms ;; harris) basic_machine=m88k-harris - os=sysv3 + basic_os=sysv3 ;; - hp300) + hp300 | hp300hpux) basic_machine=m68k-hp + basic_os=hpux ;; hp300bsd) basic_machine=m68k-hp - os=bsd - ;; - hp300hpux) - basic_machine=m68k-hp - os=hpux + basic_os=bsd ;; hppaosf) basic_machine=hppa1.1-hp - os=osf + basic_os=osf ;; hppro) basic_machine=hppa1.1-hp - os=proelf + basic_os=proelf ;; i386mach) basic_machine=i386-mach - os=mach - ;; - vsta) - basic_machine=i386-pc - os=vsta + basic_os=mach ;; isi68 | isi) basic_machine=m68k-isi - os=sysv + basic_os=sysv ;; m68knommu) basic_machine=m68k-unknown - os=linux + basic_os=linux ;; magnum | m3230) basic_machine=mips-mips - os=sysv + basic_os=sysv ;; merlin) basic_machine=ns32k-utek - os=sysv + basic_os=sysv ;; mingw64) basic_machine=x86_64-pc - os=mingw64 + basic_os=mingw64 ;; mingw32) basic_machine=i686-pc - os=mingw32 + basic_os=mingw32 ;; mingw32ce) basic_machine=arm-unknown - os=mingw32ce + basic_os=mingw32ce ;; monitor) basic_machine=m68k-rom68k - os=coff + basic_os=coff ;; morphos) basic_machine=powerpc-unknown - os=morphos + basic_os=morphos ;; moxiebox) basic_machine=moxie-unknown - os=moxiebox + basic_os=moxiebox ;; msdos) basic_machine=i386-pc - os=msdos + basic_os=msdos ;; msys) basic_machine=i686-pc - os=msys + basic_os=msys ;; mvs) basic_machine=i370-ibm - os=mvs + basic_os=mvs ;; nacl) basic_machine=le32-unknown - os=nacl + basic_os=nacl ;; ncr3000) basic_machine=i486-ncr - os=sysv4 + basic_os=sysv4 ;; netbsd386) basic_machine=i386-pc - os=netbsd + basic_os=netbsd ;; netwinder) basic_machine=armv4l-rebel - os=linux + basic_os=linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony - os=newsos + basic_os=newsos ;; news1000) basic_machine=m68030-sony - os=newsos + basic_os=newsos ;; necv70) basic_machine=v70-nec - os=sysv + basic_os=sysv ;; nh3000) basic_machine=m68k-harris - os=cxux + basic_os=cxux ;; nh[45]000) basic_machine=m88k-harris - os=cxux + basic_os=cxux ;; nindy960) basic_machine=i960-intel - os=nindy + basic_os=nindy ;; mon960) basic_machine=i960-intel - os=mon960 + basic_os=mon960 ;; nonstopux) basic_machine=mips-compaq - os=nonstopux + basic_os=nonstopux ;; os400) basic_machine=powerpc-ibm - os=os400 + basic_os=os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson - os=ose + basic_os=ose ;; os68k) basic_machine=m68k-none - os=os68k + basic_os=os68k ;; paragon) basic_machine=i860-intel - os=osf + basic_os=osf ;; parisc) basic_machine=hppa-unknown - os=linux + basic_os=linux + ;; + psp) + basic_machine=mipsallegrexel-sony + basic_os=psp ;; pw32) basic_machine=i586-unknown - os=pw32 + basic_os=pw32 ;; rdos | rdos64) basic_machine=x86_64-pc - os=rdos + basic_os=rdos ;; rdos32) basic_machine=i386-pc - os=rdos + basic_os=rdos ;; rom68k) basic_machine=m68k-rom68k - os=coff + basic_os=coff ;; sa29200) basic_machine=a29k-amd - os=udi + basic_os=udi ;; sei) basic_machine=mips-sei - os=seiux + basic_os=seiux ;; sequent) basic_machine=i386-sequent - os= + basic_os= ;; sps7) basic_machine=m68k-bull - os=sysv2 + basic_os=sysv2 ;; st2000) basic_machine=m68k-tandem - os= + basic_os= ;; stratus) basic_machine=i860-stratus - os=sysv4 + basic_os=sysv4 ;; sun2) basic_machine=m68000-sun - os= + basic_os= ;; sun2os3) basic_machine=m68000-sun - os=sunos3 + basic_os=sunos3 ;; sun2os4) basic_machine=m68000-sun - os=sunos4 + basic_os=sunos4 ;; sun3) basic_machine=m68k-sun - os= + basic_os= ;; sun3os3) basic_machine=m68k-sun - os=sunos3 + basic_os=sunos3 ;; sun3os4) basic_machine=m68k-sun - os=sunos4 + basic_os=sunos4 ;; sun4) basic_machine=sparc-sun - os= + basic_os= ;; sun4os3) basic_machine=sparc-sun - os=sunos3 + basic_os=sunos3 ;; sun4os4) basic_machine=sparc-sun - os=sunos4 + basic_os=sunos4 ;; sun4sol2) basic_machine=sparc-sun - os=solaris2 + basic_os=solaris2 ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun - os= + basic_os= ;; sv1) basic_machine=sv1-cray - os=unicos + basic_os=unicos ;; symmetry) basic_machine=i386-sequent - os=dynix + basic_os=dynix ;; t3e) basic_machine=alphaev5-cray - os=unicos + basic_os=unicos ;; t90) basic_machine=t90-cray - os=unicos + basic_os=unicos ;; toad1) basic_machine=pdp10-xkl - os=tops20 + basic_os=tops20 ;; tpf) basic_machine=s390x-ibm - os=tpf + basic_os=tpf ;; udi29k) basic_machine=a29k-amd - os=udi + basic_os=udi ;; ultra3) basic_machine=a29k-nyu - os=sym1 + basic_os=sym1 ;; v810 | necv810) basic_machine=v810-nec - os=none + basic_os=none ;; vaxv) basic_machine=vax-dec - os=sysv + basic_os=sysv ;; vms) basic_machine=vax-dec - os=vms + basic_os=vms + ;; + vsta) + basic_machine=i386-pc + basic_os=vsta ;; vxworks960) basic_machine=i960-wrs - os=vxworks + basic_os=vxworks ;; vxworks68) basic_machine=m68k-wrs - os=vxworks + basic_os=vxworks ;; vxworks29k) basic_machine=a29k-wrs - os=vxworks + basic_os=vxworks ;; xbox) basic_machine=i686-pc - os=mingw32 + basic_os=mingw32 ;; ymp) basic_machine=ymp-cray - os=unicos + basic_os=unicos ;; *) basic_machine=$1 - os= + basic_os= ;; esac ;; @@ -686,27 +755,38 @@ case $basic_machine in bluegene*) cpu=powerpc vendor=ibm - os=cnk + basic_os=cnk ;; decsystem10* | dec10*) cpu=pdp10 vendor=dec - os=tops10 + basic_os=tops10 ;; decsystem20* | dec20*) cpu=pdp10 vendor=dec - os=tops20 + basic_os=tops20 ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) + delta | 3300 | delta-motorola | 3300-motorola | motorola-delta | motorola-3300) cpu=m68k vendor=motorola ;; - dpx2*) + # This used to be dpx2*, but that gets the RS6000-based + # DPX/20 and the x86-based DPX/2-100 wrong. See + # https://oldskool.silicium.org/stations/bull_dpx20.htm + # https://www.feb-patrimoine.com/english/bull_dpx2.htm + # https://www.feb-patrimoine.com/english/unix_and_bull.htm + dpx2 | dpx2[23]00 | dpx2[23]xx) cpu=m68k vendor=bull - os=sysv3 + ;; + dpx2100 | dpx21xx) + cpu=i386 + vendor=bull + ;; + dpx20) + cpu=rs6000 + vendor=bull ;; encore | umax | mmax) cpu=ns32k @@ -715,7 +795,7 @@ case $basic_machine in elxsi) cpu=elxsi vendor=elxsi - os=${os:-bsd} + basic_os=${basic_os:-bsd} ;; fx2800) cpu=i860 @@ -728,7 +808,7 @@ case $basic_machine in h3050r* | hiux*) cpu=hppa1.1 vendor=hitachi - os=hiuxwe2 + basic_os=hiuxwe2 ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) cpu=hppa1.0 @@ -771,36 +851,36 @@ case $basic_machine in i*86v32) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc - os=sysv32 + basic_os=sysv32 ;; i*86v4*) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc - os=sysv4 + basic_os=sysv4 ;; i*86v) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc - os=sysv + basic_os=sysv ;; i*86sol2) cpu=`echo "$1" | sed -e 's/86.*/86/'` vendor=pc - os=solaris2 + basic_os=solaris2 ;; j90 | j90-cray) cpu=j90 vendor=cray - os=${os:-unicos} + basic_os=${basic_os:-unicos} ;; iris | iris4d) cpu=mips vendor=sgi - case $os in + case $basic_os in irix*) ;; *) - os=irix4 + basic_os=irix4 ;; esac ;; @@ -811,28 +891,16 @@ case $basic_machine in *mint | mint[0-9]* | *MiNT | *MiNT[0-9]*) cpu=m68k vendor=atari - os=mint + basic_os=mint ;; news-3600 | risc-news) cpu=mips vendor=sony - os=newsos + basic_os=newsos ;; next | m*-next) cpu=m68k vendor=next - case $os in - openstep*) - ;; - nextstep*) - ;; - ns2*) - os=nextstep2 - ;; - *) - os=nextstep3 - ;; - esac ;; np1) cpu=np1 @@ -841,12 +909,12 @@ case $basic_machine in op50n-* | op60c-*) cpu=hppa1.1 vendor=oki - os=proelf + basic_os=proelf ;; pa-hitachi) cpu=hppa1.1 vendor=hitachi - os=hiuxwe2 + basic_os=hiuxwe2 ;; pbd) cpu=sparc @@ -883,12 +951,12 @@ case $basic_machine in sde) cpu=mipsisa32 vendor=sde - os=${os:-elf} + basic_os=${basic_os:-elf} ;; simso-wrs) cpu=sparclite vendor=wrs - os=vxworks + basic_os=vxworks ;; tower | tower-32) cpu=m68k @@ -905,7 +973,7 @@ case $basic_machine in w89k-*) cpu=hppa1.1 vendor=winbond - os=proelf + basic_os=proelf ;; none) cpu=none @@ -921,12 +989,13 @@ case $basic_machine in ;; *-*) - # shellcheck disable=SC2162 + saved_IFS=$IFS IFS="-" read cpu vendor <<EOF $basic_machine EOF + IFS=$saved_IFS ;; - # We use `pc' rather than `unknown' + # We use 'pc' rather than 'unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) @@ -954,15 +1023,19 @@ unset -v basic_machine # Decode basic machines in the full and proper CPU-Company form. case $cpu-$vendor in - # Here we handle the default manufacturer of certain CPU types in canonical form. It is in - # some cases the only manufacturer, in others, it is the most popular. + # Here we handle the default manufacturer of certain CPU types in canonical form. + # It is in some cases the only manufacturer, in others, it is the most popular. + c[12]-convex | c[12]-unknown | c3[248]-convex | c3[248]-unknown) + vendor=convex + basic_os=${basic_os:-bsd} + ;; craynv-unknown) vendor=cray - os=${os:-unicosmp} + basic_os=${basic_os:-unicosmp} ;; c90-unknown | c90-cray) vendor=cray - os=${os:-unicos} + basic_os=${basic_os:-unicos} ;; fx80-unknown) vendor=alliant @@ -1003,10 +1076,33 @@ case $cpu-$vendor in ;; # Here we normalize CPU types with a missing or matching vendor - dpx20-unknown | dpx20-bull) - cpu=rs6000 - vendor=bull - os=${os:-bosx} + armh-unknown | armh-alt) + cpu=armv7l + vendor=alt + basic_os=${basic_os:-linux-gnueabihf} + ;; + + # Normalized CPU+vendor pairs that imply an OS, if not otherwise specified + m68k-isi) + basic_os=${basic_os:-sysv} + ;; + m68k-sony) + basic_os=${basic_os:-newsos} + ;; + m68k-tektronix) + basic_os=${basic_os:-bsd} + ;; + m88k-harris) + basic_os=${basic_os:-sysv3} + ;; + i386-bull | m68k-bull) + basic_os=${basic_os:-sysv3} + ;; + rs6000-bull) + basic_os=${basic_os:-bosx} + ;; + mips-sni) + basic_os=${basic_os:-sysv4} ;; # Here we normalize CPU types irrespective of the vendor @@ -1015,7 +1111,7 @@ case $cpu-$vendor in ;; blackfin-*) cpu=bfin - os=linux + basic_os=${basic_os:-linux} ;; c54x-*) cpu=tic54x @@ -1028,7 +1124,7 @@ case $cpu-$vendor in ;; e500v[12]-*) cpu=powerpc - os=$os"spe" + basic_os=${basic_os}"spe" ;; mips3*-*) cpu=mips64 @@ -1038,7 +1134,7 @@ case $cpu-$vendor in ;; m68knommu-*) cpu=m68k - os=linux + basic_os=${basic_os:-linux} ;; m9s12z-* | m68hcs12z-* | hcs12z-* | s12z-*) cpu=s12z @@ -1048,12 +1144,12 @@ case $cpu-$vendor in ;; parisc-*) cpu=hppa - os=linux + basic_os=${basic_os:-linux} ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) cpu=i586 ;; - pentiumpro-* | p6-* | 6x86-* | athlon-* | athalon_*-*) + pentiumpro-* | p6-* | 6x86-* | athlon-* | athlon_*-*) cpu=i686 ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) @@ -1062,9 +1158,6 @@ case $cpu-$vendor in pentium4-*) cpu=i786 ;; - pc98-*) - cpu=i386 - ;; ppc-* | ppcbe-*) cpu=powerpc ;; @@ -1098,17 +1191,17 @@ case $cpu-$vendor in tx39el-*) cpu=mipstx39el ;; - x64-*) - cpu=x86_64 - ;; xscale-* | xscalee[bl]-*) cpu=`echo "$cpu" | sed 's/^xscale/arm/'` ;; + arm64-* | aarch64le-* | arm64_32-*) + cpu=aarch64 + ;; # Recognize the canonical CPU Types that limit and/or modify the # company names they are paired with. cr16-*) - os=${os:-elf} + basic_os=${basic_os:-elf} ;; crisv32-* | etraxfs*-*) cpu=crisv32 @@ -1119,7 +1212,7 @@ case $cpu-$vendor in vendor=axis ;; crx-*) - os=${os:-elf} + basic_os=${basic_os:-elf} ;; neo-tandem) cpu=neo @@ -1141,123 +1234,244 @@ case $cpu-$vendor in cpu=nsx vendor=tandem ;; - s390-*) - cpu=s390 - vendor=ibm - ;; - s390x-*) - cpu=s390x - vendor=ibm + mipsallegrexel-sony) + cpu=mipsallegrexel + vendor=sony ;; tile*-*) - os=${os:-linux-gnu} + basic_os=${basic_os:-linux-gnu} ;; *) # Recognize the canonical CPU types that are allowed with any # company name. case $cpu in - 1750a | 580 \ + 1750a \ + | 580 \ + | [cjt]90 \ | a29k \ - | aarch64 | aarch64_be \ + | aarch64 \ + | aarch64_be \ + | aarch64c \ | abacus \ - | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \ - | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \ - | alphapca5[67] | alpha64pca5[67] \ + | alpha \ + | alpha64 \ + | alpha64ev56 \ + | alpha64ev6[78] \ + | alpha64ev[4-8] \ + | alpha64pca5[67] \ + | alphaev56 \ + | alphaev6[78] \ + | alphaev[4-8] \ + | alphapca5[67] \ | am33_2.0 \ | amdgcn \ - | arc | arceb \ - | arm | arm[lb]e | arme[lb] | armv* \ - | avr | avr32 \ + | arc \ + | arc32 \ + | arc64 \ + | arceb \ + | arm \ + | arm64e \ + | arm64ec \ + | arm[lb]e \ + | arme[lb] \ + | armv* \ | asmjs \ + | avr \ + | avr32 \ | ba \ - | be32 | be64 \ - | bfin | bpf | bs2000 \ - | c[123]* | c30 | [cjt]90 | c4x \ - | c8051 | clipper | craynv | csky | cydra \ - | d10v | d30v | dlx | dsp16xx \ - | e2k | elxsi | epiphany \ - | f30[01] | f700 | fido | fr30 | frv | ft32 | fx80 \ - | h8300 | h8500 \ - | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ + | be32 \ + | be64 \ + | bfin \ + | bpf \ + | bs2000 \ + | c30 \ + | c4x \ + | c8051 \ + | c[123]* \ + | clipper \ + | craynv \ + | csky \ + | cydra \ + | d10v \ + | d30v \ + | dlx \ + | dsp16xx \ + | e2k \ + | elxsi \ + | epiphany \ + | f30[01] \ + | f700 \ + | fido \ + | fr30 \ + | frv \ + | ft32 \ + | fx80 \ + | h8300 \ + | h8500 \ | hexagon \ - | i370 | i*86 | i860 | i960 | ia16 | ia64 \ - | ip2k | iq2000 \ + | hppa \ + | hppa1.[01] \ + | hppa2.0 \ + | hppa2.0[nw] \ + | hppa64 \ + | i*86 \ + | i370 \ + | i860 \ + | i960 \ + | ia16 \ + | ia64 \ + | intelgt \ + | ip2k \ + | iq2000 \ + | javascript \ | k1om \ - | le32 | le64 \ + | kvx \ + | le32 \ + | le64 \ | lm32 \ - | m32c | m32r | m32rle \ - | m5200 | m68000 | m680[012346]0 | m68360 | m683?2 | m68k \ - | m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x \ - | m88110 | m88k | maxq | mb | mcore | mep | metag \ - | microblaze | microblazeel \ - | mips | mipsbe | mipseb | mipsel | mipsle \ - | mips16 \ - | mips64 | mips64eb | mips64el \ - | mips64octeon | mips64octeonel \ - | mips64orion | mips64orionel \ - | mips64r5900 | mips64r5900el \ - | mips64vr | mips64vrel \ - | mips64vr4100 | mips64vr4100el \ - | mips64vr4300 | mips64vr4300el \ - | mips64vr5000 | mips64vr5000el \ - | mips64vr5900 | mips64vr5900el \ - | mipsisa32 | mipsisa32el \ - | mipsisa32r2 | mipsisa32r2el \ - | mipsisa32r6 | mipsisa32r6el \ - | mipsisa64 | mipsisa64el \ - | mipsisa64r2 | mipsisa64r2el \ - | mipsisa64r6 | mipsisa64r6el \ - | mipsisa64sb1 | mipsisa64sb1el \ - | mipsisa64sr71k | mipsisa64sr71kel \ - | mipsr5900 | mipsr5900el \ - | mipstx39 | mipstx39el \ + | loongarch32 \ + | loongarch64 \ + | m32c \ + | m32r \ + | m32rle \ + | m5200 \ + | m68000 \ + | m680[012346]0 \ + | m6811 \ + | m6812 \ + | m68360 \ + | m683?2 \ + | m68hc11 \ + | m68hc12 \ + | m68hcs12x \ + | m68k \ + | m88110 \ + | m88k \ + | maxq \ + | mb \ + | mcore \ + | mep \ + | metag \ + | microblaze \ + | microblazeel \ + | mips* \ | mmix \ - | mn10200 | mn10300 \ + | mn10200 \ + | mn10300 \ | moxie \ - | mt \ | msp430 \ - | nds32 | nds32le | nds32be \ + | mt \ + | nanomips* \ + | nds32 \ + | nds32be \ + | nds32le \ | nfp \ - | nios | nios2 | nios2eb | nios2el \ - | none | np1 | ns16k | ns32k | nvptx \ + | nios \ + | nios2 \ + | nios2eb \ + | nios2el \ + | none \ + | np1 \ + | ns16k \ + | ns32k \ + | nvptx \ | open8 \ | or1k* \ | or32 \ | orion \ + | pdp10 \ + | pdp11 \ | picochip \ - | pdp10 | pdp11 | pj | pjl | pn | power \ - | powerpc | powerpc64 | powerpc64le | powerpcle | powerpcspe \ + | pj \ + | pjl \ + | pn \ + | power \ + | powerpc \ + | powerpc64 \ + | powerpc64le \ + | powerpcle \ + | powerpcspe \ | pru \ | pyramid \ - | riscv | riscv32 | riscv64 \ - | rl78 | romp | rs6000 | rx \ + | riscv \ + | riscv32 \ + | riscv32be \ + | riscv64 \ + | riscv64be \ + | rl78 \ + | romp \ + | rs6000 \ + | rx \ + | s390 \ + | s390x \ | score \ - | sh | shl \ - | sh[1234] | sh[24]a | sh[24]ae[lb] | sh[23]e | she[lb] | sh[lb]e \ - | sh[1234]e[lb] | sh[12345][lb]e | sh[23]ele | sh64 | sh64le \ - | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet \ + | sh \ + | sh64 \ + | sh64le \ + | sh[12345][lb]e \ + | sh[1234] \ + | sh[1234]e[lb] \ + | sh[23]e \ + | sh[23]ele \ + | sh[24]a \ + | sh[24]ae[lb] \ + | sh[lb]e \ + | she[lb] \ + | shl \ + | sparc \ + | sparc64 \ + | sparc64b \ + | sparc64v \ + | sparc86x \ + | sparclet \ | sparclite \ - | sparcv8 | sparcv9 | sparcv9b | sparcv9v | sv1 | sx* \ + | sparcv8 \ + | sparcv9 \ + | sparcv9b \ + | sparcv9v \ | spu \ + | sv1 \ + | sx* \ | tahoe \ - | tic30 | tic4x | tic54x | tic55x | tic6x | tic80 \ + | thumbv7* \ + | tic30 \ + | tic4x \ + | tic54x \ + | tic55x \ + | tic6x \ + | tic80 \ | tron \ | ubicom32 \ - | v70 | v850 | v850e | v850e1 | v850es | v850e2 | v850e2v3 \ + | v70 \ + | v810 \ + | v850 \ + | v850e \ + | v850e1 \ + | v850e2 \ + | v850e2v3 \ + | v850es \ | vax \ + | vc4 \ | visium \ | w65 \ - | wasm32 | wasm64 \ + | wasm32 \ + | wasm64 \ | we32k \ - | x86 | x86_64 | xc16x | xgate | xps100 \ - | xstormy16 | xtensa* \ + | x86 \ + | x86_64 \ + | xc16x \ + | xgate \ + | xps100 \ + | xstormy16 \ + | xtensa* \ | ymp \ - | z8k | z80) + | z80 \ + | z8k) ;; *) - echo Invalid configuration \`"$1"\': machine \`"$cpu-$vendor"\' not recognized 1>&2 + echo "Invalid configuration '$1': machine '$cpu-$vendor' not recognized" 1>&2 exit 1 ;; esac @@ -1278,8 +1492,57 @@ esac # Decode manufacturer-specific aliases for certain operating systems. -if [ x$os != x ] +if test x"$basic_os" != x then + +# First recognize some ad-hoc cases, or perhaps split kernel-os, or else just +# set os. +obj= +case $basic_os in + gnu/linux*) + kernel=linux + os=`echo "$basic_os" | sed -e 's|gnu/linux|gnu|'` + ;; + os2-emx) + kernel=os2 + os=`echo "$basic_os" | sed -e 's|os2-emx|emx|'` + ;; + nto-qnx*) + kernel=nto + os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'` + ;; + *-*) + saved_IFS=$IFS + IFS="-" read kernel os <<EOF +$basic_os +EOF + IFS=$saved_IFS + ;; + # Default OS when just kernel was specified + nto*) + kernel=nto + os=`echo "$basic_os" | sed -e 's|nto|qnx|'` + ;; + ironclad*) + kernel=ironclad + os=`echo "$basic_os" | sed -e 's|ironclad|mlibc|'` + ;; + linux*) + kernel=linux + os=`echo "$basic_os" | sed -e 's|linux|gnu|'` + ;; + managarm*) + kernel=managarm + os=`echo "$basic_os" | sed -e 's|managarm|mlibc|'` + ;; + *) + kernel= + os=$basic_os + ;; +esac + +# Now, normalize the OS (knowing we just have one component, it's not a kernel, +# etc.) case $os in # First match some system type aliases that might get confused # with valid system types. @@ -1291,7 +1554,7 @@ case $os in os=cnk ;; solaris1 | solaris1.*) - os=`echo $os | sed -e 's|solaris1|sunos4|'` + os=`echo "$os" | sed -e 's|solaris1|sunos4|'` ;; solaris) os=solaris2 @@ -1299,8 +1562,22 @@ case $os in unixware*) os=sysv4.2uw ;; - gnu/linux*) - os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` + # The marketing names for NeXT's operating systems were + # NeXTSTEP, NeXTSTEP 2, OpenSTEP 3, OpenSTEP 4. 'openstep' is + # mapped to 'openstep3', but 'openstep1' and 'openstep2' are + # mapped to 'nextstep' and 'nextstep2', consistent with the + # treatment of SunOS/Solaris. + ns | ns1 | nextstep | nextstep1 | openstep1) + os=nextstep + ;; + ns2 | nextstep2 | openstep2) + os=nextstep2 + ;; + ns3 | nextstep3 | openstep | openstep3) + os=openstep3 + ;; + ns4 | nextstep4 | openstep4) + os=openstep4 ;; # es1800 is here to avoid being matched by es* (a different OS) es1800*) @@ -1323,12 +1600,9 @@ case $os in os=sco3.2v4 ;; sco3.2.[4-9]*) - os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` + os=`echo "$os" | sed -e 's/sco3.2./sco3.2v/'` ;; - sco3.2v[4-9]* | sco5v6*) - # Don't forget version if it is 3.2v4 or newer. - ;; - scout) + sco*v* | scout) # Don't match below ;; sco*) @@ -1337,77 +1611,25 @@ case $os in psos*) os=psos ;; - # Now accept the basic system types. - # The portable systems comes first. - # Each alternative MUST end in a * to match a version number. - # sysv* is not here because it comes later, after sysvr4. - gnu* | bsd* | mach* | minix* | genix* | ultrix* | irix* \ - | *vms* | esix* | aix* | cnk* | sunos | sunos[34]*\ - | hpux* | unos* | osf* | luna* | dgux* | auroraux* | solaris* \ - | sym* | kopensolaris* | plan9* \ - | amigaos* | amigados* | msdos* | newsos* | unicos* | aof* \ - | aos* | aros* | cloudabi* | sortix* \ - | nindy* | vxsim* | vxworks* | ebmon* | hms* | mvs* \ - | clix* | riscos* | uniplus* | iris* | isc* | rtu* | xenix* \ - | knetbsd* | mirbsd* | netbsd* \ - | bitrig* | openbsd* | solidbsd* | libertybsd* \ - | ekkobsd* | kfreebsd* | freebsd* | riscix* | lynxos* \ - | bosx* | nextstep* | cxux* | aout* | elf* | oabi* \ - | ptx* | coff* | ecoff* | winnt* | domain* | vsta* \ - | udi* | eabi* | lites* | ieee* | go32* | aux* | hcos* \ - | chorusrdb* | cegcc* | glidix* \ - | cygwin* | msys* | pe* | moss* | proelf* | rtems* \ - | midipix* | mingw32* | mingw64* | linux-gnu* | linux-android* \ - | linux-newlib* | linux-musl* | linux-uclibc* \ - | uxpv* | beos* | mpeix* | udk* | moxiebox* \ - | interix* | uwin* | mks* | rhapsody* | darwin* \ - | openstep* | oskit* | conix* | pw32* | nonstopux* \ - | storm-chaos* | tops10* | tenex* | tops20* | its* \ - | os2* | vos* | palmos* | uclinux* | nucleus* \ - | morphos* | superux* | rtmk* | windiss* \ - | powermax* | dnix* | nx6 | nx7 | sei* | dragonfly* \ - | skyos* | haiku* | rdos* | toppers* | drops* | es* \ - | onefs* | tirtos* | phoenix* | fuchsia* | redox* | bme* \ - | midnightbsd* | amdhsa* | unleashed* | emscripten* | wasi*) - # Remember, each alternative MUST END IN *, to match a version number. - ;; qnx*) - case $cpu in - x86 | i*86) - ;; - *) - os=nto-$os - ;; - esac + os=qnx ;; hiux*) os=hiuxwe2 ;; - nto-qnx*) - ;; - nto*) - os=`echo $os | sed -e 's|nto|nto-qnx|'` - ;; - sim | xray | os68k* | v88r* \ - | windows* | osx | abug | netware* | os9* \ - | macos* | mpw* | magic* | mmixware* | mon960* | lnews*) - ;; - linux-dietlibc) - os=linux-dietlibc - ;; - linux*) - os=`echo $os | sed -e 's|linux|linux-gnu|'` - ;; lynx*178) os=lynxos178 ;; lynx*5) os=lynxos5 ;; + lynxos*) + # don't get caught up in next wildcard + ;; lynx*) os=lynxos ;; - mac*) + mac[0-9]*) os=`echo "$os" | sed -e 's|mac|macos|'` ;; opened*) @@ -1427,6 +1649,7 @@ case $os in ;; utek*) os=bsd + vendor=`echo "$vendor" | sed -e 's|^unknown$|tektronix|'` ;; dynix*) os=bsd @@ -1443,24 +1666,25 @@ case $os in 386bsd) os=bsd ;; - ctix* | uts*) + ctix*) os=sysv + vendor=`echo "$vendor" | sed -e 's|^unknown$|convergent|'` ;; - nova*) - os=rtmk-nova - ;; - ns2) - os=nextstep2 + uts*) + os=sysv ;; - nsk*) - os=nsk + nova*) + kernel=rtmk + os=nova ;; # Preserve the version number of sinix5. sinix5.*) - os=`echo $os | sed -e 's|sinix|sysv|'` + os=`echo "$os" | sed -e 's|sinix|sysv|'` + vendor=`echo "$vendor" | sed -e 's|^unknown$|sni|'` ;; sinix*) os=sysv4 + vendor=`echo "$vendor" | sed -e 's|^unknown$|sni|'` ;; tpf*) os=tpf @@ -1480,18 +1704,12 @@ case $os in sysvr4) os=sysv4 ;; - # This must come after sysvr4. - sysv*) - ;; ose*) os=ose ;; *mint | mint[0-9]* | *MiNT | MiNT[0-9]*) os=mint ;; - zvmoe) - os=zvmoe - ;; dicos*) os=dicos ;; @@ -1504,23 +1722,21 @@ case $os in os=eabi ;; *) - os=elf + os= + obj=elf ;; esac ;; - nacl*) - ;; - ios) - ;; - none) - ;; - *-eabi) + aout* | coff* | elf* | pe*) + # These are machine code file formats, not OSes + obj=$os + os= ;; *) - echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2 - exit 1 + # No normalization, but not necessarily accepted, that comes below. ;; esac + else # Here we handle the default operating systems that come with various machines. @@ -1533,42 +1749,54 @@ else # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. +kernel= +obj= case $cpu-$vendor in score-*) - os=elf + os= + obj=elf ;; spu-*) - os=elf + os= + obj=elf ;; *-acorn) os=riscix1.2 ;; arm*-rebel) - os=linux + kernel=linux + os=gnu ;; arm*-semi) - os=aout + os= + obj=aout ;; c4x-* | tic4x-*) - os=coff + os= + obj=coff ;; c8051-*) - os=elf + os= + obj=elf ;; clipper-intergraph) os=clix ;; hexagon-*) - os=elf + os= + obj=elf ;; tic54x-*) - os=coff + os= + obj=coff ;; tic55x-*) - os=coff + os= + obj=coff ;; tic6x-*) - os=coff + os= + obj=coff ;; # This must come before the *-dec entry. pdp10-*) @@ -1590,28 +1818,43 @@ case $cpu-$vendor in os=sunos3 ;; m68*-cisco) - os=aout + os= + obj=aout ;; mep-*) - os=elf + os= + obj=elf + ;; + # The -sgi and -siemens entries must be before the mips- entry + # or we get the wrong os. + *-sgi) + os=irix + ;; + *-siemens) + os=sysv4 ;; mips*-cisco) - os=elf + os= + obj=elf ;; - mips*-*) - os=elf + mips*-*|nanomips*-*) + os= + obj=elf ;; or32-*) - os=coff + os= + obj=coff ;; - *-tti) # must be before sparc entry or we get the wrong os. + # This must be before the sparc-* entry or we get the wrong os. + *-tti) os=sysv3 ;; sparc-* | *-sun) os=sunos4.1.1 ;; pru-*) - os=elf + os= + obj=elf ;; *-be) os=beos @@ -1635,7 +1878,7 @@ case $cpu-$vendor in os=hpux ;; *-hitachi) - os=hiux + os=hiuxwe2 ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=sysv @@ -1679,12 +1922,6 @@ case $cpu-$vendor in *-encore) os=bsd ;; - *-sgi) - os=irix - ;; - *-siemens) - os=sysv4 - ;; *-masscomp) os=rtu ;; @@ -1692,10 +1929,12 @@ case $cpu-$vendor in os=uxpv ;; *-rom68k) - os=coff + os= + obj=coff ;; *-*bug) - os=coff + os= + obj=coff ;; *-apple) os=macos @@ -1710,89 +1949,416 @@ case $cpu-$vendor in os=none ;; esac + fi +# Now, validate our (potentially fixed-up) individual pieces (OS, OBJ). + +case $os in + # Sometimes we do "kernel-libc", so those need to count as OSes. + llvm* | musl* | newlib* | relibc* | uclibc*) + ;; + # Likewise for "kernel-abi" + eabi* | gnueabi*) + ;; + # VxWorks passes extra cpu info in the 4th filed. + simlinux | simwindows | spe) + ;; + # See `case $cpu-$os` validation below + ghcjs) + ;; + # Now accept the basic system types. + # Each alternative MUST end in a * to match a version number. + abug \ + | aix* \ + | amdhsa* \ + | amigados* \ + | amigaos* \ + | android* \ + | aof* \ + | aos* \ + | aros* \ + | atheos* \ + | auroraux* \ + | aux* \ + | banan_os* \ + | beos* \ + | bitrig* \ + | bme* \ + | bosx* \ + | bsd* \ + | cegcc* \ + | chorusos* \ + | chorusrdb* \ + | clix* \ + | cloudabi* \ + | cnk* \ + | conix* \ + | cos* \ + | cxux* \ + | cygwin* \ + | darwin* \ + | dgux* \ + | dicos* \ + | dnix* \ + | domain* \ + | dragonfly* \ + | drops* \ + | ebmon* \ + | ecoff* \ + | ekkobsd* \ + | emscripten* \ + | emx* \ + | es* \ + | fiwix* \ + | freebsd* \ + | fuchsia* \ + | genix* \ + | genode* \ + | glidix* \ + | gnu* \ + | go32* \ + | haiku* \ + | hcos* \ + | hiux* \ + | hms* \ + | hpux* \ + | ieee* \ + | interix* \ + | ios* \ + | iris* \ + | irix* \ + | isc* \ + | its* \ + | l4re* \ + | libertybsd* \ + | lites* \ + | lnews* \ + | luna* \ + | lynxos* \ + | mach* \ + | macos* \ + | magic* \ + | mbr* \ + | midipix* \ + | midnightbsd* \ + | mingw32* \ + | mingw64* \ + | minix* \ + | mint* \ + | mirbsd* \ + | mks* \ + | mlibc* \ + | mmixware* \ + | mon960* \ + | morphos* \ + | moss* \ + | moxiebox* \ + | mpeix* \ + | mpw* \ + | msdos* \ + | msys* \ + | mvs* \ + | nacl* \ + | netbsd* \ + | netware* \ + | newsos* \ + | nextstep* \ + | nindy* \ + | nonstopux* \ + | nova* \ + | nsk* \ + | nucleus* \ + | nx6 \ + | nx7 \ + | oabi* \ + | ohos* \ + | onefs* \ + | openbsd* \ + | openedition* \ + | openstep* \ + | os108* \ + | os2* \ + | os400* \ + | os68k* \ + | os9* \ + | ose* \ + | osf* \ + | oskit* \ + | osx* \ + | palmos* \ + | phoenix* \ + | plan9* \ + | powermax* \ + | powerunix* \ + | proelf* \ + | psos* \ + | psp* \ + | ptx* \ + | pw32* \ + | qnx* \ + | rdos* \ + | redox* \ + | rhapsody* \ + | riscix* \ + | riscos* \ + | rtems* \ + | rtmk* \ + | rtu* \ + | scout* \ + | secbsd* \ + | sei* \ + | serenity* \ + | sim* \ + | skyos* \ + | solaris* \ + | solidbsd* \ + | sortix* \ + | storm-chaos* \ + | sunos \ + | sunos[34]* \ + | superux* \ + | syllable* \ + | sym* \ + | sysv* \ + | tenex* \ + | tirtos* \ + | tock* \ + | toppers* \ + | tops10* \ + | tops20* \ + | tpf* \ + | tvos* \ + | twizzler* \ + | uclinux* \ + | udi* \ + | udk* \ + | ultrix* \ + | unicos* \ + | uniplus* \ + | unleashed* \ + | unos* \ + | uwin* \ + | uxpv* \ + | v88r* \ + |*vms* \ + | vos* \ + | vsta* \ + | vxsim* \ + | vxworks* \ + | wasi* \ + | watchos* \ + | wince* \ + | windiss* \ + | windows* \ + | winnt* \ + | xenix* \ + | xray* \ + | zephyr* \ + | zvmoe* ) + ;; + # This one is extra strict with allowed versions + sco3.2v2 | sco3.2v[4-9]* | sco5v6*) + # Don't forget version if it is 3.2v4 or newer. + ;; + # This refers to builds using the UEFI calling convention + # (which depends on the architecture) and PE file format. + # Note that this is both a different calling convention and + # different file format than that of GNU-EFI + # (x86_64-w64-mingw32). + uefi) + ;; + none) + ;; + kernel* | msvc* ) + # Restricted further below + ;; + '') + if test x"$obj" = x + then + echo "Invalid configuration '$1': Blank OS only allowed with explicit machine code file format" 1>&2 + fi + ;; + *) + echo "Invalid configuration '$1': OS '$os' not recognized" 1>&2 + exit 1 + ;; +esac + +case $obj in + aout* | coff* | elf* | pe*) + ;; + '') + # empty is fine + ;; + *) + echo "Invalid configuration '$1': Machine code format '$obj' not recognized" 1>&2 + exit 1 + ;; +esac + +# Here we handle the constraint that a (synthetic) cpu and os are +# valid only in combination with each other and nowhere else. +case $cpu-$os in + # The "javascript-unknown-ghcjs" triple is used by GHC; we + # accept it here in order to tolerate that, but reject any + # variations. + javascript-ghcjs) + ;; + javascript-* | *-ghcjs) + echo "Invalid configuration '$1': cpu '$cpu' is not valid with os '$os$obj'" 1>&2 + exit 1 + ;; +esac + +# As a final step for OS-related things, validate the OS-kernel combination +# (given a valid OS), if there is a kernel. +case $kernel-$os-$obj in + linux-gnu*- | linux-android*- | linux-dietlibc*- | linux-llvm*- \ + | linux-mlibc*- | linux-musl*- | linux-newlib*- \ + | linux-relibc*- | linux-uclibc*- | linux-ohos*- ) + ;; + uclinux-uclibc*- | uclinux-gnu*- ) + ;; + ironclad-mlibc*-) + ;; + managarm-mlibc*- | managarm-kernel*- ) + ;; + windows*-msvc*-) + ;; + -dietlibc*- | -llvm*- | -mlibc*- | -musl*- | -newlib*- | -relibc*- \ + | -uclibc*- ) + # These are just libc implementations, not actual OSes, and thus + # require a kernel. + echo "Invalid configuration '$1': libc '$os' needs explicit kernel." 1>&2 + exit 1 + ;; + -kernel*- ) + echo "Invalid configuration '$1': '$os' needs explicit kernel." 1>&2 + exit 1 + ;; + *-kernel*- ) + echo "Invalid configuration '$1': '$kernel' does not support '$os'." 1>&2 + exit 1 + ;; + *-msvc*- ) + echo "Invalid configuration '$1': '$os' needs 'windows'." 1>&2 + exit 1 + ;; + kfreebsd*-gnu*- | knetbsd*-gnu*- | netbsd*-gnu*- | kopensolaris*-gnu*-) + ;; + vxworks-simlinux- | vxworks-simwindows- | vxworks-spe-) + ;; + nto-qnx*-) + ;; + os2-emx-) + ;; + rtmk-nova-) + ;; + *-eabi*- | *-gnueabi*-) + ;; + ios*-simulator- | tvos*-simulator- | watchos*-simulator- ) + ;; + none--*) + # None (no kernel, i.e. freestanding / bare metal), + # can be paired with an machine code file format + ;; + -*-) + # Blank kernel with real OS is always fine. + ;; + --*) + # Blank kernel and OS with real machine code file format is always fine. + ;; + *-*-*) + echo "Invalid configuration '$1': Kernel '$kernel' not known to work with OS '$os'." 1>&2 + exit 1 + ;; +esac + # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. case $vendor in unknown) - case $os in - riscix*) + case $cpu-$os in + *-riscix*) vendor=acorn ;; - sunos*) + *-sunos* | *-solaris*) vendor=sun ;; - cnk*|-aix*) + *-cnk* | *-aix*) vendor=ibm ;; - beos*) + *-beos*) vendor=be ;; - hpux*) + *-hpux*) vendor=hp ;; - mpeix*) + *-mpeix*) vendor=hp ;; - hiux*) + *-hiux*) vendor=hitachi ;; - unos*) + *-unos*) vendor=crds ;; - dgux*) + *-dgux*) vendor=dg ;; - luna*) + *-luna*) vendor=omron ;; - genix*) + *-genix*) vendor=ns ;; - clix*) + *-clix*) vendor=intergraph ;; - mvs* | opened*) + *-mvs* | *-opened*) + vendor=ibm + ;; + *-os400*) vendor=ibm ;; - os400*) + s390-* | s390x-*) vendor=ibm ;; - ptx*) + *-ptx*) vendor=sequent ;; - tpf*) + *-tpf*) vendor=ibm ;; - vxsim* | vxworks* | windiss*) + *-vxsim* | *-vxworks* | *-windiss*) vendor=wrs ;; - aux*) + *-aux*) vendor=apple ;; - hms*) + *-hms*) vendor=hitachi ;; - mpw* | macos*) + *-mpw* | *-macos*) vendor=apple ;; - *mint | mint[0-9]* | *MiNT | MiNT[0-9]*) + *-*mint | *-mint[0-9]* | *-*MiNT | *-MiNT[0-9]*) vendor=atari ;; - vos*) + *-vos*) vendor=stratus ;; esac ;; esac -echo "$cpu-$vendor-$os" +echo "$cpu-$vendor${kernel:+-$kernel}${os:+-$os}${obj:+-$obj}" exit # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "timestamp='" -# time-stamp-format: "%:y-%02m-%02d" +# time-stamp-format: "%Y-%02m-%02d" # time-stamp-end: "'" # End: diff --git a/subprojects/libsodium/build-aux/depcomp b/subprojects/libsodium/build-aux/depcomp @@ -1,9 +1,9 @@ #! /bin/sh # depcomp - compile a program generating dependencies as side-effects -scriptversion=2018-03-07.03; # UTC +scriptversion=2025-06-18.21; # UTC -# Copyright (C) 1999-2018 Free Software Foundation, Inc. +# Copyright (C) 1999-2025 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -47,11 +47,13 @@ Environment variables: libtool Whether libtool is used (yes/no). Report bugs to <bug-automake@gnu.org>. +GNU Automake home page: <https://www.gnu.org/software/automake/>. +General help using GNU software: <https://www.gnu.org/gethelp/>. EOF exit $? ;; -v | --v*) - echo "depcomp $scriptversion" + echo "depcomp (GNU Automake) $scriptversion" exit $? ;; esac @@ -113,7 +115,6 @@ nl=' # These definitions help. upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ lower=abcdefghijklmnopqrstuvwxyz -digits=0123456789 alpha=${upper}${lower} if test -z "$depmode" || test -z "$source" || test -z "$object"; then @@ -128,7 +129,7 @@ tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" -# Avoid interferences from the environment. +# Avoid interference from the environment. gccflag= dashmflag= # Some modes work just like other modes, but use different flags. We @@ -198,8 +199,8 @@ gcc3) ;; gcc) -## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. -## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. +## Note that this doesn't just cater to obsolete pre-3.x GCC compilers. +## but also to in-use compilers like IBM xlc/xlC and the HP C compiler. ## (see the conditional assignment to $gccflag above). ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: @@ -783,9 +784,9 @@ exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-format: "%Y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: diff --git a/subprojects/libsodium/build-aux/install-sh b/subprojects/libsodium/build-aux/install-sh @@ -1,7 +1,7 @@ #!/bin/sh # install - install a program, script, or datafile -scriptversion=2018-03-11.20; # UTC +scriptversion=2025-06-18.21; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the @@ -69,6 +69,11 @@ posix_mkdir= # Desired mode of installed file. mode=0755 +# Create dirs (including intermediate dirs) using mode 755. +# This is like GNU 'install' as of coreutils 8.32 (2020). +mkdir_umask=22 + +backupsuffix= chgrpcmd= chmodcmd=$chmodprog chowncmd= @@ -99,19 +104,29 @@ Options: --version display version info and exit. -c (ignored) - -C install only if different (preserve the last data modification time) + -C install only if different (preserve data modification time) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. + -p pass -p to $cpprog. -s $stripprog installed files. + -S SUFFIX attempt to back up existing files, with suffix SUFFIX. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG -" + +By default, rm is invoked with -f; when overridden with RMPROG, +it's up to you to specify -f if you want it. + +If -S is not specified, no backups are attempted. + +Report bugs to <bug-automake@gnu.org>. +GNU Automake home page: <https://www.gnu.org/software/automake/>. +General help using GNU software: <https://www.gnu.org/gethelp/>." while test $# -ne 0; do case $1 in @@ -137,8 +152,13 @@ while test $# -ne 0; do -o) chowncmd="$chownprog $2" shift;; + -p) cpprog="$cpprog -p";; + -s) stripcmd=$stripprog;; + -S) backupsuffix="$2" + shift;; + -t) is_target_a_directory=always dst_arg=$2 @@ -150,7 +170,7 @@ while test $# -ne 0; do -T) is_target_a_directory=never;; - --version) echo "$0 $scriptversion"; exit $?;; + --version) echo "$0 (GNU Automake) $scriptversion"; exit $?;; --) shift break;; @@ -255,6 +275,10 @@ do dstdir=$dst test -d "$dstdir" dstdir_status=$? + # Don't chown directories that already exist. + if test $dstdir_status = 0; then + chowncmd="" + fi else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command @@ -301,22 +325,6 @@ do if test $dstdir_status != 0; then case $posix_mkdir in '') - # Create intermediate dirs using mode 755 as modified by the umask. - # This is like FreeBSD 'install' as of 1997-10-28. - umask=`umask` - case $stripcmd.$umask in - # Optimize common cases. - *[2367][2367]) mkdir_umask=$umask;; - .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; - - *[0-7]) - mkdir_umask=`expr $umask + 22 \ - - $umask % 100 % 40 + $umask % 20 \ - - $umask % 10 % 4 + $umask % 2 - `;; - *) mkdir_umask=$umask,go-w;; - esac - # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then @@ -326,52 +334,49 @@ do fi posix_mkdir=false - case $umask in - *[123567][0-7][0-7]) - # POSIX mkdir -p sets u+wx bits regardless of umask, which - # is incompatible with FreeBSD 'install' when (umask & 300) != 0. - ;; - *) - # Note that $RANDOM variable is not portable (e.g. dash); Use it - # here however when possible just to lower collision chance. - tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ - - trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0 - - # Because "mkdir -p" follows existing symlinks and we likely work - # directly in world-writeable /tmp, make sure that the '$tmpdir' - # directory is successfully created first before we actually test - # 'mkdir -p' feature. - if (umask $mkdir_umask && - $mkdirprog $mkdir_mode "$tmpdir" && - exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 - then - if test -z "$dir_arg" || { - # Check for POSIX incompatibilities with -m. - # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or - # other-writable bit of parent directory when it shouldn't. - # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. - test_tmpdir="$tmpdir/a" - ls_ld_tmpdir=`ls -ld "$test_tmpdir"` - case $ls_ld_tmpdir in - d????-?r-*) different_mode=700;; - d????-?--*) different_mode=755;; - *) false;; - esac && - $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { - ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` - test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" - } - } - then posix_mkdir=: - fi - rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" - else - # Remove any dirs left behind by ancient mkdir implementations. - rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null - fi - trap '' 0;; - esac;; + # The $RANDOM variable is not portable (e.g., dash). Use it + # here however when possible just to lower collision chance. + tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ + + trap ' + ret=$? + rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null + exit $ret + ' 0 + + # Because "mkdir -p" follows existing symlinks and we likely work + # directly in world-writable /tmp, make sure that the '$tmpdir' + # directory is successfully created first before we actually test + # 'mkdir -p'. + if (umask $mkdir_umask && + $mkdirprog $mkdir_mode "$tmpdir" && + exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 + then + if test -z "$dir_arg" || { + # Check for POSIX incompatibility with -m. + # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or + # other-writable bit of parent directory when it shouldn't. + # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. + test_tmpdir="$tmpdir/a" + ls_ld_tmpdir=`ls -ld "$test_tmpdir"` + case $ls_ld_tmpdir in + d????-?r-*) different_mode=700;; + d????-?--*) different_mode=755;; + *) false;; + esac && + $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { + ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` + test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" + } + } + then posix_mkdir=: + fi + rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" + else + # Remove any dirs left behind by ancient mkdir implementations. + rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null + fi + trap '' 0;; esac if @@ -382,7 +387,7 @@ do then : else - # The umask is ridiculous, or mkdir does not conform to POSIX, + # mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. @@ -411,7 +416,7 @@ do prefixes= else if $posix_mkdir; then - (umask=$mkdir_umask && + (umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 @@ -451,7 +456,18 @@ do trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. - (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && + (umask $cp_umask && + { test -z "$stripcmd" || { + # Create $dsttmp read-write so that cp doesn't create it read-only, + # which would cause strip to fail. + if test -z "$doit"; then + : >"$dsttmp" # No need to fork-exec 'touch'. + else + $doit touch "$dsttmp" + fi + } + } && + $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # @@ -477,6 +493,13 @@ do then rm -f "$dsttmp" else + # If $backupsuffix is set, and the file being installed + # already exists, attempt a backup. Don't worry if it fails, + # e.g., if mv doesn't support -f. + if test -n "$backupsuffix" && test -f "$dst"; then + $doit $mvcmd -f "$dst" "$dst$backupsuffix" 2>/dev/null + fi + # Rename the file to the real destination. $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || @@ -491,9 +514,9 @@ do # file should still install successfully. { test ! -f "$dst" || - $doit $rmcmd -f "$dst" 2>/dev/null || + $doit $rmcmd "$dst" 2>/dev/null || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && - { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } + { $doit $rmcmd "$rmtmp" 2>/dev/null; :; } } || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 @@ -510,9 +533,9 @@ do done # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-format: "%Y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: diff --git a/subprojects/libsodium/build-aux/ltmain.sh b/subprojects/libsodium/build-aux/ltmain.sh @@ -1,12 +1,12 @@ -#! /bin/sh +#! /usr/bin/env sh ## DO NOT EDIT - This file generated from ./build-aux/ltmain.in -## by inline-source v2014-01-03.01 +## by inline-source v2019-02-19.15 -# libtool (GNU libtool) 2.4.6 +# libtool (GNU libtool) 2.5.4 # Provide generalized library-building support services. # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 -# Copyright (C) 1996-2015 Free Software Foundation, Inc. +# Copyright (C) 1996-2019, 2021-2024 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. @@ -31,8 +31,8 @@ PROGRAM=libtool PACKAGE=libtool -VERSION=2.4.6 -package_revision=2.4.6 +VERSION=2.5.4 +package_revision=2.5.4 ## ------ ## @@ -64,34 +64,25 @@ package_revision=2.4.6 # libraries, which are installed to $pkgauxdir. # Set a version string for this script. -scriptversion=2015-01-20.17; # UTC +scriptversion=2019-02-19.15; # UTC # General shell script boiler plate, and helper functions. # Written by Gary V. Vaughan, 2004 -# Copyright (C) 2004-2015 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 3 of the License, or -# (at your option) any later version. - -# As a special exception to the GNU General Public License, if you distribute -# this file as part of a program or library that is built using GNU Libtool, -# you may include this file under the same distribution terms that you use -# for the rest of that program. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNES FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. - -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. +# This is free software. There is NO warranty; not even for +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# +# Copyright (C) 2004-2019, 2021, 2023-2024 Bootstrap Authors +# +# This file is dual licensed under the terms of the MIT license +# <https://opensource.org/licenses/MIT>, and GPL version 2 or later +# <https://www.gnu.org/licenses/gpl-2.0.html>. You must apply one of +# these licenses when using or redistributing this software or any of +# the files within it. See the URLs above, or the file `LICENSE` +# included in the Bootstrap distribution for the full license texts. -# Please report bugs or propose patches to gary@gnu.org. +# Please report bugs or propose patches to: +# <https://github.com/gnulib-modules/bootstrap/issues> ## ------ ## @@ -139,9 +130,12 @@ do _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" fi" done - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH +# These NLS vars are set unconditionally (bootstrap issue #24). Unset those +# in case the environment reset is needed later and the $save_* variant is not +# defined (see the code above). +LC_ALL=C +LANGUAGE=C +export LANGUAGE LC_ALL # Make sure IFS has a sensible default sp=' ' @@ -149,7 +143,7 @@ nl=' ' IFS="$sp $nl" -# There are apparently some retarded systems that use ';' as a PATH separator! +# There are apparently some systems that use ';' as a PATH separator! if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { @@ -159,6 +153,26 @@ if test "${PATH_SEPARATOR+set}" != set; then fi +# func_unset VAR +# -------------- +# Portably unset VAR. +# In some shells, an 'unset VAR' statement leaves a non-zero return +# status if VAR is already unset, which might be problematic if the +# statement is used at the end of a function (thus poisoning its return +# value) or when 'set -e' is active (causing even a spurious abort of +# the script in this case). +func_unset () +{ + { eval $1=; (eval unset $1) >/dev/null 2>&1 && eval unset $1 || : ; } +} + + +# Make sure CDPATH doesn't cause `cd` commands to output the target dir. +func_unset CDPATH + +# Make sure ${,E,F}GREP behave sanely. +func_unset GREP_OPTIONS + ## ------------------------- ## ## Locate command utilities. ## @@ -259,7 +273,7 @@ test -z "$SED" && { rm -f conftest.in conftest.tmp conftest.nl conftest.out } - func_path_progs "sed gsed" func_check_prog_sed $PATH:/usr/xpg4/bin + func_path_progs "sed gsed" func_check_prog_sed "$PATH:/usr/xpg4/bin" rm -f conftest.sed SED=$func_path_progs_result } @@ -295,7 +309,7 @@ test -z "$GREP" && { rm -f conftest.in conftest.tmp conftest.nl conftest.out } - func_path_progs "grep ggrep" func_check_prog_grep $PATH:/usr/xpg4/bin + func_path_progs "grep ggrep" func_check_prog_grep "$PATH:/usr/xpg4/bin" GREP=$func_path_progs_result } @@ -360,6 +374,35 @@ sed_double_backslash="\ s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g s/\n//g" +# require_check_ifs_backslash +# --------------------------- +# Check if we can use backslash as IFS='\' separator, and set +# $check_ifs_backshlash_broken to ':' or 'false'. +require_check_ifs_backslash=func_require_check_ifs_backslash +func_require_check_ifs_backslash () +{ + _G_save_IFS=$IFS + IFS='\' + _G_check_ifs_backshlash='a\\b' + for _G_i in $_G_check_ifs_backshlash + do + case $_G_i in + a) + check_ifs_backshlash_broken=false + ;; + '') + break + ;; + *) + check_ifs_backshlash_broken=: + break + ;; + esac + done + IFS=$_G_save_IFS + require_check_ifs_backslash=: +} + ## ----------------- ## ## Global variables. ## @@ -546,7 +589,7 @@ func_require_term_colors () # _G_HAVE_PLUSEQ_OP # Can be empty, in which case the shell is probed, "yes" if += is - # useable or anything else if it does not work. + # usable or anything else if it does not work. test -z "$_G_HAVE_PLUSEQ_OP" \ && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ && _G_HAVE_PLUSEQ_OP=yes @@ -580,16 +623,16 @@ if test yes = "$_G_HAVE_PLUSEQ_OP"; then { $debug_cmd - func_quote_for_eval "$2" - eval "$1+=\\ \$func_quote_for_eval_result" + func_quote_arg pretty "$2" + eval "$1+=\\ \$func_quote_arg_result" }' else func_append_quoted () { $debug_cmd - func_quote_for_eval "$2" - eval "$1=\$$1\\ \$func_quote_for_eval_result" + func_quote_arg pretty "$2" + eval "$1=\$$1\\ \$func_quote_arg_result" } fi @@ -696,7 +739,7 @@ eval 'func_dirname () # to NONDIR_REPLACEMENT. # value returned in "$func_dirname_result" # basename: Compute filename of FILE. -# value retuned in "$func_basename_result" +# value returned in "$func_basename_result" # For efficiency, we do not delegate to the functions above but instead # duplicate the functionality here. eval 'func_dirname_and_basename () @@ -854,7 +897,7 @@ func_mkdir_p () # While some portion of DIR does not yet exist... while test ! -d "$_G_directory_path"; do # ...make a list in topmost first order. Use a colon delimited - # list incase some portion of path contains whitespace. + # list in case some portion of path contains whitespace. _G_dir_list=$_G_directory_path:$_G_dir_list # If the last portion added has no slash in it, the list is done @@ -1091,85 +1134,203 @@ func_relative_path () } -# func_quote_for_eval ARG... -# -------------------------- -# Aesthetically quote ARGs to be evaled later. -# This function returns two values: -# i) func_quote_for_eval_result -# double-quoted, suitable for a subsequent eval -# ii) func_quote_for_eval_unquoted_result -# has all characters that are still active within double -# quotes backslashified. -func_quote_for_eval () +# func_quote_portable EVAL ARG +# ---------------------------- +# Internal function to portably implement func_quote_arg. Note that we still +# keep attention to performance here so we as much as possible try to avoid +# calling sed binary (so far O(N) complexity as long as func_append is O(1)). +func_quote_portable () { $debug_cmd - func_quote_for_eval_unquoted_result= - func_quote_for_eval_result= - while test 0 -lt $#; do - case $1 in - *[\\\`\"\$]*) - _G_unquoted_arg=`printf '%s\n' "$1" |$SED "$sed_quote_subst"` ;; - *) - _G_unquoted_arg=$1 ;; - esac - if test -n "$func_quote_for_eval_unquoted_result"; then - func_append func_quote_for_eval_unquoted_result " $_G_unquoted_arg" - else - func_append func_quote_for_eval_unquoted_result "$_G_unquoted_arg" + $require_check_ifs_backslash + + func_quote_portable_result=$2 + + # one-time-loop (easy break) + while true + do + if $1; then + func_quote_portable_result=`$ECHO "$2" | $SED \ + -e "$sed_double_quote_subst" -e "$sed_double_backslash"` + break fi - case $_G_unquoted_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting, command substitution and variable expansion - # for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - _G_quoted_arg=\"$_G_unquoted_arg\" + # Quote for eval. + case $func_quote_portable_result in + *[\\\`\"\$]*) + # Fallback to sed for $func_check_bs_ifs_broken=:, or when the string + # contains the shell wildcard characters. + case $check_ifs_backshlash_broken$func_quote_portable_result in + :*|*[\[\*\?]*) + func_quote_portable_result=`$ECHO "$func_quote_portable_result" \ + | $SED "$sed_quote_subst"` + break + ;; + esac + + func_quote_portable_old_IFS=$IFS + for _G_char in '\' '`' '"' '$' + do + # STATE($1) PREV($2) SEPARATOR($3) + set start "" "" + func_quote_portable_result=dummy"$_G_char$func_quote_portable_result$_G_char"dummy + IFS=$_G_char + for _G_part in $func_quote_portable_result + do + case $1 in + quote) + func_append func_quote_portable_result "$3$2" + set quote "$_G_part" "\\$_G_char" + ;; + start) + set first "" "" + func_quote_portable_result= + ;; + first) + set quote "$_G_part" "" + ;; + esac + done + done + IFS=$func_quote_portable_old_IFS ;; - *) - _G_quoted_arg=$_G_unquoted_arg - ;; + *) ;; esac - - if test -n "$func_quote_for_eval_result"; then - func_append func_quote_for_eval_result " $_G_quoted_arg" - else - func_append func_quote_for_eval_result "$_G_quoted_arg" - fi - shift + break done + + func_quote_portable_unquoted_result=$func_quote_portable_result + case $func_quote_portable_result in + # double-quote args containing shell metacharacters to delay + # word splitting, command substitution and variable expansion + # for a subsequent eval. + # many bourne shells cannot handle close brackets correctly + # in scan sets, so we specify it separately. + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") + func_quote_portable_result=\"$func_quote_portable_result\" + ;; + esac } -# func_quote_for_expand ARG -# ------------------------- -# Aesthetically quote ARG to be evaled later; same as above, -# but do not quote variable references. -func_quote_for_expand () -{ - $debug_cmd +# func_quotefast_eval ARG +# ----------------------- +# Quote one ARG (internal). This is equivalent to 'func_quote_arg eval ARG', +# but optimized for speed. Result is stored in $func_quotefast_eval. +if test xyes = `(x=; printf -v x %q yes; echo x"$x") 2>/dev/null`; then + printf -v _GL_test_printf_tilde %q '~' + if test '\~' = "$_GL_test_printf_tilde"; then + func_quotefast_eval () + { + printf -v func_quotefast_eval_result %q "$1" + } + else + # Broken older Bash implementations. Make those faster too if possible. + func_quotefast_eval () + { + case $1 in + '~'*) + func_quote_portable false "$1" + func_quotefast_eval_result=$func_quote_portable_result + ;; + *) + printf -v func_quotefast_eval_result %q "$1" + ;; + esac + } + fi +else + func_quotefast_eval () + { + func_quote_portable false "$1" + func_quotefast_eval_result=$func_quote_portable_result + } +fi - case $1 in - *[\\\`\"]*) - _G_arg=`$ECHO "$1" | $SED \ - -e "$sed_double_quote_subst" -e "$sed_double_backslash"` ;; - *) - _G_arg=$1 ;; + +# func_quote_arg MODEs ARG +# ------------------------ +# Quote one ARG to be evaled later. MODEs argument may contain zero or more +# specifiers listed below separated by ',' character. This function returns two +# values: +# i) func_quote_arg_result +# double-quoted (when needed), suitable for a subsequent eval +# ii) func_quote_arg_unquoted_result +# has all characters that are still active within double +# quotes backslashified. Available only if 'unquoted' is specified. +# +# Available modes: +# ---------------- +# 'eval' (default) +# - escape shell special characters +# 'expand' +# - the same as 'eval'; but do not quote variable references +# 'pretty' +# - request aesthetic output, i.e. '"a b"' instead of 'a\ b'. This might +# be used later in func_quote to get output like: 'echo "a b"' instead +# of 'echo a\ b'. This is slower than default on some shells. +# 'unquoted' +# - produce also $func_quote_arg_unquoted_result which does not contain +# wrapping double-quotes. +# +# Examples for 'func_quote_arg pretty,unquoted string': +# +# string | *_result | *_unquoted_result +# ------------+-----------------------+------------------- +# " | \" | \" +# a b | "a b" | a b +# "a b" | "\"a b\"" | \"a b\" +# * | "*" | * +# z="${x-$y}" | "z=\"\${x-\$y}\"" | z=\"\${x-\$y}\" +# +# Examples for 'func_quote_arg pretty,unquoted,expand string': +# +# string | *_result | *_unquoted_result +# --------------+---------------------+-------------------- +# z="${x-$y}" | "z=\"${x-$y}\"" | z=\"${x-$y}\" +func_quote_arg () +{ + _G_quote_expand=false + case ,$1, in + *,expand,*) + _G_quote_expand=: + ;; esac - case $_G_arg in - # Double-quote args containing shell metacharacters to delay - # word splitting and command substitution for a subsequent eval. - # Many Bourne shells cannot handle close brackets correctly - # in scan sets, so we specify it separately. - *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") - _G_arg=\"$_G_arg\" + case ,$1, in + *,pretty,*|*,expand,*|*,unquoted,*) + func_quote_portable $_G_quote_expand "$2" + func_quote_arg_result=$func_quote_portable_result + func_quote_arg_unquoted_result=$func_quote_portable_unquoted_result + ;; + *) + # Faster quote-for-eval for some shells. + func_quotefast_eval "$2" + func_quote_arg_result=$func_quotefast_eval_result ;; esac +} - func_quote_for_expand_result=$_G_arg + +# func_quote MODEs ARGs... +# ------------------------ +# Quote all ARGs to be evaled later and join them into single command. See +# func_quote_arg's description for more info. +func_quote () +{ + $debug_cmd + _G_func_quote_mode=$1 ; shift + func_quote_result= + while test 0 -lt $#; do + func_quote_arg "$_G_func_quote_mode" "$1" + if test -n "$func_quote_result"; then + func_append func_quote_result " $func_quote_arg_result" + else + func_append func_quote_result "$func_quote_arg_result" + fi + shift + done } @@ -1215,8 +1376,8 @@ func_show_eval () _G_cmd=$1 _G_fail_exp=${2-':'} - func_quote_for_expand "$_G_cmd" - eval "func_notquiet $func_quote_for_expand_result" + func_quote_arg pretty,expand "$_G_cmd" + eval "func_notquiet $func_quote_arg_result" $opt_dry_run || { eval "$_G_cmd" @@ -1241,8 +1402,8 @@ func_show_eval_locale () _G_fail_exp=${2-':'} $opt_quiet || { - func_quote_for_expand "$_G_cmd" - eval "func_echo $func_quote_for_expand_result" + func_quote_arg expand,pretty "$_G_cmd" + eval "func_echo $func_quote_arg_result" } $opt_dry_run || { @@ -1369,30 +1530,26 @@ func_lt_ver () # End: #! /bin/sh -# Set a version string for this script. -scriptversion=2014-01-07.03; # UTC - # A portable, pluggable option parser for Bourne shell. # Written by Gary V. Vaughan, 2010 -# Copyright (C) 2010-2015 Free Software Foundation, Inc. -# This is free software; see the source for copying conditions. There is NO -# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. +# This is free software. There is NO warranty; not even for +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +# +# Copyright (C) 2010-2019, 2021, 2023-2024 Bootstrap Authors +# +# This file is dual licensed under the terms of the MIT license +# <https://opensource.org/licenses/MIT>, and GPL version 2 or later +# <https://www.gnu.org/licenses/gpl-2.0.html>. You must apply one of +# these licenses when using or redistributing this software or any of +# the files within it. See the URLs above, or the file `LICENSE` +# included in the Bootstrap distribution for the full license texts. -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# Please report bugs or propose patches to: +# <https://github.com/gnulib-modules/bootstrap/issues> -# You should have received a copy of the GNU General Public License -# along with this program. If not, see <http://www.gnu.org/licenses/>. - -# Please report bugs or propose patches to gary@gnu.org. +# Set a version string for this script. +scriptversion=2019-02-19.15; # UTC ## ------ ## @@ -1415,7 +1572,7 @@ scriptversion=2014-01-07.03; # UTC # # In order for the '--version' option to work, you will need to have a # suitably formatted comment like the one at the top of this file -# starting with '# Written by ' and ending with '# warranty; '. +# starting with '# Written by ' and ending with '# Copyright'. # # For '-h' and '--help' to work, you will also need a one line # description of your script's purpose in a comment directly above the @@ -1427,7 +1584,7 @@ scriptversion=2014-01-07.03; # UTC # to display verbose messages only when your user has specified # '--verbose'. # -# After sourcing this file, you can plug processing for additional +# After sourcing this file, you can plug in processing for additional # options by amending the variables from the 'Configuration' section # below, and following the instructions in the 'Option parsing' # section further down. @@ -1476,8 +1633,8 @@ fatal_help="Try '\$progname --help' for more information." ## ------------------------- ## # This section contains functions for adding, removing, and running hooks -# to the main code. A hook is just a named list of of function, that can -# be run in order later on. +# in the main code. A hook is just a list of function names that can be +# run in order later on. # func_hookable FUNC_NAME # ----------------------- @@ -1510,7 +1667,8 @@ func_add_hook () # func_remove_hook FUNC_NAME HOOK_FUNC # ------------------------------------ -# Remove HOOK_FUNC from the list of functions called by FUNC_NAME. +# Remove HOOK_FUNC from the list of hook functions to be called by +# FUNC_NAME. func_remove_hook () { $debug_cmd @@ -1519,10 +1677,28 @@ func_remove_hook () } +# func_propagate_result FUNC_NAME_A FUNC_NAME_B +# --------------------------------------------- +# If the *_result variable of FUNC_NAME_A _is set_, assign its value to +# *_result variable of FUNC_NAME_B. +func_propagate_result () +{ + $debug_cmd + + func_propagate_result_result=: + if eval "test \"\${${1}_result+set}\" = set" + then + eval "${2}_result=\$${1}_result" + else + func_propagate_result_result=false + fi +} + + # func_run_hooks FUNC_NAME [ARG]... # --------------------------------- # Run all hook functions registered to FUNC_NAME. -# It is assumed that the list of hook functions contains nothing more +# It's assumed that the list of hook functions contains nothing more # than a whitespace-delimited list of legal shell function names, and # no effort is wasted trying to catch shell meta-characters or preserve # whitespace. @@ -1532,22 +1708,19 @@ func_run_hooks () case " $hookable_fns " in *" $1 "*) ;; - *) func_fatal_error "'$1' does not support hook funcions.n" ;; + *) func_fatal_error "'$1' does not support hook functions." ;; esac eval _G_hook_fns=\$$1_hooks; shift for _G_hook in $_G_hook_fns; do - eval $_G_hook '"$@"' - - # store returned options list back into positional - # parameters for next 'cmd' execution. - eval _G_hook_result=\$${_G_hook}_result - eval set dummy "$_G_hook_result"; shift + func_unset "${_G_hook}_result" + eval $_G_hook '${1+"$@"}' + func_propagate_result $_G_hook func_run_hooks + if $func_propagate_result_result; then + eval set dummy "$func_run_hooks_result"; shift + fi done - - func_quote_for_eval ${1+"$@"} - func_run_hooks_result=$func_quote_for_eval_result } @@ -1557,10 +1730,18 @@ func_run_hooks () ## --------------- ## # In order to add your own option parsing hooks, you must accept the -# full positional parameter list in your hook function, remove any -# options that you action, and then pass back the remaining unprocessed -# options in '<hooked_function_name>_result', escaped suitably for -# 'eval'. Like this: +# full positional parameter list from your hook function. You may remove +# or edit any options that you action, and then pass back the remaining +# unprocessed options in '<hooked_function_name>_result', escaped +# suitably for 'eval'. +# +# The '<hooked_function_name>_result' variable is automatically unset +# before your hook gets called; for best performance, only set the +# *_result variable when necessary (i.e. don't call the 'func_quote' +# function unnecessarily because it can be an expensive operation on some +# machines). +# +# Like this: # # my_options_prep () # { @@ -1570,9 +1751,8 @@ func_run_hooks () # usage_message=$usage_message' # -s, --silent don'\''t print informational messages # ' -# -# func_quote_for_eval ${1+"$@"} -# my_options_prep_result=$func_quote_for_eval_result +# # No change in '$@' (ignored completely by this hook). Leave +# # my_options_prep_result variable intact. # } # func_add_hook func_options_prep my_options_prep # @@ -1581,25 +1761,36 @@ func_run_hooks () # { # $debug_cmd # -# # Note that for efficiency, we parse as many options as we can +# args_changed=false +# +# # Note that, for efficiency, we parse as many options as we can # # recognise in a loop before passing the remainder back to the # # caller on the first unrecognised argument we encounter. # while test $# -gt 0; do # opt=$1; shift # case $opt in -# --silent|-s) opt_silent=: ;; +# --silent|-s) opt_silent=: +# args_changed=: +# ;; # # Separate non-argument short options: # -s*) func_split_short_opt "$_G_opt" # set dummy "$func_split_short_opt_name" \ # "-$func_split_short_opt_arg" ${1+"$@"} # shift +# args_changed=: # ;; -# *) set dummy "$_G_opt" "$*"; shift; break ;; +# *) # Make sure the first unrecognised option "$_G_opt" +# # is added back to "$@" in case we need it later, +# # if $args_changed was set to 'true'. +# set dummy "$_G_opt" ${1+"$@"}; shift; break ;; # esac # done # -# func_quote_for_eval ${1+"$@"} -# my_silent_option_result=$func_quote_for_eval_result +# # Only call 'func_quote' here if we processed at least one argument. +# if $args_changed; then +# func_quote eval ${1+"$@"} +# my_silent_option_result=$func_quote_result +# fi # } # func_add_hook func_parse_options my_silent_option # @@ -1610,17 +1801,26 @@ func_run_hooks () # # $opt_silent && $opt_verbose && func_fatal_help "\ # '--silent' and '--verbose' options are mutually exclusive." -# -# func_quote_for_eval ${1+"$@"} -# my_option_validation_result=$func_quote_for_eval_result # } # func_add_hook func_validate_options my_option_validation # -# You'll alse need to manually amend $usage_message to reflect the extra +# You'll also need to manually amend $usage_message to reflect the extra # options you parse. It's preferable to append if you can, so that # multiple option parsing hooks can be added safely. +# func_options_finish [ARG]... +# ---------------------------- +# Finishing the option parse loop (call 'func_options' hooks ATM). +func_options_finish () +{ + $debug_cmd + + func_run_hooks func_options ${1+"$@"} + func_propagate_result func_run_hooks func_options_finish +} + + # func_options [ARG]... # --------------------- # All the functions called inside func_options are hookable. See the @@ -1630,17 +1830,27 @@ func_options () { $debug_cmd - func_options_prep ${1+"$@"} - eval func_parse_options \ - ${func_options_prep_result+"$func_options_prep_result"} - eval func_validate_options \ - ${func_parse_options_result+"$func_parse_options_result"} + _G_options_quoted=false - eval func_run_hooks func_options \ - ${func_validate_options_result+"$func_validate_options_result"} + for my_func in options_prep parse_options validate_options options_finish + do + func_unset func_${my_func}_result + func_unset func_run_hooks_result + eval func_$my_func '${1+"$@"}' + func_propagate_result func_$my_func func_options + if $func_propagate_result_result; then + eval set dummy "$func_options_result"; shift + _G_options_quoted=: + fi + done - # save modified positional parameters for caller - func_options_result=$func_run_hooks_result + $_G_options_quoted || { + # As we (func_options) are top-level options-parser function and + # nobody quoted "$@" for us yet, we need to do it explicitly for + # caller. + func_quote eval ${1+"$@"} + func_options_result=$func_quote_result + } } @@ -1649,9 +1859,8 @@ func_options () # All initialisations required before starting the option parse loop. # Note that when calling hook functions, we pass through the list of # positional parameters. If a hook function modifies that list, and -# needs to propogate that back to rest of this script, then the complete -# modified list must be put in 'func_run_hooks_result' before -# returning. +# needs to propagate that back to rest of this script, then the complete +# modified list must be put in 'func_run_hooks_result' before returning. func_hookable func_options_prep func_options_prep () { @@ -1662,9 +1871,7 @@ func_options_prep () opt_warning_types= func_run_hooks func_options_prep ${1+"$@"} - - # save modified positional parameters for caller - func_options_prep_result=$func_run_hooks_result + func_propagate_result func_run_hooks func_options_prep } @@ -1676,25 +1883,32 @@ func_parse_options () { $debug_cmd - func_parse_options_result= - + _G_parse_options_requote=false # this just eases exit handling while test $# -gt 0; do # Defer to hook functions for initial option parsing, so they # get priority in the event of reusing an option name. func_run_hooks func_parse_options ${1+"$@"} - - # Adjust func_parse_options positional parameters to match - eval set dummy "$func_run_hooks_result"; shift + func_propagate_result func_run_hooks func_parse_options + if $func_propagate_result_result; then + eval set dummy "$func_parse_options_result"; shift + # Even though we may have changed "$@", we passed the "$@" array + # down into the hook and it quoted it for us (because we are in + # this if-branch). No need to quote it again. + _G_parse_options_requote=false + fi # Break out of the loop if we already parsed every option. test $# -gt 0 || break + # We expect that one of the options parsed in this function matches + # and thus we remove _G_opt from "$@" and need to re-quote. + _G_match_parse_options=: _G_opt=$1 shift case $_G_opt in --debug|-x) debug_cmd='set -x' - func_echo "enabling shell trace mode" + func_echo "enabling shell trace mode" >&2 $debug_cmd ;; @@ -1704,7 +1918,10 @@ func_parse_options () ;; --warnings|--warning|-W) - test $# = 0 && func_missing_arg $_G_opt && break + if test $# = 0 && func_missing_arg $_G_opt; then + _G_parse_options_requote=: + break + fi case " $warning_categories $1" in *" $1 "*) # trailing space prevents matching last $1 above @@ -1757,15 +1974,24 @@ func_parse_options () shift ;; - --) break ;; + --) _G_parse_options_requote=: ; break ;; -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; - *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; + *) set dummy "$_G_opt" ${1+"$@"}; shift + _G_match_parse_options=false + break + ;; esac + + if $_G_match_parse_options; then + _G_parse_options_requote=: + fi done - # save modified positional parameters for caller - func_quote_for_eval ${1+"$@"} - func_parse_options_result=$func_quote_for_eval_result + if $_G_parse_options_requote; then + # save modified positional parameters for caller + func_quote eval ${1+"$@"} + func_parse_options_result=$func_quote_result + fi } @@ -1782,12 +2008,10 @@ func_validate_options () test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" func_run_hooks func_validate_options ${1+"$@"} + func_propagate_result func_run_hooks func_validate_options # Bail if the options were screwed! $exit_cmd $EXIT_FAILURE - - # save modified positional parameters for caller - func_validate_options_result=$func_run_hooks_result } @@ -1843,8 +2067,8 @@ func_missing_arg () # func_split_equals STRING # ------------------------ -# Set func_split_equals_lhs and func_split_equals_rhs shell variables after -# splitting STRING at the '=' sign. +# Set func_split_equals_lhs and func_split_equals_rhs shell variables +# after splitting STRING at the '=' sign. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ @@ -1859,8 +2083,9 @@ then func_split_equals_lhs=${1%%=*} func_split_equals_rhs=${1#*=} - test "x$func_split_equals_lhs" = "x$1" \ - && func_split_equals_rhs= + if test "x$func_split_equals_lhs" = "x$1"; then + func_split_equals_rhs= + fi }' else # ...otherwise fall back to using expr, which is often a shell builtin. @@ -1870,7 +2095,7 @@ else func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` func_split_equals_rhs= - test "x$func_split_equals_lhs" = "x$1" \ + test "x$func_split_equals_lhs=" = "x$1" \ || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` } fi #func_split_equals @@ -1896,7 +2121,7 @@ else { $debug_cmd - func_split_short_opt_name=`expr "x$1" : 'x-\(.\)'` + func_split_short_opt_name=`expr "x$1" : 'x\(-.\)'` func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` } fi #func_split_short_opt @@ -1938,31 +2163,44 @@ func_usage_message () # func_version # ------------ # Echo version message to standard output and exit. +# The version message is extracted from the calling file's header +# comments, with leading '# ' stripped: +# 1. First display the progname and version +# 2. Followed by the header comment line matching /^# Written by / +# 3. Then a blank line followed by the first following line matching +# /^# Copyright / +# 4. Immediately followed by any lines between the previous matches, +# except lines preceding the intervening completely blank line. +# For example, see the header comments of this file. func_version () { $debug_cmd printf '%s\n' "$progname $scriptversion" $SED -n ' - /(C)/!b go - :more - /\./!{ - N - s|\n# | | - b more - } - :go - /^# Written by /,/# warranty; / { - s|^# || - s|^# *$|| - s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| - p + /^# Written by /!b + s|^# ||; p; n + + :fwd2blnk + /./ { + n + b fwd2blnk } - /^# Written by / { - s|^# || - p + p; n + + :holdwrnt + s|^# || + s|^# *$|| + /^Copyright /!{ + /./H + n + b holdwrnt } - /^warranty; /q' < "$progpath" + + s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| + G + s|\(\n\)\n*|\1|g + p; q' < "$progpath" exit $? } @@ -1972,12 +2210,35 @@ func_version () # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) -# time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" +# time-stamp-pattern: "30/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: # Set a version string. -scriptversion='(GNU libtool) 2.4.6' +scriptversion='(GNU libtool) 2.5.4' + +# func_version +# ------------ +# Echo version message to standard output and exit. +func_version () +{ + $debug_cmd + + year=`date +%Y` + + cat <<EOF +$progname $scriptversion +Copyright (C) $year Free Software Foundation, Inc. +License GPLv2+: GNU GPL version 2 or later <https://gnu.org/licenses/gpl.html> +This is free software: you are free to change and redistribute it. +There is NO WARRANTY, to the extent permitted by law. + +Originally written by Gordon Matzigkeit, 1996 +(See AUTHORS for complete contributor listing) +EOF + + exit $? +} # func_echo ARG... @@ -2000,18 +2261,6 @@ func_echo () } -# func_warning ARG... -# ------------------- -# Libtool warnings are not categorized, so override funclib.sh -# func_warning with this simpler definition. -func_warning () -{ - $debug_cmd - - $warning_func ${1+"$@"} -} - - ## ---------------- ## ## Options parsing. ## ## ---------------- ## @@ -2023,19 +2272,23 @@ usage='$progpath [OPTION]... [MODE-ARG]...' # Short help message in response to '-h'. usage_message="Options: - --config show all configuration variables - --debug enable verbose shell tracing - -n, --dry-run display commands without modifying any files - --features display basic configuration information and exit - --mode=MODE use operation mode MODE - --no-warnings equivalent to '-Wnone' - --preserve-dup-deps don't remove duplicate dependency libraries - --quiet, --silent don't print informational messages - --tag=TAG use configuration variables from tag TAG - -v, --verbose print more informational messages than default - --version print version information - -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] - -h, --help, --help-all print short, long, or detailed help message + --config show all configuration variables + --debug enable verbose shell tracing + -n, --dry-run display commands without modifying any files + --features display basic configuration information + --finish use operation '--mode=finish' + --mode=MODE use operation mode MODE + --no-finish don't update shared library cache + --no-quiet, --no-silent print default informational messages + --no-warnings equivalent to '-Wnone' + --preserve-dup-deps don't remove duplicate dependency libraries + --quiet, --silent don't print informational messages + --reorder-cache=DIRS reorder shared library cache for preferred DIRS + --tag=TAG use configuration variables from tag TAG + -v, --verbose print more informational messages than default + --version print version information + -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] + -h, --help, --help-all print short, long, or detailed help message " # Additional text appended to 'usage_message' in response to '--help'. @@ -2068,13 +2321,13 @@ include the following information: compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) - version: $progname (GNU libtool) 2.4.6 + version: $progname $scriptversion automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to <bug-libtool@gnu.org>. -GNU libtool home page: <http://www.gnu.org/software/libtool/>. -General help using GNU software: <http://www.gnu.org/gethelp/>." +GNU libtool home page: <https://www.gnu.org/software/libtool/>. +General help using GNU software: <https://www.gnu.org/gethelp/>." exit 0 } @@ -2124,7 +2377,7 @@ fi # a configuration failure hint, and exit. func_fatal_configuration () { - func__fatal_error ${1+"$@"} \ + func_fatal_error ${1+"$@"} \ "See the $PACKAGE documentation for more information." \ "Fatal configuration error." } @@ -2264,12 +2517,17 @@ libtool_options_prep () opt_dry_run=false opt_help=false opt_mode= + opt_reorder_cache=false opt_preserve_dup_deps=false opt_quiet=false + opt_finishing=true + opt_warning= nonopt= preserve_args= + _G_rc_lt_options_prep=: + # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) @@ -2293,11 +2551,16 @@ libtool_options_prep () uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) shift; set dummy --mode uninstall ${1+"$@"}; shift ;; + *) + _G_rc_lt_options_prep=false + ;; esac - # Pass back the list of options. - func_quote_for_eval ${1+"$@"} - libtool_options_prep_result=$func_quote_for_eval_result + if $_G_rc_lt_options_prep; then + # Pass back the list of options. + func_quote eval ${1+"$@"} + libtool_options_prep_result=$func_quote_result + fi } func_add_hook func_options_prep libtool_options_prep @@ -2309,9 +2572,12 @@ libtool_parse_options () { $debug_cmd + _G_rc_lt_parse_options=false + # Perform our own loop to consume as many options as possible in # each iteration. while test $# -gt 0; do + _G_match_lt_parse_options=: _G_opt=$1 shift case $_G_opt in @@ -2345,14 +2611,18 @@ libtool_parse_options () clean|compile|execute|finish|install|link|relink|uninstall) ;; # Catch anything else as an error - *) func_error "invalid argument for $_G_opt" + *) func_error "invalid argument '$1' for $_G_opt" exit_cmd=exit - break ;; esac shift ;; + --no-finish) + opt_finishing=false + func_append preserve_args " $_G_opt" + ;; + --no-silent|--no-quiet) opt_quiet=false func_append preserve_args " $_G_opt" @@ -2368,6 +2638,24 @@ libtool_parse_options () func_append preserve_args " $_G_opt" ;; + --reorder-cache) + opt_reorder_cache=true + shared_lib_dirs=$1 + if test -n "$shared_lib_dirs"; then + case $1 in + # Must begin with /: + /*) ;; + + # Catch anything else as an error (relative paths) + *) func_error "invalid argument '$1' for $_G_opt" + func_error "absolute paths are required for $_G_opt" + exit_cmd=exit + ;; + esac + fi + shift + ;; + --silent|--quiet) opt_quiet=: opt_verbose=false @@ -2386,19 +2674,36 @@ libtool_parse_options () func_append preserve_args " $_G_opt" ;; - # An option not handled by this hook function: - *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; + # An option not handled by this hook function: + *) set dummy "$_G_opt" ${1+"$@"} ; shift + _G_match_lt_parse_options=false + break + ;; esac + $_G_match_lt_parse_options && _G_rc_lt_parse_options=: done - - # save modified positional parameters for caller - func_quote_for_eval ${1+"$@"} - libtool_parse_options_result=$func_quote_for_eval_result + if $_G_rc_lt_parse_options; then + # save modified positional parameters for caller + func_quote eval ${1+"$@"} + libtool_parse_options_result=$func_quote_result + fi } func_add_hook func_parse_options libtool_parse_options +# func_warning ARG... +# ------------------- +# Libtool warnings are not categorized, so override funclib.sh +# func_warning with this simpler definition. +func_warning () +{ + if $opt_warning; then + $debug_cmd + $warning_func ${1+"$@"} + fi +} + # libtool_validate_options [ARG]... # --------------------------------- @@ -2415,10 +2720,10 @@ libtool_validate_options () # preserve --debug test : = "$debug_cmd" || func_append preserve_args " --debug" - case $host in + case $host_os in # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 - *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) + cygwin* | mingw* | windows* | pw32* | cegcc* | solaris2* | os2*) # don't eliminate duplications in $postdeps and $predeps opt_duplicate_compiler_generated_deps=: ;; @@ -2451,8 +2756,8 @@ libtool_validate_options () } # Pass back the unparsed argument list - func_quote_for_eval ${1+"$@"} - libtool_validate_options_result=$func_quote_for_eval_result + func_quote eval ${1+"$@"} + libtool_validate_options_result=$func_quote_result } func_add_hook func_validate_options libtool_validate_options @@ -2750,7 +3055,7 @@ EOF # func_convert_core_file_wine_to_w32 ARG # Helper function used by file name conversion functions when $build is *nix, -# and $host is mingw, cygwin, or some other w32 environment. Relies on a +# and $host is mingw, windows, cygwin, or some other w32 environment. Relies on a # correctly configured wine environment available, with the winepath program # in $build's $PATH. # @@ -2782,9 +3087,10 @@ func_convert_core_file_wine_to_w32 () # func_convert_core_path_wine_to_w32 ARG # Helper function used by path conversion functions when $build is *nix, and -# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly -# configured wine environment available, with the winepath program in $build's -# $PATH. Assumes ARG has no leading or trailing path separator characters. +# $host is mingw, windows, cygwin, or some other w32 environment. Relies on a +# correctly configured wine environment available, with the winepath program +# in $build's $PATH. Assumes ARG has no leading or trailing path separator +# characters. # # ARG is path to be converted from $build format to win32. # Result is available in $func_convert_core_path_wine_to_w32_result. @@ -2927,6 +3233,15 @@ func_convert_path_front_back_pathsep () # end func_convert_path_front_back_pathsep +# func_convert_delimited_path PATH ORIG_DELIMITER NEW_DELIMITER +# Replaces a delimiter for a given path. +func_convert_delimited_path () +{ + converted_path=`$ECHO "$1" | $SED "s#$2#$3#g"` +} +# end func_convert_delimited_path + + ################################################## # $build to $host FILE NAME CONVERSION FUNCTIONS # ################################################## @@ -3261,6 +3576,65 @@ func_dll_def_p () } +# func_reorder_shared_lib_cache DIRS +# Reorder the shared library cache by unconfiguring previous shared library cache +# and configuring preferred search directories before previous search directories. +# Previous shared library cache: /usr/lib /usr/local/lib +# Preferred search directories: /tmp/testing +# Reordered shared library cache: /tmp/testing /usr/lib /usr/local/lib +func_reorder_shared_lib_cache () +{ + $debug_cmd + + case $host_os in + openbsd*) + get_search_directories=`PATH="$PATH:/sbin" ldconfig -r | $GREP "search directories" | $SED "s#.*search directories:\ ##g"` + func_convert_delimited_path "$get_search_directories" ':' '\ ' + save_search_directories=$converted_path + func_convert_delimited_path "$1" ':' '\ ' + + # Ensure directories exist + for dir in $converted_path; do + # Ensure each directory is an absolute path + case $dir in + /*) ;; + *) func_error "Directory '$dir' is not an absolute path" + exit $EXIT_FAILURE ;; + esac + # Ensure no trailing slashes + func_stripname '' '/' "$dir" + dir=$func_stripname_result + if test -d "$dir"; then + if test -n "$preferred_search_directories"; then + preferred_search_directories="$preferred_search_directories $dir" + else + preferred_search_directories=$dir + fi + else + func_error "Directory '$dir' does not exist" + exit $EXIT_FAILURE + fi + done + + PATH="$PATH:/sbin" ldconfig -U $save_search_directories + PATH="$PATH:/sbin" ldconfig -m $preferred_search_directories $save_search_directories + get_search_directories=`PATH="$PATH:/sbin" ldconfig -r | $GREP "search directories" | $SED "s#.*search directories:\ ##g"` + func_convert_delimited_path "$get_search_directories" ':' '\ ' + reordered_search_directories=$converted_path + + $ECHO "Original: $save_search_directories" + $ECHO "Reordered: $reordered_search_directories" + exit $EXIT_SUCCESS + ;; + *) + func_error "--reorder-cache is not supported for host_os=$host_os." + exit $EXIT_FAILURE + ;; + esac +} +# end func_reorder_shared_lib_cache + + # func_mode_compile arg... func_mode_compile () { @@ -3418,8 +3792,8 @@ func_mode_compile () esac done - func_quote_for_eval "$libobj" - test "X$libobj" != "X$func_quote_for_eval_result" \ + func_quote_arg pretty "$libobj" + test "X$libobj" != "X$func_quote_arg_result" \ && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ && func_warning "libobj name '$libobj' may not contain shell special characters." func_dirname_and_basename "$obj" "/" "" @@ -3439,7 +3813,7 @@ func_mode_compile () # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in - cygwin* | mingw* | pw32* | os2* | cegcc*) + cygwin* | mingw* | windows* | pw32* | os2* | cegcc*) pic_mode=default ;; esac @@ -3492,8 +3866,8 @@ compiler." func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 srcfile=$func_to_tool_file_result - func_quote_for_eval "$srcfile" - qsrcfile=$func_quote_for_eval_result + func_quote_arg pretty "$srcfile" + qsrcfile=$func_quote_arg_result # Only build a PIC object if we are building libtool libraries. if test yes = "$build_libtool_libs"; then @@ -3648,7 +4022,8 @@ This mode accepts the following additional options: -prefer-non-pic try to build non-PIC objects only -shared do not build a '.o' file suitable for static linking -static only build a '.o' file suitable for static linking - -Wc,FLAG pass FLAG directly to the compiler + -Wc,FLAG + -Xcompiler FLAG pass FLAG directly to the compiler COMPILE-COMMAND is a command to be used in creating a 'standard' object file from the given SOURCEFILE. @@ -3754,6 +4129,8 @@ The following components of LINK-COMMAND are treated specially: -weak LIBNAME declare that the target provides the LIBNAME interface -Wc,FLAG -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wa,FLAG + -Xassembler FLAG pass linker-specific FLAG directly to the assembler -Wl,FLAG -Xlinker FLAG pass linker-specific FLAG directly to the linker -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) @@ -3830,6 +4207,12 @@ if $opt_help; then fi +# If option '--reorder-cache', reorder the shared library cache and exit. +if $opt_reorder_cache; then + func_reorder_shared_lib_cache $shared_lib_dirs +fi + + # func_mode_execute arg... func_mode_execute () { @@ -4014,7 +4397,7 @@ func_mode_finish () fi fi - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs" && $opt_finishing; then for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. @@ -4039,6 +4422,12 @@ func_mode_finish () for libdir in $libdirs; do $ECHO " $libdir" done + if test "false" = "$opt_finishing"; then + echo + echo "NOTE: finish_cmds were not executed during testing, so you must" + echo "manually run ldconfig to add a given test directory, LIBDIR, to" + echo "the search path for generated executables." + fi echo echo "If you ever happen to want to link against installed libraries" echo "in a given directory, LIBDIR, you must either use libtool, and" @@ -4096,8 +4485,8 @@ func_mode_install () case $nonopt in *shtool*) :;; *) false;; esac then # Aesthetically quote it. - func_quote_for_eval "$nonopt" - install_prog="$func_quote_for_eval_result " + func_quote_arg pretty "$nonopt" + install_prog="$func_quote_arg_result " arg=$1 shift else @@ -4107,8 +4496,8 @@ func_mode_install () # The real first argument should be the name of the installation program. # Aesthetically quote it. - func_quote_for_eval "$arg" - func_append install_prog "$func_quote_for_eval_result" + func_quote_arg pretty "$arg" + func_append install_prog "$func_quote_arg_result" install_shared_prog=$install_prog case " $install_prog " in *[\\\ /]cp\ *) install_cp=: ;; @@ -4165,12 +4554,12 @@ func_mode_install () esac # Aesthetically quote the argument. - func_quote_for_eval "$arg" - func_append install_prog " $func_quote_for_eval_result" + func_quote_arg pretty "$arg" + func_append install_prog " $func_quote_arg_result" if test -n "$arg2"; then - func_quote_for_eval "$arg2" + func_quote_arg pretty "$arg2" fi - func_append install_shared_prog " $func_quote_for_eval_result" + func_append install_shared_prog " $func_quote_arg_result" done test -z "$install_prog" && \ @@ -4181,8 +4570,8 @@ func_mode_install () if test -n "$install_override_mode" && $no_mode; then if $install_cp; then :; else - func_quote_for_eval "$install_override_mode" - func_append install_shared_prog " -m $func_quote_for_eval_result" + func_quote_arg pretty "$install_override_mode" + func_append install_shared_prog " -m $func_quote_arg_result" fi fi @@ -4275,8 +4664,15 @@ func_mode_install () func_append dir "$objdir" if test -n "$relink_command"; then + # Strip any trailing slash from the destination. + func_stripname '' '/' "$libdir" + destlibdir=$func_stripname_result + + func_stripname '' '/' "$destdir" + s_destdir=$func_stripname_result + # Determine the prefix the user has applied to our future dir. - inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` + inst_prefix_dir=`$ECHO "X$s_destdir" | $Xsed -e "s%$destlibdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that @@ -4313,7 +4709,7 @@ func_mode_install () 'exit $?' tstripme=$stripme case $host_os in - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) case $realname in *.dll.a) tstripme= @@ -4426,7 +4822,7 @@ func_mode_install () # Do a test to see if this is really a libtool program. case $host in - *cygwin* | *mingw*) + *cygwin* | *mingw* | *windows*) if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" wrapper=$func_ltwrapper_scriptname_result @@ -4478,8 +4874,8 @@ func_mode_install () relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` $opt_quiet || { - func_quote_for_expand "$relink_command" - eval "func_echo $func_quote_for_expand_result" + func_quote_arg expand,pretty "$relink_command" + eval "func_echo $func_quote_arg_result" } if eval "$relink_command"; then : else @@ -4654,7 +5050,7 @@ extern \"C\" { $RM $export_symbols eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in - *cygwin* | *mingw* | *cegcc* ) + *cygwin* | *mingw* | *windows* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; @@ -4666,7 +5062,7 @@ extern \"C\" { eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' case $host in - *cygwin* | *mingw* | *cegcc* ) + *cygwin* | *mingw* | *windows* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; @@ -4680,7 +5076,7 @@ extern \"C\" { func_basename "$dlprefile" name=$func_basename_result case $host in - *cygwin* | *mingw* | *cegcc* ) + *cygwin* | *mingw* | *windows* | *cegcc* ) # if an import library, we need to obtain dlname if func_win32_import_lib_p "$dlprefile"; then func_tr_sh "$dlprefile" @@ -4706,8 +5102,16 @@ extern \"C\" { eval '$ECHO ": $name " >> "$nlist"' fi func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 - eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | - $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + case $host in + i[3456]86-*-mingw32*) + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + ;; + *) + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/__nm_//' >> '$nlist'" + ;; + esac } else # not an import lib $opt_dry_run || { @@ -4855,7 +5259,7 @@ static const void *lt_preloaded_setup() { # Transform the symbol file into the correct name. symfileobj=$output_objdir/${my_outputname}S.$objext case $host in - *cygwin* | *mingw* | *cegcc* ) + *cygwin* | *mingw* | *windows* | *cegcc* ) if test -f "$output_objdir/$my_outputname.def"; then compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` @@ -4931,7 +5335,7 @@ func_win32_libid () *ar\ archive*) # could be an import, or static # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | - $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64|pe-aarch64)' >/dev/null; then case $nm_interface in "MS dumpbin") if func_cygming_ms_implib_p "$1" || @@ -5198,7 +5602,7 @@ func_extract_archives () # # Emit a libtool wrapper script on stdout. # Don't directly open a file because we may want to -# incorporate the script contents within a cygwin/mingw +# incorporate the script contents within a cygwin/mingw/windows # wrapper executable. Must ONLY be called from within # func_mode_link because it depends on a number of variables # set therein. @@ -5206,7 +5610,7 @@ func_extract_archives () # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR # variable will take. If 'yes', then the emitted script # will assume that the directory where it is stored is -# the $objdir directory. This is a cygwin/mingw-specific +# the $objdir directory. This is a cygwin/mingw/windows-specific # behavior. func_emit_wrapper () { @@ -5258,7 +5662,8 @@ else if test \"\$libtool_execute_magic\" != \"$magic\"; then file=\"\$0\"" - qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + func_quote_arg pretty "$ECHO" + qECHO=$func_quote_arg_result $ECHO "\ # A function that is used when there is no print builtin or printf. @@ -5268,7 +5673,7 @@ func_fallback_echo () \$1 _LTECHO_EOF' } - ECHO=\"$qECHO\" + ECHO=$qECHO fi # Very basic option parsing. These options are (a) specific to @@ -5330,7 +5735,7 @@ func_exec_program_core () " case $host in # Backslashes separate directories on plain windows - *-*-mingw | *-*-os2* | *-cegcc*) + *-*-mingw* | *-*-windows* | *-*-os2* | *-cegcc*) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 @@ -5398,7 +5803,7 @@ func_exec_program () file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` done - # Usually 'no', except on cygwin/mingw when embedded into + # Usually 'no', except on cygwin/mingw/windows when embedded into # the cwrapper. WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then @@ -5530,7 +5935,7 @@ EOF #endif #include <stdio.h> #include <stdlib.h> -#ifdef _MSC_VER +#if defined _WIN32 && !defined __GNUC__ # include <direct.h> # include <process.h> # include <io.h> @@ -5555,7 +5960,7 @@ EOF /* declarations of non-ANSI functions */ #if defined __MINGW32__ # ifdef __STRICT_ANSI__ -int _putenv (const char *); +_CRTIMP int __cdecl _putenv (const char *); # endif #elif defined __CYGWIN__ # ifdef __STRICT_ANSI__ @@ -5753,7 +6158,7 @@ main (int argc, char *argv[]) { EOF case $host in - *mingw* | *cygwin* ) + *mingw* | *windows* | *cygwin* ) # make stdout use "unix" line endings echo " setmode(1,_O_BINARY);" ;; @@ -5772,7 +6177,7 @@ EOF { /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX namespace, but it is not one of the ones we know about and - have already dealt with, above (inluding dump-script), then + have already dealt with, above (including dump-script), then report an error. Otherwise, targets might begin to believe they are allowed to use options in the LTWRAPPER_OPTION_PREFIX namespace. The first time any user complains about this, we'll @@ -5856,7 +6261,7 @@ EOF EOF case $host_os in - mingw*) + mingw* | windows*) cat <<"EOF" { char* p; @@ -5898,7 +6303,7 @@ EOF EOF case $host_os in - mingw*) + mingw* | windows*) cat <<"EOF" /* execv doesn't actually work on mingw as expected on unix */ newargz = prepare_spawn (newargz); @@ -6317,7 +6722,7 @@ lt_update_lib_path (const char *name, const char *value) EOF case $host_os in - mingw*) + mingw* | windows*) cat <<"EOF" /* Prepares an argument vector before calling spawn(). @@ -6492,7 +6897,7 @@ func_mode_link () $debug_cmd case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-os2* | *-cegcc*) # It is impossible to link a dll without this setting, and # we shouldn't force the makefile maintainer to figure out # what system we are compiling for in order to pass an extra @@ -6516,6 +6921,7 @@ func_mode_link () finalize_command=$nonopt compile_rpath= + compile_rpath_tail= finalize_rpath= compile_shlibpath= finalize_shlibpath= @@ -6556,10 +6962,12 @@ func_mode_link () xrpath= perm_rpath= temp_rpath= + temp_rpath_tail= thread_safe=no vinfo= vinfo_number=no weak_libs= + rpath_arg= single_module=$wl-single_module func_infer_tag $base_compile @@ -6611,9 +7019,9 @@ func_mode_link () while test "$#" -gt 0; do arg=$1 shift - func_quote_for_eval "$arg" - qarg=$func_quote_for_eval_unquoted_result - func_append libtool_args " $func_quote_for_eval_result" + func_quote_arg pretty,unquoted "$arg" + qarg=$func_quote_arg_unquoted_result + func_append libtool_args " $func_quote_arg_result" # If the previous option needs an argument, assign it. if test -n "$prev"; then @@ -6822,7 +7230,7 @@ func_mode_link () case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) - func_fatal_error "only absolute run-paths are allowed" + func_fatal_error "argument to -rpath is not absolute: $arg" ;; esac if test rpath = "$prev"; then @@ -6849,6 +7257,13 @@ func_mode_link () prev= continue ;; + xassembler) + func_append compiler_flags " -Xassembler $qarg" + prev= + func_append compile_command " -Xassembler $qarg" + func_append finalize_command " -Xassembler $qarg" + continue + ;; xcclinker) func_append linker_flags " $qarg" func_append compiler_flags " $qarg" @@ -6991,7 +7406,7 @@ func_mode_link () ;; esac case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; @@ -7011,7 +7426,7 @@ func_mode_link () -l*) if test X-lc = "X$arg" || test X-lm = "X$arg"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) # These systems don't actually have a C or math library (as such) continue ;; @@ -7019,7 +7434,7 @@ func_mode_link () # These systems don't actually have a C library (as such) test X-lc = "X$arg" && continue ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. test X-lc = "X$arg" && continue ;; @@ -7039,7 +7454,7 @@ func_mode_link () esac elif test X-lc_r = "X$arg"; then case $host in - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) # Do not include libc_r directly, use -pthread flag. continue ;; @@ -7062,16 +7477,29 @@ func_mode_link () # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. # Darwin uses the -arch flag to determine output architecture. - -model|-arch|-isysroot|--sysroot) + # -q <option> for IBM XL C/C++ compiler. + -model|-arch|-isysroot|--sysroot|-q) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" prev=xcompiler continue ;; - - -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + # Solaris ld rejects as of 11.4. Refer to Oracle bug 22985199. + -pthread) + case $host in + *solaris2*) ;; + *) + case "$new_inherited_linker_flags " in + *" $arg "*) ;; + * ) func_append new_inherited_linker_flags " $arg" ;; + esac + ;; + esac + continue + ;; + -mt|-mthreads|-kthread|-Kthread|-pthreads|--thread-safe \ + |-threads|-fopenmp|-fopenmp=*|-openmp|-mp|-xopenmp|-omp|-qsmp=*) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" @@ -7094,7 +7522,7 @@ func_mode_link () -no-install) case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. func_warning "'-no-install' is ignored for $host" @@ -7154,7 +7582,7 @@ func_mode_link () dir=$lt_sysroot$func_stripname_result ;; *) - func_fatal_error "only absolute run-paths are allowed" + func_fatal_error "argument ($arg) to '-R' is not an absolute path: $dir" ;; esac case "$xrpath " in @@ -7211,9 +7639,9 @@ func_mode_link () save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs - func_quote_for_eval "$flag" - func_append arg " $func_quote_for_eval_result" - func_append compiler_flags " $func_quote_for_eval_result" + func_quote_arg pretty "$flag" + func_append arg " $func_quote_arg_result" + func_append compiler_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" @@ -7227,16 +7655,21 @@ func_mode_link () save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs - func_quote_for_eval "$flag" - func_append arg " $wl$func_quote_for_eval_result" - func_append compiler_flags " $wl$func_quote_for_eval_result" - func_append linker_flags " $func_quote_for_eval_result" + func_quote_arg pretty "$flag" + func_append arg " $wl$func_quote_arg_result" + func_append compiler_flags " $wl$func_quote_arg_result" + func_append linker_flags " $func_quote_arg_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; + -Xassembler) + prev=xassembler + continue + ;; + -Xcompiler) prev=xcompiler continue @@ -7254,8 +7687,8 @@ func_mode_link () # -msg_* for osf cc -msg_*) - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result + func_quote_arg pretty "$arg" + arg=$func_quote_arg_result ;; # Flags to be passed through unchanged, with rationale: @@ -7272,12 +7705,33 @@ func_mode_link () # -tp=* Portland pgcc target processor selection # --sysroot=* for sysroot support # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization + # -specs=* GCC specs files # -stdlib=* select c++ std lib with clang + # -fdiagnostics-color* simply affects output + # -frecord-gcc-switches used to verify flags were respected + # -fsanitize=* Clang/GCC memory and address sanitizer + # -fno-sanitize* Clang/GCC memory and address sanitizer + # -shared-libsan Link with shared sanitizer runtimes (Clang) + # -static-libsan Link with static sanitizer runtimes (Clang) + # -no-canonical-prefixes Do not expand any symbolic links + # -fuse-ld=* Linker select flags for GCC + # -static-* direct GCC to link specific libraries statically + # -fcilkplus Cilk Plus language extension features for C/C++ + # -rtlib=* select c runtime lib with clang + # --unwindlib=* select unwinder library with clang + # -f{file|debug|macro|profile}-prefix-map=* needed for lto linking + # -Wa,* Pass flags directly to the assembler + # -Werror, -Werror=* Report (specified) warnings as errors -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ - -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*) - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result + -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-no-canonical-prefixes| \ + -stdlib=*|-rtlib=*|--unwindlib=*| \ + -specs=*|-fsanitize=*|-fno-sanitize*|-shared-libsan|-static-libsan| \ + -ffile-prefix-map=*|-fdebug-prefix-map=*|-fmacro-prefix-map=*|-fprofile-prefix-map=*| \ + -fdiagnostics-color*|-frecord-gcc-switches| \ + -fuse-ld=*|-static-*|-fcilkplus|-Wa,*|-Werror|-Werror=*) + func_quote_arg pretty "$arg" + arg=$func_quote_arg_result func_append compile_command " $arg" func_append finalize_command " $arg" func_append compiler_flags " $arg" @@ -7298,15 +7752,15 @@ func_mode_link () continue else # Otherwise treat like 'Some other compiler flag' below - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result + func_quote_arg pretty "$arg" + arg=$func_quote_arg_result fi ;; # Some other compiler flag. -* | +*) - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result + func_quote_arg pretty "$arg" + arg=$func_quote_arg_result ;; *.$objext) @@ -7426,15 +7880,27 @@ func_mode_link () *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. - func_quote_for_eval "$arg" - arg=$func_quote_for_eval_result + func_quote_arg pretty "$arg" + arg=$func_quote_arg_result ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then - func_append compile_command " $arg" - func_append finalize_command " $arg" + if test -n "$rpath_arg"; then + func_append finalize_rpath " ${arg##*,}" + unset rpath_arg + else + case $arg in + -Wl,-rpath,*) + func_append finalize_rpath " ${arg##*,}";; + -Wl,-rpath) + rpath_arg=1;; + *) + func_append compile_command " $arg" + func_append finalize_command " $arg" + esac + fi fi done # argument parsing loop @@ -7605,7 +8071,7 @@ func_mode_link () found=false case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ - |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) + |-threads|-fopenmp|-fopenmp=*|-openmp|-mp|-xopenmp|-omp|-qsmp=*) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" @@ -7782,18 +8248,15 @@ func_mode_link () ;; esac if $valid_a_lib; then - echo - $ECHO "*** Warning: Linking the shared library $output against the" - $ECHO "*** static library $deplib is not portable!" + func_warning "Linking the shared library $output against the static library $deplib is not portable!" deplibs="$deplib $deplibs" else - echo - $ECHO "*** Warning: Trying to link with static lib archive $deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because the file extensions .$libext of this argument makes me believe" - echo "*** that it is just a static archive that I should not use here." + func_warning "Trying to link with static lib archive $deplib." + func_warning "I have the capability to make that library automatically link in when" + func_warning "you link to this library. But I can only do this if you have a" + func_warning "shared version of the library, which you do not appear to have" + func_warning "because the file extensions .$libext of this argument makes me believe" + func_warning "that it is just a static archive that I should not use here." fi ;; esac @@ -7988,7 +8451,7 @@ func_mode_link () fi case $host in # special handling for platforms with PE-DLLs. - *cygwin* | *mingw* | *cegcc* ) + *cygwin* | *mingw* | *windows* | *cegcc* ) # Linker will automatically link against shared library if both # static and shared are present. Therefore, ensure we extract # symbols from the import library if a shared library is present @@ -8088,7 +8551,10 @@ func_mode_link () # Make sure the rpath contains only unique directories. case $temp_rpath: in *"$absdir:"*) ;; - *) func_append temp_rpath "$absdir:" ;; + *) case $absdir in + "$progdir/"*) func_append temp_rpath "$absdir:" ;; + *) func_append temp_rpath_tail "$absdir:" ;; + esac esac fi @@ -8098,9 +8564,12 @@ func_mode_link () case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) - case "$compile_rpath " in + case "$compile_rpath$compile_rpath_tail " in *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; + *) case $absdir in + "$progdir/"*) func_append compile_rpath " $absdir" ;; + *) func_append compile_rpath_tail " $absdir" ;; + esac esac ;; esac @@ -8131,8 +8600,8 @@ func_mode_link () fi if test -n "$library_names" && { test no = "$use_static_libs" || test -z "$old_library"; }; then - case $host in - *cygwin* | *mingw* | *cegcc* | *os2*) + case $host_os in + cygwin* | mingw* | windows* | cegcc* | os2*) # No point in relinking DLLs because paths are not encoded func_append notinst_deplibs " $lib" need_relink=no @@ -8158,11 +8627,11 @@ func_mode_link () if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then echo if test prog = "$linkmode"; then - $ECHO "*** Warning: Linking the executable $output against the loadable module" + func_warning "Linking the executable $output against the loadable module" else - $ECHO "*** Warning: Linking the shared library $output against the loadable module" + func_warning "Linking the shared library $output against the loadable module" fi - $ECHO "*** $linklib is not portable!" + func_warning "$linklib is not portable!" fi if test lib = "$linkmode" && test yes = "$hardcode_into_libs"; then @@ -8172,9 +8641,12 @@ func_mode_link () case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) - case "$compile_rpath " in + case "$compile_rpath$compile_rpath_tail " in *" $absdir "*) ;; - *) func_append compile_rpath " $absdir" ;; + *) case $absdir in + "$progdir/"*) func_append compile_rpath " $absdir" ;; + *) func_append compile_rpath_tail " $absdir" ;; + esac esac ;; esac @@ -8201,8 +8673,8 @@ func_mode_link () soname=$dlname elif test -n "$soname_spec"; then # bleh windows - case $host in - *cygwin* | mingw* | *cegcc* | *os2*) + case $host_os in + cygwin* | mingw* | windows* | cegcc* | os2*) func_arith $current - $age major=$func_arith_result versuffix=-$major @@ -8249,6 +8721,7 @@ func_mode_link () case $host in *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; *-*-sysv4*uw2*) add_dir=-L$dir ;; + *-*-emscripten*) add_dir=-L$dir ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir=-L$dir ;; *-*-darwin* ) @@ -8257,11 +8730,10 @@ func_mode_link () if /usr/bin/file -L $add 2> /dev/null | $GREP ": [^:]* bundle" >/dev/null; then if test "X$dlopenmodule" != "X$lib"; then - $ECHO "*** Warning: lib $linklib is a module, not a shared library" + func_warning "lib $linklib is a module, not a shared library" if test -z "$old_library"; then - echo - echo "*** And there doesn't seem to be a static archive available" - echo "*** The link will probably fail, sorry" + func_warning "And there doesn't seem to be a static archive available" + func_warning "The link will probably fail, sorry" else add=$dir/$old_library fi @@ -8344,7 +8816,7 @@ func_mode_link () test no = "$hardcode_direct_absolute"; then add=$libdir/$linklib elif test yes = "$hardcode_minus_L"; then - add_dir=-L$libdir + add_dir=-L$lt_sysroot$libdir add=-l$name elif test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in @@ -8361,7 +8833,7 @@ func_mode_link () fi else # We cannot seem to hardcode it, guess we'll fake it. - add_dir=-L$libdir + add_dir=-L$lt_sysroot$libdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in @@ -8401,21 +8873,19 @@ func_mode_link () # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. - echo - $ECHO "*** Warning: This system cannot link to static lib archive $lib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have." + func_warning "This system cannot link to static lib archive $lib." + func_warning "I have the capability to make that library automatically link in when" + func_warning "you link to this library. But I can only do this if you have a" + func_warning "shared version of the library, which you do not appear to have." if test yes = "$module"; then - echo "*** But as you try to build a module library, libtool will still create " - echo "*** a static module, that should work as long as the dlopening application" - echo "*** is linked with the -dlopen flag to resolve symbols at runtime." + func_warning "But as you try to build a module library, libtool will still create " + func_warning "a static module, that should work as long as the dlopening application" + func_warning "is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using 'nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** 'nm' from GNU binutils and a full rebuild may help." + func_warning "However, this would only work if libtool was able to extract symbol" + func_warning "lists from a program, using 'nm' or equivalent, but libtool could" + func_warning "not find such a program. So, this module is probably useless." + func_warning "'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then build_libtool_libs=module @@ -8538,6 +9008,10 @@ func_mode_link () fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs + + func_append temp_rpath "$temp_rpath_tail" + func_append compile_rpath "$compile_rpath_tail" + if test link = "$pass"; then if test prog = "$linkmode"; then compile_deplibs="$new_inherited_linker_flags $compile_deplibs" @@ -8575,42 +9049,46 @@ func_mode_link () # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= + # FIXME: Pedantically, this is the right thing to do, so + # that some nasty dependency loop isn't accidentally + # broken: new_libs="$deplib $new_libs" for deplib in $tmp_libs; do - # FIXME: Pedantically, this is the right thing to do, so - # that some nasty dependency loop isn't accidentally - # broken: - #new_libs="$deplib $new_libs" - # Pragmatically, this seems to cause very few problems in - # practice: - case $deplib in - -L*) new_libs="$deplib $new_libs" ;; - -R*) ;; - *) - # And here is the reason: when a library appears more - # than once as an explicit dependence of a library, or - # is implicitly linked in more than once by the - # compiler, it is considered special, and multiple - # occurrences thereof are not removed. Compare this - # with having the same library being listed as a - # dependency of multiple other libraries: in this case, - # we know (pedantically, we assume) the library does not - # need to be listed more than once, so we keep only the - # last copy. This is not always right, but it is rare - # enough that we require users that really mean to play - # such unportable linking tricks to link the library - # using -Wl,-lname, so that libtool does not consider it - # for duplicate removal. - case " $specialdeplibs " in - *" $deplib "*) new_libs="$deplib $new_libs" ;; + if $opt_preserve_dup_deps; then + new_libs="$deplib $new_libs" + else + # Pragmatically, this seems to cause very few problems in + # practice: + case $deplib in + -L*) new_libs="$deplib $new_libs" ;; + -R*) ;; *) - case " $new_libs " in - *" $deplib "*) ;; - *) new_libs="$deplib $new_libs" ;; - esac - ;; + # And here is the reason: when a library appears more + # than once as an explicit dependence of a library, or + # is implicitly linked in more than once by the + # compiler, it is considered special, and multiple + # occurrences thereof are not removed. Compare this + # with having the same library being listed as a + # dependency of multiple other libraries: in this case, + # we know (pedantically, we assume) the library does not + # need to be listed more than once, so we keep only the + # last copy. This is not always right, but it is rare + # enough that we require users that really mean to play + # such unportable linking tricks to link the library + # using -Wl,-lname, so that libtool does not consider it + # for duplicate removal. And if not possible for portability + # reasons, then --preserve-dup-deps should be used. + case " $specialdeplibs " in + *" $deplib "*) new_libs="$deplib $new_libs" ;; + *) + case " $new_libs " in + *" $deplib "*) ;; + *) new_libs="$deplib $new_libs" ;; + esac + ;; + esac + ;; esac - ;; - esac + fi done tmp_libs= for deplib in $new_libs; do @@ -8632,7 +9110,7 @@ func_mode_link () test CXX = "$tagname" && { case $host_os in linux*) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 func_suncc_cstd_abi @@ -8742,9 +9220,7 @@ func_mode_link () if test pass_all != "$deplibs_check_method"; then func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" else - echo - $ECHO "*** Warning: Linking the shared library $output against the non-libtool" - $ECHO "*** objects $objs is not portable!" + func_warning "Linking the shared library $output against the non-libtool objects $objs is not portable!" func_append libobjs " $objs" fi fi @@ -8805,13 +9281,13 @@ func_mode_link () # case $version_type in # correct linux to gnu/linux during the next big refactor - darwin|freebsd-elf|linux|osf|windows|none) + darwin|freebsd-elf|linux|midnightbsd-elf|osf|qnx|windows|none) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_revision ;; - freebsd-aout|qnx|sunos) + freebsd-aout|sco|sunos) current=$number_major revision=$number_minor age=0 @@ -8823,6 +9299,9 @@ func_mode_link () revision=$number_minor lt_irix_increment=no ;; + *) + func_fatal_configuration "$modename: unknown library version type '$version_type'" + ;; esac ;; no) @@ -8896,7 +9375,7 @@ func_mode_link () versuffix=.$current.$revision ;; - freebsd-elf) + freebsd-elf | midnightbsd-elf) func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision @@ -8958,8 +9437,9 @@ func_mode_link () ;; qnx) - major=.$current - versuffix=.$current + func_arith $current - $age + major=.$func_arith_result + versuffix=$major.$age.$revision ;; sco) @@ -9112,7 +9592,7 @@ func_mode_link () if test yes = "$build_libtool_libs"; then if test -n "$rpath"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) @@ -9122,7 +9602,7 @@ func_mode_link () *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; - *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-midnightbsd*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) @@ -9163,108 +9643,6 @@ func_mode_link () # implementing what was already the behavior. newdeplibs=$deplibs ;; - test_compile) - # This code stresses the "libraries are programs" paradigm to its - # limits. Maybe even breaks it. We compile a program, linking it - # against the deplibs as a proxy for the library. Then we can check - # whether they linked in statically or dynamically with ldd. - $opt_dry_run || $RM conftest.c - cat > conftest.c <<EOF - int main() { return 0; } -EOF - $opt_dry_run || $RM conftest - if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then - ldd_output=`ldd conftest` - for i in $deplibs; do - case $i in - -l*) - func_stripname -l '' "$i" - name=$func_stripname_result - if test yes = "$allow_libtool_libs_with_static_runtimes"; then - case " $predeps $postdeps " in - *" $i "*) - func_append newdeplibs " $i" - i= - ;; - esac - fi - if test -n "$i"; then - libname=`eval "\\$ECHO \"$libname_spec\""` - deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` - set dummy $deplib_matches; shift - deplib_match=$1 - if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then - func_append newdeplibs " $i" - else - droppeddeps=yes - echo - $ECHO "*** Warning: dynamic linker does not accept needed library $i." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which I believe you do not have" - echo "*** because a test_compile did reveal that the linker did not use it for" - echo "*** its dynamic dependency list that programs get resolved with at runtime." - fi - fi - ;; - *) - func_append newdeplibs " $i" - ;; - esac - done - else - # Error occurred in the first compile. Let's try to salvage - # the situation: Compile a separate program for each library. - for i in $deplibs; do - case $i in - -l*) - func_stripname -l '' "$i" - name=$func_stripname_result - $opt_dry_run || $RM conftest - if $LTCC $LTCFLAGS -o conftest conftest.c $i; then - ldd_output=`ldd conftest` - if test yes = "$allow_libtool_libs_with_static_runtimes"; then - case " $predeps $postdeps " in - *" $i "*) - func_append newdeplibs " $i" - i= - ;; - esac - fi - if test -n "$i"; then - libname=`eval "\\$ECHO \"$libname_spec\""` - deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` - set dummy $deplib_matches; shift - deplib_match=$1 - if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then - func_append newdeplibs " $i" - else - droppeddeps=yes - echo - $ECHO "*** Warning: dynamic linker does not accept needed library $i." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because a test_compile did reveal that the linker did not use this one" - echo "*** as a dynamic dependency that programs can get resolved with at runtime." - fi - fi - else - droppeddeps=yes - echo - $ECHO "*** Warning! Library $i is needed by this library but I was not able to" - echo "*** make it link in! You will probably need to install it or some" - echo "*** library that it depends on before this library will be fully" - echo "*** functional. Installing it before continuing would be even better." - fi - ;; - *) - func_append newdeplibs " $i" - ;; - esac - done - fi - ;; file_magic*) set dummy $deplibs_check_method; shift file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` @@ -9328,17 +9706,16 @@ EOF fi if test -n "$a_deplib"; then droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" + func_warning "Linker path does not have real file for library $a_deplib." + func_warning "I have the capability to make that library automatically link in when" + func_warning "you link to this library. But I can only do this if you have a" + func_warning "shared version of the library, which you do not appear to have" + func_warning "because I did check the linker path looking for a file starting" if test -z "$potlib"; then - $ECHO "*** with $libname but no candidates were found. (...for file magic test)" + func_warning "with $libname but no candidates were found. (...for file magic test)" else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a file magic. Last file checked: $potlib" + func_warning "with $libname and none of the candidates passed a file format test" + func_warning "using a file magic. Last file checked: $potlib" fi fi ;; @@ -9382,17 +9759,16 @@ EOF fi if test -n "$a_deplib"; then droppeddeps=yes - echo - $ECHO "*** Warning: linker path does not have real file for library $a_deplib." - echo "*** I have the capability to make that library automatically link in when" - echo "*** you link to this library. But I can only do this if you have a" - echo "*** shared version of the library, which you do not appear to have" - echo "*** because I did check the linker path looking for a file starting" + func_warning "Linker path does not have real file for library $a_deplib." + func_warning "I have the capability to make that library automatically link in when" + func_warning "you link to this library. But I can only do this if you have a" + func_warning "shared version of the library, which you do not appear to have" + func_warning "because I did check the linker path looking for a file starting" if test -z "$potlib"; then - $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" + func_warning "with $libname but no candidates were found. (...for regex pattern test)" else - $ECHO "*** with $libname and none of the candidates passed a file format test" - $ECHO "*** using a regex pattern. Last file checked: $potlib" + func_warning "with $libname and none of the candidates passed a file format test" + func_warning "using a regex pattern. Last file checked: $potlib" fi fi ;; @@ -9416,11 +9792,11 @@ EOF *[!\ \ ]*) echo if test none = "$deplibs_check_method"; then - echo "*** Warning: inter-library dependencies are not supported in this platform." + func_warning "Inter-library dependencies are not supported in this platform." else - echo "*** Warning: inter-library dependencies are not known to be supported." + func_warning "Inter-library dependencies are not known to be supported." fi - echo "*** All declared inter-library dependencies are being dropped." + func_warning "All declared inter-library dependencies are being dropped." droppeddeps=yes ;; esac @@ -9441,17 +9817,15 @@ EOF if test yes = "$droppeddeps"; then if test yes = "$module"; then - echo - echo "*** Warning: libtool could not satisfy all declared inter-library" - $ECHO "*** dependencies of module $libname. Therefore, libtool will create" - echo "*** a static module, that should work as long as the dlopening" - echo "*** application is linked with the -dlopen flag." + func_warning "libtool could not satisfy all declared inter-library" + func_warning "dependencies of module $libname. Therefore, libtool will create" + func_warning "a static module, that should work as long as the dlopening" + func_warning "application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then - echo - echo "*** However, this would only work if libtool was able to extract symbol" - echo "*** lists from a program, using 'nm' or equivalent, but libtool could" - echo "*** not find such a program. So, this module is probably useless." - echo "*** 'nm' from GNU binutils and a full rebuild may help." + func_warning "However, this would only work if libtool was able to extract symbol" + func_warning "lists from a program, using 'nm' or equivalent, but libtool could" + func_warning "not find such a program. So, this module is probably useless." + func_warning "'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext @@ -9626,7 +10000,7 @@ EOF orig_export_symbols= case $host_os in - cygwin* | mingw* | cegcc*) + cygwin* | mingw* | windows* | cegcc*) if test -n "$export_symbols" && test -z "$export_symbols_regex"; then # exporting using user supplied symfile func_dll_def_p "$export_symbols" || { @@ -9824,20 +10198,7 @@ EOF last_robj= k=1 - if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then - output=$output_objdir/$output_la.lnkscript - func_verbose "creating GNU ld script: $output" - echo 'INPUT (' > $output - for obj in $save_libobjs - do - func_to_tool_file "$obj" - $ECHO "$func_to_tool_file_result" >> $output - done - echo ')' >> $output - func_append delfiles " $output" - func_to_tool_file "$output" - output=$func_to_tool_file_result - elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then + if test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then output=$output_objdir/$output_la.lnk func_verbose "creating linker input file list: $output" : > $output @@ -9856,6 +10217,19 @@ EOF func_append delfiles " $output" func_to_tool_file "$output" output=$firstobj\"$file_list_spec$func_to_tool_file_result\" + elif test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then + output=$output_objdir/$output_la.lnkscript + func_verbose "creating GNU ld script: $output" + echo 'INPUT (' > $output + for obj in $save_libobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output + done + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result else if test -n "$save_libobjs"; then func_verbose "creating reloadable object files..." @@ -9933,8 +10307,8 @@ EOF for cmd in $concat_cmds; do IFS=$save_ifs $opt_quiet || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" + func_quote_arg expand,pretty "$cmd" + eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? @@ -10027,8 +10401,8 @@ EOF eval cmd=\"$cmd\" IFS=$save_ifs $opt_quiet || { - func_quote_for_expand "$cmd" - eval "func_echo $func_quote_for_expand_result" + func_quote_arg expand,pretty "$cmd" + eval "func_echo $func_quote_arg_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? @@ -10296,7 +10670,7 @@ EOF esac fi case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + *-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; @@ -10374,7 +10748,7 @@ EOF # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. wrappers_required=false ;; - *cygwin* | *mingw* ) + *cygwin* | *mingw* | *windows* ) test yes = "$build_libtool_libs" || wrappers_required=false ;; *) @@ -10502,12 +10876,13 @@ EOF elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + func_quote_arg pretty "$var_value" + relink_command="$var=$func_quote_arg_result; export $var; $relink_command" fi done - relink_command="(cd `pwd`; $relink_command)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + func_quote eval cd "`pwd`" + func_quote_arg pretty,unquoted "($func_quote_result; $relink_command)" + relink_command=$func_quote_arg_unquoted_result fi # Only actually do things if not in dry run mode. @@ -10527,7 +10902,7 @@ EOF *) exeext= ;; esac case $host in - *cygwin* | *mingw* ) + *cygwin* | *mingw* | windows* ) func_dirname_and_basename "$output" "" "." output_name=$func_basename_result output_path=$func_dirname_result @@ -10747,13 +11122,15 @@ EOF elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else - func_quote_for_eval "$var_value" - relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" + func_quote_arg pretty,unquoted "$var_value" + relink_command="$var=$func_quote_arg_unquoted_result; export $var; $relink_command" fi done # Quote the link command for shipping. - relink_command="(cd `pwd`; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" - relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` + func_quote eval cd "`pwd`" + relink_command="($func_quote_result; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" + func_quote_arg pretty,unquoted "$relink_command" + relink_command=$func_quote_arg_unquoted_result if test yes = "$hardcode_automatic"; then relink_command= fi @@ -10859,7 +11236,7 @@ EOF # tests/bindir.at for full details. tdlname=$dlname case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *windows*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) # If a -bindir argument was supplied, place the dll there. if test -n "$bindir"; then func_relative_path "$install_libdir" "$bindir" diff --git a/subprojects/libsodium/build-aux/missing b/subprojects/libsodium/build-aux/missing @@ -1,9 +1,11 @@ #! /bin/sh -# Common wrapper for a few potentially missing GNU programs. +# Common wrapper for a few potentially missing GNU and other programs. -scriptversion=2018-03-07.03; # UTC +scriptversion=2025-06-18.21; # UTC -# Copyright (C) 1996-2018 Free Software Foundation, Inc. +# shellcheck disable=SC2006,SC2268 # we must support pre-POSIX shells + +# Copyright (C) 1996-2025 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996. # This program is free software; you can redistribute it and/or modify @@ -54,18 +56,20 @@ Options: -v, --version output version information and exit Supported PROGRAM values: - aclocal autoconf autoheader autom4te automake makeinfo - bison yacc flex lex help2man +aclocal autoconf autogen autoheader autom4te automake autoreconf +bison flex help2man lex makeinfo perl yacc Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and 'g' are ignored when checking the name. -Send bug reports to <bug-automake@gnu.org>." +Report bugs to <bug-automake@gnu.org>. +GNU Automake home page: <https://www.gnu.org/software/automake/>. +General help using GNU software: <https://www.gnu.org/gethelp/>." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) - echo "missing $scriptversion (GNU Automake)" + echo "missing (GNU Automake) $scriptversion" exit $? ;; @@ -108,7 +112,7 @@ gnu_software_URL=https://www.gnu.org/software program_details () { case $1 in - aclocal|automake) + aclocal|automake|autoreconf) echo "The '$1' program is part of the GNU Automake package:" echo "<$gnu_software_URL/automake>" echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" @@ -123,6 +127,9 @@ program_details () echo "<$gnu_software_URL/m4/>" echo "<$perl_URL>" ;; + *) + : + ;; esac } @@ -137,48 +144,55 @@ give_advice () printf '%s\n' "'$1' is $msg." configure_deps="'configure.ac' or m4 files included by 'configure.ac'" + autoheader_deps="'acconfig.h'" + automake_deps="'Makefile.am'" + aclocal_deps="'acinclude.m4'" case $normalized_program in + aclocal*) + echo "You should only need it if you modified $aclocal_deps or" + echo "$configure_deps." + ;; autoconf*) - echo "You should only need it if you modified 'configure.ac'," - echo "or m4 files included by it." - program_details 'autoconf' + echo "You should only need it if you modified $configure_deps." + ;; + autogen*) + echo "You should only need it if you modified a '.def' or '.tpl' file." + echo "You may want to install the GNU AutoGen package:" + echo "<$gnu_software_URL/autogen/>" ;; autoheader*) - echo "You should only need it if you modified 'acconfig.h' or" + echo "You should only need it if you modified $autoheader_deps or" echo "$configure_deps." - program_details 'autoheader' ;; automake*) - echo "You should only need it if you modified 'Makefile.am' or" - echo "$configure_deps." - program_details 'automake' - ;; - aclocal*) - echo "You should only need it if you modified 'acinclude.m4' or" + echo "You should only need it if you modified $automake_deps or" echo "$configure_deps." - program_details 'aclocal' ;; - autom4te*) + autom4te*) echo "You might have modified some maintainer files that require" echo "the 'autom4te' program to be rebuilt." - program_details 'autom4te' + ;; + autoreconf*) + echo "You should only need it if you modified $aclocal_deps or" + echo "$automake_deps or $autoheader_deps or $automake_deps or" + echo "$configure_deps." ;; bison*|yacc*) echo "You should only need it if you modified a '.y' file." echo "You may want to install the GNU Bison package:" echo "<$gnu_software_URL/bison/>" ;; - lex*|flex*) - echo "You should only need it if you modified a '.l' file." - echo "You may want to install the Fast Lexical Analyzer package:" - echo "<$flex_URL>" - ;; help2man*) echo "You should only need it if you modified a dependency" \ "of a man page." echo "You may want to install the GNU Help2man package:" echo "<$gnu_software_URL/help2man/>" ;; + lex*|flex*) + echo "You should only need it if you modified a '.l' file." + echo "You may want to install the Fast Lexical Analyzer package:" + echo "<$flex_URL>" + ;; makeinfo*) echo "You should only need it if you modified a '.texi' file, or" echo "any other file indirectly affecting the aspect of the manual." @@ -189,6 +203,12 @@ give_advice () echo "want to install GNU make:" echo "<$gnu_software_URL/make/>" ;; + perl*) + echo "You should only need it to run GNU Autoconf, GNU Automake, " + echo " assorted other tools, or if you modified a Perl source file." + echo "You may want to install the Perl 5 language interpreter:" + echo "<$perl_URL>" + ;; *) echo "You might have modified some files without having the proper" echo "tools for further handling them. Check the 'README' file, it" @@ -197,6 +217,7 @@ give_advice () echo "case some other package contains this missing '$1' program." ;; esac + program_details "$normalized_program" } give_advice "$1" | sed -e '1s/^/WARNING: /' \ @@ -207,9 +228,9 @@ give_advice "$1" | sed -e '1s/^/WARNING: /' \ exit $st # Local variables: -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-format: "%Y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: diff --git a/subprojects/libsodium/build-aux/test-driver b/subprojects/libsodium/build-aux/test-driver @@ -1,9 +1,9 @@ #! /bin/sh # test-driver - basic testsuite driver script. -scriptversion=2018-03-07.03; # UTC +scriptversion=2025-06-18.21; # UTC -# Copyright (C) 2011-2018 Free Software Foundation, Inc. +# Copyright (C) 2011-2025 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -42,11 +42,18 @@ print_usage () { cat <<END Usage: - test-driver --test-name=NAME --log-file=PATH --trs-file=PATH - [--expect-failure={yes|no}] [--color-tests={yes|no}] - [--enable-hard-errors={yes|no}] [--] + test-driver --test-name NAME --log-file PATH --trs-file PATH + [--expect-failure {yes|no}] [--color-tests {yes|no}] + [--collect-skipped-logs {yes|no}] + [--enable-hard-errors {yes|no}] [--] TEST-SCRIPT [TEST-SCRIPT-ARGUMENTS] + The '--test-name', '--log-file' and '--trs-file' options are mandatory. +See the GNU Automake documentation for information. + +Report bugs to <bug-automake@gnu.org>. +GNU Automake home page: <https://www.gnu.org/software/automake/>. +General help using GNU software: <https://www.gnu.org/gethelp/>. END } @@ -55,15 +62,17 @@ log_file= # Where to save the output of the test script. trs_file= # Where to save the metadata of the test run. expect_failure=no color_tests=no +collect_skipped_logs=yes enable_hard_errors=yes while test $# -gt 0; do case $1 in --help) print_usage; exit $?;; - --version) echo "test-driver $scriptversion"; exit $?;; + --version) echo "test-driver (GNU Automake) $scriptversion"; exit $?;; --test-name) test_name=$2; shift;; --log-file) log_file=$2; shift;; --trs-file) trs_file=$2; shift;; --color-tests) color_tests=$2; shift;; + --collect-skipped-logs) collect_skipped_logs=$2; shift;; --expect-failure) expect_failure=$2; shift;; --enable-hard-errors) enable_hard_errors=$2; shift;; --) shift; break;; @@ -103,8 +112,11 @@ trap "st=130; $do_exit" 2 trap "st=141; $do_exit" 13 trap "st=143; $do_exit" 15 -# Test script is run here. -"$@" >$log_file 2>&1 +# Test script is run here. We create the file first, then append to it, +# to ameliorate tests themselves also writing to the log file. Our tests +# don't, but others can (automake bug#35762). +: >"$log_file" +"$@" >>"$log_file" 2>&1 estatus=$? if test $enable_hard_errors = no && test $estatus -eq 99; then @@ -116,7 +128,7 @@ fi case $tweaked_estatus:$expect_failure in 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; 0:*) col=$grn res=PASS recheck=no gcopy=no;; - 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; + 77:*) col=$blu res=SKIP recheck=no gcopy=$collect_skipped_logs;; 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; *:*) col=$red res=FAIL recheck=yes gcopy=yes;; @@ -126,7 +138,7 @@ esac # know whether the test passed or failed simply by looking at the '.log' # file, without the need of also peaking into the corresponding '.trs' # file (automake bug#11814). -echo "$res $test_name (exit status: $estatus)" >>$log_file +echo "$res $test_name (exit status: $estatus)" >>"$log_file" # Report outcome to console. echo "${col}${res}${std}: $test_name" @@ -140,9 +152,9 @@ echo ":copy-in-global-log: $gcopy" >> $trs_file # Local Variables: # mode: shell-script # sh-indentation: 2 -# eval: (add-hook 'before-save-hook 'time-stamp) +# eval: (add-hook 'before-save-hook 'time-stamp nil t) # time-stamp-start: "scriptversion=" -# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-format: "%Y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: diff --git a/subprojects/libsodium/build.zig b/subprojects/libsodium/build.zig @@ -0,0 +1,281 @@ +const std = @import("std"); +const fmt = std.fmt; +const fs = std.fs; +const heap = std.heap; +const mem = std.mem; +const Compile = std.Build.Step.Compile; +const Target = std.Target; + +fn initLibConfig(b: *std.Build, target: std.Build.ResolvedTarget, lib: *Compile) void { + lib.linkLibC(); + lib.addIncludePath(b.path("src/libsodium/include/sodium")); + lib.root_module.addCMacro("_GNU_SOURCE", "1"); + lib.root_module.addCMacro("CONFIGURED", "1"); + lib.root_module.addCMacro("DEV_MODE", "1"); + lib.root_module.addCMacro("HAVE_ATOMIC_OPS", "1"); + lib.root_module.addCMacro("HAVE_C11_MEMORY_FENCES", "1"); + lib.root_module.addCMacro("HAVE_CET_H", "1"); + lib.root_module.addCMacro("HAVE_GCC_MEMORY_FENCES", "1"); + lib.root_module.addCMacro("HAVE_INLINE_ASM", "1"); + lib.root_module.addCMacro("HAVE_INTTYPES_H", "1"); + lib.root_module.addCMacro("HAVE_STDINT_H", "1"); + lib.root_module.addCMacro("HAVE_TI_MODE", "1"); + lib.want_lto = false; + + const endian = target.result.cpu.arch.endian(); + switch (endian) { + .big => lib.root_module.addCMacro("NATIVE_BIG_ENDIAN", "1"), + .little => lib.root_module.addCMacro("NATIVE_LITTLE_ENDIAN", "1"), + } + + switch (target.result.os.tag) { + .linux => { + lib.root_module.addCMacro("ASM_HIDE_SYMBOL", ".hidden"); + lib.root_module.addCMacro("TLS", "_Thread_local"); + + lib.root_module.addCMacro("HAVE_CATCHABLE_ABRT", "1"); + lib.root_module.addCMacro("HAVE_CATCHABLE_SEGV", "1"); + lib.root_module.addCMacro("HAVE_CLOCK_GETTIME", "1"); + lib.root_module.addCMacro("HAVE_GETPID", "1"); + lib.root_module.addCMacro("HAVE_MADVISE", "1"); + lib.root_module.addCMacro("HAVE_MLOCK", "1"); + lib.root_module.addCMacro("HAVE_MMAP", "1"); + lib.root_module.addCMacro("HAVE_MPROTECT", "1"); + lib.root_module.addCMacro("HAVE_NANOSLEEP", "1"); + lib.root_module.addCMacro("HAVE_POSIX_MEMALIGN", "1"); + lib.root_module.addCMacro("HAVE_PTHREAD_PRIO_INHERIT", "1"); + lib.root_module.addCMacro("HAVE_PTHREAD", "1"); + lib.root_module.addCMacro("HAVE_RAISE", "1"); + lib.root_module.addCMacro("HAVE_SYSCONF", "1"); + lib.root_module.addCMacro("HAVE_SYS_AUXV_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_MMAN_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_PARAM_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_RANDOM_H", "1"); + lib.root_module.addCMacro("HAVE_WEAK_SYMBOLS", "1"); + }, + .windows => { + lib.root_module.addCMacro("HAVE_RAISE", "1"); + lib.root_module.addCMacro("HAVE_SYS_PARAM_H", "1"); + if (lib.isStaticLibrary()) { + lib.root_module.addCMacro("SODIUM_STATIC", "1"); + } + }, + .macos => { + lib.root_module.addCMacro("ASM_HIDE_SYMBOL", ".private_extern"); + lib.root_module.addCMacro("TLS", "_Thread_local"); + + lib.root_module.addCMacro("HAVE_ARC4RANDOM", "1"); + lib.root_module.addCMacro("HAVE_ARC4RANDOM_BUF", "1"); + lib.root_module.addCMacro("HAVE_CATCHABLE_ABRT", "1"); + lib.root_module.addCMacro("HAVE_CATCHABLE_SEGV", "1"); + lib.root_module.addCMacro("HAVE_CLOCK_GETTIME", "1"); + lib.root_module.addCMacro("HAVE_GETENTROPY", "1"); + lib.root_module.addCMacro("HAVE_GETPID", "1"); + lib.root_module.addCMacro("HAVE_MADVISE", "1"); + lib.root_module.addCMacro("HAVE_MEMSET_S", "1"); + lib.root_module.addCMacro("HAVE_MLOCK", "1"); + lib.root_module.addCMacro("HAVE_MMAP", "1"); + lib.root_module.addCMacro("HAVE_MPROTECT", "1"); + lib.root_module.addCMacro("HAVE_NANOSLEEP", "1"); + lib.root_module.addCMacro("HAVE_POSIX_MEMALIGN", "1"); + lib.root_module.addCMacro("HAVE_PTHREAD", "1"); + lib.root_module.addCMacro("HAVE_PTHREAD_PRIO_INHERIT", "1"); + lib.root_module.addCMacro("HAVE_RAISE", "1"); + lib.root_module.addCMacro("HAVE_SYSCONF", "1"); + lib.root_module.addCMacro("HAVE_SYS_MMAN_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_PARAM_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_RANDOM_H", "1"); + lib.root_module.addCMacro("HAVE_WEAK_SYMBOLS", "1"); + }, + .wasi => { + lib.root_module.addCMacro("HAVE_ARC4RANDOM", "1"); + lib.root_module.addCMacro("HAVE_ARC4RANDOM_BUF", "1"); + lib.root_module.addCMacro("HAVE_CLOCK_GETTIME", "1"); + lib.root_module.addCMacro("HAVE_GETENTROPY", "1"); + lib.root_module.addCMacro("HAVE_NANOSLEEP", "1"); + lib.root_module.addCMacro("HAVE_POSIX_MEMALIGN", "1"); + lib.root_module.addCMacro("HAVE_SYS_AUXV_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_PARAM_H", "1"); + lib.root_module.addCMacro("HAVE_SYS_RANDOM_H", "1"); + }, + else => {}, + } + + switch (target.result.cpu.arch) { + .x86_64 => { + switch (target.result.os.tag) { + .windows => {}, + else => { + lib.root_module.addCMacro("HAVE_AMD64_ASM", "1"); + lib.root_module.addCMacro("HAVE_AVX_ASM", "1"); + }, + } + lib.root_module.addCMacro("HAVE_CPUID", "1"); + lib.root_module.addCMacro("HAVE_MMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_EMMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_PMMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_TMMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_SMMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_AVXINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_AVX2INTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_AVX512FINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_WMMINTRIN_H", "1"); + lib.root_module.addCMacro("HAVE_RDRAND", "1"); + }, + .aarch64, .aarch64_be => { + lib.root_module.addCMacro("HAVE_ARMCRYPTO", "1"); + }, + .wasm32, .wasm64 => { + lib.root_module.addCMacro("__wasm__", "1"); + }, + else => {}, + } + + switch (target.result.os.tag) { + .wasi => { + lib.root_module.addCMacro("__wasi__", "1"); + }, + else => {}, + } +} + +pub fn build(b: *std.Build) !void { + const root_path = b.pathFromRoot("."); + var cwd = try fs.openDirAbsolute(root_path, .{}); + defer cwd.close(); + + const src_path = "src/libsodium"; + const src_dir = try fs.Dir.openDir(cwd, src_path, .{ .iterate = true, .no_follow = true }); + + var target = b.standardTargetOptions(.{}); + const optimize = b.standardOptimizeOption(.{}); + + const enable_benchmarks = b.option(bool, "enable_benchmarks", "Whether tests should be benchmarks.") orelse false; + const benchmarks_iterations = b.option(u32, "iterations", "Number of iterations for benchmarks.") orelse 200; + var build_static = b.option(bool, "static", "Build libsodium as a static library.") orelse true; + var build_shared = b.option(bool, "shared", "Build libsodium as a shared library.") orelse true; + + const build_tests = b.option(bool, "test", "Build the tests (implies -Dstatic=true)") orelse true; + + if (target.result.cpu.arch.isWasm()) { + build_shared = false; + } + if (build_tests) { + build_static = true; + } + + switch (target.result.cpu.arch) { + .aarch64, .aarch64_be => { + // ARM CPUs supported by Windows are assumed to have NEON support + if (target.result.isMinGW()) { + target.query.cpu_features_add.addFeature(@intFromEnum(Target.aarch64.Feature.neon)); + } + }, + else => {}, + } + + const static_lib = b.addStaticLibrary(.{ + .name = if (target.result.isMinGW()) "libsodium-static" else "sodium", + .target = target, + .optimize = optimize, + }); + const shared_lib = b.addSharedLibrary(.{ + .name = if (target.result.isMinGW()) "libsodium" else "sodium", + .target = target, + .optimize = optimize, + .strip = optimize != .Debug and !target.result.isMinGW(), + }); + + // work out which libraries we are building + var libs = std.ArrayList(*Compile).init(b.allocator); + defer libs.deinit(); + if (build_static) { + try libs.append(static_lib); + } + if (build_shared) { + try libs.append(shared_lib); + } + + const prebuilt_version_file_path = "builds/msvc/version.h"; + const version_file_path = "include/sodium/version.h"; + + if (src_dir.access(version_file_path, .{ .mode = .read_only })) {} else |_| { + try cwd.copyFile(prebuilt_version_file_path, src_dir, version_file_path, .{}); + } + + for (libs.items) |lib| { + b.installArtifact(lib); + lib.installHeader(b.path(src_path ++ "/include/sodium.h"), "sodium.h"); + lib.installHeadersDirectory(b.path(src_path ++ "/include/sodium"), "sodium", .{}); + + initLibConfig(b, target, lib); + + const flags = &.{ + "-fvisibility=hidden", + "-fno-strict-aliasing", + "-fno-strict-overflow", + "-fwrapv", + "-flax-vector-conversions", + "-Werror=vla", + }; + + const allocator = heap.page_allocator; + + var walker = try src_dir.walk(allocator); + while (try walker.next()) |entry| { + const name = entry.basename; + if (mem.endsWith(u8, name, ".c")) { + const full_path = try fmt.allocPrint(allocator, "{s}/{s}", .{ src_path, entry.path }); + + lib.addCSourceFiles(.{ + .files = &.{full_path}, + .flags = flags, + }); + } else if (mem.endsWith(u8, name, ".S")) { + const full_path = try fmt.allocPrint(allocator, "{s}/{s}", .{ src_path, entry.path }); + lib.addAssemblyFile(b.path(full_path)); + } + } + } + + const test_path = "test/default"; + const out_bin_path = "zig-out/bin"; + const test_dir = try fs.Dir.openDir(cwd, test_path, .{ .iterate = true, .no_follow = true }); + fs.Dir.makePath(cwd, out_bin_path) catch {}; + const out_bin_dir = try fs.Dir.openDir(cwd, out_bin_path, .{}); + try test_dir.copyFile("run.sh", out_bin_dir, "run.sh", .{}); + const allocator = heap.page_allocator; + var walker = try test_dir.walk(allocator); + if (build_tests) { + while (try walker.next()) |entry| { + const name = entry.basename; + if (mem.endsWith(u8, name, ".exp")) { + try test_dir.copyFile(name, out_bin_dir, name, .{}); + continue; + } + if (!mem.endsWith(u8, name, ".c")) { + continue; + } + const exe_name = name[0 .. name.len - 2]; + var exe = b.addExecutable(.{ + .name = exe_name, + .target = target, + .optimize = optimize, + .strip = true, + }); + exe.linkLibC(); + exe.linkLibrary(static_lib); + exe.addIncludePath(b.path("src/libsodium/include")); + exe.addIncludePath(b.path("test/quirks")); + const full_path = try fmt.allocPrint(allocator, "{s}/{s}", .{ test_path, entry.path }); + exe.addCSourceFiles(.{ .files = &.{full_path} }); + if (enable_benchmarks) { + exe.root_module.addCMacro("BENCHMARKS", "1"); + var buf: [16]u8 = undefined; + exe.root_module.addCMacro("ITERATIONS", std.fmt.bufPrintIntToSlice(&buf, benchmarks_iterations, 10, .lower, .{})); + } + + b.installArtifact(exe); + } + } +} diff --git a/subprojects/libsodium/builds/Makefile.am b/subprojects/libsodium/builds/Makefile.am @@ -1,6 +1,7 @@ EXTRA_DIST = \ msvc/build/buildall.bat \ msvc/build/buildbase.bat \ + msvc/properties/ARM64.props \ msvc/properties/Common.props \ msvc/properties/Debug.props \ msvc/properties/DebugDEXE.props \ @@ -69,4 +70,12 @@ EXTRA_DIST = \ msvc/vs2019/libsodium/libsodium.xml \ msvc/vs2019/libsodium.import.props \ msvc/vs2019/libsodium.import.xml \ - msvc/vs2019/libsodium.sln + msvc/vs2019/libsodium.sln \ + msvc/vs2022/libsodium.sln \ + msvc/vs2022/libsodium/libsodium.props \ + msvc/vs2022/libsodium/libsodium.vcxproj \ + msvc/vs2022/libsodium/libsodium.vcxproj.filters \ + msvc/vs2022/libsodium/libsodium.xml \ + msvc/vs2022/libsodium.import.props \ + msvc/vs2022/libsodium.import.xml \ + msvc/vs2022/libsodium.sln diff --git a/subprojects/libsodium/builds/Makefile.in b/subprojects/libsodium/builds/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,9 +89,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = builds ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -125,6 +129,10 @@ am__can_run_installinfo = \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -133,7 +141,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -145,6 +152,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -157,6 +165,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -173,8 +183,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -217,6 +229,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -242,8 +255,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -277,11 +292,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -290,6 +310,7 @@ valgrind_tools = @valgrind_tools@ EXTRA_DIST = \ msvc/build/buildall.bat \ msvc/build/buildbase.bat \ + msvc/properties/ARM64.props \ msvc/properties/Common.props \ msvc/properties/Debug.props \ msvc/properties/DebugDEXE.props \ @@ -358,7 +379,15 @@ EXTRA_DIST = \ msvc/vs2019/libsodium/libsodium.xml \ msvc/vs2019/libsodium.import.props \ msvc/vs2019/libsodium.import.xml \ - msvc/vs2019/libsodium.sln + msvc/vs2019/libsodium.sln \ + msvc/vs2022/libsodium.sln \ + msvc/vs2022/libsodium/libsodium.props \ + msvc/vs2022/libsodium/libsodium.vcxproj \ + msvc/vs2022/libsodium/libsodium.vcxproj.filters \ + msvc/vs2022/libsodium/libsodium.xml \ + msvc/vs2022/libsodium.import.props \ + msvc/vs2022/libsodium.import.xml \ + msvc/vs2022/libsodium.sln all: all-am @@ -398,6 +427,11 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: tags TAGS: ctags CTAGS: @@ -466,12 +500,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-am + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-am + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-am + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-am + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-am + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am @@ -540,7 +594,12 @@ uninstall-am: .MAKE: install-am install-strip -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ +.PHONY: all all-am check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ @@ -558,3 +617,10 @@ uninstall-am: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/builds/msvc/build/buildall.bat b/subprojects/libsodium/builds/msvc/build/buildall.bat @@ -1,5 +1,7 @@ @ECHO OFF +CALL buildbase.bat ..\vs2022\libsodium.sln 17 +ECHO. CALL buildbase.bat ..\vs2019\libsodium.sln 16 ECHO. CALL buildbase.bat ..\vs2017\libsodium.sln 15 diff --git a/subprojects/libsodium/builds/msvc/build/buildbase.bat b/subprojects/libsodium/builds/msvc/build/buildbase.bat @@ -8,6 +8,17 @@ SET version=%2 SET log=build_%version%.log SET tools=Microsoft Visual Studio %version%.0\VC\vcvarsall.bat +IF %version% == 17 ( + SET tools=Microsoft Visual Studio\2022\Enterprise\VC\Auxiliary\Build\vcvarsall.bat + SET environment="%programfiles%\!tools!" + IF NOT EXIST !environment! ( + SET environment="%programfiles(x86)%\!tools!" + IF NOT EXIST !environment! ( + SET tools=Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvarsall.bat + ) + ) +) + IF %version% == 16 ( SET tools=Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat SET environment="%programfiles%\!tools!" @@ -82,6 +93,31 @@ ECHO Configuration=StaticRelease msbuild /m /v:n /p:Configuration=StaticRelease /p:Platform=x64 %solution% >> %log% IF errorlevel 1 GOTO error +@REM Build ARM64 packages only for Visual studio 2019 and later +IF %version% GEQ 16 ( + CALL !environment! ARM64 > nul + ECHO Platform=ARM64 + + ECHO Configuration=DynDebug + msbuild /m /v:n /p:Configuration=DynDebug /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error + ECHO Configuration=DynRelease + msbuild /m /v:n /p:Configuration=DynRelease /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error + ECHO Configuration=LtcgDebug + msbuild /m /v:n /p:Configuration=LtcgDebug /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error + ECHO Configuration=LtcgRelease + msbuild /m /v:n /p:Configuration=LtcgRelease /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error + ECHO Configuration=StaticDebug + msbuild /m /v:n /p:Configuration=StaticDebug /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error + ECHO Configuration=StaticRelease + msbuild /m /v:n /p:Configuration=StaticRelease /p:Platform=ARM64 %solution% >> %log% + IF errorlevel 1 GOTO error +) + ECHO Complete: %solution% GOTO end diff --git a/subprojects/libsodium/builds/msvc/properties/ARM64.props b/subprojects/libsodium/builds/msvc/properties/ARM64.props @@ -0,0 +1,23 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + + <PropertyGroup> + <_PropertySheetDisplayName>ARM64 Settings</_PropertySheetDisplayName> + </PropertyGroup> + + <ItemDefinitionGroup> + <ClCompile> + <PreprocessorDefinitions>WIN32;_WIN32;WIN64;_WIN64;%(PreprocessorDefinitions)</PreprocessorDefinitions> + </ClCompile> + <ResourceCompile> + <PreprocessorDefinitions>ARM64;%(PreprocessorDefinitions)</PreprocessorDefinitions> + </ResourceCompile> + <Link> + <TargetMachine>MachineARM64</TargetMachine> + </Link> + <Lib> + <AdditionalOptions>/MACHINE:ARM64 %(AdditionalOptions)</AdditionalOptions> + </Lib> + </ItemDefinitionGroup> + +</Project> diff --git a/subprojects/libsodium/builds/msvc/properties/DebugLIB.props b/subprojects/libsodium/builds/msvc/properties/DebugLIB.props @@ -12,10 +12,10 @@ <ItemDefinitionGroup> <ClCompile> - <DebugInformationFormat>OldStyle</DebugInformationFormat> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> <LinkIncremental>true</LinkIncremental> </ClCompile> </ItemDefinitionGroup> -</Project> -\ No newline at end of file +</Project> diff --git a/subprojects/libsodium/builds/msvc/properties/Release.props b/subprojects/libsodium/builds/msvc/properties/Release.props @@ -14,7 +14,7 @@ <ItemDefinitionGroup> <ClCompile> <AdditionalOptions>/Oy- %(AdditionalOptions)</AdditionalOptions> - <!--<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>--> + <DebugInformationFormat>ProgramDatabase</DebugInformationFormat> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion> @@ -38,4 +38,4 @@ </ClCompile> </ItemDefinitionGroup> -</Project> -\ No newline at end of file +</Project> diff --git a/subprojects/libsodium/builds/msvc/resource.rc b/subprojects/libsodium/builds/msvc/resource.rc @@ -4,14 +4,16 @@ #include "windows.h" //specify the version numbers for the dll's -#define LIBSODIUM_VERSION_STRING "1.0.18.0" -#define LIBSODIUM_VERSION_BIN 1,0,18,0 +#define LIBSODIUM_VERSION_STRING "1.0.20.0" +#define LIBSODIUM_VERSION_BIN 1,0,20,0 //specify the product name for the dlls based on the platform we are compiling for #if defined(x64) #define LIBSODIUM_PRODUCT_NAME "libsodium (x64)" #elif defined(Win32) #define LIBSODIUM_PRODUCT_NAME "libsodium (x86)" +#elif defined(ARM64) + #define LIBSODIUM_PRODUCT_NAME "libsodium (arm64)" #else #define LIBSODIUM_PRODUCT_NAME "libsodium" #endif @@ -44,10 +46,10 @@ BEGIN BEGIN BLOCK "040904b0" BEGIN - VALUE "FileDescription", "The Sodium crypto library (libsodium) " + VALUE "FileDescription", "The Sodium crypto library (libsodium)" VALUE "FileVersion", LIBSODIUM_VERSION_STRING VALUE "InternalName", "libsodium" - VALUE "LegalCopyright", "Copyright (c) 2013-2019 The libsodium authors." + VALUE "LegalCopyright", "Copyright (c) 2013-2024 The libsodium authors." VALUE "OriginalFilename", "libsodium.dll" VALUE "ProductName", LIBSODIUM_PRODUCT_NAME VALUE "ProductVersion", LIBSODIUM_VERSION_STRING diff --git a/subprojects/libsodium/builds/msvc/version.h b/subprojects/libsodium/builds/msvc/version.h @@ -4,10 +4,11 @@ #include "export.h" -#define SODIUM_VERSION_STRING "1.0.18" +#define SODIUM_VERSION_STRING "1.0.20" + +#define SODIUM_LIBRARY_VERSION_MAJOR 26 +#define SODIUM_LIBRARY_VERSION_MINOR 2 -#define SODIUM_LIBRARY_VERSION_MAJOR 10 -#define SODIUM_LIBRARY_VERSION_MINOR 3 #ifdef __cplusplus extern "C" { diff --git a/subprojects/libsodium/builds/msvc/vs2010/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2010/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,50 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> + <ProjectConfiguration Include="ReleaseDLL|Win32"> <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|Win32"> <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|x64"> <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|x64"> <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +68,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +104,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +165,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +202,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +228,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +245,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +254,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +265,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +289,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +316,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2010/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2010/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2012/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2012/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,50 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> + <ProjectConfiguration Include="ReleaseDLL|Win32"> <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|Win32"> <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|x64"> <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|x64"> <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +68,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +104,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +165,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +202,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +228,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +245,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +254,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +265,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +289,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +316,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2012/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2012/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2013/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2013/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,50 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> + <ProjectConfiguration Include="ReleaseDLL|Win32"> <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|Win32"> <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|x64"> <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|x64"> <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +68,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +104,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +165,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +202,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +228,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +245,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +254,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +265,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +289,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +316,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2013/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2013/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2015/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2015/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,50 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> + <ProjectConfiguration Include="ReleaseDLL|Win32"> <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|Win32"> <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|x64"> <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|x64"> <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +68,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +104,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +165,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +202,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +228,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +245,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +254,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +265,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +289,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +316,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2015/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2015/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2017/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2017/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,50 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> + <ProjectConfiguration Include="ReleaseDLL|Win32"> <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|Win32"> <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugLIB|x64"> <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|x64"> <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +68,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +104,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +165,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +202,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +228,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +245,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +254,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +265,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +289,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +316,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2017/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2017/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2019/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2019/libsodium/libsodium.vcxproj @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> @@ -10,50 +11,74 @@ <Configuration>DebugDLL</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> <ProjectConfiguration Include="DebugDLL|x64"> <Configuration>DebugDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="DebugDLL|ARM64"> + <Configuration>DebugDLL</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|Win32"> + <Configuration>ReleaseDLL</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> <ProjectConfiguration Include="ReleaseDLL|x64"> <Configuration>ReleaseDLL</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> - <Platform>Win32</Platform> + <ProjectConfiguration Include="ReleaseDLL|ARM64"> + <Configuration>ReleaseDLL</Configuration> + <Platform>ARM64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="DebugLIB|Win32"> + <Configuration>DebugLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> + <ProjectConfiguration Include="DebugLIB|x64"> + <Configuration>DebugLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="DebugLIB|Win32"> + <ProjectConfiguration Include="DebugLIB|ARM64"> <Configuration>DebugLIB</Configuration> - <Platform>Win32</Platform> + <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="ReleaseLIB|Win32"> <Configuration>ReleaseLIB</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="DebugLIB|x64"> - <Configuration>DebugLIB</Configuration> + <ProjectConfiguration Include="ReleaseLIB|x64"> + <Configuration>ReleaseLIB</Configuration> <Platform>x64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|x64"> + <ProjectConfiguration Include="ReleaseLIB|ARM64"> <Configuration>ReleaseLIB</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|ARM64"> + <Configuration>DebugLTCG</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> <Platform>x64</Platform> </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|ARM64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +92,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> @@ -113,13 +128,15 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> @@ -172,14 +189,25 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> @@ -198,8 +226,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> @@ -222,6 +252,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> @@ -238,6 +269,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> @@ -246,6 +278,7 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> @@ -256,9 +289,11 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> @@ -278,12 +313,10 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> @@ -307,6 +340,16 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> diff --git a/subprojects/libsodium/builds/msvc/vs2019/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2019/libsodium/libsodium.vcxproj.filters @@ -132,8 +132,8 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>crypto_verify\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> <Filter>crypto_auth</Filter> @@ -153,6 +153,12 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> <Filter>crypto_kdf\blake2b</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> <Filter>crypto_shorthash</Filter> </ClCompile> @@ -309,14 +315,44 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> <Filter>crypto_hash\sha256\cp</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>crypto_aead\xchacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> <Filter>crypto_aead\aes256gcm\aesni</Filter> </ClCompile> - <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>crypto_aead\chacha20poly1305\sodium</Filter> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> <Filter>crypto_secretstream\xchacha20poly1305</Filter> @@ -333,6 +369,9 @@ <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> <Filter>crypto_core\hsalsa20\ref2</Filter> </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> <Filter>crypto_core\ed25519</Filter> </ClCompile> @@ -383,12 +422,18 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> <Filter>include\sodium</Filter> </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -455,6 +500,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -503,6 +551,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -527,6 +578,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> <Filter>include\sodium</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> <Filter>include\sodium</Filter> </ClInclude> @@ -557,6 +611,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -566,6 +623,9 @@ <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> <Filter>include\sodium\private</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> <Filter>include\sodium\private</Filter> </ClInclude> @@ -623,9 +683,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> @@ -638,9 +695,6 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> </ClInclude> - <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> - </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> <Filter>crypto_scalarmult\curve25519\ref10</Filter> </ClInclude> @@ -710,6 +764,36 @@ <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> <Filter>crypto_stream\salsa20\xmm6</Filter> </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> </ClInclude> @@ -739,24 +823,27 @@ <Filter Include="crypto_aead"> <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\aes256gcm"> <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> </Filter> <Filter Include="crypto_aead\aes256gcm\aesni"> <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> <Filter Include="crypto_aead\chacha20poly1305"> <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\chacha20poly1305\sodium"> - <UniqueIdentifier>{b145288f-68ad-3e79-93cb-e36537b20e26}</UniqueIdentifier> - </Filter> <Filter Include="crypto_aead\xchacha20poly1305"> <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> </Filter> - <Filter Include="crypto_aead\xchacha20poly1305\sodium"> - <UniqueIdentifier>{2720c2c8-c517-356e-83ed-c2997ab782c3}</UniqueIdentifier> - </Filter> <Filter Include="crypto_auth"> <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> </Filter> @@ -808,6 +895,9 @@ <Filter Include="crypto_core\salsa\ref"> <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> <Filter Include="crypto_generichash"> <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> </Filter> @@ -838,6 +928,9 @@ <Filter Include="crypto_kdf\blake2b"> <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> <Filter Include="crypto_kx"> <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> </Filter> @@ -970,9 +1063,6 @@ <Filter Include="crypto_verify"> <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> </Filter> - <Filter Include="crypto_verify\sodium"> - <UniqueIdentifier>{80669cf5-3c9c-3c60-b409-9d8fb305bc77}</UniqueIdentifier> - </Filter> <Filter Include="include"> <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> </Filter> diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium.import.props b/subprojects/libsodium/builds/msvc/vs2022/libsodium.import.props @@ -0,0 +1,52 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + + <PropertyGroup Label="Globals"> + <_PropertySheetDisplayName>Libsodium Import Settings</_PropertySheetDisplayName> + </PropertyGroup> + + <!-- User Interface --> + + <ItemGroup Label="BuildOptionsExtension"> + <PropertyPageSchema Include="$(MSBuildThisFileDirectory)libsodium.import.xml" /> + </ItemGroup> + + <!-- Linkage --> + + <ItemDefinitionGroup> + <ClCompile> + <AdditionalIncludeDirectories>$(ProjectDir)..\..\..\..\..\libsodium\src\libsodium\include;$(ProjectDir)..\..\..\..\..\libsodium\src\libsodium\include\sodium\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <PreprocessorDefinitions Condition="'$(Linkage-libsodium)' == 'static' Or '$(Linkage-libsodium)' == 'ltcg'">SODIUM_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions> + </ClCompile> + <Link> + <AdditionalDependencies Condition="'$(Linkage-libsodium)' != ''">advapi32.lib;libsodium.lib;%(AdditionalDependencies)</AdditionalDependencies> + <AdditionalLibraryDirectories Condition="$(Configuration.IndexOf('Debug')) != -1">$(ProjectDir)..\..\..\..\..\libsodium\bin\$(PlatformName)\Debug\$(PlatformToolset)\$(Linkage-libsodium)\;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> + <AdditionalLibraryDirectories Condition="$(Configuration.IndexOf('Release')) != -1">$(ProjectDir)..\..\..\..\..\libsodium\bin\$(PlatformName)\Release\$(PlatformToolset)\$(Linkage-libsodium)\;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> + </Link> + </ItemDefinitionGroup> + + <!-- Copy --> + + <Target Name="Linkage-libsodium-dynamic" AfterTargets="AfterBuild" Condition="'$(Linkage-libsodium)' == 'dynamic'"> + <Copy Condition="$(Configuration.IndexOf('Debug')) != -1" + SourceFiles="$(ProjectDir)..\..\..\..\..\libsodium\bin\$(PlatformName)\Debug\$(PlatformToolset)\dynamic\libsodium.dll" + DestinationFiles="$(TargetDir)libsodium.dll" + SkipUnchangedFiles="true" /> + <Copy Condition="$(Configuration.IndexOf('Debug')) != -1" + SourceFiles="$(ProjectDir)..\..\..\..\..\libsodium\bin\$(PlatformName)\Debug\$(PlatformToolset)\dynamic\libsodium.pdb" + DestinationFiles="$(TargetDir)libsodium.pdb" + SkipUnchangedFiles="true" /> + <Copy Condition="$(Configuration.IndexOf('Release')) != -1" + SourceFiles="$(ProjectDir)..\..\..\..\..\libsodium\bin\$(PlatformName)\Release\$(PlatformToolset)\dynamic\libsodium.dll" + DestinationFiles="$(TargetDir)libsodium.dll" + SkipUnchangedFiles="true" /> + </Target> + + <!-- Messages --> + + <Target Name="libsodium-info" BeforeTargets="AfterBuild" Condition="'$(Linkage-libsodium)' == 'dynamic'"> + <Message Text="Copying libsodium.dll -> $(TargetDir)libsodium.dll" Importance="high"/> + <Message Text="Copying libsodium.pdb -> $(TargetDir)libsodium.pdb" Importance="high" Condition="$(Configuration.IndexOf('Debug')) != -1" /> + </Target> + +</Project> +\ No newline at end of file diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium.import.xml b/subprojects/libsodium/builds/msvc/vs2022/libsodium.import.xml @@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="utf-8"?> +<ProjectSchemaDefinitions xmlns="clr-namespace:Microsoft.Build.Framework.XamlTypes;assembly=Microsoft.Build.Framework"> + <Rule Name="libsodium-linkage-uiextension" PageTemplate="tool" DisplayName="Local Dependencies" SwitchPrefix="/" Order="1"> + <Rule.Categories> + <Category Name="libsodium" DisplayName="libsodium" /> + </Rule.Categories> + <Rule.DataSource> + <DataSource Persistence="ProjectFile" ItemType="" /> + </Rule.DataSource> + <EnumProperty Name="Linkage-libsodium" DisplayName="Linkage" Description="How libsodium will be linked into the output of this project" Category="libsodium"> + <EnumValue Name="" DisplayName="Not linked" /> + <EnumValue Name="dynamic" DisplayName="Dynamic (DLL)" /> + <EnumValue Name="static" DisplayName="Static (LIB)" /> + <EnumValue Name="ltcg" DisplayName="Static using link time compile generation (LTCG)" /> + </EnumProperty> + </Rule> +</ProjectSchemaDefinitions> +\ No newline at end of file diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium.sln b/subprojects/libsodium/builds/msvc/vs2022/libsodium.sln @@ -0,0 +1,70 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.26228.4 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libsodium", "libsodium\libsodium.vcxproj", "{A185B162-6CB6-4502-B03F-B56F7699A8D9}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + DynDebug|Win32 = DynDebug|Win32 + DynDebug|x64 = DynDebug|x64 + DynDebug|ARM64 = DynDebug|ARM64 + DynRelease|Win32 = DynRelease|Win32 + DynRelease|x64 = DynRelease|x64 + DynRelease|ARM64 = DynRelease|ARM64 + LtcgDebug|Win32 = LtcgDebug|Win32 + LtcgDebug|x64 = LtcgDebug|x64 + LtcgDebug|ARM64 = LtcgDebug|ARM64 + LtcgRelease|Win32 = LtcgRelease|Win32 + LtcgRelease|x64 = LtcgRelease|x64 + LtcgRelease|ARM64 = LtcgRelease|ARM64 + StaticDebug|Win32 = StaticDebug|Win32 + StaticDebug|x64 = StaticDebug|x64 + StaticDebug|ARM64 = StaticDebug|ARM64 + StaticRelease|Win32 = StaticRelease|Win32 + StaticRelease|x64 = StaticRelease|x64 + StaticRelease|ARM64 = StaticRelease|ARM64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|Win32.ActiveCfg = DebugDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|Win32.Build.0 = DebugDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|x64.ActiveCfg = DebugDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|x64.Build.0 = DebugDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|ARM64.ActiveCfg = DebugDLL|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynDebug|ARM64.Build.0 = DebugDLL|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|Win32.ActiveCfg = ReleaseDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|Win32.Build.0 = ReleaseDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|x64.ActiveCfg = ReleaseDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|x64.Build.0 = ReleaseDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|ARM64.ActiveCfg = ReleaseDLL|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DynRelease|ARM64.Build.0 = ReleaseDLL|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|Win32.ActiveCfg = DebugLTCG|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|Win32.Build.0 = DebugLTCG|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|x64.ActiveCfg = DebugLTCG|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|x64.Build.0 = DebugLTCG|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|ARM64.ActiveCfg = DebugLTCG|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgDebug|ARM64.Build.0 = DebugLTCG|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|Win32.ActiveCfg = ReleaseLTCG|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|Win32.Build.0 = ReleaseLTCG|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|x64.ActiveCfg = ReleaseLTCG|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|x64.Build.0 = ReleaseLTCG|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|ARM64.ActiveCfg = ReleaseLTCG|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.LtcgRelease|ARM64.Build.0 = ReleaseLTCG|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|Win32.ActiveCfg = DebugLIB|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|Win32.Build.0 = DebugLIB|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|x64.ActiveCfg = DebugLIB|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|x64.Build.0 = DebugLIB|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|ARM64.ActiveCfg = DebugLIB|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticDebug|ARM64.Build.0 = DebugLIB|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|Win32.ActiveCfg = ReleaseLIB|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|Win32.Build.0 = ReleaseLIB|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|x64.ActiveCfg = ReleaseLIB|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|x64.Build.0 = ReleaseLIB|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|ARM64.ActiveCfg = ReleaseLIB|ARM64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.StaticRelease|ARM64.Build.0 = ReleaseLIB|ARM64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.props b/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.props @@ -0,0 +1,48 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + + <PropertyGroup Label="Globals"> + <_PropertySheetDisplayName>Libsodium Common Settings</_PropertySheetDisplayName> + <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet> + <RunCodeAnalysis>false</RunCodeAnalysis> + </PropertyGroup> + + <!-- User Interface --> + + <ItemGroup Label="BuildOptionsExtension"> + <PropertyPageSchema Include="$(MSBuildThisFileDirectory)$(ProjectName).xml" /> + </ItemGroup> + + <!-- Configuration --> + + <ItemDefinitionGroup> + <PreBuildEvent> + <Command>copy "$(BuildRoot)version.h" "$(RepoRoot)src\libsodium\include\sodium\"</Command> + </PreBuildEvent> + <ClCompile> + <AdditionalIncludeDirectories>$(RepoRoot)src\libsodium\include;$(RepoRoot)src\libsodium\include\sodium\;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <DisableSpecificWarnings>4146;4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <EnablePREfast>false</EnablePREfast> + <PreprocessorDefinitions>inline=__inline;NATIVE_LITTLE_ENDIAN;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <PreprocessorDefinitions Condition="'$(ConfigurationType)' == 'StaticLibrary'">SODIUM_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <PreprocessorDefinitions Condition="'$(ConfigurationType)' == 'DynamicLibrary'">SODIUM_DLL_EXPORT;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <PreprocessorDefinitions Condition="'$(Option-amd64asm)' == 'true'">HAVE_AMD64_ASM;%(PreprocessorDefinitions)</PreprocessorDefinitions> + </ClCompile> + </ItemDefinitionGroup> + + <!-- Messages --> + + <Target Name="CustomInfo" BeforeTargets="PrepareForBuild"> + <Message Text="Will copy $(BuildRoot)version.h -> $(RepoRoot)src\libsodium\include\sodium\version.h" Importance="high"/> + </Target> + + <Target Name="OptionInfo" BeforeTargets="PrepareForBuild"> + <Message Text="Option-amd64asm : $(Option-amd64asm)" Importance="high"/> + </Target> + + <ItemDefinitionGroup> + <Link> + <AdditionalDependencies>advapi32.lib</AdditionalDependencies> + </Link> + </ItemDefinitionGroup> +</Project> diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.vcxproj b/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.vcxproj @@ -0,0 +1,370 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup Label="Globals"> + <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> + <ProjectName>libsodium</ProjectName> + <PlatformToolset>v143</PlatformToolset> + </PropertyGroup> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="DebugDLL|Win32"> + <Configuration>DebugDLL</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugDLL|x64"> + <Configuration>DebugDLL</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugDLL|ARM64"> + <Configuration>DebugDLL</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|Win32"> + <Configuration>ReleaseDLL</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|ARM64"> + <Configuration>ReleaseDLL</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLIB|Win32"> + <Configuration>DebugLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLIB|x64"> + <Configuration>DebugLIB</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLIB|ARM64"> + <Configuration>DebugLIB</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|Win32"> + <Configuration>ReleaseLIB</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|x64"> + <Configuration>ReleaseLIB</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLIB|ARM64"> + <Configuration>ReleaseLIB</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|Win32"> + <Configuration>DebugLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|x64"> + <Configuration>DebugLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugLTCG|ARM64"> + <Configuration>DebugLTCG</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|Win32"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|x64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseLTCG|ARM64"> + <Configuration>ReleaseLTCG</Configuration> + <Platform>ARM64</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Configuration"> + <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> + <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) != -1">DynamicLibrary</ConfigurationType> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <ImportGroup Label="PropertySheets"> + <Import Project="$(ProjectDir)..\..\properties\$(Configuration).props" /> + <Import Project="$(ProjectDir)..\..\properties\Output.props" /> + <Import Project="$(ProjectDir)$(ProjectName).props" /> + </ImportGroup> + <ItemGroup> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kx\crypto_kx.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\crypto_sign.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\sign_ed25519.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\obsolete.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\sign.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\keypair.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\open.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\crypto_secretbox.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\crypto_secretbox_easy.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\crypto_pwhash.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\crypto_scalarmult.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\randombytes.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\internal\randombytes_internal_random.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box_easy.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box_seal.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\codecs.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\runtime.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\core.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\utils.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\version.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\crypto_stream.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa208\stream_salsa208.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\crypto_hash.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\hash_sha512.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa2012.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kx.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ristretto255.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa208.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aes256gcm.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa2012.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_16.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_chacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xsalsa20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hsalsa20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_onetimeauth.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_ed25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u4.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u0.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u1.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u8.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u4.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u0.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u1.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h" /> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h" /> + <ClInclude Include="..\..\resource.h" /> + </ItemGroup> + <ItemGroup> + <ResourceCompile Include="..\..\resource.rc"> + </ResourceCompile> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> + <ImportGroup Label="ExtensionTargets"> + </ImportGroup> +</Project> diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.vcxproj.filters @@ -0,0 +1,1088 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup> + <None Include="..\..\..\..\packaging\nuget\package.bat"> + <Filter>packaging</Filter> + </None> + <None Include="..\..\..\..\packaging\nuget\package.gsl"> + <Filter>packaging</Filter> + </None> + <None Include="..\..\..\..\packaging\nuget\package.nuspec"> + <Filter>packaging</Filter> + </None> + <None Include="..\..\..\..\packaging\nuget\package.targets"> + <Filter>packaging</Filter> + </None> + <None Include="..\..\..\..\packaging\nuget\package.config"> + <Filter>packaging</Filter> + </None> + <Xml Include="..\..\..\..\packaging\nuget\package.xml"> + <Filter>packaging</Filter> + </Xml> + </ItemGroup> + <ItemGroup> + <ResourceCompile Include="..\..\resource.rc" /> + </ItemGroup> + <ItemGroup> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\crypto_generichash.c"> + <Filter>crypto_generichash</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c"> + <Filter>crypto_generichash\blake2b</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kx\crypto_kx.c"> + <Filter>crypto_kx</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\crypto_sign.c"> + <Filter>crypto_sign</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\sign_ed25519.c"> + <Filter>crypto_sign\ed25519</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\obsolete.c"> + <Filter>crypto_sign\ed25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\sign.c"> + <Filter>crypto_sign\ed25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\keypair.c"> + <Filter>crypto_sign\ed25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\open.c"> + <Filter>crypto_sign\ed25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\crypto_secretbox.c"> + <Filter>crypto_secretbox</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\crypto_secretbox_easy.c"> + <Filter>crypto_secretbox</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c"> + <Filter>crypto_secretbox\xsalsa20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c"> + <Filter>crypto_secretbox\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\crypto_pwhash.c"> + <Filter>crypto_pwhash</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.c"> + <Filter>crypto_pwhash\argon2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256\nosse</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> + <Filter>crypto_pwhash\scryptsalsa208sha256\sse</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>crypto_verify</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\crypto_auth.c"> + <Filter>crypto_auth</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c"> + <Filter>crypto_auth\hmacsha512</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c"> + <Filter>crypto_auth\hmacsha512256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c"> + <Filter>crypto_auth\hmacsha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\crypto_kdf.c"> + <Filter>crypto_kdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> + <Filter>crypto_kdf\blake2b</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>crypto_kdf\hkdf</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> + <Filter>crypto_shorthash</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c"> + <Filter>crypto_shorthash\siphash24</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c"> + <Filter>crypto_shorthash\siphash24</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c"> + <Filter>crypto_shorthash\siphash24\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c"> + <Filter>crypto_shorthash\siphash24\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\crypto_scalarmult.c"> + <Filter>crypto_scalarmult</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c"> + <Filter>crypto_scalarmult\ristretto255\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c"> + <Filter>crypto_scalarmult\ed25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c"> + <Filter>crypto_scalarmult\curve25519</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c"> + <Filter>crypto_scalarmult\curve25519\ref10</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c"> + <Filter>crypto_onetimeauth</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c"> + <Filter>crypto_onetimeauth\poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c"> + <Filter>crypto_onetimeauth\poly1305\donna</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c"> + <Filter>crypto_onetimeauth\poly1305\sse2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\randombytes.c"> + <Filter>randombytes</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c"> + <Filter>randombytes\sysrandom</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\randombytes\internal\randombytes_internal_random.c"> + <Filter>randombytes\internal</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box_easy.c"> + <Filter>crypto_box</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box_seal.c"> + <Filter>crypto_box</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\crypto_box.c"> + <Filter>crypto_box</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c"> + <Filter>crypto_box\curve25519xsalsa20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c"> + <Filter>crypto_box\curve25519xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c"> + <Filter>crypto_box\curve25519xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\codecs.c"> + <Filter>sodium</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\runtime.c"> + <Filter>sodium</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\core.c"> + <Filter>sodium</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\utils.c"> + <Filter>sodium</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\sodium\version.c"> + <Filter>sodium</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\crypto_stream.c"> + <Filter>crypto_stream</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c"> + <Filter>crypto_stream\xchacha20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.c"> + <Filter>crypto_stream\chacha20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c"> + <Filter>crypto_stream\chacha20\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.c"> + <Filter>crypto_stream\salsa20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c"> + <Filter>crypto_stream\salsa20\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c"> + <Filter>crypto_stream\salsa20\xmm6</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c"> + <Filter>crypto_stream\salsa2012</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c"> + <Filter>crypto_stream\salsa2012\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa208\stream_salsa208.c"> + <Filter>crypto_stream\salsa208</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c"> + <Filter>crypto_stream\salsa208\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c"> + <Filter>crypto_stream\xsalsa20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\crypto_hash.c"> + <Filter>crypto_hash</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\hash_sha512.c"> + <Filter>crypto_hash\sha512</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c"> + <Filter>crypto_hash\sha512\cp</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c"> + <Filter>crypto_hash\sha256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> + <Filter>crypto_hash\sha256\cp</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>crypto_aead\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>crypto_aead\aegis128l</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>crypto_aead\aegis256</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>crypto_aead\aes256gcm</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> + <Filter>crypto_aead\aes256gcm\aesni</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>crypto_aead\aes256gcm\armcrypto</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>crypto_aead\chacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> + <Filter>crypto_secretstream\xchacha20poly1305</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c"> + <Filter>crypto_core\salsa\ref</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c"> + <Filter>crypto_core\hchacha20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c"> + <Filter>crypto_core\hsalsa20</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> + <Filter>crypto_core\hsalsa20\ref2</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>crypto_core\softaes</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> + <Filter>crypto_core\ed25519</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c"> + <Filter>crypto_core\ed25519</Filter> + </ClCompile> + <ClCompile Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c"> + <Filter>crypto_core\ed25519\ref10</Filter> + </ClCompile> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h"> + <Filter>crypto_generichash\blake2b\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h"> + <Filter>crypto_sign\ed25519\ref10</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium.h"> + <Filter>include</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa2012.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\utils.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\core.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\version.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\export.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kx.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_hash.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_32.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ristretto255.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa208.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_sysrandom.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\runtime.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_salsa208.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_aead_aes256gcm.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_salsa2012.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_16.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_chacha20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_stream_xsalsa20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_hsalsa20.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_shorthash.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_ed25519.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_onetimeauth.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_verify_64.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\randombytes_internal_random.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_secretbox.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_scalarmult_ed25519.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h"> + <Filter>include\sodium</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\common.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\mutex.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\include\sodium\private\implementations.h"> + <Filter>include\sodium\private</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.h"> + <Filter>crypto_pwhash\argon2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h"> + <Filter>crypto_pwhash\scryptsalsa208sha256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h"> + <Filter>crypto_shorthash\siphash24\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h"> + <Filter>crypto_scalarmult\curve25519</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> + <Filter>crypto_scalarmult\curve25519\sandy2x</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> + <Filter>crypto_scalarmult\curve25519\ref10</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h"> + <Filter>crypto_onetimeauth\poly1305</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h"> + <Filter>crypto_onetimeauth\poly1305\donna</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h"> + <Filter>crypto_onetimeauth\poly1305\donna</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h"> + <Filter>crypto_onetimeauth\poly1305\donna</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h"> + <Filter>crypto_onetimeauth\poly1305\sse2</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.h"> + <Filter>crypto_stream\chacha20</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h"> + <Filter>crypto_stream\chacha20\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u4.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u0.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u1.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u8.h"> + <Filter>crypto_stream\chacha20\dolbeau</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.h"> + <Filter>crypto_stream\salsa20</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h"> + <Filter>crypto_stream\salsa20\ref</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u4.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u0.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u1.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h"> + <Filter>crypto_stream\salsa20\xmm6int</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> + <Filter>crypto_stream\salsa20\xmm6</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>crypto_aead\aegis128l</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>crypto_aead\aegis256</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> + <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h"> + <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h"> + <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h"> + <Filter>crypto_core\ed25519\ref10\fe_25_5</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h"> + <Filter>crypto_core\ed25519\ref10\fe_51</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h"> + <Filter>crypto_core\ed25519\ref10\fe_51</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h"> + <Filter>crypto_core\ed25519\ref10\fe_51</Filter> + </ClInclude> + <ClInclude Include="..\..\..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h"> + <Filter>crypto_core\ed25519\ref10\fe_51</Filter> + </ClInclude> + </ItemGroup> + <ItemGroup> + <Filter Include="crypto_aead"> + <UniqueIdentifier>{a6837e41-3751-38c9-bb90-dd59d5f4af7b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis128l"> + <UniqueIdentifier>{9e2a023d-fef1-3231-90ba-9a0ffc9bc9ab}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aegis256"> + <UniqueIdentifier>{6897a4cc-0091-3970-b712-c0ac75c16b67}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aes256gcm"> + <UniqueIdentifier>{3e53394c-b59c-30cc-ae69-a4f46f9edfa3}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aes256gcm\aesni"> + <UniqueIdentifier>{7eb51140-a50f-3f50-b379-83677a82496c}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\aes256gcm\armcrypto"> + <UniqueIdentifier>{507bb9aa-b65c-3034-946b-bcd375b7deaa}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\chacha20poly1305"> + <UniqueIdentifier>{1f4d6dd1-517f-3eeb-b974-2304ada5e67a}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_aead\xchacha20poly1305"> + <UniqueIdentifier>{3122f223-e6c2-3ab1-ad85-ca289b47419e}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_auth"> + <UniqueIdentifier>{0a3af0f3-56f7-3551-a64e-6284feccc423}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_auth\hmacsha256"> + <UniqueIdentifier>{64e89b4f-eec9-38c9-90f2-4881bf5e84c0}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_auth\hmacsha512"> + <UniqueIdentifier>{0c0b4001-ae11-3d0f-8e73-75ac9b6e1ae8}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_auth\hmacsha512256"> + <UniqueIdentifier>{f5065d74-beda-3e1e-819a-f606279c7fe9}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_box"> + <UniqueIdentifier>{f7aedb93-94a6-3ede-9374-ff41daca4841}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_box\curve25519xchacha20poly1305"> + <UniqueIdentifier>{0e7473c9-9c69-36b3-ab6c-d953647a15a6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_box\curve25519xsalsa20poly1305"> + <UniqueIdentifier>{d75db64c-eb08-3f10-9b99-1b6e6827f348}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core"> + <UniqueIdentifier>{73194d5d-588a-342f-bee6-f28b4486f20b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\ed25519"> + <UniqueIdentifier>{7c5e6f81-e4ce-3018-a776-a1f125072d73}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\ed25519\ref10"> + <UniqueIdentifier>{76990c08-d692-367f-b286-c728a8cad6bf}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\ed25519\ref10\fe_25_5"> + <UniqueIdentifier>{bf04f786-7862-3bde-aeba-ed82ee59ca22}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\ed25519\ref10\fe_51"> + <UniqueIdentifier>{98b6126a-3725-3707-a4cc-ff3af657cba0}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\hchacha20"> + <UniqueIdentifier>{8b704d11-af1f-30c0-9981-479da6d88dc3}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\hsalsa20"> + <UniqueIdentifier>{342e684b-4e18-311c-953c-8391a544a04f}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\hsalsa20\ref2"> + <UniqueIdentifier>{c6b8e28c-7c54-3af7-bee3-2948ba7b2082}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\salsa"> + <UniqueIdentifier>{4e9a1d6b-ee07-3bbc-ad78-6d0ba0e6d9d3}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\salsa\ref"> + <UniqueIdentifier>{eb259fd9-56f0-32db-a903-6bc1549a7326}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_core\softaes"> + <UniqueIdentifier>{05997596-e3d7-3bf1-ad4d-39e4c5fd56f6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_generichash"> + <UniqueIdentifier>{e53b6258-fcdd-34c8-96c5-44510a34a390}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_generichash\blake2b"> + <UniqueIdentifier>{8bd3b558-2d08-3c3a-81ca-22677dde943b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_generichash\blake2b\ref"> + <UniqueIdentifier>{16a8dd41-b0ab-39a7-80c8-3052d8b63811}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_hash"> + <UniqueIdentifier>{d7ec3690-bae7-3653-8c53-66a3142cfcfa}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_hash\sha256"> + <UniqueIdentifier>{722ef422-8c03-3008-ba2a-3a7e91c6647c}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_hash\sha256\cp"> + <UniqueIdentifier>{8c7d8b62-7b4f-3eb9-85b7-18e8d925be14}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_hash\sha512"> + <UniqueIdentifier>{8fb6a906-dbd6-3746-9b0f-f49e7028daec}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_hash\sha512\cp"> + <UniqueIdentifier>{f2d6a22b-dd67-3561-90a4-88696169cb7b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_kdf"> + <UniqueIdentifier>{aaf59186-1c0d-33cf-a34d-93e14bb87226}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_kdf\blake2b"> + <UniqueIdentifier>{3d42d2a2-b192-33dd-9162-508916414707}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_kdf\hkdf"> + <UniqueIdentifier>{baf7d894-9298-391d-8dc2-e4c3010f5ddc}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_kx"> + <UniqueIdentifier>{898b6bd5-1360-3a34-adcd-0fade7561685}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_onetimeauth"> + <UniqueIdentifier>{323c0a15-3c1d-39b2-9ec1-299deb299497}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_onetimeauth\poly1305"> + <UniqueIdentifier>{52c2080d-37c0-34c2-864a-c201c728e5d8}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_onetimeauth\poly1305\donna"> + <UniqueIdentifier>{ff618a41-caeb-3a18-ad36-d34b049a8f50}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_onetimeauth\poly1305\sse2"> + <UniqueIdentifier>{ffc3712d-dfe0-3b51-8257-f5ffc9c9cea3}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_pwhash"> + <UniqueIdentifier>{f54b65b6-71cf-3ab3-9c8c-f89c81846836}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_pwhash\argon2"> + <UniqueIdentifier>{1bd97a78-befa-3805-8e9c-80d7c1aff37b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_pwhash\scryptsalsa208sha256"> + <UniqueIdentifier>{e785f104-1212-37bf-8511-cc518b9ace66}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_pwhash\scryptsalsa208sha256\nosse"> + <UniqueIdentifier>{447b993f-59fb-3efd-8c59-a1712c97dfe8}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_pwhash\scryptsalsa208sha256\sse"> + <UniqueIdentifier>{cdb8d233-06b0-3872-a62b-c1ccf4cb4314}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult"> + <UniqueIdentifier>{402a1c5a-d499-333a-a2fa-acd0e6a3c2b2}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\curve25519"> + <UniqueIdentifier>{77f5a2e9-2ef1-3a72-b63c-88e8e4b92678}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\curve25519\ref10"> + <UniqueIdentifier>{6c9c7c30-0808-3fad-8a88-944d7645e5d5}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\curve25519\sandy2x"> + <UniqueIdentifier>{5d2fb1a2-f063-32db-a81a-41f79e36fd23}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\ed25519"> + <UniqueIdentifier>{7bec6074-fbc7-330b-9e18-7dc3e868569a}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\ed25519\ref10"> + <UniqueIdentifier>{834d4827-81e4-3de3-baa1-a216763f11d6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\ristretto255"> + <UniqueIdentifier>{52bf28eb-7ffd-399a-be35-0df3e8e99c15}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_scalarmult\ristretto255\ref10"> + <UniqueIdentifier>{39cc576f-4b54-3d71-b14c-27445bc4b138}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_secretbox"> + <UniqueIdentifier>{b9b02bee-5c1f-36d2-b97d-983f865a4cc6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_secretbox\xchacha20poly1305"> + <UniqueIdentifier>{41f1f35b-4639-3424-be85-7dfba02f3c5e}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_secretbox\xsalsa20poly1305"> + <UniqueIdentifier>{8bf11d29-2f5a-3f10-8ae6-82229d19c5b0}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_secretstream"> + <UniqueIdentifier>{62f7ae38-4ce6-3976-acc3-47c462db4fbe}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_secretstream\xchacha20poly1305"> + <UniqueIdentifier>{e07a28cd-775a-3798-bfdb-97842d3614d6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_shorthash"> + <UniqueIdentifier>{bb073c16-adc8-3cff-80b9-99cf5a28de6c}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_shorthash\siphash24"> + <UniqueIdentifier>{63de0ec8-ecde-35e3-8b97-6e9e4da342ee}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_shorthash\siphash24\ref"> + <UniqueIdentifier>{29925210-53eb-342c-8527-7ebc173e668f}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_sign"> + <UniqueIdentifier>{b2f989b6-87a6-3388-a35c-2d0d59cb4236}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_sign\ed25519"> + <UniqueIdentifier>{bc6466a1-57b0-3a35-9973-ad488a4bef8c}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_sign\ed25519\ref10"> + <UniqueIdentifier>{5599d9ab-b5b2-3310-b541-ae0fb70eecf1}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream"> + <UniqueIdentifier>{eaedd08a-46f8-3d12-9e8d-bb3ee3ead5f6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\chacha20"> + <UniqueIdentifier>{806b6ff3-578b-308a-a359-0f5ed8472ecc}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\chacha20\dolbeau"> + <UniqueIdentifier>{5a1d852e-67bb-3dc1-9ec5-99ef74b7faca}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\chacha20\ref"> + <UniqueIdentifier>{33e45d9c-e12a-3e76-9ef2-4f5510244a5b}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa20"> + <UniqueIdentifier>{048ba2a8-b22b-346c-9886-668b63c88c68}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa20\ref"> + <UniqueIdentifier>{f08a312f-f8a3-350b-87ab-1f79d33e513f}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa20\xmm6"> + <UniqueIdentifier>{c403f690-cd22-3ed4-9cc7-3f46e73081fd}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa20\xmm6int"> + <UniqueIdentifier>{c34d03f5-cf47-39fe-a5ad-5eb917006203}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa2012"> + <UniqueIdentifier>{4da0c5ca-33d1-34e0-9689-12e69ae2dbd6}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa2012\ref"> + <UniqueIdentifier>{dd6b294c-5871-386c-92ec-aa46fcc411d4}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa208"> + <UniqueIdentifier>{07aca978-0547-329a-b70b-29aa579cacc5}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\salsa208\ref"> + <UniqueIdentifier>{f171fa05-35c4-32a0-b035-b5d6680ab714}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\xchacha20"> + <UniqueIdentifier>{ede2279c-1ba7-3d62-8345-733c6c1965e7}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_stream\xsalsa20"> + <UniqueIdentifier>{9c15151b-10dc-3dfe-b97b-a7d8c6b58920}</UniqueIdentifier> + </Filter> + <Filter Include="crypto_verify"> + <UniqueIdentifier>{49fb9272-ffe2-3993-b562-b19d5f2c9b40}</UniqueIdentifier> + </Filter> + <Filter Include="include"> + <UniqueIdentifier>{96da72eb-3aa0-3850-83eb-32788f91e5bd}</UniqueIdentifier> + </Filter> + <Filter Include="include\sodium"> + <UniqueIdentifier>{56bb40fc-d381-3a9e-925b-681774c48dde}</UniqueIdentifier> + </Filter> + <Filter Include="include\sodium\private"> + <UniqueIdentifier>{fde88485-0fe6-3b22-9480-1d2b49fade53}</UniqueIdentifier> + </Filter> + <Filter Include="randombytes"> + <UniqueIdentifier>{ef090484-4db4-3dc2-aca7-c59bab1db23b}</UniqueIdentifier> + </Filter> + <Filter Include="randombytes\internal"> + <UniqueIdentifier>{14c126fd-bb91-37ea-b807-b60c386be601}</UniqueIdentifier> + </Filter> + <Filter Include="randombytes\sysrandom"> + <UniqueIdentifier>{ac56c38f-7e17-3b79-bf47-58e9476b3b89}</UniqueIdentifier> + </Filter> + <Filter Include="sodium"> + <UniqueIdentifier>{5dfc520b-f690-3d5f-a86a-8b667f2e7490}</UniqueIdentifier> + </Filter> + </ItemGroup> +</Project> diff --git a/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.xml b/subprojects/libsodium/builds/msvc/vs2022/libsodium/libsodium.xml @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="utf-8"?> +<ProjectSchemaDefinitions xmlns="clr-namespace:Microsoft.Build.Framework.XamlTypes;assembly=Microsoft.Build.Framework"> + <Rule Name="libsodium-uiextension" PageTemplate="tool" DisplayName="Sodium Options" SwitchPrefix="/" Order="1"> + <Rule.Categories> + <Category Name="amd64asm" DisplayName="amd64asm" /> + </Rule.Categories> + <Rule.DataSource> + <DataSource Persistence="ProjectFile" ItemType="" /> + </Rule.DataSource> + <EnumProperty Name="Option-amd64asm" DisplayName="Enable AMD64 Assembly" Description="Enable the AMD64 Assembly build option" Category="amd64asm"> + <EnumValue Name="" DisplayName="No" /> + <EnumValue Name="true" DisplayName="Yes" /> + </EnumProperty> + </Rule> +</ProjectSchemaDefinitions> +\ No newline at end of file diff --git a/subprojects/libsodium/builds/xcode/sodium/version.h b/subprojects/libsodium/builds/xcode/sodium/version.h @@ -1,33 +0,0 @@ - -#ifndef sodium_version_H -#define sodium_version_H - -#include "export.h" - -#define SODIUM_VERSION_STRING "1.0.18" - -#define SODIUM_LIBRARY_VERSION_MAJOR 10 -#define SODIUM_LIBRARY_VERSION_MINOR 3 - - -#ifdef __cplusplus -extern "C" { -#endif - -SODIUM_EXPORT -const char *sodium_version_string(void); - -SODIUM_EXPORT -int sodium_library_version_major(void); - -SODIUM_EXPORT -int sodium_library_version_minor(void); - -SODIUM_EXPORT -int sodium_library_minimal(void); - -#ifdef __cplusplus -} -#endif - -#endif diff --git a/subprojects/libsodium/ci/appveyor/libsodium.sln b/subprojects/libsodium/ci/appveyor/libsodium.sln @@ -0,0 +1,40 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 14 +VisualStudioVersion = 14.0.23107.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libsodium", "libsodium.vcxproj", "{A185B162-6CB6-4502-B03F-B56F7699A8D9}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 + DebugDLL|Win32 = DebugDLL|Win32 + DebugDLL|x64 = DebugDLL|x64 + Release|Win32 = Release|Win32 + Release|x64 = Release|x64 + ReleaseDLL|Win32 = ReleaseDLL|Win32 + ReleaseDLL|x64 = ReleaseDLL|x64 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|Win32.ActiveCfg = Debug|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|Win32.Build.0 = Debug|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|x64.ActiveCfg = Debug|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|x64.Build.0 = Debug|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|Win32.ActiveCfg = DebugDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|Win32.Build.0 = DebugDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|x64.ActiveCfg = DebugDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|x64.Build.0 = DebugDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|Win32.ActiveCfg = Release|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|Win32.Build.0 = Release|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|x64.ActiveCfg = Release|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|x64.Build.0 = Release|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|Win32.ActiveCfg = ReleaseDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|Win32.Build.0 = ReleaseDLL|Win32 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|x64.ActiveCfg = ReleaseDLL|x64 + {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|x64.Build.0 = ReleaseDLL|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/subprojects/libsodium/ci/appveyor/libsodium.vcxproj b/subprojects/libsodium/ci/appveyor/libsodium.vcxproj @@ -0,0 +1,594 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup Label="ProjectConfigurations"> + <ProjectConfiguration Include="DebugDLL|Win32"> + <Configuration>DebugDLL</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="DebugDLL|x64"> + <Configuration>DebugDLL</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Debug|Win32"> + <Configuration>Debug</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Debug|x64"> + <Configuration>Debug</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|Win32"> + <Configuration>ReleaseDLL</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="ReleaseDLL|x64"> + <Configuration>ReleaseDLL</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Release|Win32"> + <Configuration>Release</Configuration> + <Platform>Win32</Platform> + </ProjectConfiguration> + <ProjectConfiguration Include="Release|x64"> + <Configuration>Release</Configuration> + <Platform>x64</Platform> + </ProjectConfiguration> + </ItemGroup> + <PropertyGroup Label="Globals"> + <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> + <Keyword>Win32Proj</Keyword> + <RootNamespace>libsodium</RootNamespace> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> + <ConfigurationType>StaticLibrary</ConfigurationType> + <UseDebugLibraries>true</UseDebugLibraries> + <CharacterSet>MultiByte</CharacterSet> + <WholeProgramOptimization>false</WholeProgramOptimization> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <UseDebugLibraries>true</UseDebugLibraries> + <CharacterSet>MultiByte</CharacterSet> + <WholeProgramOptimization>false</WholeProgramOptimization> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> + <ConfigurationType>StaticLibrary</ConfigurationType> + <UseDebugLibraries>true</UseDebugLibraries> + <CharacterSet>MultiByte</CharacterSet> + <WholeProgramOptimization>false</WholeProgramOptimization> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <UseDebugLibraries>true</UseDebugLibraries> + <CharacterSet>MultiByte</CharacterSet> + <WholeProgramOptimization>false</WholeProgramOptimization> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> + <ConfigurationType>StaticLibrary</ConfigurationType> + <UseDebugLibraries>false</UseDebugLibraries> + <WholeProgramOptimization>true</WholeProgramOptimization> + <CharacterSet>MultiByte</CharacterSet> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <UseDebugLibraries>false</UseDebugLibraries> + <WholeProgramOptimization>true</WholeProgramOptimization> + <CharacterSet>MultiByte</CharacterSet> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> + <ConfigurationType>StaticLibrary</ConfigurationType> + <UseDebugLibraries>false</UseDebugLibraries> + <WholeProgramOptimization>true</WholeProgramOptimization> + <CharacterSet>MultiByte</CharacterSet> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'" Label="Configuration"> + <ConfigurationType>DynamicLibrary</ConfigurationType> + <UseDebugLibraries>false</UseDebugLibraries> + <WholeProgramOptimization>true</WholeProgramOptimization> + <CharacterSet>MultiByte</CharacterSet> + <PlatformToolset>v140</PlatformToolset> + </PropertyGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> + <ImportGroup Label="ExtensionSettings"> + </ImportGroup> + <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <ImportGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'" Label="PropertySheets"> + <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> + <Import Project="msvc-scripts\sodium.props" /> + </ImportGroup> + <PropertyGroup Label="UserMacros" /> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <LinkIncremental>true</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'"> + <LinkIncremental>true</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <LinkIncremental>true</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'"> + <LinkIncremental>true</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <LinkIncremental>false</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'"> + <LinkIncremental>false</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> + <LinkIncremental>false</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'"> + <LinkIncremental>false</LinkIncremental> + <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> + <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> + </PropertyGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ClCompile> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <Optimization>Disabled</Optimization> + <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'"> + <ClCompile> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <Optimization>Disabled</Optimization> + <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + <AdditionalIncludeDirectories>$(SolutionDir)..\..\;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <ClCompile> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <Optimization>Disabled</Optimization> + <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'"> + <ClCompile> + <PrecompiledHeader> + </PrecompiledHeader> + <WarningLevel>Level3</WarningLevel> + <Optimization>Disabled</Optimization> + <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ClCompile> + <WarningLevel>Level3</WarningLevel> + <PrecompiledHeader> + </PrecompiledHeader> + <Optimization>Full</Optimization> + <FunctionLevelLinking>true</FunctionLevelLinking> + <IntrinsicFunctions>true</IntrinsicFunctions> + <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreaded</RuntimeLibrary> + <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + <EnableCOMDATFolding>true</EnableCOMDATFolding> + <OptimizeReferences>true</OptimizeReferences> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'"> + <ClCompile> + <WarningLevel>Level3</WarningLevel> + <PrecompiledHeader> + </PrecompiledHeader> + <Optimization>Full</Optimization> + <FunctionLevelLinking>true</FunctionLevelLinking> + <IntrinsicFunctions>true</IntrinsicFunctions> + <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> + <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + <EnableCOMDATFolding>true</EnableCOMDATFolding> + <OptimizeReferences>true</OptimizeReferences> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> + <ClCompile> + <WarningLevel>Level3</WarningLevel> + <PrecompiledHeader> + </PrecompiledHeader> + <Optimization>MaxSpeed</Optimization> + <FunctionLevelLinking>true</FunctionLevelLinking> + <IntrinsicFunctions>true</IntrinsicFunctions> + <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreaded</RuntimeLibrary> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + <EnableCOMDATFolding>true</EnableCOMDATFolding> + <OptimizeReferences>true</OptimizeReferences> + </Link> + </ItemDefinitionGroup> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'"> + <ClCompile> + <WarningLevel>Level3</WarningLevel> + <PrecompiledHeader> + </PrecompiledHeader> + <Optimization>MaxSpeed</Optimization> + <FunctionLevelLinking>true</FunctionLevelLinking> + <IntrinsicFunctions>true</IntrinsicFunctions> + <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> + <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> + </ClCompile> + <Link> + <SubSystem>Console</SubSystem> + <GenerateDebugInformation>true</GenerateDebugInformation> + <EnableCOMDATFolding>true</EnableCOMDATFolding> + <OptimizeReferences>true</OptimizeReferences> + </Link> + </ItemDefinitionGroup> + <ItemGroup> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\crypto_generichash.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_kx\crypto_kx.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\crypto_sign.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\sign_ed25519.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\obsolete.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\sign.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\keypair.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\open.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\crypto_secretbox.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\crypto_secretbox_easy.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\crypto_pwhash.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_verify\verify.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_auth\crypto_auth.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\crypto_kdf.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\crypto_scalarmult.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c" /> + <ClCompile Include="..\..\src\libsodium\randombytes\randombytes.c" /> + <ClCompile Include="..\..\src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c" /> + <ClCompile Include="..\..\src\libsodium\randombytes\internal\randombytes_internal_random.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box_easy.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box_seal.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\sodium\codecs.c" /> + <ClCompile Include="..\..\src\libsodium\sodium\runtime.c" /> + <ClCompile Include="..\..\src\libsodium\sodium\core.c" /> + <ClCompile Include="..\..\src\libsodium\sodium\utils.c" /> + <ClCompile Include="..\..\src\libsodium\sodium\version.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\crypto_stream.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa208\stream_salsa208.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_hash\crypto_hash.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha512\hash_sha512.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\softaes\softaes.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa2012.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\utils.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash_sha512.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\core.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\version.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\export.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash_sha256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kx.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_32.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_ristretto255.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa208.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes_sysrandom.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\runtime.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa208.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aes256gcm.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa2012.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_16.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_chacha20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_xsalsa20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_hsalsa20.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_shorthash.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign_ed25519.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_onetimeauth.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_64.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_ed25519.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes_internal_random.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_generichash.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_ed25519.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\softaes.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\sse2_64_32.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\asm_cet.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\common.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\mutex.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\implementations.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u4.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u0.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u1.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u8.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u4.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u0.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u1.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\implementations.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\implementations.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h" /> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h" /> + <ClInclude Include="..\..\builds\msvc\resource.h" /> + </ItemGroup> + <ItemGroup> + <ResourceCompile Include="..\..\builds\msvc\resource.rc"> + </ResourceCompile> + </ItemGroup> + <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> + <ImportGroup Label="ExtensionTargets"> + </ImportGroup> +</Project> diff --git a/subprojects/libsodium/ci/appveyor/libsodium.vcxproj.filters b/subprojects/libsodium/ci/appveyor/libsodium.vcxproj.filters @@ -0,0 +1,813 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ItemGroup> + <Filter Include="Source Files"> + <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> + <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> + </Filter> + <Filter Include="Header Files"> + <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier> + <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions> + </Filter> + <Filter Include="Resource Files"> + <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier> + <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions> + </Filter> + </ItemGroup> + <ItemGroup> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\crypto_generichash.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\generichash_blake2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_kx\crypto_kx.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\crypto_sign.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\sign_ed25519.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\obsolete.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\sign.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\keypair.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\open.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\crypto_secretbox.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\crypto_secretbox_easy.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\crypto_pwhash.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_verify\verify.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_auth\crypto_auth.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\crypto_kdf.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_kdf\hkdf\kdf_hkdf_sha512.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\crypto_shorthash.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\crypto_scalarmult.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\randombytes\randombytes.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\randombytes\internal\randombytes_internal_random.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box_easy.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box_seal.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\crypto_box.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\sodium\codecs.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\sodium\runtime.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\sodium\core.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\sodium\utils.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\sodium\version.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\crypto_stream.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa208\stream_salsa208.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_hash\crypto_hash.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha512\hash_sha512.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha256\hash_sha256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\xchacha20poly1305\aead_xchacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aead_aegis128l.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aead_aegis256.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\aead_aes256gcm.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\aes256gcm\armcrypto\aead_aes256gcm_armcrypto.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_aead\chacha20poly1305\aead_chacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\hchacha20\core_hchacha20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\softaes\softaes.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\core_ed25519.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\core_ristretto255.c"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\..\src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c"> + <Filter>Source Files</Filter> + </ClCompile> + </ItemGroup> + <ItemGroup> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa2012.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\utils.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_hchacha20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aegis256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash_sha512.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\core.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\version.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\export.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_shorthash_siphash24.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash_sha256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kx.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_hash.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_32.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_ristretto255.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_xchacha20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa208.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aegis128l.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes_sysrandom.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\runtime.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_salsa208.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_aead_aes256gcm.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_salsa2012.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_16.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_chacha20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_stream_xsalsa20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_hsalsa20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_blake2b.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_curve25519.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_shorthash.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign_ed25519.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_onetimeauth.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_verify_64.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_core_ed25519.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_kdf_hkdf_sha512.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\randombytes_internal_random.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_generichash.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_secretbox.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_scalarmult_ed25519.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_generichash_blake2b.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\softaes.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\sse2_64_32.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\asm_cet.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\common.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\mutex.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\chacha20_ietf_ext.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\include\sodium\private\implementations.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-encoding.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blake2b-long.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\argon2\argon2-core.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\stream_chacha20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u4.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u0.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u1.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\chacha20\dolbeau\u8.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\stream_salsa20.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u4.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u0.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u1.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\u8.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_armcrypto.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_aesni.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_soft.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\aegis128l_common.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis128l\implementations.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_aesni.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_common.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\implementations.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_armcrypto.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_aead\aegis256\aegis256_soft.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h"> + <Filter>Header Files</Filter> + </ClInclude> + <ClInclude Include="..\..\src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h"> + <Filter>Header Files</Filter> + </ClInclude> + </ItemGroup> +</Project> diff --git a/subprojects/libsodium/ci/appveyor/msvc-scripts/process.bat b/subprojects/libsodium/ci/appveyor/msvc-scripts/process.bat @@ -0,0 +1,5 @@ +cscript msvc-scripts/rep.vbs //Nologo s/@VERSION@/1.0.20/ < ..\..\src\libsodium\include\sodium\version.h.in > tmp +cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_VERSION_MAJOR@/26/ < tmp > tmp2 +cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_VERSION_MINOR@/2/ < tmp2 > tmp3 +cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_MINIMAL_DEF@// < tmp3 > ..\..\src\libsodium\include\sodium\version.h +del tmp tmp2 tmp3 diff --git a/subprojects/libsodium/msvc-scripts/rep.vbs b/subprojects/libsodium/ci/appveyor/msvc-scripts/rep.vbs diff --git a/subprojects/libsodium/ci/appveyor/msvc-scripts/sodium.props b/subprojects/libsodium/ci/appveyor/msvc-scripts/sodium.props @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <ImportGroup Label="PropertySheets" /> + <PropertyGroup Label="UserMacros" /> + <PropertyGroup /> + <ItemDefinitionGroup> + <ClCompile> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <MultiProcessorCompilation>true</MultiProcessorCompilation> + <PreprocessorDefinitions>UNICODE;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <PreprocessorDefinitions>NATIVE_LITTLE_ENDIAN=1;%(PreprocessorDefinitions)</PreprocessorDefinitions> + <PreprocessorDefinitions>inline=__inline;%(PreprocessorDefinitions)</PreprocessorDefinitions> + </ClCompile> + <PreBuildEvent> + <Command>"$(SolutionDir)\msvc-scripts\process.bat"</Command> + </PreBuildEvent> + <PreBuildEvent> + <Message>Process .in files</Message> + </PreBuildEvent> + <PostBuildEvent> + <Command>"$(SolutionDir)..\..\test\default\wintest.bat" $(Configuration) $(Platform)</Command> + </PostBuildEvent> + <PostBuildEvent> + <Message>Run the test suite</Message> + </PostBuildEvent> + </ItemDefinitionGroup> + <ItemGroup /> +</Project> diff --git a/subprojects/libsodium/configure b/subprojects/libsodium/configure @@ -1,11 +1,12 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for libsodium 1.0.18. +# Generated by GNU Autoconf 2.72 for libsodium 1.0.20. # # Report bugs to <https://github.com/jedisct1/libsodium/issues>. # # -# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# Copyright (C) 1992-1996, 1998-2017, 2020-2023 Free Software Foundation, +# Inc. # # # This configure script is free software; the Free Software Foundation @@ -16,63 +17,65 @@ # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : +if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 +then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( +else case e in #( + e) case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; +esac ;; esac fi + +# Reset variables that may have inherited troublesome values from +# the environment. + +# IFS needs to be set, to space, tab, and newline, in precisely that order. +# (If _AS_PATH_WALK were called with IFS unset, it would have the +# side effect of setting IFS to empty, thus disabling word splitting.) +# Quoting is to prevent editors from complaining about space-tab. as_nl=' ' export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi +IFS=" "" $as_nl" + +PS1='$ ' +PS2='> ' +PS4='+ ' + +# Ensure predictable behavior from utilities with locale-dependent output. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# We cannot yet rely on "unset" to work, but we need these variables +# to be unset--not just set to an empty or harmless value--now, to +# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct +# also avoids known problems related to "unset" and subshell syntax +# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). +for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH +do eval test \${$as_var+y} \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done + +# Ensure that fds 0, 1, and 2 are open. +if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi +if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi +if (exec 3>&2) ; then :; else exec 2>/dev/null; fi # The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then +if ${PATH_SEPARATOR+false} :; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || @@ -81,13 +84,6 @@ if test "${PATH_SEPARATOR+set}" != set; then fi -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( @@ -96,43 +92,27 @@ case $0 in #(( for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + test -r "$as_dir$0" && as_myself=$as_dir$0 && break done IFS=$as_save_IFS ;; esac -# We did not find ourselves, most probably we were run as `sh COMMAND' +# We did not find ourselves, most probably we were run as 'sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. @@ -153,26 +133,28 @@ case $- in # (((( esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 -as_fn_exit 255 +# out after a failed 'exec'. +printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 +exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then - as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : + as_bourne_compatible="if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 +then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST -else - case \`(set -o) 2>/dev/null\` in #( +else case e in #( + e) case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; +esac ;; esac fi " @@ -187,12 +169,16 @@ as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } -if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : +if ( set x; as_fn_ret_success y && test x = \"\$1\" ) +then : -else - exitcode=1; echo positional parameters were not saved. +else case e in #( + e) exitcode=1; echo positional parameters were not saved. ;; +esac fi test x\$exitcode = x0 || exit 1 +blah=\$(echo \$(echo blah)) +test x\"\$blah\" = xblah || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO @@ -207,30 +193,39 @@ test \$(( 1 + 1 )) = 2 || exit 1 PATH=/empty FPATH=/empty; export PATH FPATH test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" - if (eval "$as_required") 2>/dev/null; then : + if (eval "$as_required") 2>/dev/null +then : as_have_required=yes -else - as_have_required=no +else case e in #( + e) as_have_required=no ;; +esac fi - if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null +then : -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +else case e in #( + e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. - as_shell=$as_dir/$as_base + as_shell=$as_dir$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null +then : CONFIG_SHELL=$as_shell as_have_required=yes - if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null +then : break 2 fi fi @@ -238,14 +233,22 @@ fi esac as_found=false done -$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && - { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : - CONFIG_SHELL=$SHELL as_have_required=yes -fi; } IFS=$as_save_IFS +if $as_found +then : + +else case e in #( + e) if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null +then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi ;; +esac +fi - if test "x$CONFIG_SHELL" != x; then : + if test "x$CONFIG_SHELL" != x +then : export CONFIG_SHELL # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also @@ -262,26 +265,28 @@ case $- in # (((( esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail -# out after a failed `exec'. -$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 +# out after a failed 'exec'. +printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi - if test x$as_have_required = xno; then : - $as_echo "$0: This script requires a shell more modern than all" - $as_echo "$0: the shells that I found on your system." - if test x${ZSH_VERSION+set} = xset ; then - $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" - $as_echo "$0: be upgraded to zsh 4.3.4 or later." + if test x$as_have_required = xno +then : + printf "%s\n" "$0: This script requires a shell more modern than all" + printf "%s\n" "$0: the shells that I found on your system." + if test ${ZSH_VERSION+y} ; then + printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should" + printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later." else - $as_echo "$0: Please tell bug-autoconf@gnu.org and + printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and $0: https://github.com/jedisct1/libsodium/issues about your $0: system, including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 -fi +fi ;; +esac fi fi SHELL=${CONFIG_SHELL-/bin/sh} @@ -302,6 +307,7 @@ as_fn_unset () } as_unset=as_fn_unset + # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. @@ -333,7 +339,7 @@ as_fn_mkdir_p () as_dirs= while :; do case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" @@ -342,7 +348,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | +printf "%s\n" X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -381,16 +387,18 @@ as_fn_executable_p () # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null +then : eval 'as_fn_append () { eval $1+=\$2 }' -else - as_fn_append () +else case e in #( + e) as_fn_append () { eval $1=\$$1\$2 - } + } ;; +esac fi # as_fn_append # as_fn_arith ARG... @@ -398,16 +406,18 @@ fi # as_fn_append # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null +then : eval 'as_fn_arith () { as_val=$(( $* )) }' -else - as_fn_arith () +else case e in #( + e) as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` - } + } ;; +esac fi # as_fn_arith @@ -421,9 +431,9 @@ as_fn_error () as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi - $as_echo "$as_me: error: $2" >&2 + printf "%s\n" "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error @@ -450,7 +460,7 @@ as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | +printf "%s\n" X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q @@ -483,6 +493,8 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits /[$]LINENO/= ' <$as_myself | sed ' + t clear + :clear s/[$]LINENO.*/&-/ t lineno b @@ -494,7 +506,7 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || - { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } + { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall @@ -508,6 +520,10 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits exit } + +# Determine whether it's possible to make 'echo' print without a newline. +# These variables are no longer used directly by Autoconf, but are AC_SUBSTed +# for compatibility with existing Makefiles. ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) @@ -521,6 +537,12 @@ case `echo -n x` in #((((( ECHO_N='-n';; esac +# For backward compatibility with old third-party macros, we provide +# the shell variables $as_echo and $as_echo_n. New code should use +# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. +as_echo='printf %s\n' +as_echo_n='printf %s' + rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file @@ -532,9 +554,9 @@ if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. + # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable. + # In both cases, we have to default to 'cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then @@ -559,10 +581,12 @@ as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" +as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g" +as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated # Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g" +as_tr_sh="eval sed '$as_sed_sh'" # deprecated SHELL=${CONFIG_SHELL-/bin/sh} @@ -590,55 +614,50 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libsodium' PACKAGE_TARNAME='libsodium' -PACKAGE_VERSION='1.0.18' -PACKAGE_STRING='libsodium 1.0.18' +PACKAGE_VERSION='1.0.20' +PACKAGE_STRING='libsodium 1.0.20' PACKAGE_BUGREPORT='https://github.com/jedisct1/libsodium/issues' -PACKAGE_URL='https://github.com/jedisct1/libsodium' +PACKAGE_URL='https://libsodium.org' ac_unique_file="src/libsodium/sodium/version.c" # Factoring default headers for most tests. ac_includes_default="\ -#include <stdio.h> -#ifdef HAVE_SYS_TYPES_H -# include <sys/types.h> -#endif -#ifdef HAVE_SYS_STAT_H -# include <sys/stat.h> +#include <stddef.h> +#ifdef HAVE_STDIO_H +# include <stdio.h> #endif -#ifdef STDC_HEADERS +#ifdef HAVE_STDLIB_H # include <stdlib.h> -# include <stddef.h> -#else -# ifdef HAVE_STDLIB_H -# include <stdlib.h> -# endif #endif #ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include <memory.h> -# endif # include <string.h> #endif -#ifdef HAVE_STRINGS_H -# include <strings.h> -#endif #ifdef HAVE_INTTYPES_H # include <inttypes.h> #endif #ifdef HAVE_STDINT_H # include <stdint.h> #endif +#ifdef HAVE_STRINGS_H +# include <strings.h> +#endif +#ifdef HAVE_SYS_TYPES_H +# include <sys/types.h> +#endif +#ifdef HAVE_SYS_STAT_H +# include <sys/stat.h> +#endif #ifdef HAVE_UNISTD_H # include <unistd.h> #endif" +ac_header_c_list= ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS HAVE_LD_OUTPUT_DEF_FALSE HAVE_LD_OUTPUT_DEF_TRUE -AS WASI_FALSE WASI_TRUE EMSCRIPTEN_FALSE @@ -667,6 +686,7 @@ CFLAGS_SSSE3 CFLAGS_SSE3 CFLAGS_SSE2 CFLAGS_MMX +CFLAGS_ARMCRYPTO LIBTOOL_DEPS LT_SYS_LIBRARY_PATH OTOOL64 @@ -680,19 +700,17 @@ ac_ct_AR AR DLLTOOL OBJDUMP +FILECMD LN_S NM ac_ct_DUMPBIN DUMPBIN LD FGREP +EGREP +GREP LIBTOOL CWFLAGS -am__fastdepCCAS_FALSE -am__fastdepCCAS_TRUE -CCASDEPMODE -CCASFLAGS -CCAS VALGRIND_CHECK_RULES valgrind_enabled_tools valgrind_tools @@ -708,15 +726,19 @@ PKGCONFIG_LIBS_PRIVATE SAFECODE_HOME PTHREAD_CFLAGS PTHREAD_LIBS +PTHREAD_CXX PTHREAD_CC ax_pthread_config -EGREP -GREP CPP SED SODIUM_LIBRARY_MINIMAL_DEF MINIMAL_FALSE MINIMAL_TRUE +am__fastdepCCAS_FALSE +am__fastdepCCAS_TRUE +CCASDEPMODE +CCASFLAGS +CCAS am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE @@ -740,10 +762,15 @@ AMDEP_TRUE MAINT MAINTAINER_MODE_FALSE MAINTAINER_MODE_TRUE +am__xargs_n +am__rm_f_notfound AM_BACKSLASH AM_DEFAULT_VERBOSITY AM_DEFAULT_V AM_V +CSCOPE +ETAGS +CTAGS am__untar am__tar AMTAR @@ -767,6 +794,10 @@ am__isrc INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM +target_os +target_vendor +target_cpu +target host_os host_vendor host_cpu @@ -794,6 +825,7 @@ infodir docdir oldincludedir includedir +runstatedir localstatedir sharedstatedir sysconfdir @@ -839,8 +871,10 @@ enable_valgrind_sgcheck enable_soname_versions enable_shared enable_static +enable_pic with_pic enable_fast_install +enable_aix_soname with_aix_soname with_gnu_ld with_sysroot @@ -854,10 +888,10 @@ CFLAGS LDFLAGS LIBS CPPFLAGS -CPP -SAFECODE_HOME CCAS CCASFLAGS +CPP +SAFECODE_HOME CWFLAGS LT_SYS_LIBRARY_PATH AR' @@ -899,6 +933,7 @@ datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' +runstatedir='${localstatedir}/run' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' @@ -928,8 +963,6 @@ do *) ac_optarg=yes ;; esac - # Accept the important Cygnus configure options, so we can diagnose typos. - case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; @@ -970,9 +1003,9 @@ do ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: '$ac_useropt'" ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" @@ -996,9 +1029,9 @@ do ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid feature name: $ac_useropt" + as_fn_error $? "invalid feature name: '$ac_useropt'" ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" @@ -1151,6 +1184,15 @@ do | -silent | --silent | --silen | --sile | --sil) silent=yes ;; + -runstatedir | --runstatedir | --runstatedi | --runstated \ + | --runstate | --runstat | --runsta | --runst | --runs \ + | --run | --ru | --r) + ac_prev=runstatedir ;; + -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ + | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ + | --run=* | --ru=* | --r=*) + runstatedir=$ac_optarg ;; + -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ @@ -1200,9 +1242,9 @@ do ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: '$ac_useropt'" ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" @@ -1216,9 +1258,9 @@ do ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && - as_fn_error $? "invalid package name: $ac_useropt" + as_fn_error $? "invalid package name: '$ac_useropt'" ac_useropt_orig=$ac_useropt - ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` + ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" @@ -1246,8 +1288,8 @@ do | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; - -*) as_fn_error $? "unrecognized option: \`$ac_option' -Try \`$0 --help' for more information" + -*) as_fn_error $? "unrecognized option: '$ac_option' +Try '$0 --help' for more information" ;; *=*) @@ -1255,16 +1297,16 @@ Try \`$0 --help' for more information" # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) - as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + as_fn_error $? "invalid variable name: '$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. - $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 + printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && - $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 + printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; @@ -1280,7 +1322,7 @@ if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; - *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; + *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi @@ -1288,7 +1330,7 @@ fi for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ - libdir localedir mandir + libdir localedir mandir runstatedir do eval ac_val=\$$ac_var # Remove trailing slashes. @@ -1305,7 +1347,7 @@ do as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done -# There might be people who depend on the old broken behavior: `$host' +# There might be people who depend on the old broken behavior: '$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias @@ -1344,7 +1386,7 @@ $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_myself" | +printf "%s\n" X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -1373,7 +1415,7 @@ if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi -ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" +ac_msg="sources are in $srcdir, but 'cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` @@ -1401,7 +1443,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures libsodium 1.0.18 to adapt to many kinds of systems. +'configure' configures libsodium 1.0.20 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1415,11 +1457,11 @@ Configuration: --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit - -q, --quiet, --silent do not print \`checking ...' messages + -q, --quiet, --silent do not print 'checking ...' messages --cache-file=FILE cache test results in FILE [disabled] - -C, --config-cache alias for \`--cache-file=config.cache' + -C, --config-cache alias for '--cache-file=config.cache' -n, --no-create do not create output files - --srcdir=DIR find the sources in DIR [configure dir or \`..'] + --srcdir=DIR find the sources in DIR [configure dir or '..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX @@ -1427,10 +1469,10 @@ Installation directories: --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] -By default, \`make install' will install all the files in -\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify -an installation prefix other than \`$ac_default_prefix' using \`--prefix', -for instance \`--prefix=\$HOME'. +By default, 'make install' will install all the files in +'$ac_default_prefix/bin', '$ac_default_prefix/lib' etc. You can specify +an installation prefix other than '$ac_default_prefix' using '--prefix', +for instance '--prefix=\$HOME'. For better control, use the options below. @@ -1441,6 +1483,7 @@ Fine tuning of the installation directories: --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] + --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] @@ -1466,12 +1509,13 @@ Program names: System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] + --target=TARGET configure for building compilers for TARGET [HOST] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of libsodium 1.0.18:";; + short | recursive ) echo "Configuration of libsodium 1.0.20:";; esac cat <<\_ACEOF @@ -1504,7 +1548,6 @@ Optional Features: --enable-opt Optimize for the native CPU - The resulting library will be faster but not portable --enable-valgrind Whether to enable Valgrind on the unit tests - (requires GNU make) --disable-valgrind-memcheck Whether to skip memcheck during the Valgrind tests --disable-valgrind-helgrind @@ -1517,22 +1560,22 @@ Optional Features: Android) (default: enabled) --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] + --enable-pic[=PKGS] try to use only PIC/non-PIC objects [default=use + both] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] + --enable-aix-soname=aix|svr4|both + shared library versioning (aka "SONAME") variant to + provide on AIX, [default=aix]. --disable-libtool-lock avoid locking (might break parallel builds) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-pthreads use pthreads library, or --without-pthreads to - disable threading support. + disable threading support --with-safecode For maintainers only - please do not use --with-ctgrind For maintainers only - please do not use - --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use - both] - --with-aix-soname=aix|svr4|both - shared library versioning (aka "SONAME") variant to - provide on AIX, [default=aix]. --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified). @@ -1545,21 +1588,21 @@ Some influential environment variables: LIBS libraries to pass to the linker, e.g. -l<library> CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if you have headers in a nonstandard directory <include dir> + CCAS assembler compiler command (defaults to CC) + CCASFLAGS assembler compiler flags (defaults to CFLAGS) CPP C preprocessor SAFECODE_HOME set to the safecode base directory - CCAS assembler compiler command (defaults to CC) - CCASFLAGS assembler compiler flags (defaults to CFLAGS) - CWFLAGS define to compilation flags for generating extra warnings + CWFLAGS compilation flags for generating extra warnings LT_SYS_LIBRARY_PATH User-defined run-time library search path. AR path to the ar utility -Use these variables to override the choices made by `configure' or to help +Use these variables to override the choices made by 'configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to <https://github.com/jedisct1/libsodium/issues>. -libsodium home page: <https://github.com/jedisct1/libsodium>. +libsodium home page: <https://libsodium.org>. _ACEOF ac_status=$? fi @@ -1575,9 +1618,9 @@ if test "$ac_init_help" = "recursive"; then case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; @@ -1605,7 +1648,8 @@ esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } - # Check for guested configure. + # Check for configure.gnu first; this name is used for a wrapper for + # Metaconfig's "Configure" on case-insensitive file systems. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive @@ -1613,7 +1657,7 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix echo && $SHELL "$ac_srcdir/configure" --help=recursive else - $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 + printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done @@ -1622,10 +1666,10 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -libsodium configure 1.0.18 -generated by GNU Autoconf 2.69 +libsodium configure 1.0.20 +generated by GNU Autoconf 2.72 -Copyright (C) 2012 Free Software Foundation, Inc. +Copyright (C) 2023 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1642,14 +1686,14 @@ fi ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext + rm -f conftest.$ac_objext conftest.beam if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then @@ -1657,37 +1701,74 @@ $as_echo "$ac_try_echo"; } >&5 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err - } && test -s conftest.$ac_objext; then : + } && test -s conftest.$ac_objext +then : ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 +else case e in #( + e) printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=1 + ac_retval=1 ;; +esac fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +printf %s "checking for $2... " >&6; } +if eval test \${$3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + eval "$3=yes" +else case e in #( + e) eval "$3=no" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +eval ac_res=\$$3 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - rm -f conftest.$ac_objext conftest$ac_exeext + rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then @@ -1695,20 +1776,22 @@ $as_echo "$ac_try_echo"; } >&5 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext - }; then : + } +then : ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 +else case e in #( + e) printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=1 + ac_retval=1 ;; +esac fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would @@ -1732,7 +1815,7 @@ case "(($ac_try" in *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then @@ -1740,118 +1823,29 @@ $as_echo "$ac_try_echo"; } >&5 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err - }; then : + } +then : ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 +else case e in #( + e) printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=1 + ac_retval=1 ;; +esac fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp -# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists, giving a warning if it cannot be compiled using -# the include files in INCLUDES and setting the cache variable VAR -# accordingly. -ac_fn_c_check_header_mongrel () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval \${$3+:} false; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 -$as_echo_n "checking $2 usability... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_header_compiler=yes -else - ac_header_compiler=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } - -# Is the header present? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 -$as_echo_n "checking $2 presence... " >&6; } -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <$2> -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - ac_header_preproc=yes -else - ac_header_preproc=no -fi -rm -f conftest.err conftest.i conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( - yes:no: ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} - ;; - no:yes:* ) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} -( $as_echo "## ----------------------------------------------------------- ## -## Report this to https://github.com/jedisct1/libsodium/issues ## -## ----------------------------------------------------------- ##" - ) | sed "s/^/$as_me: WARNING: /" >&2 - ;; -esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=\$ac_header_compiler" -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -fi - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_mongrel - # ac_fn_c_try_run LINENO # ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. +# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that +# executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack @@ -1861,28 +1855,30 @@ case "(($ac_try" in *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } +then : ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 +else case e in #( + e) printf "%s\n" "$as_me: program exited with status $ac_status" >&5 + printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=$ac_status + ac_retval=$ac_status ;; +esac fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno @@ -1890,65 +1886,28 @@ fi } # ac_fn_c_try_run -# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES -# ------------------------------------------------------- -# Tests whether HEADER exists and can be compiled using the include files in -# INCLUDES, setting the cache variable VAR accordingly. -ac_fn_c_check_header_compile () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -$4 -#include <$2> -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - eval "$3=yes" -else - eval "$3=no" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - -} # ac_fn_c_check_header_compile - # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +printf %s "checking for $2... " >&6; } +if eval test \${$3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case <limits.h> declares $2. For example, HP-UX 11i <limits.h> declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $2 (); below. - Prefer <limits.h> to <assert.h> if __STDC__ is defined, since - <limits.h> exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include <limits.h> -#else -# include <assert.h> -#endif + which can conflict with char $2 (void); below. */ +#include <limits.h> #undef $2 /* Override any GCC internal prototype to avoid an error. @@ -1957,7 +1916,7 @@ else #ifdef __cplusplus extern "C" #endif -char $2 (); +char $2 (void); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ @@ -1966,24 +1925,27 @@ choke me #endif int -main () +main (void) { return $2 (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$3=yes" -else - eval "$3=no" +else case e in #( + e) eval "$3=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext ;; +esac fi eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func @@ -1995,17 +1957,18 @@ $as_echo "$ac_res" >&6; } ac_fn_c_check_type () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 -$as_echo_n "checking for $2... " >&6; } -if eval \${$3+:} false; then : - $as_echo_n "(cached) " >&6 -else - eval "$3=no" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +printf %s "checking for $2... " >&6; } +if eval test \${$3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int -main () +main (void) { if (sizeof ($2)) return 0; @@ -2013,12 +1976,13 @@ if (sizeof ($2)) return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int -main () +main (void) { if (sizeof (($2))) return 0; @@ -2026,29 +1990,52 @@ if (sizeof (($2))) return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : -else - eval "$3=yes" +else case e in #( + e) eval "$3=yes" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi eval ac_res=\$$3 - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_type +ac_configure_args_raw= +for ac_arg +do + case $ac_arg in + *\'*) + ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + esac + as_fn_append ac_configure_args_raw " '$ac_arg'" +done + +case $ac_configure_args_raw in + *$as_nl*) + ac_safe_unquote= ;; + *) + ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab. + ac_unsafe_a="$ac_unsafe_z#~" + ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g" + ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;; +esac + cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by libsodium $as_me 1.0.18, which was -generated by GNU Autoconf 2.69. Invocation command line was +It was created by libsodium $as_me 1.0.20, which was +generated by GNU Autoconf 2.72. Invocation command line was - $ $0 $@ + $ $0$ac_configure_args_raw _ACEOF exec 5>>config.log @@ -2081,8 +2068,12 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + printf "%s\n" "PATH: $as_dir" done IFS=$as_save_IFS @@ -2117,7 +2108,7 @@ do | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) - ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; + ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; @@ -2152,11 +2143,13 @@ done # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? + # Sanitize IFS. + IFS=" "" $as_nl" # Save into config.log some information that might help in debugging. { echo - $as_echo "## ---------------- ## + printf "%s\n" "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo @@ -2167,8 +2160,8 @@ trap 'exit_status=$? case $ac_val in #( *${as_nl}*) case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( @@ -2192,7 +2185,7 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; ) echo - $as_echo "## ----------------- ## + printf "%s\n" "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo @@ -2200,14 +2193,14 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; do eval ac_val=\$$ac_var case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac - $as_echo "$ac_var='\''$ac_val'\''" + printf "%s\n" "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then - $as_echo "## ------------------- ## + printf "%s\n" "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo @@ -2215,15 +2208,15 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; do eval ac_val=\$$ac_var case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; + *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac - $as_echo "$ac_var='\''$ac_val'\''" + printf "%s\n" "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then - $as_echo "## ----------- ## + printf "%s\n" "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo @@ -2231,8 +2224,8 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; echo fi test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" + printf "%s\n" "$as_me: caught signal $ac_signal" + printf "%s\n" "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && @@ -2246,65 +2239,50 @@ ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h -$as_echo "/* confdefs.h */" > confdefs.h +printf "%s\n" "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. -cat >>confdefs.h <<_ACEOF -#define PACKAGE_NAME "$PACKAGE_NAME" -_ACEOF +printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define PACKAGE_TARNAME "$PACKAGE_TARNAME" -_ACEOF +printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define PACKAGE_VERSION "$PACKAGE_VERSION" -_ACEOF +printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define PACKAGE_STRING "$PACKAGE_STRING" -_ACEOF +printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" -_ACEOF +printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define PACKAGE_URL "$PACKAGE_URL" -_ACEOF +printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. -ac_site_file1=NONE -ac_site_file2=NONE if test -n "$CONFIG_SITE"; then - # We do not want a PATH search for config.site. - case $CONFIG_SITE in #(( - -*) ac_site_file1=./$CONFIG_SITE;; - */*) ac_site_file1=$CONFIG_SITE;; - *) ac_site_file1=./$CONFIG_SITE;; - esac + ac_site_files="$CONFIG_SITE" elif test "x$prefix" != xNONE; then - ac_site_file1=$prefix/share/config.site - ac_site_file2=$prefix/etc/config.site + ac_site_files="$prefix/share/config.site $prefix/etc/config.site" else - ac_site_file1=$ac_default_prefix/share/config.site - ac_site_file2=$ac_default_prefix/etc/config.site + ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" fi -for ac_site_file in "$ac_site_file1" "$ac_site_file2" + +for ac_site_file in $ac_site_files do - test "x$ac_site_file" = xNONE && continue - if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 -$as_echo "$as_me: loading site script $ac_site_file" >&6;} + case $ac_site_file in #( + */*) : + ;; #( + *) : + ac_site_file=./$ac_site_file ;; +esac + if test -f "$ac_site_file" && test -r "$ac_site_file"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 +printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ - || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } fi done @@ -2312,61 +2290,496 @@ if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 -$as_echo "$as_me: loading cache $cache_file" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 +printf "%s\n" "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 -$as_echo "$as_me: creating cache $cache_file" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 +printf "%s\n" "$as_me: creating cache $cache_file" >&6;} >$cache_file fi -# Check that the precious variables saved in the cache have kept the same -# value. -ac_cache_corrupted=false -for ac_var in $ac_precious_vars; do - eval ac_old_set=\$ac_cv_env_${ac_var}_set - eval ac_new_set=\$ac_env_${ac_var}_set - eval ac_old_val=\$ac_cv_env_${ac_var}_value - eval ac_new_val=\$ac_env_${ac_var}_value - case $ac_old_set,$ac_new_set in - set,) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,set) - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 -$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} - ac_cache_corrupted=: ;; - ,);; - *) - if test "x$ac_old_val" != "x$ac_new_val"; then - # differences in whitespace do not lead to failure. - ac_old_val_w=`echo x $ac_old_val` - ac_new_val_w=`echo x $ac_new_val` - if test "$ac_old_val_w" != "$ac_new_val_w"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 -$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} - ac_cache_corrupted=: - else - { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 -$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} - eval $ac_var=\$ac_old_val - fi - { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 -$as_echo "$as_me: former value: \`$ac_old_val'" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 -$as_echo "$as_me: current value: \`$ac_new_val'" >&2;} - fi;; - esac +# Test code for whether the C compiler supports C89 (global declarations) +ac_c_conftest_c89_globals=' +/* Does the compiler advertise C89 conformance? + Do not test the value of __STDC__, because some compilers set it to 0 + while being otherwise adequately conformant. */ +#if !defined __STDC__ +# error "Compiler does not advertise C89 conformance" +#endif + +#include <stddef.h> +#include <stdarg.h> +struct stat; +/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */ +struct buf { int x; }; +struct buf * (*rcsopen) (struct buf *, struct stat *, int); +static char *e (char **p, int i) +{ + return p[i]; +} +static char *f (char * (*g) (char **, int), char **p, ...) +{ + char *s; + va_list v; + va_start (v,p); + s = g (p, va_arg (v,int)); + va_end (v); + return s; +} + +/* C89 style stringification. */ +#define noexpand_stringify(a) #a +const char *stringified = noexpand_stringify(arbitrary+token=sequence); + +/* C89 style token pasting. Exercises some of the corner cases that + e.g. old MSVC gets wrong, but not very hard. */ +#define noexpand_concat(a,b) a##b +#define expand_concat(a,b) noexpand_concat(a,b) +extern int vA; +extern int vbee; +#define aye A +#define bee B +int *pvA = &expand_concat(v,aye); +int *pvbee = &noexpand_concat(v,bee); + +/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has + function prototypes and stuff, but not \xHH hex character constants. + These do not provoke an error unfortunately, instead are silently treated + as an "x". The following induces an error, until -std is added to get + proper ANSI mode. Curiously \x00 != x always comes out true, for an + array size at least. It is necessary to write \x00 == 0 to get something + that is true only with -std. */ +int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1]; + +/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters + inside strings and character constants. */ +#define FOO(x) '\''x'\'' +int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1]; + +int test (int i, double x); +struct s1 {int (*f) (int a);}; +struct s2 {int (*f) (double a);}; +int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int), + int, int);' + +# Test code for whether the C compiler supports C89 (body of main). +ac_c_conftest_c89_main=' +ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]); +' + +# Test code for whether the C compiler supports C99 (global declarations) +ac_c_conftest_c99_globals=' +/* Does the compiler advertise C99 conformance? */ +#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L +# error "Compiler does not advertise C99 conformance" +#endif + +// See if C++-style comments work. + +#include <stdbool.h> +extern int puts (const char *); +extern int printf (const char *, ...); +extern int dprintf (int, const char *, ...); +extern void *malloc (size_t); +extern void free (void *); + +// Check varargs macros. These examples are taken from C99 6.10.3.5. +// dprintf is used instead of fprintf to avoid needing to declare +// FILE and stderr. +#define debug(...) dprintf (2, __VA_ARGS__) +#define showlist(...) puts (#__VA_ARGS__) +#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) +static void +test_varargs_macros (void) +{ + int x = 1234; + int y = 5678; + debug ("Flag"); + debug ("X = %d\n", x); + showlist (The first, second, and third items.); + report (x>y, "x is %d but y is %d", x, y); +} + +// Check long long types. +#define BIG64 18446744073709551615ull +#define BIG32 4294967295ul +#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) +#if !BIG_OK + #error "your preprocessor is broken" +#endif +#if BIG_OK +#else + #error "your preprocessor is broken" +#endif +static long long int bignum = -9223372036854775807LL; +static unsigned long long int ubignum = BIG64; + +struct incomplete_array +{ + int datasize; + double data[]; +}; + +struct named_init { + int number; + const wchar_t *name; + double average; +}; + +typedef const char *ccp; + +static inline int +test_restrict (ccp restrict text) +{ + // Iterate through items via the restricted pointer. + // Also check for declarations in for loops. + for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i) + continue; + return 0; +} + +// Check varargs and va_copy. +static bool +test_varargs (const char *format, ...) +{ + va_list args; + va_start (args, format); + va_list args_copy; + va_copy (args_copy, args); + + const char *str = ""; + int number = 0; + float fnumber = 0; + + while (*format) + { + switch (*format++) + { + case '\''s'\'': // string + str = va_arg (args_copy, const char *); + break; + case '\''d'\'': // int + number = va_arg (args_copy, int); + break; + case '\''f'\'': // float + fnumber = va_arg (args_copy, double); + break; + default: + break; + } + } + va_end (args_copy); + va_end (args); + + return *str && number && fnumber; +} +' + +# Test code for whether the C compiler supports C99 (body of main). +ac_c_conftest_c99_main=' + // Check bool. + _Bool success = false; + success |= (argc != 0); + + // Check restrict. + if (test_restrict ("String literal") == 0) + success = true; + char *restrict newvar = "Another string"; + + // Check varargs. + success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234); + test_varargs_macros (); + + // Check flexible array members. + struct incomplete_array *ia = + malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); + ia->datasize = 10; + for (int i = 0; i < ia->datasize; ++i) + ia->data[i] = i * 1.234; + // Work around memory leak warnings. + free (ia); + + // Check named initializers. + struct named_init ni = { + .number = 34, + .name = L"Test wide string", + .average = 543.34343, + }; + + ni.number = 58; + + int dynamic_array[ni.number]; + dynamic_array[0] = argv[0][0]; + dynamic_array[ni.number - 1] = 543; + + // work around unused variable warnings + ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\'' + || dynamic_array[ni.number - 1] != 543); +' + +# Test code for whether the C compiler supports C11 (global declarations) +ac_c_conftest_c11_globals=' +/* Does the compiler advertise C11 conformance? */ +#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L +# error "Compiler does not advertise C11 conformance" +#endif + +// Check _Alignas. +char _Alignas (double) aligned_as_double; +char _Alignas (0) no_special_alignment; +extern char aligned_as_int; +char _Alignas (0) _Alignas (int) aligned_as_int; + +// Check _Alignof. +enum +{ + int_alignment = _Alignof (int), + int_array_alignment = _Alignof (int[100]), + char_alignment = _Alignof (char) +}; +_Static_assert (0 < -_Alignof (int), "_Alignof is signed"); + +// Check _Noreturn. +int _Noreturn does_not_return (void) { for (;;) continue; } + +// Check _Static_assert. +struct test_static_assert +{ + int x; + _Static_assert (sizeof (int) <= sizeof (long int), + "_Static_assert does not work in struct"); + long int y; +}; + +// Check UTF-8 literals. +#define u8 syntax error! +char const utf8_literal[] = u8"happens to be ASCII" "another string"; + +// Check duplicate typedefs. +typedef long *long_ptr; +typedef long int *long_ptr; +typedef long_ptr long_ptr; + +// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1. +struct anonymous +{ + union { + struct { int i; int j; }; + struct { int k; long int l; } w; + }; + int m; +} v1; +' + +# Test code for whether the C compiler supports C11 (body of main). +ac_c_conftest_c11_main=' + _Static_assert ((offsetof (struct anonymous, i) + == offsetof (struct anonymous, w.k)), + "Anonymous union alignment botch"); + v1.i = 2; + v1.w.k = 5; + ok |= v1.i != 5; +' + +# Test code for whether the C compiler supports C11 (complete). +ac_c_conftest_c11_program="${ac_c_conftest_c89_globals} +${ac_c_conftest_c99_globals} +${ac_c_conftest_c11_globals} + +int +main (int argc, char **argv) +{ + int ok = 0; + ${ac_c_conftest_c89_main} + ${ac_c_conftest_c99_main} + ${ac_c_conftest_c11_main} + return ok; +} +" + +# Test code for whether the C compiler supports C99 (complete). +ac_c_conftest_c99_program="${ac_c_conftest_c89_globals} +${ac_c_conftest_c99_globals} + +int +main (int argc, char **argv) +{ + int ok = 0; + ${ac_c_conftest_c89_main} + ${ac_c_conftest_c99_main} + return ok; +} +" + +# Test code for whether the C compiler supports C89 (complete). +ac_c_conftest_c89_program="${ac_c_conftest_c89_globals} + +int +main (int argc, char **argv) +{ + int ok = 0; + ${ac_c_conftest_c89_main} + return ok; +} +" + +as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H" +as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H" +as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H" +as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H" +as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H" +as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H" +as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H" +as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H" +as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H" +as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H" +as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H" + +# Auxiliary files required by this configure script. +ac_aux_files="ltmain.sh compile missing install-sh config.guess config.sub" + +# Locations in which to look for auxiliary files. +ac_aux_dir_candidates="${srcdir}/build-aux" + +# Search for a directory containing all of the required auxiliary files, +# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates. +# If we don't find one directory that contains all the files we need, +# we report the set of missing files from the *first* directory in +# $ac_aux_dir_candidates and give up. +ac_missing_aux_files="" +ac_first_candidate=: +printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5 +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false +for as_dir in $ac_aux_dir_candidates +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + as_found=: + + printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5 + ac_aux_dir_found=yes + ac_install_sh= + for ac_aux in $ac_aux_files + do + # As a special case, if "install-sh" is required, that requirement + # can be satisfied by any of "install-sh", "install.sh", or "shtool", + # and $ac_install_sh is set appropriately for whichever one is found. + if test x"$ac_aux" = x"install-sh" + then + if test -f "${as_dir}install-sh"; then + printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5 + ac_install_sh="${as_dir}install-sh -c" + elif test -f "${as_dir}install.sh"; then + printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5 + ac_install_sh="${as_dir}install.sh -c" + elif test -f "${as_dir}shtool"; then + printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5 + ac_install_sh="${as_dir}shtool install -c" + else + ac_aux_dir_found=no + if $ac_first_candidate; then + ac_missing_aux_files="${ac_missing_aux_files} install-sh" + else + break + fi + fi + else + if test -f "${as_dir}${ac_aux}"; then + printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5 + else + ac_aux_dir_found=no + if $ac_first_candidate; then + ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}" + else + break + fi + fi + fi + done + if test "$ac_aux_dir_found" = yes; then + ac_aux_dir="$as_dir" + break + fi + ac_first_candidate=false + + as_found=false +done +IFS=$as_save_IFS +if $as_found +then : + +else case e in #( + e) as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 ;; +esac +fi + + +# These three variables are undocumented and unsupported, +# and are intended to be withdrawn in a future Autoconf release. +# They can cause serious problems if a builder's source tree is in a directory +# whose full name contains unusual characters. +if test -f "${ac_aux_dir}config.guess"; then + ac_config_guess="$SHELL ${ac_aux_dir}config.guess" +fi +if test -f "${ac_aux_dir}config.sub"; then + ac_config_sub="$SHELL ${ac_aux_dir}config.sub" +fi +if test -f "$ac_aux_dir/configure"; then + ac_configure="$SHELL ${ac_aux_dir}configure" +fi + +# Check that the precious variables saved in the cache have kept the same +# value. +ac_cache_corrupted=false +for ac_var in $ac_precious_vars; do + eval ac_old_set=\$ac_cv_env_${ac_var}_set + eval ac_new_set=\$ac_env_${ac_var}_set + eval ac_old_val=\$ac_cv_env_${ac_var}_value + eval ac_new_val=\$ac_env_${ac_var}_value + case $ac_old_set,$ac_new_set in + set,) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&5 +printf "%s\n" "$as_me: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,set) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was not set in the previous run" >&5 +printf "%s\n" "$as_me: error: '$ac_var' was not set in the previous run" >&2;} + ac_cache_corrupted=: ;; + ,);; + *) + if test "x$ac_old_val" != "x$ac_new_val"; then + # differences in whitespace do not lead to failure. + ac_old_val_w=`echo x $ac_old_val` + ac_new_val_w=`echo x $ac_new_val` + if test "$ac_old_val_w" != "$ac_new_val_w"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' has changed since the previous run:" >&5 +printf "%s\n" "$as_me: error: '$ac_var' has changed since the previous run:" >&2;} + ac_cache_corrupted=: + else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&5 +printf "%s\n" "$as_me: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&2;} + eval $ac_var=\$ac_old_val + fi + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: '$ac_old_val'" >&5 +printf "%s\n" "$as_me: former value: '$ac_old_val'" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: '$ac_new_val'" >&5 +printf "%s\n" "$as_me: current value: '$ac_new_val'" >&2;} + fi;; + esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in - *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in @@ -2376,11 +2789,12 @@ $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi done if $ac_cache_corrupted; then - { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} - { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 -$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} - as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 +printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;} + as_fn_error $? "run '${MAKE-make} distclean' and/or 'rm $cache_file' + and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## @@ -2393,57 +2807,34 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -ac_aux_dir= -for ac_dir in build-aux "$srcdir"/build-aux; do - if test -f "$ac_dir/install-sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install-sh -c" - break - elif test -f "$ac_dir/install.sh"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/install.sh -c" - break - elif test -f "$ac_dir/shtool"; then - ac_aux_dir=$ac_dir - ac_install_sh="$ac_aux_dir/shtool install -c" - break - fi -done -if test -z "$ac_aux_dir"; then - as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5 -fi -# These three variables are undocumented and unsupported, -# and are intended to be withdrawn in a future Autoconf release. -# They can cause serious problems if a builder's source tree is in a directory -# whose full name contains unusual characters. -ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. -ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. -ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. -# Make sure we can run config.sub. -$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || - as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 -$as_echo_n "checking build system type... " >&6; } -if ${ac_cv_build+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_build_alias=$build_alias + # Make sure we can run config.sub. +$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 || + as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5 + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 +printf %s "checking build system type... " >&6; } +if test ${ac_cv_build+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_build_alias=$build_alias test "x$ac_build_alias" = x && - ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` + ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 -ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 - +ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` || + as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5 + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 +printf "%s\n" "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; @@ -2462,21 +2853,23 @@ IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 -$as_echo_n "checking host system type... " >&6; } -if ${ac_cv_host+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "x$host_alias" = x; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 +printf %s "checking host system type... " >&6; } +if test ${ac_cv_host+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else - ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || - as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 + ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` || + as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5 fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -$as_echo "$ac_cv_host" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 +printf "%s\n" "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; @@ -2495,9 +2888,51 @@ IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac -am__api_version='1.16' +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 +printf %s "checking target system type... " >&6; } +if test ${ac_cv_target+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test "x$target_alias" = x; then + ac_cv_target=$ac_cv_host +else + ac_cv_target=`$SHELL "${ac_aux_dir}config.sub" $target_alias` || + as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $target_alias failed" "$LINENO" 5 +fi + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 +printf "%s\n" "$ac_cv_target" >&6; } +case $ac_cv_target in +*-*-*) ;; +*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; +esac +target=$ac_cv_target +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_target +shift +target_cpu=$1 +target_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +target_os=$* +IFS=$ac_save_IFS +case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac + + +# The aliases save the names the user supplied, while $host etc. +# will get canonicalized. +test -n "$target_alias" && + test "$program_prefix$program_suffix$program_transform_name" = \ + NONENONEs,x,x, && + program_prefix=${target_alias}- +am__api_version='1.18' -# Find a good install program. We prefer a C program (faster), + + # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install @@ -2511,20 +2946,25 @@ am__api_version='1.16' # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 -$as_echo_n "checking for a BSD-compatible install... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 +printf %s "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then -if ${ac_cv_path_install+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +if test ${ac_cv_path_install+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - # Account for people who put trailing slashes in PATH elements. -case $as_dir/ in #(( - ./ | .// | /[cC]/* | \ + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + # Account for fact that we put trailing slashes in our PATH walk. +case $as_dir in #(( + ./ | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; @@ -2534,13 +2974,13 @@ case $as_dir/ in #(( # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then if test $ac_prog = install && - grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && - grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then + grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else @@ -2548,12 +2988,12 @@ case $as_dir/ in #(( echo one > conftest.one echo two > conftest.two mkdir conftest.dir - if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && + if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then - ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" + ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c" break 3 fi fi @@ -2567,9 +3007,10 @@ esac IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir - + ;; +esac fi - if test "${ac_cv_path_install+set}" = set; then + if test ${ac_cv_path_install+y}; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a @@ -2579,8 +3020,8 @@ fi INSTALL=$ac_install_sh fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 -$as_echo "$INSTALL" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 +printf "%s\n" "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. @@ -2590,18 +3031,181 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 -$as_echo_n "checking whether build environment is sane... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether sleep supports fractional seconds" >&5 +printf %s "checking whether sleep supports fractional seconds... " >&6; } +if test ${am_cv_sleep_fractional_seconds+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if sleep 0.001 2>/dev/null +then : + am_cv_sleep_fractional_seconds=yes +else case e in #( + e) am_cv_sleep_fractional_seconds=no ;; +esac +fi + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_sleep_fractional_seconds" >&5 +printf "%s\n" "$am_cv_sleep_fractional_seconds" >&6; } + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking filesystem timestamp resolution" >&5 +printf %s "checking filesystem timestamp resolution... " >&6; } +if test ${am_cv_filesystem_timestamp_resolution+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # Default to the worst case. +am_cv_filesystem_timestamp_resolution=2 + +# Only try to go finer than 1 sec if sleep can do it. +# Don't try 1 sec, because if 0.01 sec and 0.1 sec don't work, +# - 1 sec is not much of a win compared to 2 sec, and +# - it takes 2 seconds to perform the test whether 1 sec works. +# +# Instead, just use the default 2s on platforms that have 1s resolution, +# accept the extra 1s delay when using $sleep in the Automake tests, in +# exchange for not incurring the 2s delay for running the test for all +# packages. +# +am_try_resolutions= +if test "$am_cv_sleep_fractional_seconds" = yes; then + # Even a millisecond often causes a bunch of false positives, + # so just try a hundredth of a second. The time saved between .001 and + # .01 is not terribly consequential. + am_try_resolutions="0.01 0.1 $am_try_resolutions" +fi + +# In order to catch current-generation FAT out, we must *modify* files +# that already exist; the *creation* timestamp is finer. Use names +# that make ls -t sort them differently when they have equal +# timestamps than when they have distinct timestamps, keeping +# in mind that ls -t prints the *newest* file first. +rm -f conftest.ts? +: > conftest.ts1 +: > conftest.ts2 +: > conftest.ts3 + +# Make sure ls -t actually works. Do 'set' in a subshell so we don't +# clobber the current shell's arguments. (Outer-level square brackets +# are removed by m4; they're present so that m4 does not expand +# <dollar><star>; be careful, easy to get confused.) +if ( + set X `ls -t conftest.ts[12]` && + { + test "$*" != "X conftest.ts1 conftest.ts2" || + test "$*" != "X conftest.ts2 conftest.ts1"; + } +); then :; else + # If neither matched, then we have a broken ls. This can happen + # if, for instance, CONFIG_SHELL is bash and it inherits a + # broken ls alias from the environment. This has actually + # happened. Such a system could not be considered "sane". + printf "%s\n" ""Bad output from ls -t: \"`ls -t conftest.ts[12]`\""" >&5 + { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} +as_fn_error $? "ls -t produces unexpected output. +Make sure there is not a broken ls alias in your environment. +See 'config.log' for more details" "$LINENO" 5; } +fi + +for am_try_res in $am_try_resolutions; do + # Any one fine-grained sleep might happen to cross the boundary + # between two values of a coarser actual resolution, but if we do + # two fine-grained sleeps in a row, at least one of them will fall + # entirely within a coarse interval. + echo alpha > conftest.ts1 + sleep $am_try_res + echo beta > conftest.ts2 + sleep $am_try_res + echo gamma > conftest.ts3 + + # We assume that 'ls -t' will make use of high-resolution + # timestamps if the operating system supports them at all. + if (set X `ls -t conftest.ts?` && + test "$2" = conftest.ts3 && + test "$3" = conftest.ts2 && + test "$4" = conftest.ts1); then + # + # Ok, ls -t worked. If we're at a resolution of 1 second, we're done, + # because we don't need to test make. + make_ok=true + if test $am_try_res != 1; then + # But if we've succeeded so far with a subsecond resolution, we + # have one more thing to check: make. It can happen that + # everything else supports the subsecond mtimes, but make doesn't; + # notably on macOS, which ships make 3.81 from 2006 (the last one + # released under GPLv2). https://bugs.gnu.org/68808 + # + # We test $MAKE if it is defined in the environment, else "make". + # It might get overridden later, but our hope is that in practice + # it does not matter: it is the system "make" which is (by far) + # the most likely to be broken, whereas if the user overrides it, + # probably they did so with a better, or at least not worse, make. + # https://lists.gnu.org/archive/html/automake/2024-06/msg00051.html + # + # Create a Makefile (real tab character here): + rm -f conftest.mk + echo 'conftest.ts1: conftest.ts2' >conftest.mk + echo ' touch conftest.ts2' >>conftest.mk + # + # Now, running + # touch conftest.ts1; touch conftest.ts2; make + # should touch ts1 because ts2 is newer. This could happen by luck, + # but most often, it will fail if make's support is insufficient. So + # test for several consecutive successes. + # + # (We reuse conftest.ts[12] because we still want to modify existing + # files, not create new ones, per above.) + n=0 + make=${MAKE-make} + until test $n -eq 3; do + echo one > conftest.ts1 + sleep $am_try_res + echo two > conftest.ts2 # ts2 should now be newer than ts1 + if $make -f conftest.mk | grep 'up to date' >/dev/null; then + make_ok=false + break # out of $n loop + fi + n=`expr $n + 1` + done + fi + # + if $make_ok; then + # Everything we know to check worked out, so call this resolution good. + am_cv_filesystem_timestamp_resolution=$am_try_res + break # out of $am_try_res loop + fi + # Otherwise, we'll go on to check the next resolution. + fi +done +rm -f conftest.ts? +# (end _am_filesystem_timestamp_resolution) + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_filesystem_timestamp_resolution" >&5 +printf "%s\n" "$am_cv_filesystem_timestamp_resolution" >&6; } + +# This check should not be cached, as it may vary across builds of +# different projects. +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 +printf %s "checking whether build environment is sane... " >&6; } # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac @@ -2610,49 +3214,45 @@ esac # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). -if ( - am_has_slept=no - for am_try in 1 2; do - echo "timestamp, slept: $am_has_slept" > conftest.file - set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` - if test "$*" = "X"; then - # -L didn't work. - set X `ls -t "$srcdir/configure" conftest.file` - fi - if test "$*" != "X $srcdir/configure conftest.file" \ - && test "$*" != "X conftest.file $srcdir/configure"; then - - # If neither matched, then we have a broken ls. This can happen - # if, for instance, CONFIG_SHELL is bash and it inherits a - # broken ls alias from the environment. This has actually - # happened. Such a system could not be considered "sane". - as_fn_error $? "ls -t appears to fail. Make sure there is not a broken - alias in your environment" "$LINENO" 5 - fi - if test "$2" = conftest.file || test $am_try -eq 2; then - break - fi - # Just in case. - sleep 1 - am_has_slept=yes - done - test "$2" = conftest.file - ) -then - # Ok. - : -else - as_fn_error $? "newly created file is older than distributed files! +am_build_env_is_sane=no +am_has_slept=no +rm -f conftest.file +for am_try in 1 2; do + echo "timestamp, slept: $am_has_slept" > conftest.file + if ( + set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` + if test "$*" = "X"; then + # -L didn't work. + set X `ls -t "$srcdir/configure" conftest.file` + fi + test "$2" = conftest.file + ); then + am_build_env_is_sane=yes + break + fi + # Just in case. + sleep "$am_cv_filesystem_timestamp_resolution" + am_has_slept=yes +done + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_build_env_is_sane" >&5 +printf "%s\n" "$am_build_env_is_sane" >&6; } +if test "$am_build_env_is_sane" = no; then + as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= -if grep 'slept: no' conftest.file >/dev/null 2>&1; then - ( sleep 1 ) & +if test -e conftest.file || grep 'slept: no' conftest.file >/dev/null 2>&1 +then : + +else case e in #( + e) ( sleep "$am_cv_filesystem_timestamp_resolution" ) & am_sleep_pid=$! + ;; +esac fi rm -f conftest.file @@ -2663,28 +3263,25 @@ test "$program_prefix" != NONE && test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. -# By default was `s,x,x', remove it if useless. +# By default was 's,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' -program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` +program_transform_name=`printf "%s\n" "$program_transform_name" | sed "$ac_script"` + # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` -if test x"${MISSING+set}" != xset; then - case $am_aux_dir in - *\ * | *\ *) - MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; - *) - MISSING="\${SHELL} $am_aux_dir/missing" ;; - esac + + if test x"${MISSING+set}" != xset; then + MISSING="\${SHELL} '$am_aux_dir/missing'" fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 -$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 +printf "%s\n" "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi if test x"${install_sh+set}" != xset; then @@ -2704,38 +3301,44 @@ if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_STRIP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +printf "%s\n" "$STRIP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -2744,38 +3347,44 @@ if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_STRIP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +printf "%s\n" "$ac_ct_STRIP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then @@ -2783,8 +3392,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP @@ -2796,98 +3405,110 @@ fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 -$as_echo_n "checking for a thread-safe mkdir -p... " >&6; } + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5 +printf %s "checking for a race-free mkdir -p... " >&6; } if test -z "$MKDIR_P"; then - if ${ac_cv_path_mkdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR + if test ${ac_cv_path_mkdir+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do - as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue - case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( - 'mkdir (GNU coreutils) '* | \ - 'mkdir (coreutils) '* | \ + as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue + case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #( + 'mkdir ('*'coreutils) '* | \ + *'BusyBox '* | \ 'mkdir (fileutils) '4.1*) - ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext + ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS - + ;; +esac fi test -d ./--version && rmdir ./--version - if test "${ac_cv_path_mkdir+set}" = set; then + if test ${ac_cv_path_mkdir+y}; then MKDIR_P="$ac_cv_path_mkdir -p" else - # As a last resort, use the slow shell script. Don't cache a - # value for MKDIR_P within a source directory, because that will - # break other packages using the cache if that directory is - # removed, or if the value is a relative name. - MKDIR_P="$ac_install_sh -d" + # As a last resort, use plain mkdir -p, + # in the hope it doesn't have the bugs of ancient mkdir. + MKDIR_P='mkdir -p' fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 +printf "%s\n" "$MKDIR_P" >&6; } for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AWK+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AWK"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_AWK+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 -$as_echo "$AWK" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +printf "%s\n" "$AWK" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi test -n "$AWK" && break done -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 -$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} -ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` -if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat >conftest.make <<\_ACEOF +ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` +if eval test \${ac_cv_prog_make_${ac_make}_set+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' @@ -2899,15 +3520,16 @@ case `${MAKE-make} -f conftest.make 2>/dev/null` in *) eval ac_cv_prog_make_${ac_make}_set=no;; esac -rm -f conftest.make +rm -f conftest.make ;; +esac fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } SET_MAKE= else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi @@ -2920,23 +3542,21 @@ else fi rmdir .tst 2>/dev/null +AM_DEFAULT_VERBOSITY=1 # Check whether --enable-silent-rules was given. -if test "${enable_silent_rules+set}" = set; then : +if test ${enable_silent_rules+y} +then : enableval=$enable_silent_rules; fi -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=1;; -esac am_make=${MAKE-make} -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -$as_echo_n "checking whether $am_make supports nested variables... " >&6; } -if ${am_cv_make_support_nested_variables+:} false; then : - $as_echo_n "(cached) " >&6 -else - if $as_echo 'TRUE=$(BAR$(V)) +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 +printf %s "checking whether $am_make supports nested variables... " >&6; } +if test ${am_cv_make_support_nested_variables+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if printf "%s\n" 'TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 @@ -2946,18 +3566,49 @@ am__doit: am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no +fi ;; +esac fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 +printf "%s\n" "$am_cv_make_support_nested_variables" >&6; } +AM_BACKSLASH='\' + +am__rm_f_notfound= +if (rm -f && rm -fr && rm -rf) 2>/dev/null +then : + +else case e in #( + e) am__rm_f_notfound='""' ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -$as_echo "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking xargs -n works" >&5 +printf %s "checking xargs -n works... " >&6; } +if test ${am_cv_xargs_n_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test "`echo 1 2 3 | xargs -n2 echo`" = "1 2 +3" +then : + am_cv_xargs_n_works=yes +else case e in #( + e) am_cv_xargs_n_works=no ;; +esac +fi ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_xargs_n_works" >&5 +printf "%s\n" "$am_cv_xargs_n_works" >&6; } +if test "$am_cv_xargs_n_works" = yes +then : + am__xargs_n='xargs -n' +else case e in #( + e) am__xargs_n='am__xargs_n () { shift; sed "s/ /\\n/g" | while read am__xargs_n_arg; do "" "$am__xargs_n_arg"; done; }' + ;; +esac fi -AM_BACKSLASH='\' if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output @@ -2981,17 +3632,13 @@ fi # Define the identity of the package. PACKAGE='libsodium' - VERSION='1.0.18' + VERSION='1.0.20' -cat >>confdefs.h <<_ACEOF -#define PACKAGE "$PACKAGE" -_ACEOF +printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define VERSION "$VERSION" -_ACEOF +printf "%s\n" "#define VERSION \"$VERSION\"" >>confdefs.h # Some tools Automake needs. @@ -3037,29 +3684,35 @@ _am_tools='gnutar plaintar pax cpio none' # (that is, avoid stderr redirection). am_uid=`id -u || echo unknown` am_gid=`id -g || echo unknown` - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UID '$am_uid' is supported by ustar format" >&5 -$as_echo_n "checking whether UID '$am_uid' is supported by ustar format... " >&6; } - if test $am_uid -le $am_max_uid; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether UID '$am_uid' is supported by ustar format" >&5 +printf %s "checking whether UID '$am_uid' is supported by ustar format... " >&6; } + if test x$am_uid = xunknown; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ancient id detected; assuming current UID is ok, but dist-ustar might not work" >&5 +printf "%s\n" "$as_me: WARNING: ancient id detected; assuming current UID is ok, but dist-ustar might not work" >&2;} + elif test $am_uid -le $am_max_uid; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - _am_tools=none + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + _am_tools=none fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GID '$am_gid' is supported by ustar format" >&5 -$as_echo_n "checking whether GID '$am_gid' is supported by ustar format... " >&6; } - if test $am_gid -le $am_max_gid; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether GID '$am_gid' is supported by ustar format" >&5 +printf %s "checking whether GID '$am_gid' is supported by ustar format... " >&6; } + if test x$gm_gid = xunknown; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ancient id detected; assuming current GID is ok, but dist-ustar might not work" >&5 +printf "%s\n" "$as_me: WARNING: ancient id detected; assuming current GID is ok, but dist-ustar might not work" >&2;} + elif test $am_gid -le $am_max_gid; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } _am_tools=none fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to create a ustar tar archive" >&5 -$as_echo_n "checking how to create a ustar tar archive... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to create a ustar tar archive" >&5 +printf %s "checking how to create a ustar tar archive... " >&6; } # Go ahead even if we have the value already cached. We do so because we # need to set the values for the 'am__tar' and 'am__untar' variables. @@ -3134,113 +3787,58 @@ $as_echo_n "checking how to create a ustar tar archive... " >&6; } done rm -rf conftest.dir - if ${am_cv_prog_tar_ustar+:} false; then : - $as_echo_n "(cached) " >&6 -else - am_cv_prog_tar_ustar=$_am_tool + if test ${am_cv_prog_tar_ustar+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) am_cv_prog_tar_ustar=$_am_tool ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_tar_ustar" >&5 -$as_echo "$am_cv_prog_tar_ustar" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_tar_ustar" >&5 +printf "%s\n" "$am_cv_prog_tar_ustar" >&6; } +# Variables for tags utilities; see am/tags.am +if test -z "$CTAGS"; then + CTAGS=ctags +fi -# POSIX will say in a future version that running "rm -f" with no argument -# is OK; and we want to be able to make that assumption in our Makefile -# recipes. So use an aggressive probe to check that the usage we want is -# actually supported "in the wild" to an acceptable degree. -# See automake bug#10828. -# To make any issue more visible, cause the running configure to be aborted -# by default if the 'rm' program in use doesn't match our expectations; the -# user can still override this though. -if rm -f && rm -fr && rm -rf; then : OK; else - cat >&2 <<'END' -Oops! +if test -z "$ETAGS"; then + ETAGS=etags +fi -Your 'rm' program seems unable to run without file operands specified -on the command line, even when the '-f' option is present. This is contrary -to the behaviour of most rm programs out there, and not conforming with -the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> +if test -z "$CSCOPE"; then + CSCOPE=cscope +fi -Please tell bug-automake@gnu.org about your system, including the value -of your $PATH and any error possibly output before this message. This -can help us improve future automake versions. -END - if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then - echo 'Configuration will proceed anyway, since you have set the' >&2 - echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 - echo >&2 - else - cat >&2 <<'END' -Aborting the configuration process, to ensure you take notice of the issue. -You can download and install GNU coreutils to get an 'rm' implementation -that behaves properly: <https://www.gnu.org/software/coreutils/>. -If you want to complete the configuration process using your problematic -'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM -to "yes", and re-run configure. -END - as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 - fi -fi -# Check whether --enable-silent-rules was given. -if test "${enable_silent_rules+set}" = set; then : - enableval=$enable_silent_rules; -fi -case $enable_silent_rules in # ((( - yes) AM_DEFAULT_VERBOSITY=0;; - no) AM_DEFAULT_VERBOSITY=1;; - *) AM_DEFAULT_VERBOSITY=0;; -esac -am_make=${MAKE-make} -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 -$as_echo_n "checking whether $am_make supports nested variables... " >&6; } -if ${am_cv_make_support_nested_variables+:} false; then : - $as_echo_n "(cached) " >&6 -else - if $as_echo 'TRUE=$(BAR$(V)) -BAR0=false -BAR1=true -V=1 -am__doit: - @$(TRUE) -.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then - am_cv_make_support_nested_variables=yes -else - am_cv_make_support_nested_variables=no -fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 -$as_echo "$am_cv_make_support_nested_variables" >&6; } -if test $am_cv_make_support_nested_variables = yes; then - AM_V='$(V)' - AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' -else - AM_V=$AM_DEFAULT_VERBOSITY - AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY -fi -AM_BACKSLASH='\' + +AM_DEFAULT_VERBOSITY=0 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 -$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 +printf %s "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } # Check whether --enable-maintainer-mode was given. -if test "${enable_maintainer_mode+set}" = set; then : +if test ${enable_maintainer_mode+y} +then : enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval -else - USE_MAINTAINER_MODE=no +else case e in #( + e) USE_MAINTAINER_MODE=no ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 -$as_echo "$USE_MAINTAINER_MODE" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 +printf "%s\n" "$USE_MAINTAINER_MODE" >&6; } if test $USE_MAINTAINER_MODE = yes; then MAINTAINER_MODE_TRUE= MAINTAINER_MODE_FALSE='#' @@ -3253,7 +3851,8 @@ fi # Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then : +if test ${enable_dependency_tracking+y} +then : enableval=$enable_dependency_tracking; fi @@ -3274,10 +3873,10 @@ fi -SODIUM_LIBRARY_VERSION_MAJOR=10 -SODIUM_LIBRARY_VERSION_MINOR=3 -DLL_VERSION=24 -SODIUM_LIBRARY_VERSION=26:0:3 +SODIUM_LIBRARY_VERSION_MAJOR=26 +SODIUM_LIBRARY_VERSION_MINOR=2 +DLL_VERSION=26 +SODIUM_LIBRARY_VERSION=28:0:2 # | | | # +------+ | +---+ # | | | @@ -3299,95 +3898,23 @@ LX_CFLAGS=${CFLAGS-NONE} PKGCONFIG_LIBS_PRIVATE="" -if pwd | fgrep ' ' > /dev/null 2>&1; then : +if pwd | fgrep ' ' > /dev/null 2>&1 +then : as_fn_error $? "The build directory contains whitespaces - This can cause tests/installation to fail due to limitations of some libtool versions" "$LINENO" 5 fi +sodium_CFLAGS=${CFLAGS+set} +: ${CFLAGS=""} -# Check whether --enable-ssp was given. -if test "${enable_ssp+set}" = set; then : - enableval=$enable_ssp; - if test "x$enableval" = "xno"; then : - - enable_ssp="no" - -else - - enable_ssp="yes" - -fi - -else - - enable_ssp="yes" - -fi - - -# Check whether --enable-asm was given. -if test "${enable_asm+set}" = set; then : - enableval=$enable_asm; - if test "x$enableval" = "xno"; then : - - enable_asm="no" - -else - - enable_asm="yes" -fi -else - enable_asm="yes" -fi -DEPDIR="${am__leading_dot}deps" -ac_config_commands="$ac_config_commands depfiles" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 -$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; } -cat > confinc.mk << 'END' -am__doit: - @echo this is the am__doit target >confinc.out -.PHONY: am__doit -END -am__include="#" -am__quote= -# BSD make does it like this. -echo '.include "confinc.mk" # ignored' > confmf.BSD -# Other make implementations (GNU, Solaris 10, AIX) do it like this. -echo 'include confinc.mk # ignored' > confmf.GNU -_am_result=no -for s in GNU BSD; do - { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 - (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 - ac_status=$? - echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } - case $?:`cat confinc.out 2>/dev/null` in #( - '0:this is the am__doit target') : - case $s in #( - BSD) : - am__include='.include' am__quote='"' ;; #( - *) : - am__include='include' am__quote='' ;; -esac ;; #( - *) : - ;; -esac - if test "$am__include" != "#"; then - _am_result="yes ($s style)" - break - fi -done -rm -f confinc.* confmf.* -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 -$as_echo "${_am_result}" >&6; } ac_ext=c ac_cpp='$CPP $CPPFLAGS' @@ -3397,38 +3924,44 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +printf "%s\n" "$CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -3437,38 +3970,44 @@ if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +printf "%s\n" "$ac_ct_CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_CC" = x; then @@ -3476,8 +4015,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC @@ -3490,38 +4029,44 @@ if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +printf "%s\n" "$CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -3530,12 +4075,13 @@ fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no @@ -3543,15 +4089,19 @@ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -3567,18 +4117,19 @@ if test $ac_prog_rejected = yes; then # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift - ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" + ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@" fi fi -fi +fi ;; +esac fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +printf "%s\n" "$CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -3589,38 +4140,44 @@ if test -z "$CC"; then do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 -$as_echo "$CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +printf "%s\n" "$CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -3633,38 +4190,44 @@ if test -z "$CC"; then do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 -$as_echo "$ac_ct_CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +printf "%s\n" "$ac_ct_CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -3676,34 +4239,140 @@ done else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + CC=$ac_ct_CC + fi +fi + +fi +if test -z "$CC"; then + if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args. +set dummy ${ac_tool_prefix}clang; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CC"; then + ac_cv_prog_CC="$CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_CC="${ac_tool_prefix}clang" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi ;; +esac +fi +CC=$ac_cv_prog_CC +if test -n "$CC"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 +printf "%s\n" "$CC" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + +fi +if test -z "$ac_cv_prog_CC"; then + ac_ct_CC=$CC + # Extract the first word of "clang", so it can be a program name with args. +set dummy clang; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_CC"; then + ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_CC="clang" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi ;; +esac +fi +ac_ct_CC=$ac_cv_prog_ac_ct_CC +if test -n "$ac_ct_CC"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 +printf "%s\n" "$ac_ct_CC" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + if test "x$ac_ct_CC" = x; then + CC="" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi +else + CC="$ac_cv_prog_CC" fi fi -test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. -$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 +printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 -for ac_option in --version -v -V -qversion; do +for ac_option in --version -v -V -qversion -version; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then @@ -3713,7 +4382,7 @@ $as_echo "$ac_try_echo"; } >&5 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done @@ -3721,7 +4390,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; @@ -3733,9 +4402,9 @@ ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 -$as_echo_n "checking whether the C compiler works... " >&6; } -ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 +printf %s "checking whether the C compiler works... " >&6; } +ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" @@ -3756,13 +4425,14 @@ case "(($ac_try" in *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. -# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +then : + # Autoconf-2.13 could set the ac_cv_exeext variable to 'no'. +# So ignore a value of 'no', otherwise this would lead to 'EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. @@ -3777,12 +4447,12 @@ do # certainly right. break;; *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not - # safe: cross compilers may not add the suffix if given an `-o' + # safe: cross compilers may not add the suffix if given an '-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. @@ -3793,48 +4463,52 @@ do done test "$ac_cv_exeext" = no && ac_cv_exeext= -else - ac_file='' +else case e in #( + e) ac_file='' ;; +esac fi -if test -z "$ac_file"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -$as_echo "$as_me: failed program was:" >&5 +if test -z "$ac_file" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables -See \`config.log' for more details" "$LINENO" 5; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +See 'config.log' for more details" "$LINENO" 5; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 -$as_echo_n "checking for C compiler default output file name... " >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 -$as_echo "$ac_file" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 +printf %s "checking for C compiler default output file name... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +printf "%s\n" "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 -$as_echo_n "checking for suffix of executables... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 +printf %s "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : - # If both `conftest.exe' and `conftest' are `present' (well, observable) -# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will -# work properly (i.e., refer to `conftest.exe'), while it won't with -# `rm'. + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +then : + # If both 'conftest.exe' and 'conftest' are 'present' (well, observable) +# catch 'conftest.exe'. For instance with Cygwin, 'ls conftest' will +# work properly (i.e., refer to 'conftest.exe'), while it won't with +# 'rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in @@ -3844,15 +4518,16 @@ for ac_file in conftest.exe conftest conftest.*; do * ) break;; esac done -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +else case e in #( + e) { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } ;; +esac fi rm -f conftest conftest$ac_cv_exeext -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 -$as_echo "$ac_cv_exeext" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 +printf "%s\n" "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext @@ -3861,9 +4536,11 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdio.h> int -main () +main (void) { FILE *f = fopen ("conftest.out", "w"); + if (!f) + return 1; return ferror (f) || fclose (f) != 0; ; @@ -3873,8 +4550,8 @@ _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 -$as_echo_n "checking whether we are cross compiling... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +printf %s "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in @@ -3882,10 +4559,10 @@ case "(($ac_try" in *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in @@ -3893,39 +4570,41 @@ $as_echo "$ac_try_echo"; } >&5 *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "cannot run C compiled programs. -If you meant to cross compile, use \`--host'. -See \`config.log' for more details" "$LINENO" 5; } + { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} +as_fn_error 77 "cannot run C compiled programs. +If you meant to cross compile, use '--host'. +See 'config.log' for more details" "$LINENO" 5; } fi fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +printf "%s\n" "$cross_compiling" >&6; } -rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +rm -f conftest.$ac_ext conftest$ac_cv_exeext \ + conftest.o conftest.obj conftest.out ac_clean_files=$ac_clean_files_save -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 -$as_echo_n "checking for suffix of object files... " >&6; } -if ${ac_cv_objext+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 +printf %s "checking for suffix of object files... " >&6; } +if test ${ac_cv_objext+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; @@ -3939,11 +4618,12 @@ case "(($ac_try" in *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 +printf "%s\n" "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then : + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in @@ -3952,31 +4632,34 @@ $as_echo "$ac_try_echo"; } >&5 break;; esac done -else - $as_echo "$as_me: failed program was:" >&5 +else case e in #( + e) printf "%s\n" "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 -{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } ;; +esac fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext +rm -f conftest.$ac_cv_objext conftest.$ac_ext ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$ac_cv_objext" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 +printf "%s\n" "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 -$as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if ${ac_cv_c_compiler_gnu+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 +printf %s "checking whether the compiler supports GNU C... " >&6; } +if test ${ac_cv_c_compiler_gnu+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { #ifndef __GNUC__ choke me @@ -3986,30 +4669,36 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_compiler_gnu=yes -else - ac_compiler_gnu=no +else case e in #( + e) ac_compiler_gnu=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 -$as_echo "$ac_cv_c_compiler_gnu" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 +printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } +ac_compiler_gnu=$ac_cv_c_compiler_gnu + if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi -ac_test_CFLAGS=${CFLAGS+set} +ac_test_CFLAGS=${CFLAGS+y} ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 -$as_echo_n "checking whether $CC accepts -g... " >&6; } -if ${ac_cv_prog_cc_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_c_werror_flag=$ac_c_werror_flag +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 +printf %s "checking whether $CC accepts -g... " >&6; } +if test ${ac_cv_prog_cc_g+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" @@ -4017,57 +4706,63 @@ else /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_prog_cc_g=yes -else - CFLAGS="" +else case e in #( + e) CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : -else - ac_c_werror_flag=$ac_save_c_werror_flag +else case e in #( + e) ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_prog_cc_g=yes fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ac_c_werror_flag=$ac_save_c_werror_flag +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 -$as_echo "$ac_cv_prog_cc_g" >&6; } -if test "$ac_test_CFLAGS" = set; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 +printf "%s\n" "$ac_cv_prog_cc_g" >&6; } +if test $ac_test_CFLAGS; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then @@ -4082,94 +4777,153 @@ else CFLAGS= fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 -$as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if ${ac_cv_prog_cc_c89+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c89=no +ac_prog_cc_stdc=no +if test x$ac_prog_cc_stdc = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 +printf %s "checking for $CC option to enable C11 features... " >&6; } +if test ${ac_cv_prog_cc_c11+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_prog_cc_c11=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <stdarg.h> -#include <stdio.h> -struct stat; -/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ -struct buf { int x; }; -FILE * (*rcsopen) (struct buf *, struct stat *, int); -static char *e (p, i) - char **p; - int i; -{ - return p[i]; -} -static char *f (char * (*g) (char **, int), char **p, ...) -{ - char *s; - va_list v; - va_start (v,p); - s = g (p, va_arg (v,int)); - va_end (v); - return s; -} - -/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has - function prototypes and stuff, but not '\xHH' hex character constants. - These don't provoke an error unfortunately, instead are silently treated - as 'x'. The following induces an error, until -std is added to get - proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an - array size at least. It's necessary to write '\x00'==0 to get something - that's true only with -std. */ -int osf4_cc_array ['\x00' == 0 ? 1 : -1]; +$ac_c_conftest_c11_program +_ACEOF +for ac_arg in '' -std=gnu11 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_c11=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam + test "x$ac_cv_prog_cc_c11" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC ;; +esac +fi -/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters - inside strings and character constants. */ -#define FOO(x) 'x' -int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; +if test "x$ac_cv_prog_cc_c11" = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } +else case e in #( + e) if test "x$ac_cv_prog_cc_c11" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 +printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } + CC="$CC $ac_cv_prog_cc_c11" ;; +esac +fi + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 + ac_prog_cc_stdc=c11 ;; +esac +fi +fi +if test x$ac_prog_cc_stdc = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 +printf %s "checking for $CC option to enable C99 features... " >&6; } +if test ${ac_cv_prog_cc_c99+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_prog_cc_c99=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_c_conftest_c99_program +_ACEOF +for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_c99=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam + test "x$ac_cv_prog_cc_c99" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC ;; +esac +fi -int test (int i, double x); -struct s1 {int (*f) (int a);}; -struct s2 {int (*f) (double a);}; -int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); -int argc; -char **argv; -int -main () -{ -return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; - ; - return 0; -} +if test "x$ac_cv_prog_cc_c99" = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } +else case e in #( + e) if test "x$ac_cv_prog_cc_c99" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 +printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } + CC="$CC $ac_cv_prog_cc_c99" ;; +esac +fi + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 + ac_prog_cc_stdc=c99 ;; +esac +fi +fi +if test x$ac_prog_cc_stdc = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 +printf %s "checking for $CC option to enable C89 features... " >&6; } +if test ${ac_cv_prog_cc_c89+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_prog_cc_c89=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_c_conftest_c89_program _ACEOF -for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ - -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" +for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : + if ac_fn_c_try_compile "$LINENO" +then : ac_cv_prog_cc_c89=$ac_arg fi -rm -f core conftest.err conftest.$ac_objext +rm -f core conftest.err conftest.$ac_objext conftest.beam test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext -CC=$ac_save_CC +CC=$ac_save_CC ;; +esac +fi +if test "x$ac_cv_prog_cc_c89" = xno +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 +printf "%s\n" "unsupported" >&6; } +else case e in #( + e) if test "x$ac_cv_prog_cc_c89" = x +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 +printf "%s\n" "none needed" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 +printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } + CC="$CC $ac_cv_prog_cc_c89" ;; +esac fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c89" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c89" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 -$as_echo "$ac_cv_prog_cc_c89" >&6; } ;; + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 + ac_prog_cc_stdc=c89 ;; esac -if test "x$ac_cv_prog_cc_c89" != xno; then : - +fi fi ac_ext=c @@ -4178,21 +4932,23 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -ac_ext=c + + ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 -$as_echo_n "checking whether $CC understands -c and -o together... " >&6; } -if ${am_cv_prog_cc_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 +printf %s "checking whether $CC understands -c and -o together... " >&6; } +if test ${am_cv_prog_cc_c_o+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; @@ -4217,11 +4973,15 @@ _ACEOF break fi done - rm -f core conftest* - unset am_i + # aligned with autoconf, so not including core; see bug#72225. + rm -f -r a.out a.exe b.out conftest.$ac_ext conftest.$ac_objext \ + conftest.dSYM conftest1.$ac_ext conftest1.$ac_objext conftest1.dSYM \ + conftest2.$ac_ext conftest2.$ac_objext conftest2.dSYM + unset am_i ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 -$as_echo "$am_cv_prog_cc_c_o" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 +printf "%s\n" "$am_cv_prog_cc_c_o" >&6; } if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. @@ -4236,15 +4996,60 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu +DEPDIR="${am__leading_dot}deps" + +ac_config_commands="$ac_config_commands depfiles" + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 +printf %s "checking whether ${MAKE-make} supports the include directive... " >&6; } +cat > confinc.mk << 'END' +am__doit: + @echo this is the am__doit target >confinc.out +.PHONY: am__doit +END +am__include="#" +am__quote= +# BSD make does it like this. +echo '.include "confinc.mk" # ignored' > confmf.BSD +# Other make implementations (GNU, Solaris 10, AIX) do it like this. +echo 'include confinc.mk # ignored' > confmf.GNU +_am_result=no +for s in GNU BSD; do + { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 + (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } + case $?:`cat confinc.out 2>/dev/null` in #( + '0:this is the am__doit target') : + case $s in #( + BSD) : + am__include='.include' am__quote='"' ;; #( + *) : + am__include='include' am__quote='' ;; +esac ;; #( + *) : + ;; +esac + if test "$am__include" != "#"; then + _am_result="yes ($s style)" + break + fi +done +rm -f confinc.* confmf.* +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 +printf "%s\n" "${_am_result}" >&6; } + depcc="$CC" am_compiler_list= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CC_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +printf %s "checking dependency style of $depcc... " >&6; } +if test ${am_cv_CC_dependencies_compiler_type+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up @@ -4331,7 +5136,7 @@ else # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: + # When given -MP, icc 7.0 and 7.1 complain thus: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported @@ -4348,10 +5153,11 @@ else else am_cv_CC_dependencies_compiler_type=none fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 +printf "%s\n" "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if @@ -4365,373 +5171,732 @@ else fi +# By default we simply use the C compiler to build assembly code. -if test "x$EMSCRIPTEN" != "x"; then : +test "${CCAS+set}" = set || CCAS=$CC +test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -s ASSERTIONS=0" >&5 -$as_echo_n "checking whether C compiler accepts -s ASSERTIONS=0... " >&6; } -if ${ax_cv_check_cflags___s_ASSERTIONS_0+:} false; then : - $as_echo_n "(cached) " >&6 -else - ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -s ASSERTIONS=0" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <time.h> -int -main () -{ -time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___s_ASSERTIONS_0=yes -else - ax_cv_check_cflags___s_ASSERTIONS_0=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___s_ASSERTIONS_0" >&5 -$as_echo "$ax_cv_check_cflags___s_ASSERTIONS_0" >&6; } -if test "x$ax_cv_check_cflags___s_ASSERTIONS_0" = xyes; then : - enable_asm="no" - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiling to JavaScript - asm implementations disabled" >&5 -$as_echo "$as_me: WARNING: compiling to JavaScript - asm implementations disabled" >&2;} +depcc="$CCAS" am_compiler_list= -else +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 +printf %s "checking dependency style of $depcc... " >&6; } +if test ${am_cv_CCAS_dependencies_compiler_type+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then + # We make a subdir and do the tests there. Otherwise we can end up + # making bogus files that we don't know about and never remove. For + # instance it was reported that on HP-UX the gcc test will end up + # making a dummy file named 'D' -- because '-MD' means "put the output + # in D". + rm -rf conftest.dir + mkdir conftest.dir + # Copy depcomp to subdir because otherwise we won't find it if we're + # using a relative directory. + cp "$am_depcomp" conftest.dir + cd conftest.dir + # We will build objects and dependencies in a subdirectory because + # it helps to detect inapplicable dependency modes. For instance + # both Tru64's cc and ICC support -MD to output dependencies as a + # side effect of compilation, but ICC will put the dependencies in + # the current directory while Tru64 will put them in the object + # directory. + mkdir sub - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: EMSCRIPTEN environment variable defined, but emcc doesn't appear to be used - Assuming compilation to native code" >&5 -$as_echo "$as_me: WARNING: EMSCRIPTEN environment variable defined, but emcc doesn't appear to be used - Assuming compilation to native code" >&2;} - CFLAGS="$CFLAGS -U__EMSCRIPTEN__" - unset EMSCRIPTEN + am_cv_CCAS_dependencies_compiler_type=none + if test "$am_compiler_list" = ""; then + am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` + fi + am__universal=false -fi + for depmode in $am_compiler_list; do + # Setup a source with many dependencies, because some compilers + # like to wrap large dependency lists on column 80 (with \), and + # we should not choose a depcomp mode which is confused by this. + # + # We need to recreate these files for each test, as the compiler may + # overwrite some of them when testing with obscure command lines. + # This happens at least with the AIX C compiler. + : > sub/conftest.c + for i in 1 2 3 4 5 6; do + echo '#include "conftst'$i'.h"' >> sub/conftest.c + # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with + # Solaris 10 /bin/sh. + echo '/* dummy */' > sub/conftst$i.h + done + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf + + # We check with '-c' and '-o' for the sake of the "dashmstdout" + # mode. It turns out that the SunPro C++ compiler does not properly + # handle '-M -o', and we need to detect this. Also, some Intel + # versions had trouble with output in subdirs. + am__obj=sub/conftest.${OBJEXT-o} + am__minus_obj="-o $am__obj" + case $depmode in + gcc) + # This depmode causes a compiler race in universal mode. + test "$am__universal" = false || continue + ;; + nosideeffect) + # After this tag, mechanisms are not by side-effect, so they'll + # only be used when explicitly requested. + if test "x$enable_dependency_tracking" = xyes; then + continue + else + break + fi + ;; + msvc7 | msvc7msys | msvisualcpp | msvcmsys) + # This compiler won't grok '-c -o', but also, the minuso test has + # not run yet. These depmodes are late enough in the game, and + # so weak that their functioning should not be impacted. + am__obj=conftest.${OBJEXT-o} + am__minus_obj= + ;; + none) break ;; + esac + if depmode=$depmode \ + source=sub/conftest.c object=$am__obj \ + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ + $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ + >/dev/null 2>conftest.err && + grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && + grep $am__obj sub/conftest.Po > /dev/null 2>&1 && + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then + # icc doesn't choke on unknown options, it will just issue warnings + # or remarks (even with -Werror). So we grep stderr for any message + # that says an option was ignored or not supported. + # When given -MP, icc 7.0 and 7.1 complain thus: + # icc: Command line warning: ignoring option '-M'; no argument required + # The diagnosis changed in icc 8.0: + # icc: Command line remark: option '-MP' not supported + if (grep 'ignoring option' conftest.err || + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else + am_cv_CCAS_dependencies_compiler_type=$depmode + break + fi + fi + done + cd .. + rm -rf conftest.dir +else + am_cv_CCAS_dependencies_compiler_type=none fi + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_CCAS_dependencies_compiler_type" >&5 +printf "%s\n" "$am_cv_CCAS_dependencies_compiler_type" >&6; } +CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type -# Check whether --enable-pie was given. -if test "${enable_pie+set}" = set; then : - enableval=$enable_pie; enable_pie=$enableval + if + test "x$enable_dependency_tracking" != xno \ + && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then + am__fastdepCCAS_TRUE= + am__fastdepCCAS_FALSE='#' else - enable_pie="maybe" + am__fastdepCCAS_TRUE='#' + am__fastdepCCAS_FALSE= fi -case $host_os in #( - mingw*|cygwin*|msys) : - enable_pie="no" ;; #( - *) : - ;; -esac -# Check whether --enable-blocking-random was given. -if test "${enable_blocking_random+set}" = set; then : - enableval=$enable_blocking_random; - if test "x$enableval" = "xyes"; then : +ac_header= ac_cache= +for ac_item in $ac_header_c_list +do + if test $ac_cache; then + ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default" + if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then + printf "%s\n" "#define $ac_item 1" >> confdefs.h + fi + ac_header= ac_cache= + elif test $ac_header; then + ac_cache=$ac_item + else + ac_header=$ac_item + fi +done + + -$as_echo "#define USE_BLOCKING_RANDOM 1" >>confdefs.h -fi + + +if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes +then : + +printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h fi -# Check whether --enable-minimal was given. -if test "${enable_minimal+set}" = set; then : - enableval=$enable_minimal; - if test "x$enableval" = "xyes"; then : - enable_minimal="yes" - SODIUM_LIBRARY_MINIMAL_DEF="#define SODIUM_LIBRARY_MINIMAL 1" -$as_echo "#define MINIMAL 1" >>confdefs.h -else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 +printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; } +if test ${ac_cv_safe_to_define___extensions__+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - enable_minimal="no" +# define __EXTENSIONS__ 1 + $ac_includes_default +int +main (void) +{ + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_safe_to_define___extensions__=yes +else case e in #( + e) ac_cv_safe_to_define___extensions__=no ;; +esac fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 +printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; } + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5 +printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; } +if test ${ac_cv_should_define__xopen_source+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_should_define__xopen_source=no + if test $ac_cv_header_wchar_h = yes +then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -else + #include <wchar.h> + mbstate_t x; +int +main (void) +{ - enable_minimal="no" + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : -fi +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - if test x$enable_minimal = xyes; then - MINIMAL_TRUE= - MINIMAL_FALSE='#' -else - MINIMAL_TRUE='#' - MINIMAL_FALSE= + #define _XOPEN_SOURCE 500 + #include <wchar.h> + mbstate_t x; +int +main (void) +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_should_define__xopen_source=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext +fi ;; +esac fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5 +printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; } + printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h + printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h + printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h -# Check whether --with-pthreads was given. -if test "${with_pthreads+set}" = set; then : - withval=$with_pthreads; -else - withval="yes" -fi + printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h + printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if ${ac_cv_path_SED+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ - for ac_i in 1 2 3 4 5 6 7; do - ac_script="$ac_script$as_nl$ac_script" - done - echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed - { ac_script=; unset ac_script;} - if test -z "$SED"; then - ac_path_SED_found=false - # Loop through the user's path and test for each of PROGNAME-LIST - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_SED" || continue -# Check for GNU ac_path_SED and select it if it is found. - # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in -*GNU*) - ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; -*) - ac_count=0 - $as_echo_n 0123456789 >"conftest.in" - while : - do - cat "conftest.in" "conftest.in" >"conftest.tmp" - mv "conftest.tmp" "conftest.in" - cp "conftest.in" "conftest.nl" - $as_echo '' >> "conftest.nl" - "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break - diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break - as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_SED_max-0}; then - # Best one so far, save it but keep looking for a better one - ac_cv_path_SED="$ac_path_SED" - ac_path_SED_max=$ac_count - fi - # 10*(2^10) chars as input seems more than enough - test $ac_count -gt 10 && break - done - rm -f conftest.in conftest.tmp conftest.nl conftest.out;; -esac + printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h - $ac_path_SED_found && break 3 - done - done - done -IFS=$as_save_IFS - if test -z "$ac_cv_path_SED"; then - as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 - fi -else - ac_cv_path_SED=$SED -fi + printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h + + printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h + + printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h + + if test $ac_cv_header_minix_config_h = yes +then : + MINIX=yes + printf "%s\n" "#define _MINIX 1" >>confdefs.h + printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h + + printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h + +else case e in #( + e) MINIX= ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -$as_echo "$ac_cv_path_SED" >&6; } - SED="$ac_cv_path_SED" - rm -f conftest.sed + if test $ac_cv_safe_to_define___extensions__ = yes +then : + printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 -$as_echo_n "checking how to run the C preprocessor... " >&6; } -# On Suns, sometimes $CPP names a directory. -if test -n "$CPP" && test -d "$CPP"; then - CPP= fi -if test -z "$CPP"; then - if ${ac_cv_prog_CPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CPP needs to be expanded - for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" - do - ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since - # <limits.h> exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#ifdef __STDC__ -# include <limits.h> -#else -# include <assert.h> -#endif - Syntax error -_ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : + if test $ac_cv_should_define__xopen_source = yes +then : + printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h -else - # Broken: fails on valid input. -continue fi -rm -f conftest.err conftest.i conftest.$ac_ext - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. + + +if test "$sodium_CFLAGS" != "set" ; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -O3" >&5 +printf %s "checking whether C compiler accepts -O3... " >&6; } +if test ${ax_cv_check_cflags___O3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -O3" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <ac_nonexistent.h> +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___O3=yes +else case e in #( + e) ax_cv_check_cflags___O3=no ;; +esac fi -rm -f conftest.err conftest.i conftest.$ac_ext - -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : - break +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___O3" >&5 +printf "%s\n" "$ax_cv_check_cflags___O3" >&6; } +if test "x$ax_cv_check_cflags___O3" = xyes +then : + CFLAGS="$CFLAGS -O3" +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -O2" >&5 +printf %s "checking whether C compiler accepts -O2... " >&6; } +if test ${ax_cv_check_cflags___O2+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -O2" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x - done - ac_cv_prog_CPP=$CPP + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___O2=yes +else case e in #( + e) ax_cv_check_cflags___O2=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___O2" >&5 +printf "%s\n" "$ax_cv_check_cflags___O2" >&6; } +if test "x$ax_cv_check_cflags___O2" = xyes +then : + CFLAGS="$CFLAGS -O2" +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -O1" >&5 +printf %s "checking whether C compiler accepts -O1... " >&6; } +if test ${ax_cv_check_cflags___O1+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -O1" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___O1=yes +else case e in #( + e) ax_cv_check_cflags___O1=no ;; +esac fi - CPP=$ac_cv_prog_CPP -else - ac_cv_prog_CPP=$CPP +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } -ac_preproc_ok=false -for ac_c_preproc_warn_flag in '' yes -do - # Use a header file that comes with gcc, so configuring glibc - # with a fresh cross-compiler works. - # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since - # <limits.h> exists even on freestanding compilers. - # On the NeXT, cc -E runs the code through the compiler's parser, - # not just through cpp. "Syntax error" is here to catch this case. +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___O1" >&5 +printf "%s\n" "$ax_cv_check_cflags___O1" >&6; } +if test "x$ax_cv_check_cflags___O1" = xyes +then : + CFLAGS="$CFLAGS -O1" +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -O" >&5 +printf %s "checking whether C compiler accepts -O... " >&6; } +if test ${ax_cv_check_cflags___O+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -O" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef __STDC__ -# include <limits.h> -#else -# include <assert.h> -#endif - Syntax error +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___O=yes +else case e in #( + e) ax_cv_check_cflags___O=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___O" >&5 +printf "%s\n" "$ax_cv_check_cflags___O" >&6; } +if test "x$ax_cv_check_cflags___O" = xyes +then : + CFLAGS="$CFLAGS -O" +else case e in #( + e) : ;; +esac +fi + ;; +esac +fi + ;; +esac +fi + ;; +esac +fi -else - # Broken: fails on valid input. -continue fi -rm -f conftest.err conftest.i conftest.$ac_ext - # OK, works on sane cases. Now check whether nonexistent headers - # can be detected and how. + +# Check whether --enable-ssp was given. +if test ${enable_ssp+y} +then : + enableval=$enable_ssp; + if test "x$enableval" = "xno" +then : + + enable_ssp="no" + +else case e in #( + e) + enable_ssp="yes" + ;; +esac +fi + +else case e in #( + e) + enable_ssp="yes" + ;; +esac +fi + + +# Check whether --enable-asm was given. +if test ${enable_asm+y} +then : + enableval=$enable_asm; + if test "x$enableval" = "xno" +then : + + enable_asm="no" + +else case e in #( + e) + enable_asm="yes" + ;; +esac +fi + +else case e in #( + e) + enable_asm="yes" + ;; +esac +fi + + +if test "x$EMSCRIPTEN" != "x" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -s ASSERTIONS=0" >&5 +printf %s "checking whether C compiler accepts -s ASSERTIONS=0... " >&6; } +if test ${ax_cv_check_cflags___s_ASSERTIONS_0+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -s ASSERTIONS=0" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <ac_nonexistent.h> +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : - # Broken: success on invalid input. -continue -else - # Passes both tests. -ac_preproc_ok=: -break +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___s_ASSERTIONS_0=yes +else case e in #( + e) ax_cv_check_cflags___s_ASSERTIONS_0=no ;; +esac fi -rm -f conftest.err conftest.i conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___s_ASSERTIONS_0" >&5 +printf "%s\n" "$ax_cv_check_cflags___s_ASSERTIONS_0" >&6; } +if test "x$ax_cv_check_cflags___s_ASSERTIONS_0" = xyes +then : -done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. -rm -f conftest.i conftest.err conftest.$ac_ext -if $ac_preproc_ok; then : + enable_asm="no" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: compiling to JavaScript - asm implementations disabled" >&5 +printf "%s\n" "$as_me: WARNING: compiling to JavaScript - asm implementations disabled" >&2;} -else - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -as_fn_error $? "C preprocessor \"$CPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: EMSCRIPTEN environment variable defined, but emcc doesn\'t appear to be used - Assuming compilation to native code" >&5 +printf "%s\n" "$as_me: WARNING: EMSCRIPTEN environment variable defined, but emcc doesn\'t appear to be used - Assuming compilation to native code" >&2;} + CFLAGS="$CFLAGS -U__EMSCRIPTEN__" + unset EMSCRIPTEN + ;; +esac fi -ac_ext=c -ac_cpp='$CPP $CPPFLAGS' -ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_c_compiler_gnu +fi + +# Check whether --enable-pie was given. +if test ${enable_pie+y} +then : + enableval=$enable_pie; enable_pie=$enableval +else case e in #( + e) enable_pie="maybe" ;; +esac +fi + + +case $host_os in #( + mingw*|cygwin*|msys|eabi*) : + enable_pie="no" ;; #( + *) : + ;; +esac + +# Check whether --enable-blocking-random was given. +if test ${enable_blocking_random+y} +then : + enableval=$enable_blocking_random; + if test "x$enableval" = "xyes" +then : + + +printf "%s\n" "#define USE_BLOCKING_RANDOM 1" >>confdefs.h + + +fi + +fi + + +# Check whether --enable-minimal was given. +if test ${enable_minimal+y} +then : + enableval=$enable_minimal; + if test "x$enableval" = "xyes" +then : + + enable_minimal="yes" + SODIUM_LIBRARY_MINIMAL_DEF="#define SODIUM_LIBRARY_MINIMAL 1" + +printf "%s\n" "#define MINIMAL 1" >>confdefs.h + + +else case e in #( + e) + enable_minimal="no" + ;; +esac +fi + +else case e in #( + e) + enable_minimal="no" + ;; +esac +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 -$as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if ${ac_cv_path_GREP+:} false; then : - $as_echo_n "(cached) " >&6 + if test x$enable_minimal = xyes; then + MINIMAL_TRUE= + MINIMAL_FALSE='#' else - if test -z "$GREP"; then - ac_path_GREP_found=false + MINIMAL_TRUE='#' + MINIMAL_FALSE= +fi + + + + +# Check whether --with-pthreads was given. +if test ${with_pthreads+y} +then : + withval=$with_pthreads; +else case e in #( + e) withval="yes" ;; +esac +fi + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +printf %s "checking for a sed that does not truncate output... " >&6; } +if test ${ac_cv_path_SED+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ + for ac_i in 1 2 3 4 5 6 7; do + ac_script="$ac_script$as_nl$ac_script" + done + echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed + { ac_script=; unset ac_script;} + if test -z "$SED"; then + ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in grep ggrep; do + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in sed gsed + do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_GREP" || continue -# Check for GNU ac_path_GREP and select it if it is found. - # Check for GNU $ac_path_GREP -case `"$ac_path_GREP" --version 2>&1` in + ac_path_SED="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_SED" || continue +# Check for GNU ac_path_SED and select it if it is found. + # Check for GNU $ac_path_SED +case `"$ac_path_SED" --version 2>&1` in #( *GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; + ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +#( *) ac_count=0 - $as_echo_n 0123456789 >"conftest.in" + printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" - $as_echo 'GREP' >> "conftest.nl" - "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break + printf "%s\n" '' >> "conftest.nl" + "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_GREP_max-0}; then + if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one - ac_cv_path_GREP="$ac_path_GREP" - ac_path_GREP_max=$ac_count + ac_cv_path_SED="$ac_path_SED" + ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break @@ -4739,65 +5904,209 @@ case `"$ac_path_GREP" --version 2>&1` in rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac - $ac_path_GREP_found && break 3 + $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS - if test -z "$ac_cv_path_GREP"; then - as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else - ac_cv_path_GREP=$GREP + ac_cv_path_SED=$SED +fi + ;; +esac fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +printf "%s\n" "$ac_cv_path_SED" >&6; } + SED="$ac_cv_path_SED" + rm -f conftest.sed +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 +printf %s "checking how to run the C preprocessor... " >&6; } +# On Suns, sometimes $CPP names a directory. +if test -n "$CPP" && test -d "$CPP"; then + CPP= fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 -$as_echo "$ac_cv_path_GREP" >&6; } - GREP="$ac_cv_path_GREP" +if test -z "$CPP"; then + if test ${ac_cv_prog_CPP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # Double quotes because $CC needs to be expanded + for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp + do + ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <limits.h> + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO" +then : + +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_c_try_cpp "$LINENO" +then : + # Broken: success on invalid input. +continue +else case e in #( + e) # Passes both tests. +ac_preproc_ok=: +break ;; +esac +fi +rm -f conftest.err conftest.i conftest.$ac_ext +done +# Because of 'break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok +then : + break +fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 -$as_echo_n "checking for egrep... " >&6; } -if ${ac_cv_path_EGREP+:} false; then : - $as_echo_n "(cached) " >&6 + done + ac_cv_prog_CPP=$CPP + ;; +esac +fi + CPP=$ac_cv_prog_CPP else - if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 - then ac_cv_path_EGREP="$GREP -E" - else - if test -z "$EGREP"; then - ac_path_EGREP_found=false + ac_cv_prog_CPP=$CPP +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 +printf "%s\n" "$CPP" >&6; } +ac_preproc_ok=false +for ac_c_preproc_warn_flag in '' yes +do + # Use a header file that comes with gcc, so configuring glibc + # with a fresh cross-compiler works. + # On the NeXT, cc -E runs the code through the compiler's parser, + # not just through cpp. "Syntax error" is here to catch this case. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <limits.h> + Syntax error +_ACEOF +if ac_fn_c_try_cpp "$LINENO" +then : + +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac +fi +rm -f conftest.err conftest.i conftest.$ac_ext + + # OK, works on sane cases. Now check whether nonexistent headers + # can be detected and how. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <ac_nonexistent.h> +_ACEOF +if ac_fn_c_try_cpp "$LINENO" +then : + # Broken: success on invalid input. +continue +else case e in #( + e) # Passes both tests. +ac_preproc_ok=: +break ;; +esac +fi +rm -f conftest.err conftest.i conftest.$ac_ext + +done +# Because of 'break', _AC_PREPROC_IFELSE's cleaning code was skipped. +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok +then : + +else case e in #( + e) { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See 'config.log' for more details" "$LINENO" 5; } ;; +esac +fi + +ac_ext=c +ac_cpp='$CPP $CPPFLAGS' +ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_c_compiler_gnu + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep -e" >&5 +printf %s "checking for egrep -e... " >&6; } +if test ${ac_cv_path_EGREP_TRADITIONAL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -z "$EGREP_TRADITIONAL"; then + ac_path_EGREP_TRADITIONAL_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in egrep; do + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in grep ggrep + do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_EGREP" || continue -# Check for GNU ac_path_EGREP and select it if it is found. - # Check for GNU $ac_path_EGREP -case `"$ac_path_EGREP" --version 2>&1` in + ac_path_EGREP_TRADITIONAL="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP_TRADITIONAL" || continue +# Check for GNU ac_path_EGREP_TRADITIONAL and select it if it is found. + # Check for GNU $ac_path_EGREP_TRADITIONAL +case `"$ac_path_EGREP_TRADITIONAL" --version 2>&1` in #( *GNU*) - ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; + ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" ac_path_EGREP_TRADITIONAL_found=:;; +#( *) ac_count=0 - $as_echo_n 0123456789 >"conftest.in" + printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" - $as_echo 'EGREP' >> "conftest.nl" - "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + printf "%s\n" 'EGREP_TRADITIONAL' >> "conftest.nl" + "$ac_path_EGREP_TRADITIONAL" -E 'EGR(EP|AC)_TRADITIONAL$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_EGREP_max-0}; then + if test $ac_count -gt ${ac_path_EGREP_TRADITIONAL_max-0}; then # Best one so far, save it but keep looking for a better one - ac_cv_path_EGREP="$ac_path_EGREP" - ac_path_EGREP_max=$ac_count + ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" + ac_path_EGREP_TRADITIONAL_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break @@ -4805,26 +6114,90 @@ case `"$ac_path_EGREP" --version 2>&1` in rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac - $ac_path_EGREP_found && break 3 + $ac_path_EGREP_TRADITIONAL_found && break 3 done done done IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + if test -z "$ac_cv_path_EGREP_TRADITIONAL"; then + : fi else - ac_cv_path_EGREP=$EGREP + ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 -$as_echo "$ac_cv_path_EGREP" >&6; } - EGREP="$ac_cv_path_EGREP" + if test "$ac_cv_path_EGREP_TRADITIONAL" +then : + ac_cv_path_EGREP_TRADITIONAL="$ac_cv_path_EGREP_TRADITIONAL -E" +else case e in #( + e) if test -z "$EGREP_TRADITIONAL"; then + ac_path_EGREP_TRADITIONAL_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in egrep + do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP_TRADITIONAL="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP_TRADITIONAL" || continue +# Check for GNU ac_path_EGREP_TRADITIONAL and select it if it is found. + # Check for GNU $ac_path_EGREP_TRADITIONAL +case `"$ac_path_EGREP_TRADITIONAL" --version 2>&1` in #( +*GNU*) + ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" ac_path_EGREP_TRADITIONAL_found=:;; +#( +*) + ac_count=0 + printf %s 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + printf "%s\n" 'EGREP_TRADITIONAL' >> "conftest.nl" + "$ac_path_EGREP_TRADITIONAL" 'EGR(EP|AC)_TRADITIONAL$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_TRADITIONAL_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" + ac_path_EGREP_TRADITIONAL_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + $ac_path_EGREP_TRADITIONAL_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP_TRADITIONAL"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL +fi + ;; +esac +fi ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP_TRADITIONAL" >&5 +printf "%s\n" "$ac_cv_path_EGREP_TRADITIONAL" >&6; } + EGREP_TRADITIONAL=$ac_cv_path_EGREP_TRADITIONAL -if test "x$withval" = "xyes"; then : +if test "x$withval" = "xyes" +then : @@ -4849,38 +6222,47 @@ if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then ax_pthread_save_CC="$CC" ax_pthread_save_CFLAGS="$CFLAGS" ax_pthread_save_LIBS="$LIBS" - if test "x$PTHREAD_CC" != "x"; then : + if test "x$PTHREAD_CC" != "x" +then : CC="$PTHREAD_CC" fi + if test "x$PTHREAD_CXX" != "x" +then : + CXX="$PTHREAD_CXX" +fi CFLAGS="$CFLAGS $PTHREAD_CFLAGS" LIBS="$PTHREAD_LIBS $LIBS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5 -$as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5 +printf %s "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char pthread_join (); +char pthread_join (void); int -main () +main (void) { return pthread_join (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_pthread_ok=yes fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5 -$as_echo "$ax_pthread_ok" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5 +printf "%s\n" "$ax_pthread_ok" >&6; } if test "x$ax_pthread_ok" = "xno"; then PTHREAD_LIBS="" PTHREAD_CFLAGS="" @@ -4895,10 +6277,12 @@ fi # (e.g. DEC) have both -lpthread and -lpthreads, where one of the # libraries is broken (non-POSIX). -# Create a list of thread flags to try. Items starting with a "-" are -# C compiler flags, and other items are library names, except for "none" -# which indicates that we try without any flags at all, and "pthread-config" -# which is a program returning the flags for the Pth emulation library. +# Create a list of thread flags to try. Items with a "," contain both +# C compiler flags (before ",") and linker flags (after ","). Other items +# starting with a "-" are C compiler flags, and remaining items are +# library names, except for "none" which indicates that we try without +# any flags at all, and "pthread-config" which is a program returning +# the flags for the Pth emulation library. ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config" @@ -4956,11 +6340,12 @@ case $host_os in _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5 -$as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;} + $EGREP_TRADITIONAL "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1 +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5 +printf "%s\n" "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;} fi -rm -f conftest* +rm -rf conftest* ;; @@ -4974,16 +6359,68 @@ rm -f conftest* # that too in a future libc.) So we'll check first for the # standard Solaris way of linking pthreads (-mt -lpthread). - ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags" + ax_pthread_flags="-mt,-lpthread pthread $ax_pthread_flags" ;; esac +# Are we compiling with Clang? + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5 +printf %s "checking whether $CC is Clang... " >&6; } +if test ${ax_cv_PTHREAD_CLANG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_PTHREAD_CLANG=no + # Note that Autoconf sets GCC=yes for Clang as well as GCC + if test "x$GCC" = "xyes"; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Note: Clang 2.7 lacks __clang_[a-z]+__ */ +# if defined(__clang__) && defined(__llvm__) + AX_PTHREAD_CC_IS_CLANG +# endif + +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP_TRADITIONAL "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1 +then : + ax_cv_PTHREAD_CLANG=yes +fi +rm -rf conftest* + + fi + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5 +printf "%s\n" "$ax_cv_PTHREAD_CLANG" >&6; } +ax_pthread_clang="$ax_cv_PTHREAD_CLANG" + + # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC) -if test "x$GCC" = "xyes"; then : - ax_pthread_flags="-pthread -pthreads $ax_pthread_flags" +# Note that for GCC and Clang -pthread generally implies -lpthread, +# except when -nostdlib is passed. +# This is problematic using libtool to build C++ shared libraries with pthread: +# [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25460 +# [2] https://bugzilla.redhat.com/show_bug.cgi?id=661333 +# [3] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=468555 +# To solve this, first try -pthread together with -lpthread for GCC + +if test "x$GCC" = "xyes" +then : + ax_pthread_flags="-pthread,-lpthread -pthread -pthreads $ax_pthread_flags" +fi + +# Clang takes -pthread (never supported any other flag), but we'll try with -lpthread first + +if test "x$ax_pthread_clang" = "xyes" +then : + ax_pthread_flags="-pthread,-lpthread -pthread" fi + # The presence of a feature test macro requesting re-entrant function # definitions is, on some systems, a strong hint that pthreads support is # correctly enabled @@ -5001,51 +6438,168 @@ case $host_os in ax_pthread_check_macro="--" ;; esac -if test "x$ax_pthread_check_macro" = "x--"; then : +if test "x$ax_pthread_check_macro" = "x--" +then : ax_pthread_check_cond=0 -else - ax_pthread_check_cond="!defined($ax_pthread_check_macro)" +else case e in #( + e) ax_pthread_check_cond="!defined($ax_pthread_check_macro)" ;; +esac fi -# Are we compiling with Clang? -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5 -$as_echo_n "checking whether $CC is Clang... " >&6; } -if ${ax_cv_PTHREAD_CLANG+:} false; then : - $as_echo_n "(cached) " >&6 -else - ax_cv_PTHREAD_CLANG=no - # Note that Autoconf sets GCC=yes for Clang as well as GCC - if test "x$GCC" = "xyes"; then - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -/* Note: Clang 2.7 lacks __clang_[a-z]+__ */ -# if defined(__clang__) && defined(__llvm__) - AX_PTHREAD_CC_IS_CLANG -# endif +if test "x$ax_pthread_ok" = "xno"; then +for ax_pthread_try_flag in $ax_pthread_flags; do -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then : - ax_cv_PTHREAD_CLANG=yes -fi -rm -f conftest* + case $ax_pthread_try_flag in + none) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5 +printf %s "checking whether pthreads work without any flags... " >&6; } + ;; - fi + *,*) + PTHREAD_CFLAGS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\1/"` + PTHREAD_LIBS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\2/"` + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with \"$PTHREAD_CFLAGS\" and \"$PTHREAD_LIBS\"" >&5 +printf %s "checking whether pthreads work with \"$PTHREAD_CFLAGS\" and \"$PTHREAD_LIBS\"... " >&6; } + ;; -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5 -$as_echo "$ax_cv_PTHREAD_CLANG" >&6; } -ax_pthread_clang="$ax_cv_PTHREAD_CLANG" + -*) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5 +printf %s "checking whether pthreads work with $ax_pthread_try_flag... " >&6; } + PTHREAD_CFLAGS="$ax_pthread_try_flag" + ;; -ax_pthread_clang_warning=no + pthread-config) + # Extract the first word of "pthread-config", so it can be a program name with args. +set dummy pthread-config; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ax_pthread_config+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ax_pthread_config"; then + ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_ax_pthread_config="yes" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# Clang needs special handling, because older versions handle the -pthread -# option in a rather... idiosyncratic way + test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no" +fi ;; +esac +fi +ax_pthread_config=$ac_cv_prog_ax_pthread_config +if test -n "$ax_pthread_config"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5 +printf "%s\n" "$ax_pthread_config" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi -if test "x$ax_pthread_clang" = "xyes"; then - # Clang takes -pthread; it has never supported any other flag + if test "x$ax_pthread_config" = "xno" +then : + continue +fi + PTHREAD_CFLAGS="`pthread-config --cflags`" + PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" + ;; + + *) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5 +printf %s "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; } + PTHREAD_LIBS="-l$ax_pthread_try_flag" + ;; + esac + + ax_pthread_save_CFLAGS="$CFLAGS" + ax_pthread_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + LIBS="$PTHREAD_LIBS $LIBS" + + # Check for various functions. We must include pthread.h, + # since some functions may be macros. (On the Sequent, we + # need a special flag -Kthread to make this header compile.) + # We check for pthread_join because it is in -lpthread on IRIX + # while pthread_create is in libc. We check for pthread_attr_init + # due to DEC craziness with -lpthreads. We check for + # pthread_cleanup_push because it is one of the few pthread + # functions on Solaris that doesn't have a non-functional libc stub. + # We try pthread_create on general principles. + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <pthread.h> +# if $ax_pthread_check_cond +# error "$ax_pthread_check_macro must be defined" +# endif + static void *some_global = NULL; + static void routine(void *a) + { + /* To avoid any unused-parameter or + unused-but-set-parameter warning. */ + some_global = a; + } + static void *start_routine(void *a) { return a; } +int +main (void) +{ +pthread_t th; pthread_attr_t attr; + pthread_create(&th, 0, start_routine, 0); + pthread_join(th, 0); + pthread_attr_init(&attr); + pthread_cleanup_push(routine, 0); + pthread_cleanup_pop(0) /* ; */ + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + ax_pthread_ok=yes +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + + CFLAGS="$ax_pthread_save_CFLAGS" + LIBS="$ax_pthread_save_LIBS" + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5 +printf "%s\n" "$ax_pthread_ok" >&6; } + if test "x$ax_pthread_ok" = "xyes" +then : + break +fi + + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" +done +fi + + +# Clang needs special handling, because older versions handle the -pthread +# option in a rather... idiosyncratic way + +if test "x$ax_pthread_clang" = "xyes"; then + + # Clang takes -pthread; it has never supported any other flag # (Note 1: This will need to be revisited if a system that Clang # supports has POSIX threads in a separate library. This tends not @@ -5057,11 +6611,6 @@ if test "x$ax_pthread_clang" = "xyes"; then # -pthread does define _REENTRANT, and while the Darwin headers # ignore this macro, third-party headers might not.) - PTHREAD_CFLAGS="-pthread" - PTHREAD_LIBS= - - ax_pthread_ok=yes - # However, older versions of Clang make a point of warning the user # that, in an invocation where only linking and no compilation is # taking place, the -pthread option has no effect ("argument unused @@ -5081,23 +6630,25 @@ if test "x$ax_pthread_clang" = "xyes"; then # that build with -Werror. So if the active version of Clang has # this misfeature, we search for an option to squash it. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5 -$as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; } -if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then : - $as_echo_n "(cached) " >&6 -else - ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5 +printf %s "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; } +if test ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown # Create an alternate version of $ac_link that compiles and # links in two steps (.c -> .o, .o -> exe) instead of one # (.c -> exe), because the warning occurs only in the second # step ax_pthread_save_ac_link="$ac_link" ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g' - ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"` + ax_pthread_link_step=`printf "%s\n" "$ac_link" | sed "$ax_pthread_sed"` ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)" ax_pthread_save_CFLAGS="$CFLAGS" for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do - if test "x$ax_pthread_try" = "xunknown"; then : + if test "x$ax_pthread_try" = "xunknown" +then : break fi CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS" @@ -5106,32 +6657,36 @@ fi /* end confdefs.h. */ int main(void){return 0;} _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_link="$ax_pthread_2step_ac_link" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main(void){return 0;} _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : break fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext done ac_link="$ax_pthread_save_ac_link" CFLAGS="$ax_pthread_save_CFLAGS" - if test "x$ax_pthread_try" = "x"; then : + if test "x$ax_pthread_try" = "x" +then : ax_pthread_try=no fi ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try" - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5 -$as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5 +printf "%s\n" "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; } case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in no | unknown) ;; @@ -5140,136 +6695,7 @@ $as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; } fi # $ax_pthread_clang = yes -if test "x$ax_pthread_ok" = "xno"; then -for ax_pthread_try_flag in $ax_pthread_flags; do - - case $ax_pthread_try_flag in - none) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5 -$as_echo_n "checking whether pthreads work without any flags... " >&6; } - ;; - - -mt,pthread) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5 -$as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; } - PTHREAD_CFLAGS="-mt" - PTHREAD_LIBS="-lpthread" - ;; - - -*) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5 -$as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; } - PTHREAD_CFLAGS="$ax_pthread_try_flag" - ;; - - pthread-config) - # Extract the first word of "pthread-config", so it can be a program name with args. -set dummy pthread-config; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ax_pthread_config+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ax_pthread_config"; then - ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ax_pthread_config="yes" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - - test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no" -fi -fi -ax_pthread_config=$ac_cv_prog_ax_pthread_config -if test -n "$ax_pthread_config"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5 -$as_echo "$ax_pthread_config" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - - if test "x$ax_pthread_config" = "xno"; then : - continue -fi - PTHREAD_CFLAGS="`pthread-config --cflags`" - PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" - ;; - - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5 -$as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; } - PTHREAD_LIBS="-l$ax_pthread_try_flag" - ;; - esac - - ax_pthread_save_CFLAGS="$CFLAGS" - ax_pthread_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $PTHREAD_CFLAGS" - LIBS="$PTHREAD_LIBS $LIBS" - - # Check for various functions. We must include pthread.h, - # since some functions may be macros. (On the Sequent, we - # need a special flag -Kthread to make this header compile.) - # We check for pthread_join because it is in -lpthread on IRIX - # while pthread_create is in libc. We check for pthread_attr_init - # due to DEC craziness with -lpthreads. We check for - # pthread_cleanup_push because it is one of the few pthread - # functions on Solaris that doesn't have a non-functional libc stub. - # We try pthread_create on general principles. - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <pthread.h> -# if $ax_pthread_check_cond -# error "$ax_pthread_check_macro must be defined" -# endif - static void routine(void *a) { a = 0; } - static void *start_routine(void *a) { return a; } -int -main () -{ -pthread_t th; pthread_attr_t attr; - pthread_create(&th, 0, start_routine, 0); - pthread_join(th, 0); - pthread_attr_init(&attr); - pthread_cleanup_push(routine, 0); - pthread_cleanup_pop(0) /* ; */ - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_pthread_ok=yes -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - - CFLAGS="$ax_pthread_save_CFLAGS" - LIBS="$ax_pthread_save_LIBS" - - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5 -$as_echo "$ax_pthread_ok" >&6; } - if test "x$ax_pthread_ok" = "xyes"; then : - break -fi - PTHREAD_LIBS="" - PTHREAD_CFLAGS="" -done -fi # Various other checks: if test "x$ax_pthread_ok" = "xyes"; then @@ -5279,98 +6705,109 @@ if test "x$ax_pthread_ok" = "xyes"; then LIBS="$PTHREAD_LIBS $LIBS" # Detect AIX lossage: JOINABLE attribute is called UNDETACHED. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5 -$as_echo_n "checking for joinable pthread attribute... " >&6; } -if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then : - $as_echo_n "(cached) " >&6 -else - ax_cv_PTHREAD_JOINABLE_ATTR=unknown + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5 +printf %s "checking for joinable pthread attribute... " >&6; } +if test ${ax_cv_PTHREAD_JOINABLE_ATTR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_PTHREAD_JOINABLE_ATTR=unknown for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <pthread.h> int -main () +main (void) { int attr = $ax_pthread_attr; return attr /* ; */ ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext done - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5 -$as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5 +printf "%s\n" "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; } if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \ test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \ - test "x$ax_pthread_joinable_attr_defined" != "xyes"; then : + test "x$ax_pthread_joinable_attr_defined" != "xyes" +then : -cat >>confdefs.h <<_ACEOF -#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR -_ACEOF +printf "%s\n" "#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR" >>confdefs.h ax_pthread_joinable_attr_defined=yes fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5 -$as_echo_n "checking whether more special flags are required for pthreads... " >&6; } -if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then : - $as_echo_n "(cached) " >&6 -else - ax_cv_PTHREAD_SPECIAL_FLAGS=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5 +printf %s "checking whether more special flags are required for pthreads... " >&6; } +if test ${ax_cv_PTHREAD_SPECIAL_FLAGS+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_PTHREAD_SPECIAL_FLAGS=no case $host_os in solaris*) ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS" ;; esac - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5 -$as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5 +printf "%s\n" "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; } if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \ - test "x$ax_pthread_special_flags_added" != "xyes"; then : + test "x$ax_pthread_special_flags_added" != "xyes" +then : PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS" ax_pthread_special_flags_added=yes fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5 -$as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; } -if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5 +printf %s "checking for PTHREAD_PRIO_INHERIT... " >&6; } +if test ${ax_cv_PTHREAD_PRIO_INHERIT+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <pthread.h> int -main () +main (void) { int i = PTHREAD_PRIO_INHERIT; + return i; ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_PTHREAD_PRIO_INHERIT=yes -else - ax_cv_PTHREAD_PRIO_INHERIT=no +else case e in #( + e) ax_cv_PTHREAD_PRIO_INHERIT=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5 -$as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5 +printf "%s\n" "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; } if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \ - test "x$ax_pthread_prio_inherit_defined" != "xyes"; then : + test "x$ax_pthread_prio_inherit_defined" != "xyes" +then : -$as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h +printf "%s\n" "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h ax_pthread_prio_inherit_defined=yes @@ -5388,54 +6825,126 @@ fi #handle absolute path differently from PATH based program lookup case "x$CC" in #( x/*) : - if as_fn_executable_p ${CC}_r; then : + + if as_fn_executable_p ${CC}_r +then : PTHREAD_CC="${CC}_r" -fi ;; #( +fi + if test "x${CXX}" != "x" +then : + if as_fn_executable_p ${CXX}_r +then : + PTHREAD_CXX="${CXX}_r" +fi +fi + ;; #( *) : - for ac_prog in ${CC}_r + + for ac_prog in ${CC}_r do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_PTHREAD_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$PTHREAD_CC"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_PTHREAD_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$PTHREAD_CC"; then ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_PTHREAD_CC="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi PTHREAD_CC=$ac_cv_prog_PTHREAD_CC if test -n "$PTHREAD_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5 -$as_echo "$PTHREAD_CC" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5 +printf "%s\n" "$PTHREAD_CC" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi test -n "$PTHREAD_CC" && break done test -n "$PTHREAD_CC" || PTHREAD_CC="$CC" - ;; -esac ;; #( + + if test "x${CXX}" != "x" +then : + for ac_prog in ${CXX}_r +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_PTHREAD_CXX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$PTHREAD_CXX"; then + ac_cv_prog_PTHREAD_CXX="$PTHREAD_CXX" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_PTHREAD_CXX="$ac_prog" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi ;; +esac +fi +PTHREAD_CXX=$ac_cv_prog_PTHREAD_CXX +if test -n "$PTHREAD_CXX"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CXX" >&5 +printf "%s\n" "$PTHREAD_CXX" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + + test -n "$PTHREAD_CXX" && break +done +test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX" + +fi + + ;; +esac + ;; #( *) : ;; esac @@ -5445,6 +6954,8 @@ esac fi test -n "$PTHREAD_CC" || PTHREAD_CC="$CC" +test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX" + @@ -5459,7 +6970,7 @@ if test "x$ax_pthread_ok" = "xyes"; then #include <pthread.h> int -main () +main (void) { pthread_mutex_t mutex; @@ -5472,10 +6983,11 @@ main () return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : -$as_echo "#define HAVE_PTHREAD 1" >>confdefs.h +printf "%s\n" "#define HAVE_PTHREAD 1" >>confdefs.h with_threads="yes" LIBS="$PTHREAD_LIBS $LIBS" @@ -5484,14 +6996,14 @@ $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h CC="$PTHREAD_CC" fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext : else ax_pthread_ok=no - { $as_echo "$as_me:${as_lineno-$LINENO}: pthread mutexes are not available" >&5 -$as_echo "$as_me: pthread mutexes are not available" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: pthread mutexes are not available" >&5 +printf "%s\n" "$as_me: pthread mutexes are not available" >&6;} fi ac_ext=c @@ -5502,14 +7014,17 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu -else - with_threads="no" +else case e in #( + e) with_threads="no" ;; +esac fi # Check whether --with-safecode was given. -if test "${with_safecode+set}" = set; then : - withval=$with_safecode; if test "x$withval" = "xyes"; then : +if test ${with_safecode+y} +then : + withval=$with_safecode; if test "x$withval" = "xyes" +then : : ${SAFECODE_HOME:=/opt/safecode} @@ -5524,49 +7039,57 @@ fi # Check whether --with-ctgrind was given. -if test "${with_ctgrind+set}" = set; then : - withval=$with_ctgrind; if test "x$withval" = "xyes"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ct_poison in -lctgrind" >&5 -$as_echo_n "checking for ct_poison in -lctgrind... " >&6; } -if ${ac_cv_lib_ctgrind_ct_poison+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +if test ${with_ctgrind+y} +then : + withval=$with_ctgrind; if test "x$withval" = "xyes" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ct_poison in -lctgrind" >&5 +printf %s "checking for ct_poison in -lctgrind... " >&6; } +if test ${ac_cv_lib_ctgrind_ct_poison+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lctgrind $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char ct_poison (); +char ct_poison (void); int -main () +main (void) { return ct_poison (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_ctgrind_ct_poison=yes -else - ac_cv_lib_ctgrind_ct_poison=no +else case e in #( + e) ac_cv_lib_ctgrind_ct_poison=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ctgrind_ct_poison" >&5 -$as_echo "$ac_cv_lib_ctgrind_ct_poison" >&6; } -if test "x$ac_cv_lib_ctgrind_ct_poison" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBCTGRIND 1 -_ACEOF +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ctgrind_ct_poison" >&5 +printf "%s\n" "$ac_cv_lib_ctgrind_ct_poison" >&6; } +if test "x$ac_cv_lib_ctgrind_ct_poison" = xyes +then : + printf "%s\n" "#define HAVE_LIBCTGRIND 1" >>confdefs.h LIBS="-lctgrind $LIBS" @@ -5579,115 +7102,138 @@ fi # Check whether --enable-retpoline was given. -if test "${enable_retpoline+set}" = set; then : - enableval=$enable_retpoline; if test "x$enableval" = "xyes"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mindirect-branch=thunk-inline" >&5 -$as_echo_n "checking whether C compiler accepts -mindirect-branch=thunk-inline... " >&6; } -if ${ax_cv_check_cflags___mindirect_branch_thunk_inline+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if test ${enable_retpoline+y} +then : + enableval=$enable_retpoline; if test "x$enableval" = "xyes" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mindirect-branch=thunk-inline" >&5 +printf %s "checking whether C compiler accepts -mindirect-branch=thunk-inline... " >&6; } +if test ${ax_cv_check_cflags___mindirect_branch_thunk_inline+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mindirect-branch=thunk-inline" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mindirect_branch_thunk_inline=yes -else - ax_cv_check_cflags___mindirect_branch_thunk_inline=no +else case e in #( + e) ax_cv_check_cflags___mindirect_branch_thunk_inline=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mindirect_branch_thunk_inline" >&5 -$as_echo "$ax_cv_check_cflags___mindirect_branch_thunk_inline" >&6; } -if test "x$ax_cv_check_cflags___mindirect_branch_thunk_inline" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mindirect_branch_thunk_inline" >&5 +printf "%s\n" "$ax_cv_check_cflags___mindirect_branch_thunk_inline" >&6; } +if test "x$ax_cv_check_cflags___mindirect_branch_thunk_inline" = xyes +then : CFLAGS="$CFLAGS -mindirect-branch=thunk-inline" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mretpoline" >&5 -$as_echo_n "checking whether C compiler accepts -mretpoline... " >&6; } -if ${ax_cv_check_cflags___mretpoline+:} false; then : - $as_echo_n "(cached) " >&6 -else - +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mretpoline" >&5 +printf %s "checking whether C compiler accepts -mretpoline... " >&6; } +if test ${ax_cv_check_cflags___mretpoline+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mretpoline" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mretpoline=yes -else - ax_cv_check_cflags___mretpoline=no +else case e in #( + e) ax_cv_check_cflags___mretpoline=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mretpoline" >&5 -$as_echo "$ax_cv_check_cflags___mretpoline" >&6; } -if test "x$ax_cv_check_cflags___mretpoline" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mretpoline" >&5 +printf "%s\n" "$ax_cv_check_cflags___mretpoline" >&6; } +if test "x$ax_cv_check_cflags___mretpoline" = xyes +then : CFLAGS="$CFLAGS -mretpoline" -else - : +else case e in #( + e) : ;; +esac fi - + ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mindirect-branch-register" >&5 -$as_echo_n "checking whether C compiler accepts -mindirect-branch-register... " >&6; } -if ${ax_cv_check_cflags___mindirect_branch_register+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mindirect-branch-register" >&5 +printf %s "checking whether C compiler accepts -mindirect-branch-register... " >&6; } +if test ${ax_cv_check_cflags___mindirect_branch_register+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mindirect-branch-register" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mindirect_branch_register=yes -else - ax_cv_check_cflags___mindirect_branch_register=no +else case e in #( + e) ax_cv_check_cflags___mindirect_branch_register=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mindirect_branch_register" >&5 -$as_echo "$ax_cv_check_cflags___mindirect_branch_register" >&6; } -if test "x$ax_cv_check_cflags___mindirect_branch_register" = xyes; then : - : -else +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mindirect_branch_register" >&5 +printf "%s\n" "$ax_cv_check_cflags___mindirect_branch_register" >&6; } +if test "x$ax_cv_check_cflags___mindirect_branch_register" = xyes +then : : +else case e in #( + e) : ;; +esac fi @@ -5698,11 +7244,14 @@ fi ENABLE_CWFLAGS=no # Check whether --enable-debug was given. -if test "${enable_debug+set}" = set; then : +if test ${enable_debug+y} +then : enableval=$enable_debug; - if test "x$enableval" = "xyes"; then : + if test "x$enableval" = "xyes" +then : - if test "x$LX_CFLAGS" = "xNONE"; then : + if test "x$LX_CFLAGS" = "xNONE" +then : nxflags="" for flag in `echo $CFLAGS`; do @@ -5729,188 +7278,225 @@ fi # Check whether --enable-opt was given. -if test "${enable_opt+set}" = set; then : +if test ${enable_opt+y} +then : enableval=$enable_opt; - if test "x$enableval" = "xyes"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Ofast" >&5 -$as_echo_n "checking whether C compiler accepts -Ofast... " >&6; } -if ${ax_cv_check_cflags___Ofast+:} false; then : - $as_echo_n "(cached) " >&6 -else - + if test "x$enableval" = "xyes" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftree-vectorize" >&5 +printf %s "checking whether C compiler accepts -ftree-vectorize... " >&6; } +if test ${ax_cv_check_cflags___ftree_vectorize+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -Ofast" + CFLAGS="$CFLAGS -ftree-vectorize" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___Ofast=yes -else - ax_cv_check_cflags___Ofast=no +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___ftree_vectorize=yes +else case e in #( + e) ax_cv_check_cflags___ftree_vectorize=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Ofast" >&5 -$as_echo "$ax_cv_check_cflags___Ofast" >&6; } -if test "x$ax_cv_check_cflags___Ofast" = xyes; then : - CFLAGS="$CFLAGS -Ofast" -else - : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftree_vectorize" >&5 +printf "%s\n" "$ax_cv_check_cflags___ftree_vectorize" >&6; } +if test "x$ax_cv_check_cflags___ftree_vectorize" = xyes +then : + CFLAGS="$CFLAGS -ftree-vectorize" +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftree-vectorize" >&5 -$as_echo_n "checking whether C compiler accepts -ftree-vectorize... " >&6; } -if ${ax_cv_check_cflags___ftree_vectorize+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftree-slp-vectorize" >&5 +printf %s "checking whether C compiler accepts -ftree-slp-vectorize... " >&6; } +if test ${ax_cv_check_cflags___ftree_slp_vectorize+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -ftree-vectorize" + CFLAGS="$CFLAGS -ftree-slp-vectorize" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___ftree_vectorize=yes -else - ax_cv_check_cflags___ftree_vectorize=no +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___ftree_slp_vectorize=yes +else case e in #( + e) ax_cv_check_cflags___ftree_slp_vectorize=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftree_vectorize" >&5 -$as_echo "$ax_cv_check_cflags___ftree_vectorize" >&6; } -if test "x$ax_cv_check_cflags___ftree_vectorize" = xyes; then : - CFLAGS="$CFLAGS -ftree-vectorize" -else - : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftree_slp_vectorize" >&5 +printf "%s\n" "$ax_cv_check_cflags___ftree_slp_vectorize" >&6; } +if test "x$ax_cv_check_cflags___ftree_slp_vectorize" = xyes +then : + CFLAGS="$CFLAGS -ftree-slp-vectorize" +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftree-slp-vectorize" >&5 -$as_echo_n "checking whether C compiler accepts -ftree-slp-vectorize... " >&6; } -if ${ax_cv_check_cflags___ftree_slp_vectorize+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fomit-frame-pointer" >&5 +printf %s "checking whether C compiler accepts -fomit-frame-pointer... " >&6; } +if test ${ax_cv_check_cflags___fomit_frame_pointer+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -ftree-slp-vectorize" + CFLAGS="$CFLAGS -fomit-frame-pointer" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___ftree_slp_vectorize=yes -else - ax_cv_check_cflags___ftree_slp_vectorize=no +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___fomit_frame_pointer=yes +else case e in #( + e) ax_cv_check_cflags___fomit_frame_pointer=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftree_slp_vectorize" >&5 -$as_echo "$ax_cv_check_cflags___ftree_slp_vectorize" >&6; } -if test "x$ax_cv_check_cflags___ftree_slp_vectorize" = xyes; then : - CFLAGS="$CFLAGS -ftree-slp-vectorize" -else - : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fomit_frame_pointer" >&5 +printf "%s\n" "$ax_cv_check_cflags___fomit_frame_pointer" >&6; } +if test "x$ax_cv_check_cflags___fomit_frame_pointer" = xyes +then : + CFLAGS="$CFLAGS -fomit-frame-pointer" +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fomit-frame-pointer" >&5 -$as_echo_n "checking whether C compiler accepts -fomit-frame-pointer... " >&6; } -if ${ax_cv_check_cflags___fomit_frame_pointer+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -march=native" >&5 +printf %s "checking whether C compiler accepts -march=native... " >&6; } +if test ${ax_cv_check_cflags___march_native+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -fomit-frame-pointer" + CFLAGS="$CFLAGS -march=native" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___fomit_frame_pointer=yes -else - ax_cv_check_cflags___fomit_frame_pointer=no +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___march_native=yes +else case e in #( + e) ax_cv_check_cflags___march_native=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fomit_frame_pointer" >&5 -$as_echo "$ax_cv_check_cflags___fomit_frame_pointer" >&6; } -if test "x$ax_cv_check_cflags___fomit_frame_pointer" = xyes; then : - CFLAGS="$CFLAGS -fomit-frame-pointer" -else - : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___march_native" >&5 +printf "%s\n" "$ax_cv_check_cflags___march_native" >&6; } +if test "x$ax_cv_check_cflags___march_native" = xyes +then : + CFLAGS="$CFLAGS -march=native" +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -march=native" >&5 -$as_echo_n "checking whether C compiler accepts -march=native... " >&6; } -if ${ax_cv_check_cflags___march_native+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mtune=native" >&5 +printf %s "checking whether C compiler accepts -mtune=native... " >&6; } +if test ${ax_cv_check_cflags___mtune_native+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -march=native" + CFLAGS="$CFLAGS -mtune=native" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___march_native=yes -else - ax_cv_check_cflags___march_native=no +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___mtune_native=yes +else case e in #( + e) ax_cv_check_cflags___mtune_native=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___march_native" >&5 -$as_echo "$ax_cv_check_cflags___march_native" >&6; } -if test "x$ax_cv_check_cflags___march_native" = xyes; then : - CFLAGS="$CFLAGS -march=native" -else - : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mtune_native" >&5 +printf "%s\n" "$ax_cv_check_cflags___mtune_native" >&6; } +if test "x$ax_cv_check_cflags___mtune_native" = xyes +then : + CFLAGS="$CFLAGS -mtune=native" +else case e in #( + e) : ;; +esac fi @@ -5923,70 +7509,86 @@ fi + + + # Check whether --enable-valgrind was given. -if test "${enable_valgrind+set}" = set; then : +if test ${enable_valgrind+y} +then : enableval=$enable_valgrind; enable_valgrind=$enableval -else - enable_valgrind=no +else case e in #( + e) enable_valgrind= ;; +esac fi - if test "$enable_valgrind" != "no"; then : + if test "$enable_valgrind" != "no" +then : # Check for Valgrind. # Extract the first word of "valgrind", so it can be a program name with args. set dummy valgrind; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_VALGRIND+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$VALGRIND"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_VALGRIND+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$VALGRIND"; then ac_cv_prog_VALGRIND="$VALGRIND" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_VALGRIND="valgrind" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi VALGRIND=$ac_cv_prog_VALGRIND if test -n "$VALGRIND"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VALGRIND" >&5 -$as_echo "$VALGRIND" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $VALGRIND" >&5 +printf "%s\n" "$VALGRIND" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi - if test "$VALGRIND" = ""; then : + if test "$VALGRIND" = "" +then : - if test "$enable_valgrind" = "yes"; then : + if test "$enable_valgrind" = "yes" +then : as_fn_error $? "Could not find valgrind; either install it or reconfigure with --disable-valgrind" "$LINENO" 5 -else - +else case e in #( + e) enable_valgrind=no - + ;; +esac fi -else - +else case e in #( + e) enable_valgrind=yes - + ;; +esac fi fi @@ -6006,54 +7608,66 @@ fi valgrind_enabled_tools= # Check whether --enable-valgrind-memcheck was given. -if test "${enable_valgrind_memcheck+set}" = set; then : +if test ${enable_valgrind_memcheck+y} +then : enableval=$enable_valgrind_memcheck; enable_valgrind_memcheck=$enableval -else - enable_valgrind_memcheck= +else case e in #( + e) enable_valgrind_memcheck= ;; +esac fi - if test "$enable_valgrind" = "no"; then : + if test "$enable_valgrind" = "no" +then : enable_valgrind_memcheck=no -elif test "$enable_valgrind_memcheck" != "no"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool memcheck" >&5 -$as_echo_n "checking for Valgrind tool memcheck... " >&6; } -if ${ax_cv_valgrind_tool_memcheck+:} false; then : - $as_echo_n "(cached) " >&6 -else - +elif test "$enable_valgrind_memcheck" != "no" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool memcheck" >&5 +printf %s "checking for Valgrind tool memcheck... " >&6; } +if test ${ax_cv_valgrind_tool_memcheck+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_valgrind_tool_memcheck=no - if `$VALGRIND --tool=memcheck --help >/dev/null 2>&1`; then : + if `$VALGRIND --tool=memcheck --help >/dev/null 2>&1` +then : ax_cv_valgrind_tool_memcheck=yes fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_memcheck" >&5 -$as_echo "$ax_cv_valgrind_tool_memcheck" >&6; } - if test "$ax_cv_valgrind_tool_memcheck" = "no"; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_memcheck" >&5 +printf "%s\n" "$ax_cv_valgrind_tool_memcheck" >&6; } + if test "$ax_cv_valgrind_tool_memcheck" = "no" +then : - if test "$enable_valgrind_memcheck" = "yes"; then : + if test "$enable_valgrind_memcheck" = "yes" +then : as_fn_error $? "Valgrind does not support memcheck; reconfigure with --disable-valgrind-memcheck" "$LINENO" 5 -else - +else case e in #( + e) enable_valgrind_memcheck=no - + ;; +esac fi -else - +else case e in #( + e) enable_valgrind_memcheck=yes - + ;; +esac fi fi - if test "$enable_valgrind_memcheck" = "yes"; then : + if test "$enable_valgrind_memcheck" = "yes" +then : valgrind_enabled_tools="$valgrind_enabled_tools memcheck" @@ -6062,54 +7676,66 @@ fi # Check whether --enable-valgrind-helgrind was given. -if test "${enable_valgrind_helgrind+set}" = set; then : +if test ${enable_valgrind_helgrind+y} +then : enableval=$enable_valgrind_helgrind; enable_valgrind_helgrind=$enableval -else - enable_valgrind_helgrind= +else case e in #( + e) enable_valgrind_helgrind= ;; +esac fi - if test "$enable_valgrind" = "no"; then : + if test "$enable_valgrind" = "no" +then : enable_valgrind_helgrind=no -elif test "$enable_valgrind_helgrind" != "no"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool helgrind" >&5 -$as_echo_n "checking for Valgrind tool helgrind... " >&6; } -if ${ax_cv_valgrind_tool_helgrind+:} false; then : - $as_echo_n "(cached) " >&6 -else - +elif test "$enable_valgrind_helgrind" != "no" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool helgrind" >&5 +printf %s "checking for Valgrind tool helgrind... " >&6; } +if test ${ax_cv_valgrind_tool_helgrind+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_valgrind_tool_helgrind=no - if `$VALGRIND --tool=helgrind --help >/dev/null 2>&1`; then : + if `$VALGRIND --tool=helgrind --help >/dev/null 2>&1` +then : ax_cv_valgrind_tool_helgrind=yes fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_helgrind" >&5 -$as_echo "$ax_cv_valgrind_tool_helgrind" >&6; } - if test "$ax_cv_valgrind_tool_helgrind" = "no"; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_helgrind" >&5 +printf "%s\n" "$ax_cv_valgrind_tool_helgrind" >&6; } + if test "$ax_cv_valgrind_tool_helgrind" = "no" +then : - if test "$enable_valgrind_helgrind" = "yes"; then : + if test "$enable_valgrind_helgrind" = "yes" +then : as_fn_error $? "Valgrind does not support helgrind; reconfigure with --disable-valgrind-helgrind" "$LINENO" 5 -else - +else case e in #( + e) enable_valgrind_helgrind=no - + ;; +esac fi -else - +else case e in #( + e) enable_valgrind_helgrind=yes - + ;; +esac fi fi - if test "$enable_valgrind_helgrind" = "yes"; then : + if test "$enable_valgrind_helgrind" = "yes" +then : valgrind_enabled_tools="$valgrind_enabled_tools helgrind" @@ -6118,54 +7744,66 @@ fi # Check whether --enable-valgrind-drd was given. -if test "${enable_valgrind_drd+set}" = set; then : +if test ${enable_valgrind_drd+y} +then : enableval=$enable_valgrind_drd; enable_valgrind_drd=$enableval -else - enable_valgrind_drd= +else case e in #( + e) enable_valgrind_drd= ;; +esac fi - if test "$enable_valgrind" = "no"; then : + if test "$enable_valgrind" = "no" +then : enable_valgrind_drd=no -elif test "$enable_valgrind_drd" != "no"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool drd" >&5 -$as_echo_n "checking for Valgrind tool drd... " >&6; } -if ${ax_cv_valgrind_tool_drd+:} false; then : - $as_echo_n "(cached) " >&6 -else - +elif test "$enable_valgrind_drd" != "no" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool drd" >&5 +printf %s "checking for Valgrind tool drd... " >&6; } +if test ${ax_cv_valgrind_tool_drd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_valgrind_tool_drd=no - if `$VALGRIND --tool=drd --help >/dev/null 2>&1`; then : + if `$VALGRIND --tool=drd --help >/dev/null 2>&1` +then : ax_cv_valgrind_tool_drd=yes fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_drd" >&5 -$as_echo "$ax_cv_valgrind_tool_drd" >&6; } - if test "$ax_cv_valgrind_tool_drd" = "no"; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_drd" >&5 +printf "%s\n" "$ax_cv_valgrind_tool_drd" >&6; } + if test "$ax_cv_valgrind_tool_drd" = "no" +then : - if test "$enable_valgrind_drd" = "yes"; then : + if test "$enable_valgrind_drd" = "yes" +then : as_fn_error $? "Valgrind does not support drd; reconfigure with --disable-valgrind-drd" "$LINENO" 5 -else - +else case e in #( + e) enable_valgrind_drd=no - + ;; +esac fi -else - +else case e in #( + e) enable_valgrind_drd=yes - + ;; +esac fi fi - if test "$enable_valgrind_drd" = "yes"; then : + if test "$enable_valgrind_drd" = "yes" +then : valgrind_enabled_tools="$valgrind_enabled_tools drd" @@ -6174,54 +7812,66 @@ fi # Check whether --enable-valgrind-sgcheck was given. -if test "${enable_valgrind_sgcheck+set}" = set; then : +if test ${enable_valgrind_sgcheck+y} +then : enableval=$enable_valgrind_sgcheck; enable_valgrind_sgcheck=$enableval -else - enable_valgrind_sgcheck= +else case e in #( + e) enable_valgrind_sgcheck= ;; +esac fi - if test "$enable_valgrind" = "no"; then : + if test "$enable_valgrind" = "no" +then : enable_valgrind_sgcheck=no -elif test "$enable_valgrind_sgcheck" != "no"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool sgcheck" >&5 -$as_echo_n "checking for Valgrind tool sgcheck... " >&6; } -if ${ax_cv_valgrind_tool_sgcheck+:} false; then : - $as_echo_n "(cached) " >&6 -else - +elif test "$enable_valgrind_sgcheck" != "no" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Valgrind tool sgcheck" >&5 +printf %s "checking for Valgrind tool sgcheck... " >&6; } +if test ${ax_cv_valgrind_tool_sgcheck+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_valgrind_tool_sgcheck=no - if `$VALGRIND --tool=exp-sgcheck --help >/dev/null 2>&1`; then : + if `$VALGRIND --tool=exp-sgcheck --help >/dev/null 2>&1` +then : ax_cv_valgrind_tool_sgcheck=yes fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_sgcheck" >&5 -$as_echo "$ax_cv_valgrind_tool_sgcheck" >&6; } - if test "$ax_cv_valgrind_tool_sgcheck" = "no"; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_valgrind_tool_sgcheck" >&5 +printf "%s\n" "$ax_cv_valgrind_tool_sgcheck" >&6; } + if test "$ax_cv_valgrind_tool_sgcheck" = "no" +then : - if test "$enable_valgrind_sgcheck" = "yes"; then : + if test "$enable_valgrind_sgcheck" = "yes" +then : as_fn_error $? "Valgrind does not support sgcheck; reconfigure with --disable-valgrind-sgcheck" "$LINENO" 5 -else - +else case e in #( + e) enable_valgrind_sgcheck=no - + ;; +esac fi -else - +else case e in #( + e) enable_valgrind_sgcheck=yes - + ;; +esac fi fi - if test "$enable_valgrind_sgcheck" = "yes"; then : + if test "$enable_valgrind_sgcheck" = "yes" +then : valgrind_enabled_tools="$valgrind_enabled_tools sgcheck" @@ -6266,7 +7916,7 @@ valgrind_quiet_ = $(valgrind_quiet_$(AM_DEFAULT_VERBOSITY)) valgrind_quiet_0 = --quiet valgrind_v_use = $(valgrind_v_use_$(V)) valgrind_v_use_ = $(valgrind_v_use_$(AM_DEFAULT_VERBOSITY)) -valgrind_v_use_0 = @echo " USE " $(patsubst check-valgrind-%,%,$''@):; +valgrind_v_use_0 = @echo " USE " $(patsubst check-valgrind-%-local,%,$''@):; # Support running with and without libtool. ifneq ($(LIBTOOL),) @@ -6276,12 +7926,12 @@ valgrind_lt = endif # Use recursive makes in order to ignore errors during check -check-valgrind: +check-valgrind-local: ifeq ($(VALGRIND_ENABLED),yes) $(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) -k \ $(foreach tool, $(valgrind_enabled_tools), check-valgrind-$(tool)) else - @echo "Need to use GNU make and reconfigure with --enable-valgrind" + @echo "Need to reconfigure with --enable-valgrind" endif # Valgrind running @@ -6295,14 +7945,16 @@ VALGRIND_LOG_COMPILER = \ $(valgrind_lt) \ $(VALGRIND) $(VALGRIND_SUPPRESSIONS) --error-exitcode=1 $(VALGRIND_FLAGS) -define valgrind_tool_rule = -check-valgrind-$(1): +define valgrind_tool_rule +check-valgrind-$(1)-local: ifeq ($$(VALGRIND_ENABLED)-$$(ENABLE_VALGRIND_$(1)),yes-yes) +ifneq ($$(TESTS),) $$(valgrind_v_use)$$(MAKE) check-TESTS \ TESTS_ENVIRONMENT="$$(VALGRIND_TESTS_ENVIRONMENT)" \ LOG_COMPILER="$$(VALGRIND_LOG_COMPILER)" \ LOG_FLAGS="$$(valgrind_$(1)_flags)" \ TEST_SUITE_LOG=test-suite-$(1).log +endif else ifeq ($$(VALGRIND_ENABLED),yes) @echo "Need to reconfigure with --enable-valgrind-$(1)" else @@ -6318,939 +7970,650 @@ A''M_DISTCHECK_CONFIGURE_FLAGS += --disable-valgrind MOSTLYCLEANFILES ?= MOSTLYCLEANFILES += $(valgrind_log_files) -.PHONY: check-valgrind $(add-prefix check-valgrind-,$(valgrind_tools)) +.PHONY: check-valgrind $(addprefix check-valgrind-,$(valgrind_tools)) ' - if test "$enable_valgrind" != "yes"; then : - - VALGRIND_CHECK_RULES=' -check-valgrind: - @echo "Need to use GNU make and reconfigure with --enable-valgrind"' -fi + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for variable-length arrays" >&5 +printf %s "checking for variable-length arrays... " >&6; } +if test ${ac_cv_c_vararrays+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #ifndef __STDC_NO_VLA__ + #error __STDC_NO_VLA__ not defined + #endif - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 -$as_echo_n "checking for $CC option to accept ISO C99... " >&6; } -if ${ac_cv_prog_cc_c99+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_prog_cc_c99=no -ac_save_CC=$CC -cat confdefs.h - <<_ACEOF >conftest.$ac_ext +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_c_vararrays='no: __STDC_NO_VLA__ is defined' +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <stdarg.h> -#include <stdbool.h> -#include <stdlib.h> -#include <wchar.h> -#include <stdio.h> +/* Test for VLA support. This test is partly inspired + from examples in the C standard. Use at least two VLA + functions to detect the GCC 3.4.3 bug described in: + https://lists.gnu.org/archive/html/bug-gnulib/2014-08/msg00014.html + */ + #ifdef __STDC_NO_VLA__ + syntax error; + #else + extern int n; + int B[100]; + int fvla (int m, int C[m][m]); + + int + simple (int count, int all[static count]) + { + return all[count - 1]; + } + + int + fvla (int m, int C[m][m]) + { + typedef int VLA[m][m]; + VLA x; + int D[m]; + static int (*q)[m] = &B; + int (*s)[n] = q; + return C && &x[0][0] == &D[0] && &D[0] == s[0]; + } + #endif -// Check varargs macros. These examples are taken from C99 6.10.3.5. -#define debug(...) fprintf (stderr, __VA_ARGS__) -#define showlist(...) puts (#__VA_ARGS__) -#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) -static void -test_varargs_macros (void) +int +main (void) { - int x = 1234; - int y = 5678; - debug ("Flag"); - debug ("X = %d\n", x); - showlist (The first, second, and third items.); - report (x>y, "x is %d but y is %d", x, y); -} -// Check long long types. -#define BIG64 18446744073709551615ull -#define BIG32 4294967295ul -#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) -#if !BIG_OK - your preprocessor is broken; -#endif -#if BIG_OK -#else - your preprocessor is broken; -#endif -static long long int bignum = -9223372036854775807LL; -static unsigned long long int ubignum = BIG64; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_c_vararrays=yes +else case e in #( + e) ac_cv_c_vararrays=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_vararrays" >&5 +printf "%s\n" "$ac_cv_c_vararrays" >&6; } + if test "$ac_cv_c_vararrays" = yes; then -struct incomplete_array -{ - int datasize; - double data[]; -}; +printf "%s\n" "#define HAVE_C_VARARRAYS 1" >>confdefs.h -struct named_init { - int number; - const wchar_t *name; - double average; -}; + elif test "$ac_cv_c_vararrays" = no; then -typedef const char *ccp; +printf "%s\n" "#define __STDC_NO_VLA__ 1" >>confdefs.h -static inline int -test_restrict (ccp restrict text) -{ - // See if C++-style comments work. - // Iterate through items via the restricted pointer. - // Also check for declarations in for loops. - for (unsigned int i = 0; *(text+i) != '\0'; ++i) - continue; - return 0; -} + fi -// Check varargs and va_copy. -static void -test_varargs (const char *format, ...) -{ - va_list args; - va_start (args, format); - va_list args_copy; - va_copy (args_copy, args); - const char *str; - int number; - float fnumber; - while (*format) - { - switch (*format++) - { - case 's': // string - str = va_arg (args_copy, const char *); - break; - case 'd': // int - number = va_arg (args_copy, int); - break; - case 'f': // float - fnumber = va_arg (args_copy, double); - break; - default: - break; - } - } - va_end (args_copy); - va_end (args); -} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __wasi__ defined" >&5 +printf %s "checking for __wasi__ defined... " >&6; } +if test ${ac_cv_defined___wasi__+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ int -main () +main (void) { - // Check bool. - _Bool success = false; + #ifdef __wasi__ + int ok; + (void)ok; + #else + choke me + #endif - // Check restrict. - if (test_restrict ("String literal") == 0) - success = true; - char *restrict newvar = "Another string"; - - // Check varargs. - test_varargs ("s, d' f .", "string", 65, 34.234); - test_varargs_macros (); - - // Check flexible array members. - struct incomplete_array *ia = - malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); - ia->datasize = 10; - for (int i = 0; i < ia->datasize; ++i) - ia->data[i] = i * 1.234; - - // Check named initializers. - struct named_init ni = { - .number = 34, - .name = L"Test wide string", - .average = 543.34343, - }; - - ni.number = 58; - - int dynamic_array[ni.number]; - dynamic_array[ni.number - 1] = 543; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_defined___wasi__=yes +else case e in #( + e) ac_cv_defined___wasi__=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_defined___wasi__" >&5 +printf "%s\n" "$ac_cv_defined___wasi__" >&6; } +if test $ac_cv_defined___wasi__ != "no" +then : + WASI="yes" +fi - // work around unused variable warnings - return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' - || dynamic_array[ni.number - 1] != 543); +case $host_os in #( + linux-gnu) : + + ac_save_cflags=$CFLAGS + ac_cwerror_flag=yes + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -Werror" >&5 +printf %s "checking whether C compiler accepts -Werror... " >&6; } +if test ${ax_cv_check_cflags___Werror+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -Werror" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99 -do - CC="$ac_save_CC $ac_arg" - if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_prog_cc_c99=$ac_arg +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___Werror=yes +else case e in #( + e) ax_cv_check_cflags___Werror=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext - test "x$ac_cv_prog_cc_c99" != "xno" && break -done -rm -f conftest.$ac_ext -CC=$ac_save_CC - +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac fi -# AC_CACHE_VAL -case "x$ac_cv_prog_cc_c99" in - x) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 -$as_echo "none needed" >&6; } ;; - xno) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 -$as_echo "unsupported" >&6; } ;; - *) - CC="$CC $ac_cv_prog_cc_c99" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 -$as_echo "$ac_cv_prog_cc_c99" >&6; } ;; +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___Werror" >&5 +printf "%s\n" "$ax_cv_check_cflags___Werror" >&6; } +if test "x$ax_cv_check_cflags___Werror" = xyes +then : + CFLAGS="$CFLAGS -Werror" +else case e in #( + e) : ;; esac -if test "x$ac_cv_prog_cc_c99" != xno; then : - fi - -# By default we simply use the C compiler to build assembly code. - -test "${CCAS+set}" = set || CCAS=$CC -test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS - + ax_add_fortify_3_failed= + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to add -D_FORTIFY_SOURCE=3 to CPPFLAGS" >&5 +printf %s "checking whether to add -D_FORTIFY_SOURCE=3 to CPPFLAGS... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -depcc="$CCAS" am_compiler_list= +int +main (void) +{ -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 -$as_echo_n "checking dependency style of $depcc... " >&6; } -if ${am_cv_CCAS_dependencies_compiler_type+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then - # We make a subdir and do the tests there. Otherwise we can end up - # making bogus files that we don't know about and never remove. For - # instance it was reported that on HP-UX the gcc test will end up - # making a dummy file named 'D' -- because '-MD' means "put the output - # in D". - rm -rf conftest.dir - mkdir conftest.dir - # Copy depcomp to subdir because otherwise we won't find it if we're - # using a relative directory. - cp "$am_depcomp" conftest.dir - cd conftest.dir - # We will build objects and dependencies in a subdirectory because - # it helps to detect inapplicable dependency modes. For instance - # both Tru64's cc and ICC support -MD to output dependencies as a - # side effect of compilation, but ICC will put the dependencies in - # the current directory while Tru64 will put them in the object - # directory. - mkdir sub + #ifndef _FORTIFY_SOURCE + return 0; + #else + _FORTIFY_SOURCE_already_defined; + #endif - am_cv_CCAS_dependencies_compiler_type=none - if test "$am_compiler_list" = ""; then - am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` - fi - am__universal=false + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - for depmode in $am_compiler_list; do - # Setup a source with many dependencies, because some compilers - # like to wrap large dependency lists on column 80 (with \), and - # we should not choose a depcomp mode which is confused by this. - # - # We need to recreate these files for each test, as the compiler may - # overwrite some of them when testing with obscure command lines. - # This happens at least with the AIX C compiler. - : > sub/conftest.c - for i in 1 2 3 4 5 6; do - echo '#include "conftst'$i'.h"' >> sub/conftest.c - # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with - # Solaris 10 /bin/sh. - echo '/* dummy */' > sub/conftst$i.h - done - echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf - # We check with '-c' and '-o' for the sake of the "dashmstdout" - # mode. It turns out that the SunPro C++ compiler does not properly - # handle '-M -o', and we need to detect this. Also, some Intel - # versions had trouble with output in subdirs. - am__obj=sub/conftest.${OBJEXT-o} - am__minus_obj="-o $am__obj" - case $depmode in - gcc) - # This depmode causes a compiler race in universal mode. - test "$am__universal" = false || continue - ;; - nosideeffect) - # After this tag, mechanisms are not by side-effect, so they'll - # only be used when explicitly requested. - if test "x$enable_dependency_tracking" = xyes; then - continue - else - break - fi - ;; - msvc7 | msvc7msys | msvisualcpp | msvcmsys) - # This compiler won't grok '-c -o', but also, the minuso test has - # not run yet. These depmodes are late enough in the game, and - # so weak that their functioning should not be impacted. - am__obj=conftest.${OBJEXT-o} - am__minus_obj= - ;; - none) break ;; - esac - if depmode=$depmode \ - source=sub/conftest.c object=$am__obj \ - depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ - $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ - >/dev/null 2>conftest.err && - grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && - grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && - grep $am__obj sub/conftest.Po > /dev/null 2>&1 && - ${MAKE-make} -s -f confmf > /dev/null 2>&1; then - # icc doesn't choke on unknown options, it will just issue warnings - # or remarks (even with -Werror). So we grep stderr for any message - # that says an option was ignored or not supported. - # When given -MP, icc 7.0 and 7.1 complain thusly: - # icc: Command line warning: ignoring option '-M'; no argument required - # The diagnosis changed in icc 8.0: - # icc: Command line remark: option '-MP' not supported - if (grep 'ignoring option' conftest.err || - grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else - am_cv_CCAS_dependencies_compiler_type=$depmode - break - fi - fi - done + #define _FORTIFY_SOURCE 3 + #include <string.h> + int main(void) { + char *s = " "; + strcpy(s, "x"); + return strlen(s)-1; + } - cd .. - rm -rf conftest.dir -else - am_cv_CCAS_dependencies_compiler_type=none -fi +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + CFLAGS=$ac_save_cflags + CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=3" + +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ax_add_fortify_3_failed=1 + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CCAS_dependencies_compiler_type" >&5 -$as_echo "$am_cv_CCAS_dependencies_compiler_type" >&6; } -CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type - - if - test "x$enable_dependency_tracking" != xno \ - && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then - am__fastdepCCAS_TRUE= - am__fastdepCCAS_FALSE='#' -else - am__fastdepCCAS_TRUE='#' - am__fastdepCCAS_FALSE= +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ax_add_fortify_3_failed=1 + ;; +esac fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 -$as_echo_n "checking for ANSI C header files... " >&6; } -if ${ac_cv_header_stdc+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + if test -n "$ax_add_fortify_3_failed" + then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to add -D_FORTIFY_SOURCE=2 to CPPFLAGS" >&5 +printf %s "checking whether to add -D_FORTIFY_SOURCE=2 to CPPFLAGS... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <stdlib.h> -#include <stdarg.h> -#include <string.h> -#include <float.h> + int -main () +main (void) { + #ifndef _FORTIFY_SOURCE + return 0; + #else + _FORTIFY_SOURCE_already_defined; + #endif + + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_header_stdc=yes -else - ac_cv_header_stdc=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - -if test $ac_cv_header_stdc = yes; then - # SunOS 4.x string.h does not declare mem*, contrary to ANSI. +if ac_fn_c_try_link "$LINENO" +then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <string.h> - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then : -else - ac_cv_header_stdc=no -fi -rm -f conftest* -fi + #define _FORTIFY_SOURCE 2 + #include <string.h> + int main(void) { + char *s = " "; + strcpy(s, "x"); + return strlen(s)-1; + } -if test $ac_cv_header_stdc = yes; then - # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <stdlib.h> _ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : - -else - ac_cv_header_stdc=no +if ac_fn_c_try_link "$LINENO" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + CFLAGS=$ac_save_cflags + CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=2" + +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + CFLAGS=$ac_save_cflags + ;; +esac fi -rm -f conftest* - +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + CFLAGS=$ac_save_cflags + ;; +esac fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + fi + ;; #( + *) : + ;; +esac -if test $ac_cv_header_stdc = yes; then - # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. - if test "$cross_compiling" = yes; then : - : -else +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fvisibility=hidden" >&5 +printf %s "checking whether C compiler accepts -fvisibility=hidden... " >&6; } +if test ${ax_cv_check_cflags___fvisibility_hidden+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -fvisibility=hidden" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include <ctype.h> -#include <stdlib.h> -#if ((' ' & 0x0FF) == 0x020) -# define ISLOWER(c) ('a' <= (c) && (c) <= 'z') -# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) -#else -# define ISLOWER(c) \ - (('a' <= (c) && (c) <= 'i') \ - || ('j' <= (c) && (c) <= 'r') \ - || ('s' <= (c) && (c) <= 'z')) -# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) -#endif - -#define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) +#include <time.h> int -main () +main (void) { - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : - -else - ac_cv_header_stdc=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - -fi +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___fvisibility_hidden=yes +else case e in #( + e) ax_cv_check_cflags___fvisibility_hidden=no ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 -$as_echo "$ac_cv_header_stdc" >&6; } -if test $ac_cv_header_stdc = yes; then - -$as_echo "#define STDC_HEADERS 1" >>confdefs.h - +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac fi - -# On IRIX 5.3, sys/types and inttypes.h are conflicting. -for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ - inttypes.h stdint.h unistd.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default -" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fvisibility_hidden" >&5 +printf "%s\n" "$ax_cv_check_cflags___fvisibility_hidden" >&6; } +if test "x$ax_cv_check_cflags___fvisibility_hidden" = xyes +then : + CFLAGS="$CFLAGS -fvisibility=hidden" +else case e in #( + e) : ;; +esac fi -done - +case $host_os in #( + cygwin*|mingw*|msys|pw32*|cegcc*|eabi*) : + ;; #( + *) : - ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" -if test "x$ac_cv_header_minix_config_h" = xyes; then : - MINIX=yes -else - MINIX= -fi - - - if test "$MINIX" = yes; then - -$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h - - -$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h - - -$as_echo "#define _MINIX 1" >>confdefs.h - - fi - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 -$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } -if ${ac_cv_safe_to_define___extensions__+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -# define __EXTENSIONS__ 1 - $ac_includes_default -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_safe_to_define___extensions__=yes -else - ac_cv_safe_to_define___extensions__=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 -$as_echo "$ac_cv_safe_to_define___extensions__" >&6; } - test $ac_cv_safe_to_define___extensions__ = yes && - $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h - - $as_echo "#define _ALL_SOURCE 1" >>confdefs.h - - $as_echo "#define _GNU_SOURCE 1" >>confdefs.h - - $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h - - $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for variable-length arrays" >&5 -$as_echo_n "checking for variable-length arrays... " >&6; } -if ${ac_cv_c_vararrays+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ -static int x; char a[++x]; a[sizeof a - 1] = 0; return a[0]; - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_c_vararrays=yes -else - ac_cv_c_vararrays=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_vararrays" >&5 -$as_echo "$ac_cv_c_vararrays" >&6; } - if test $ac_cv_c_vararrays = yes; then - -$as_echo "#define HAVE_C_VARARRAYS 1" >>confdefs.h - - fi - - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for __wasi__ defined" >&5 -$as_echo_n "checking for __wasi__ defined... " >&6; } -if ${ac_cv_defined___wasi__+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - #ifdef __wasi__ - int ok; - #else - choke me - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_defined___wasi__=yes -else - ac_cv_defined___wasi__=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_defined___wasi__" >&5 -$as_echo "$ac_cv_defined___wasi__" >&6; } -if test $ac_cv_defined___wasi__ != "no"; then : - WASI="yes" -fi - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FORTIFY_SOURCE defined" >&5 -$as_echo_n "checking for _FORTIFY_SOURCE defined... " >&6; } -if ${ac_cv_defined__FORTIFY_SOURCE+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - #ifdef _FORTIFY_SOURCE - int ok; - #else - choke me - #endif - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - ac_cv_defined__FORTIFY_SOURCE=yes -else - ac_cv_defined__FORTIFY_SOURCE=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_defined__FORTIFY_SOURCE" >&5 -$as_echo "$ac_cv_defined__FORTIFY_SOURCE" >&6; } -if test $ac_cv_defined__FORTIFY_SOURCE != "no"; then : - -else - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -D_FORTIFY_SOURCE=2" >&5 -$as_echo_n "checking whether C compiler accepts -D_FORTIFY_SOURCE=2... " >&6; } -if ${ax_cv_check_cflags___D_FORTIFY_SOURCE_2+:} false; then : - $as_echo_n "(cached) " >&6 -else - - ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -D_FORTIFY_SOURCE=2" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <time.h> -int -main () -{ -time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___D_FORTIFY_SOURCE_2=yes -else - ax_cv_check_cflags___D_FORTIFY_SOURCE_2=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___D_FORTIFY_SOURCE_2" >&5 -$as_echo "$ax_cv_check_cflags___D_FORTIFY_SOURCE_2" >&6; } -if test "x$ax_cv_check_cflags___D_FORTIFY_SOURCE_2" = xyes; then : - CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=2" -else - : -fi - - -fi - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fvisibility=hidden" >&5 -$as_echo_n "checking whether C compiler accepts -fvisibility=hidden... " >&6; } -if ${ax_cv_check_cflags___fvisibility_hidden+:} false; then : - $as_echo_n "(cached) " >&6 -else - - ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS -fvisibility=hidden" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include <time.h> -int -main () -{ -time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x - ; - return 0; -} -_ACEOF -if ac_fn_c_try_link "$LINENO"; then : - ax_cv_check_cflags___fvisibility_hidden=yes -else - ax_cv_check_cflags___fvisibility_hidden=no -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fvisibility_hidden" >&5 -$as_echo "$ax_cv_check_cflags___fvisibility_hidden" >&6; } -if test "x$ax_cv_check_cflags___fvisibility_hidden" = xyes; then : - CFLAGS="$CFLAGS -fvisibility=hidden" -else - : -fi - - -case $host_os in #( - cygwin*|mingw*|msys|pw32*|cegcc*) : - ;; #( - *) : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fPIC" >&5 -$as_echo_n "checking whether C compiler accepts -fPIC... " >&6; } -if ${ax_cv_check_cflags___fPIC+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fPIC" >&5 +printf %s "checking whether C compiler accepts -fPIC... " >&6; } +if test ${ax_cv_check_cflags___fPIC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fPIC" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fPIC=yes -else - ax_cv_check_cflags___fPIC=no +else case e in #( + e) ax_cv_check_cflags___fPIC=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fPIC" >&5 -$as_echo "$ax_cv_check_cflags___fPIC" >&6; } -if test "x$ax_cv_check_cflags___fPIC" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fPIC" >&5 +printf "%s\n" "$ax_cv_check_cflags___fPIC" >&6; } +if test "x$ax_cv_check_cflags___fPIC" = xyes +then : CFLAGS="$CFLAGS -fPIC" -else - : +else case e in #( + e) : ;; +esac fi ;; esac -if test "$enable_pie" != "no"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fPIE" >&5 -$as_echo_n "checking whether C compiler accepts -fPIE... " >&6; } -if ${ax_cv_check_cflags___fPIE+:} false; then : - $as_echo_n "(cached) " >&6 -else +if test "$enable_pie" != "no" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fPIE" >&5 +printf %s "checking whether C compiler accepts -fPIE... " >&6; } +if test ${ax_cv_check_cflags___fPIE+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fPIE" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fPIE=yes -else - ax_cv_check_cflags___fPIE=no +else case e in #( + e) ax_cv_check_cflags___fPIE=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fPIE" >&5 -$as_echo "$ax_cv_check_cflags___fPIE" >&6; } -if test "x$ax_cv_check_cflags___fPIE" = xyes; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -pie" >&5 -$as_echo_n "checking whether the linker accepts -pie... " >&6; } -if ${ax_cv_check_ldflags___pie+:} false; then : - $as_echo_n "(cached) " >&6 -else - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fPIE" >&5 +printf "%s\n" "$ax_cv_check_cflags___fPIE" >&6; } +if test "x$ax_cv_check_cflags___fPIE" = xyes +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -pie" >&5 +printf %s "checking whether the linker accepts -pie... " >&6; } +if test ${ax_cv_check_ldflags___pie+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -pie" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___pie=yes -else - ax_cv_check_ldflags___pie=no +else case e in #( + e) ax_cv_check_ldflags___pie=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___pie" >&5 -$as_echo "$ax_cv_check_ldflags___pie" >&6; } -if test "x$ax_cv_check_ldflags___pie" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___pie" >&5 +printf "%s\n" "$ax_cv_check_ldflags___pie" >&6; } +if test "x$ax_cv_check_ldflags___pie" = xyes +then : CFLAGS="$CFLAGS -fPIE" LDFLAGS="$LDFLAGS -pie" -else - : +else case e in #( + e) : ;; +esac fi -else - : +else case e in #( + e) : ;; +esac fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-strict-aliasing" >&5 -$as_echo_n "checking whether C compiler accepts -fno-strict-aliasing... " >&6; } -if ${ax_cv_check_cflags___fno_strict_aliasing+:} false; then : - $as_echo_n "(cached) " >&6 -else - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-strict-aliasing" >&5 +printf %s "checking whether C compiler accepts -fno-strict-aliasing... " >&6; } +if test ${ax_cv_check_cflags___fno_strict_aliasing+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fno-strict-aliasing" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fno_strict_aliasing=yes -else - ax_cv_check_cflags___fno_strict_aliasing=no +else case e in #( + e) ax_cv_check_cflags___fno_strict_aliasing=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_strict_aliasing" >&5 -$as_echo "$ax_cv_check_cflags___fno_strict_aliasing" >&6; } -if test "x$ax_cv_check_cflags___fno_strict_aliasing" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_strict_aliasing" >&5 +printf "%s\n" "$ax_cv_check_cflags___fno_strict_aliasing" >&6; } +if test "x$ax_cv_check_cflags___fno_strict_aliasing" = xyes +then : CFLAGS="$CFLAGS -fno-strict-aliasing" -else - : +else case e in #( + e) : ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-strict-overflow" >&5 -$as_echo_n "checking whether C compiler accepts -fno-strict-overflow... " >&6; } -if ${ax_cv_check_cflags___fno_strict_overflow+:} false; then : - $as_echo_n "(cached) " >&6 -else - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-strict-overflow" >&5 +printf %s "checking whether C compiler accepts -fno-strict-overflow... " >&6; } +if test ${ax_cv_check_cflags___fno_strict_overflow+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fno-strict-overflow" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fno_strict_overflow=yes -else - ax_cv_check_cflags___fno_strict_overflow=no +else case e in #( + e) ax_cv_check_cflags___fno_strict_overflow=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_strict_overflow" >&5 -$as_echo "$ax_cv_check_cflags___fno_strict_overflow" >&6; } -if test "x$ax_cv_check_cflags___fno_strict_overflow" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_strict_overflow" >&5 +printf "%s\n" "$ax_cv_check_cflags___fno_strict_overflow" >&6; } +if test "x$ax_cv_check_cflags___fno_strict_overflow" = xyes +then : CFLAGS="$CFLAGS -fno-strict-overflow" -else - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fwrapv" >&5 -$as_echo_n "checking whether C compiler accepts -fwrapv... " >&6; } -if ${ax_cv_check_cflags___fwrapv+:} false; then : - $as_echo_n "(cached) " >&6 -else - +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fwrapv" >&5 +printf %s "checking whether C compiler accepts -fwrapv... " >&6; } +if test ${ax_cv_check_cflags___fwrapv+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fwrapv" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fwrapv=yes -else - ax_cv_check_cflags___fwrapv=no +else case e in #( + e) ax_cv_check_cflags___fwrapv=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fwrapv" >&5 -$as_echo "$ax_cv_check_cflags___fwrapv" >&6; } -if test "x$ax_cv_check_cflags___fwrapv" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fwrapv" >&5 +printf "%s\n" "$ax_cv_check_cflags___fwrapv" >&6; } +if test "x$ax_cv_check_cflags___fwrapv" = xyes +then : CFLAGS="$CFLAGS -fwrapv" -else - : +else case e in #( + e) : ;; +esac fi - + ;; +esac fi -if test "$GCC" = "yes" ; then : +if test "$GCC" = "yes" +then : case $host_cpu in #( i?86|amd64|x86_64) : @@ -7264,49 +8627,58 @@ if test "$GCC" = "yes" ; then : int main(void) { return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - -else - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -flax-vector-conversions" >&5 -$as_echo_n "checking whether C compiler accepts -flax-vector-conversions... " >&6; } -if ${ax_cv_check_cflags___flax_vector_conversions+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_compile "$LINENO" +then : + +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -flax-vector-conversions" >&5 +printf %s "checking whether C compiler accepts -flax-vector-conversions... " >&6; } +if test ${ax_cv_check_cflags___flax_vector_conversions+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -flax-vector-conversions" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___flax_vector_conversions=yes -else - ax_cv_check_cflags___flax_vector_conversions=no +else case e in #( + e) ax_cv_check_cflags___flax_vector_conversions=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___flax_vector_conversions" >&5 -$as_echo "$ax_cv_check_cflags___flax_vector_conversions" >&6; } -if test "x$ax_cv_check_cflags___flax_vector_conversions" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___flax_vector_conversions" >&5 +printf "%s\n" "$ax_cv_check_cflags___flax_vector_conversions" >&6; } +if test "x$ax_cv_check_cflags___flax_vector_conversions" = xyes +then : CFLAGS="$CFLAGS -flax-vector-conversions" -else - : +else case e in #( + e) : ;; +esac fi - + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; #( *) : @@ -7318,9 +8690,11 @@ fi LIBTOOL_OLD_FLAGS="$LIBTOOL_EXTRA_FLAGS" LIBTOOL_EXTRA_FLAGS="$LIBTOOL_EXTRA_FLAGS -version-info $SODIUM_LIBRARY_VERSION" # Check whether --enable-soname-versions was given. -if test "${enable_soname_versions+set}" = set; then : +if test ${enable_soname_versions+y} +then : enableval=$enable_soname_versions; - if test "x$enableval" = "xno"; then : + if test "x$enableval" = "xno" +then : LIBTOOL_EXTRA_FLAGS="$LIBTOOL_OLD_FLAGS -avoid-version" @@ -7333,112 +8707,130 @@ fi case $host_os in #( cygwin*|mingw*|msys|pw32*|cegcc*) : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--dynamicbase" >&5 -$as_echo_n "checking whether the linker accepts -Wl,--dynamicbase... " >&6; } -if ${ax_cv_check_ldflags___Wl___dynamicbase+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--dynamicbase" >&5 +printf %s "checking whether the linker accepts -Wl,--dynamicbase... " >&6; } +if test ${ax_cv_check_ldflags___Wl___dynamicbase+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,--dynamicbase" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl___dynamicbase=yes -else - ax_cv_check_ldflags___Wl___dynamicbase=no +else case e in #( + e) ax_cv_check_ldflags___Wl___dynamicbase=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___dynamicbase" >&5 -$as_echo "$ax_cv_check_ldflags___Wl___dynamicbase" >&6; } -if test "x$ax_cv_check_ldflags___Wl___dynamicbase" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___dynamicbase" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl___dynamicbase" >&6; } +if test "x$ax_cv_check_ldflags___Wl___dynamicbase" = xyes +then : LDFLAGS="$LDFLAGS -Wl,--dynamicbase" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--high-entropy-va" >&5 -$as_echo_n "checking whether the linker accepts -Wl,--high-entropy-va... " >&6; } -if ${ax_cv_check_ldflags___Wl___high_entropy_va+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--high-entropy-va" >&5 +printf %s "checking whether the linker accepts -Wl,--high-entropy-va... " >&6; } +if test ${ax_cv_check_ldflags___Wl___high_entropy_va+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,--high-entropy-va" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl___high_entropy_va=yes -else - ax_cv_check_ldflags___Wl___high_entropy_va=no +else case e in #( + e) ax_cv_check_ldflags___Wl___high_entropy_va=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___high_entropy_va" >&5 -$as_echo "$ax_cv_check_ldflags___Wl___high_entropy_va" >&6; } -if test "x$ax_cv_check_ldflags___Wl___high_entropy_va" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___high_entropy_va" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl___high_entropy_va" >&6; } +if test "x$ax_cv_check_ldflags___Wl___high_entropy_va" = xyes +then : LDFLAGS="$LDFLAGS -Wl,--high-entropy-va" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--nxcompat" >&5 -$as_echo_n "checking whether the linker accepts -Wl,--nxcompat... " >&6; } -if ${ax_cv_check_ldflags___Wl___nxcompat+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,--nxcompat" >&5 +printf %s "checking whether the linker accepts -Wl,--nxcompat... " >&6; } +if test ${ax_cv_check_ldflags___Wl___nxcompat+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,--nxcompat" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl___nxcompat=yes -else - ax_cv_check_ldflags___Wl___nxcompat=no +else case e in #( + e) ax_cv_check_ldflags___Wl___nxcompat=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___nxcompat" >&5 -$as_echo "$ax_cv_check_ldflags___Wl___nxcompat" >&6; } -if test "x$ax_cv_check_ldflags___Wl___nxcompat" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl___nxcompat" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl___nxcompat" >&6; } +if test "x$ax_cv_check_ldflags___Wl___nxcompat" = xyes +then : LDFLAGS="$LDFLAGS -Wl,--nxcompat" -else - : +else case e in #( + e) : ;; +esac fi ;; #( @@ -7447,44 +8839,51 @@ fi esac case $host_os in #( - cygwin*|mingw*|msys|pw32*|cegcc*) : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-asynchronous-unwind-tables" >&5 -$as_echo_n "checking whether C compiler accepts -fno-asynchronous-unwind-tables... " >&6; } -if ${ax_cv_check_cflags___fno_asynchronous_unwind_tables+:} false; then : - $as_echo_n "(cached) " >&6 -else - + cygwin*|mingw*|msys|pw32*|cegcc*|eabi*) : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fno-asynchronous-unwind-tables" >&5 +printf %s "checking whether C compiler accepts -fno-asynchronous-unwind-tables... " >&6; } +if test ${ax_cv_check_cflags___fno_asynchronous_unwind_tables+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fno-asynchronous-unwind-tables" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fno_asynchronous_unwind_tables=yes -else - ax_cv_check_cflags___fno_asynchronous_unwind_tables=no +else case e in #( + e) ax_cv_check_cflags___fno_asynchronous_unwind_tables=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_asynchronous_unwind_tables" >&5 -$as_echo "$ax_cv_check_cflags___fno_asynchronous_unwind_tables" >&6; } -if test "x$ax_cv_check_cflags___fno_asynchronous_unwind_tables" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fno_asynchronous_unwind_tables" >&5 +printf "%s\n" "$ax_cv_check_cflags___fno_asynchronous_unwind_tables" >&6; } +if test "x$ax_cv_check_cflags___fno_asynchronous_unwind_tables" = xyes +then : CFLAGS="$CFLAGS -fno-asynchronous-unwind-tables" -else - : +else case e in #( + e) : ;; +esac fi ;; #( @@ -7492,86 +8891,100 @@ fi ;; esac -if test "x$enable_ssp" != "xno"; then : +if test "x$enable_ssp" != "xno" +then : case $host_os in #( - cygwin*|mingw*|msys|pw32*|cegcc*|haiku|none) : + solaris*|cygwin*|mingw*|msys|pw32*|cegcc*|haiku|none|eabi*) : ;; #( *) : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstack-protector" >&5 -$as_echo_n "checking whether C compiler accepts -fstack-protector... " >&6; } -if ${ax_cv_check_cflags___fstack_protector+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -fstack-protector" >&5 +printf %s "checking whether C compiler accepts -fstack-protector... " >&6; } +if test ${ax_cv_check_cflags___fstack_protector+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -fstack-protector" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___fstack_protector=yes -else - ax_cv_check_cflags___fstack_protector=no +else case e in #( + e) ax_cv_check_cflags___fstack_protector=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fstack_protector" >&5 -$as_echo "$ax_cv_check_cflags___fstack_protector" >&6; } -if test "x$ax_cv_check_cflags___fstack_protector" = xyes; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -fstack-protector" >&5 -$as_echo_n "checking whether the linker accepts -fstack-protector... " >&6; } -if ${ax_cv_check_ldflags___fstack_protector+:} false; then : - $as_echo_n "(cached) " >&6 -else - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___fstack_protector" >&5 +printf "%s\n" "$ax_cv_check_cflags___fstack_protector" >&6; } +if test "x$ax_cv_check_cflags___fstack_protector" = xyes +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -fstack-protector" >&5 +printf %s "checking whether the linker accepts -fstack-protector... " >&6; } +if test ${ax_cv_check_ldflags___fstack_protector+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -fstack-protector" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___fstack_protector=yes -else - ax_cv_check_ldflags___fstack_protector=no +else case e in #( + e) ax_cv_check_ldflags___fstack_protector=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___fstack_protector" >&5 -$as_echo "$ax_cv_check_ldflags___fstack_protector" >&6; } -if test "x$ax_cv_check_ldflags___fstack_protector" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___fstack_protector" >&5 +printf "%s\n" "$ax_cv_check_ldflags___fstack_protector" >&6; } +if test "x$ax_cv_check_ldflags___fstack_protector" = xyes +then : CFLAGS="$CFLAGS -fstack-protector" -else - : +else case e in #( + e) : ;; +esac fi -else - : +else case e in #( + e) : ;; +esac fi ;; #( @@ -7581,1299 +8994,1671 @@ esac fi - - -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CFLAGS -Wall" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -Wall" >&5 -$as_echo_n "checking whether C compiler accepts $CFLAGS -Wall... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CFLAGS -Wall" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -Wall" >&5 +printf %s "checking whether C compiler accepts $CFLAGS -Wall... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CFLAGS -Wall" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CFLAGS -Wall" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CFLAGS -Wextra" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -Wextra" >&5 -$as_echo_n "checking whether C compiler accepts $CFLAGS -Wextra... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CFLAGS -Wno-deprecated-declarations" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -Wno-deprecated-declarations" >&5 +printf %s "checking whether C compiler accepts $CFLAGS -Wno-deprecated-declarations... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS $CFLAGS -Wno-deprecated-declarations" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + eval "$as_CACHEVAR=yes" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +eval ac_res=\$$as_CACHEVAR + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : + CFLAGS="$CFLAGS -Wno-deprecated-declarations" +else case e in #( + e) : ;; +esac +fi +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CFLAGS -Wno-unknown-pragmas" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -Wno-unknown-pragmas" >&5 +printf %s "checking whether C compiler accepts $CFLAGS -Wno-unknown-pragmas... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS - CFLAGS="$CFLAGS $CFLAGS -Wextra" + CFLAGS="$CFLAGS $CFLAGS -Wno-unknown-pragmas" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : - CWFLAGS="$CFLAGS -Wextra" -else - : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : + CFLAGS="$CFLAGS -Wno-unknown-pragmas" +else case e in #( + e) : ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang" >&5 -$as_echo_n "checking for clang... " >&6; } + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clang" >&5 +printf %s "checking for clang... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { #ifndef __clang__ -#error Not clang +#error Not clang nor zig cc #endif ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wno-unknown-warning-option" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-unknown-warning-option" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wno-unknown-warning-option... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_compile "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wno-unknown-warning-option" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-unknown-warning-option" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wno-unknown-warning-option... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wno-unknown-warning-option" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wno-unknown-warning-option" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wextra" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wextra" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wextra... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS $CWFLAGS -Wextra" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + eval "$as_CACHEVAR=yes" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +eval ac_res=\$$as_CACHEVAR + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : + CWFLAGS="$WCFLAGS -Wextra" +else case e in #( + e) : ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wbad-function-cast" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wbad-function-cast" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wbad-function-cast... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Warray-bounds" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Warray-bounds" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Warray-bounds... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS $CWFLAGS -Warray-bounds" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + eval "$as_CACHEVAR=yes" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +eval ac_res=\$$as_CACHEVAR + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : + CWFLAGS="$CWFLAGS -Warray-bounds" +else case e in #( + e) : ;; +esac +fi +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wbad-function-cast" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wbad-function-cast" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wbad-function-cast... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wbad-function-cast" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wbad-function-cast" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wcast-qual" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wcast-qual" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wcast-qual... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wcast-qual" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wcast-qual" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wcast-qual... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wcast-qual" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wcast-qual" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wdiv-by-zero" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wdiv-by-zero" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wdiv-by-zero... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wdiv-by-zero" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wdiv-by-zero" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wdiv-by-zero... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wdiv-by-zero" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wdiv-by-zero" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wduplicated-branches" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wduplicated-branches" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wduplicated-branches... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wduplicated-branches" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wduplicated-branches" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wduplicated-branches... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wduplicated-branches" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wduplicated-branches" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wduplicated-cond" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wduplicated-cond" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wduplicated-cond... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wduplicated-cond" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wduplicated-cond" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wduplicated-cond... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wduplicated-cond" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wduplicated-cond" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wfloat-equal" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wfloat-equal" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wfloat-equal... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wfloat-equal" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wfloat-equal" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wfloat-equal... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wfloat-equal" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wfloat-equal" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wformat=2" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wformat=2" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wformat=2... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wformat=2" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wformat=2" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wformat=2... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wformat=2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wformat=2" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wlogical-op" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wlogical-op" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wlogical-op... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wlogical-op" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wlogical-op" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wlogical-op... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wlogical-op" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wlogical-op" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wmaybe-uninitialized" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmaybe-uninitialized" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wmaybe-uninitialized... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wmaybe-uninitialized" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmaybe-uninitialized" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wmaybe-uninitialized... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wmaybe-uninitialized" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wmaybe-uninitialized" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wmisleading-indentation" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmisleading-indentation" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wmisleading-indentation... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wmisleading-indentation" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmisleading-indentation" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wmisleading-indentation... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wmisleading-indentation" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wmisleading-indentation" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wmissing-declarations" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmissing-declarations" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wmissing-declarations... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wmissing-declarations" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmissing-declarations" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wmissing-declarations... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wmissing-declarations" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wmissing-declarations" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wmissing-prototypes" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmissing-prototypes" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wmissing-prototypes... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wmissing-prototypes" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wmissing-prototypes" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wmissing-prototypes... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wmissing-prototypes" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wmissing-prototypes" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wnested-externs" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnested-externs" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wnested-externs... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wnested-externs" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnested-externs" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wnested-externs... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wnested-externs" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wnested-externs" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wno-type-limits" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-type-limits" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wno-type-limits... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wno-type-limits" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-type-limits" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wno-type-limits... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wno-type-limits" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wno-type-limits" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wno-unknown-pragmas" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-unknown-pragmas" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wno-unknown-pragmas... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wno-unknown-pragmas" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wno-unknown-pragmas" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wno-unknown-pragmas... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wno-unknown-pragmas" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wno-unknown-pragmas" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wnormalized=id" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnormalized=id" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wnormalized=id... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wnormalized=id" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnormalized=id" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wnormalized=id... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wnormalized=id" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wnormalized=id" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wnull-dereference" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnull-dereference" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wnull-dereference... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wnull-dereference" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wnull-dereference" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wnull-dereference... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wnull-dereference" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wnull-dereference" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wold-style-declaration" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wold-style-declaration" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wold-style-declaration... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wold-style-declaration" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wold-style-declaration" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wold-style-declaration... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wold-style-declaration" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wold-style-declaration" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wpointer-arith" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wpointer-arith" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wpointer-arith... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wpointer-arith" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wpointer-arith" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wpointer-arith... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wpointer-arith" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wpointer-arith" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wredundant-decls" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wredundant-decls" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wredundant-decls... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wredundant-decls" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wredundant-decls" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wredundant-decls... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wredundant-decls" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wredundant-decls" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wrestrict" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wrestrict" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wrestrict... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wrestrict" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wrestrict" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wrestrict... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wrestrict" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wrestrict" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wshorten-64-to-32" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wshorten-64-to-32" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wshorten-64-to-32... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wshorten-64-to-32" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wshorten-64-to-32" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wshorten-64-to-32... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wshorten-64-to-32" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wshorten-64-to-32" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wsometimes-uninitialized" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wsometimes-uninitialized" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wsometimes-uninitialized... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wsometimes-uninitialized" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wsometimes-uninitialized" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wsometimes-uninitialized... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wsometimes-uninitialized" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wsometimes-uninitialized" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wstrict-prototypes" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wstrict-prototypes" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wstrict-prototypes... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wstrict-prototypes" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wstrict-prototypes" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wstrict-prototypes... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wstrict-prototypes" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wstrict-prototypes" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wswitch-enum" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wswitch-enum" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wswitch-enum... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wswitch-enum" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wswitch-enum" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wswitch-enum... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wswitch-enum" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wswitch-enum" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wvariable-decl" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wvariable-decl" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wvariable-decl... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wvariable-decl" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wvariable-decl" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wvariable-decl... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wvariable-decl" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wvariable-decl" -else - : +else case e in #( + e) : ;; +esac fi -as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CWFLAGS -Wwrite-strings" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wwrite-strings" >&5 -$as_echo_n "checking whether C compiler accepts $CWFLAGS -Wwrite-strings... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CWFLAGS -Wwrite-strings" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CWFLAGS -Wwrite-strings" >&5 +printf %s "checking whether C compiler accepts $CWFLAGS -Wwrite-strings... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CWFLAGS -Wwrite-strings" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CWFLAGS="$CWFLAGS -Wwrite-strings" -else - : +else case e in #( + e) : ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,relro" >&5 -$as_echo_n "checking whether the linker accepts -Wl,-z,relro... " >&6; } -if ${ax_cv_check_ldflags___Wl__z_relro+:} false; then : - $as_echo_n "(cached) " >&6 -else +if test "x$EMSCRIPTEN" = "x" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,relro" >&5 +printf %s "checking whether the linker accepts -Wl,-z,relro... " >&6; } +if test ${ax_cv_check_ldflags___Wl__z_relro+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-z,relro" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl__z_relro=yes -else - ax_cv_check_ldflags___Wl__z_relro=no +else case e in #( + e) ax_cv_check_ldflags___Wl__z_relro=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_relro" >&5 -$as_echo "$ax_cv_check_ldflags___Wl__z_relro" >&6; } -if test "x$ax_cv_check_ldflags___Wl__z_relro" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_relro" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl__z_relro" >&6; } +if test "x$ax_cv_check_ldflags___Wl__z_relro" = xyes +then : LDFLAGS="$LDFLAGS -Wl,-z,relro" -else - : +else case e in #( + e) : ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,now" >&5 -$as_echo_n "checking whether the linker accepts -Wl,-z,now... " >&6; } -if ${ax_cv_check_ldflags___Wl__z_now+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,now" >&5 +printf %s "checking whether the linker accepts -Wl,-z,now... " >&6; } +if test ${ax_cv_check_ldflags___Wl__z_now+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-z,now" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl__z_now=yes -else - ax_cv_check_ldflags___Wl__z_now=no +else case e in #( + e) ax_cv_check_ldflags___Wl__z_now=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_now" >&5 -$as_echo "$ax_cv_check_ldflags___Wl__z_now" >&6; } -if test "x$ax_cv_check_ldflags___Wl__z_now" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_now" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl__z_now" >&6; } +if test "x$ax_cv_check_ldflags___Wl__z_now" = xyes +then : LDFLAGS="$LDFLAGS -Wl,-z,now" -else - : +else case e in #( + e) : ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,noexecstack" >&5 -$as_echo_n "checking whether the linker accepts -Wl,-z,noexecstack... " >&6; } -if ${ax_cv_check_ldflags___Wl__z_noexecstack+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -Wl,-z,noexecstack" >&5 +printf %s "checking whether the linker accepts -Wl,-z,noexecstack... " >&6; } +if test ${ax_cv_check_ldflags___Wl__z_noexecstack+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$LDFLAGS LDFLAGS="$LDFLAGS -Wl,-z,noexecstack" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_ldflags___Wl__z_noexecstack=yes -else - ax_cv_check_ldflags___Wl__z_noexecstack=no +else case e in #( + e) ax_cv_check_ldflags___Wl__z_noexecstack=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$ax_check_save_flags + LDFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_noexecstack" >&5 -$as_echo "$ax_cv_check_ldflags___Wl__z_noexecstack" >&6; } -if test "x$ax_cv_check_ldflags___Wl__z_noexecstack" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_ldflags___Wl__z_noexecstack" >&5 +printf "%s\n" "$ax_cv_check_ldflags___Wl__z_noexecstack" >&6; } +if test "x$ax_cv_check_ldflags___Wl__z_noexecstack" = xyes +then : LDFLAGS="$LDFLAGS -Wl,-z,noexecstack" -else - : +else case e in #( + e) : ;; +esac fi +fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether segmentation violations can be caught when using the C compiler" >&5 -$as_echo_n "checking whether segmentation violations can be caught when using the C compiler... " >&6; } -if ${ax_cv_check_cCATCHABLE_SEGV+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether segmentation violations can be caught" >&5 +printf %s "checking whether segmentation violations can be caught... " >&6; } +if test ${ax_cv_check_cCATCHABLE_SEGV+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + if test "$cross_compiling" = yes +then : ax_cv_check_cCATCHABLE_SEGV=unknown -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -8882,15 +10667,20 @@ else static void sig(int _) { exit(0); } int -main () +main (void) { volatile unsigned char * volatile x = (volatile unsigned char *) malloc(8); size_t i; +#ifdef SIGPROT +signal(SIGPROT, sig); +#endif signal(SIGSEGV, sig); signal(SIGBUS, sig); #if !defined(__SANITIZE_ADDRESS__) && !defined(__EMSCRIPTEN__) +*((volatile unsigned char *) -1) = 0xd0; +*((volatile unsigned char *) 1) = 0xd0; for (i = 0; i < 10000000; i += 1024) { x[-i] = x[i] = (unsigned char) i; } #endif free((void *) x); @@ -8900,41 +10690,49 @@ exit(1) return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : +if ac_fn_c_try_run "$LINENO" +then : ax_cv_check_cCATCHABLE_SEGV=yes -else - ax_cv_check_cCATCHABLE_SEGV=no +else case e in #( + e) ax_cv_check_cCATCHABLE_SEGV=no ;; +esac fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cCATCHABLE_SEGV" >&5 -$as_echo "$ax_cv_check_cCATCHABLE_SEGV" >&6; } - if test "x$ax_cv_check_cCATCHABLE_SEGV" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cCATCHABLE_SEGV" >&5 +printf "%s\n" "$ax_cv_check_cCATCHABLE_SEGV" >&6; } + if test "x$ax_cv_check_cCATCHABLE_SEGV" = xyes +then : -$as_echo "#define HAVE_CATCHABLE_SEGV 1" >>confdefs.h - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: On this platform, segmentation violations cannot be caught using signal handlers. This is expected if you enabled a tool such as Address Sanitizer (-fsanitize=address), but be aware that using Address Sanitizer may also significantly reduce performance." >&5 -$as_echo "$as_me: WARNING: On this platform, segmentation violations cannot be caught using signal handlers. This is expected if you enabled a tool such as Address Sanitizer (-fsanitize=address), but be aware that using Address Sanitizer may also significantly reduce performance." >&2;} +printf "%s\n" "#define HAVE_CATCHABLE_SEGV 1" >>confdefs.h +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: On this platform, segmentation violations cannot be caught using signal handlers. This is expected if you enabled a tool such as Address Sanitizer (-fsanitize=address), but be aware that using Address Sanitizer may also significantly reduce performance." >&5 +printf "%s\n" "$as_me: WARNING: On this platform, segmentation violations cannot be caught using signal handlers. This is expected if you enabled a tool such as Address Sanitizer (-fsanitize=address), but be aware that using Address Sanitizer may also significantly reduce performance." >&2;} + ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether SIGABRT can be caught when using the C compiler" >&5 -$as_echo_n "checking whether SIGABRT can be caught when using the C compiler... " >&6; } -if ${ax_cv_check_cCATCHABLE_ABRT+:} false; then : - $as_echo_n "(cached) " >&6 -else - - if test "$cross_compiling" = yes; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether SIGABRT can be caught" >&5 +printf %s "checking whether SIGABRT can be caught... " >&6; } +if test ${ax_cv_check_cCATCHABLE_ABRT+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + if test "$cross_compiling" = yes +then : ax_cv_check_cCATCHABLE_ABRT=unknown -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -8965,7 +10763,7 @@ static void sigabrt_handler_1(int _) } int -main () +main (void) { signal(SIGABRT, sigabrt_handler_1); @@ -8976,39 +10774,47 @@ exit(1); return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : +if ac_fn_c_try_run "$LINENO" +then : ax_cv_check_cCATCHABLE_ABRT=yes -else - ax_cv_check_cCATCHABLE_ABRT=no +else case e in #( + e) ax_cv_check_cCATCHABLE_ABRT=no ;; +esac fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cCATCHABLE_ABRT" >&5 -$as_echo "$ax_cv_check_cCATCHABLE_ABRT" >&6; } - if test "x$ax_cv_check_cCATCHABLE_ABRT" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cCATCHABLE_ABRT" >&5 +printf "%s\n" "$ax_cv_check_cCATCHABLE_ABRT" >&6; } + if test "x$ax_cv_check_cCATCHABLE_ABRT" = xyes +then : -$as_echo "#define HAVE_CATCHABLE_ABRT 1" >>confdefs.h - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: On this platform, SIGABRT cannot be caught using signal handlers." >&5 -$as_echo "$as_me: WARNING: On this platform, SIGABRT cannot be caught using signal handlers." >&2;} +printf "%s\n" "#define HAVE_CATCHABLE_ABRT 1" >>confdefs.h +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: On this platform, SIGABRT cannot be caught using signal handlers." >&5 +printf "%s\n" "$as_me: WARNING: On this platform, SIGABRT cannot be caught using signal handlers." >&2;} + ;; +esac fi -if test "x$with_threads" = "xyes"; then : +if test "x$with_threads" = "xyes" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread local storage (TLS) class" >&5 -$as_echo_n "checking for thread local storage (TLS) class... " >&6; } - if ${ac_cv_tls+:} false; then : - $as_echo_n "(cached) " >&6 -else - for ax_tls_keyword in thread_local _Thread_local __thread '__declspec(thread)' none; do + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for thread local storage (TLS) class" >&5 +printf %s "checking for thread local storage (TLS) class... " >&6; } + if test ${ac_cv_tls+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) for ax_tls_keyword in thread_local _Thread_local __thread '__declspec(thread)' none; do case $ax_tls_keyword in #( none) : ac_cv_tls=none ; break ;; #( @@ -9016,95 +10822,103 @@ else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdlib.h> - static void - foo(void) { - static $ax_tls_keyword int bar; - exit(1); - } int -main () +main (void) { +static $ax_tls_keyword int bar; ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_tls=$ax_tls_keyword ; break -else - ac_cv_tls=none - +else case e in #( + e) ac_cv_tls=none + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ;; +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ;; esac done - + ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5 -$as_echo "$ac_cv_tls" >&6; } - - if test "$ac_cv_tls" != "none"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5 +printf "%s\n" "$ac_cv_tls" >&6; } -cat >>confdefs.h <<_ACEOF -#define TLS $ac_cv_tls -_ACEOF + if test "$ac_cv_tls" != "none" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: thread local storage is supported" >&5 -$as_echo "thread local storage is supported" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftls-model=local-dynamic" >&5 -$as_echo_n "checking whether C compiler accepts -ftls-model=local-dynamic... " >&6; } -if ${ax_cv_check_cflags___ftls_model_local_dynamic+:} false; then : - $as_echo_n "(cached) " >&6 -else +printf "%s\n" "#define TLS $ac_cv_tls" >>confdefs.h + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: thread local storage is supported" >&5 +printf "%s\n" "thread local storage is supported" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -ftls-model=local-dynamic" >&5 +printf %s "checking whether C compiler accepts -ftls-model=local-dynamic... " >&6; } +if test ${ax_cv_check_cflags___ftls_model_local_dynamic+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -ftls-model=local-dynamic" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___ftls_model_local_dynamic=yes -else - ax_cv_check_cflags___ftls_model_local_dynamic=no +else case e in #( + e) ax_cv_check_cflags___ftls_model_local_dynamic=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftls_model_local_dynamic" >&5 -$as_echo "$ax_cv_check_cflags___ftls_model_local_dynamic" >&6; } -if test "x$ax_cv_check_cflags___ftls_model_local_dynamic" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___ftls_model_local_dynamic" >&5 +printf "%s\n" "$ax_cv_check_cflags___ftls_model_local_dynamic" >&6; } +if test "x$ax_cv_check_cflags___ftls_model_local_dynamic" = xyes +then : CFLAGS="$CFLAGS -ftls-model=local-dynamic" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: thread local storage is not supported" >&5 -$as_echo "thread local storage is not supported" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: thread local storage is not supported" >&5 +printf "%s\n" "thread local storage is not supported" >&6; } ;; +esac fi fi case `pwd` in *\ * | *\ *) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 -$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 +printf "%s\n" "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; esac -macro_version='2.4.6' -macro_revision='2.4.6' +macro_version='2.5.4' +macro_revision='2.5.4' + @@ -9141,8 +10955,8 @@ ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 -$as_echo_n "checking how to print strings... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +printf %s "checking how to print strings... " >&6; } # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then @@ -9168,12 +10982,12 @@ func_echo_all () } case $ECHO in - printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 -$as_echo "printf" >&6; } ;; - print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 -$as_echo "print -r" >&6; } ;; - *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 -$as_echo "cat" >&6; } ;; + printf*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +printf "%s\n" "printf" >&6; } ;; + print*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +printf "%s\n" "print -r" >&6; } ;; + *) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +printf "%s\n" "cat" >&6; } ;; esac @@ -9189,12 +11003,13 @@ esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if ${ac_cv_path_SED+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 +printf %s "checking for a sed that does not truncate output... " >&6; } +if test ${ac_cv_path_SED+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for ac_i in 1 2 3 4 5 6 7; do ac_script="$ac_script$as_nl$ac_script" done @@ -9207,25 +11022,31 @@ else for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in sed gsed; do + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in sed gsed + do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" + ac_path_SED="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_SED" || continue # Check for GNU ac_path_SED and select it if it is found. # Check for GNU $ac_path_SED -case `"$ac_path_SED" --version 2>&1` in +case `"$ac_path_SED" --version 2>&1` in #( *GNU*) ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; +#( *) ac_count=0 - $as_echo_n 0123456789 >"conftest.in" + printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" - $as_echo '' >> "conftest.nl" + printf "%s\n" '' >> "conftest.nl" "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val @@ -9251,10 +11072,11 @@ IFS=$as_save_IFS else ac_cv_path_SED=$SED fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 -$as_echo "$ac_cv_path_SED" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 +printf "%s\n" "$ac_cv_path_SED" >&6; } SED="$ac_cv_path_SED" rm -f conftest.sed @@ -9271,47 +11093,51 @@ Xsed="$SED -e 1s/^X//" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 -$as_echo_n "checking for fgrep... " >&6; } -if ${ac_cv_path_FGREP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 - then ac_cv_path_FGREP="$GREP -F" - else - if test -z "$FGREP"; then - ac_path_FGREP_found=false +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 +printf %s "checking for grep that handles long lines and -e... " >&6; } +if test ${ac_cv_path_GREP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -z "$GREP"; then + ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in fgrep; do + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in grep ggrep + do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" - as_fn_executable_p "$ac_path_FGREP" || continue -# Check for GNU ac_path_FGREP and select it if it is found. - # Check for GNU $ac_path_FGREP -case `"$ac_path_FGREP" --version 2>&1` in + ac_path_GREP="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_GREP" || continue +# Check for GNU ac_path_GREP and select it if it is found. + # Check for GNU $ac_path_GREP +case `"$ac_path_GREP" --version 2>&1` in #( *GNU*) - ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; + ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; +#( *) ac_count=0 - $as_echo_n 0123456789 >"conftest.in" + printf %s 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" - $as_echo 'FGREP' >> "conftest.nl" - "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + printf "%s\n" 'GREP' >> "conftest.nl" + "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val - if test $ac_count -gt ${ac_path_FGREP_max-0}; then + if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one - ac_cv_path_FGREP="$ac_path_FGREP" - ac_path_FGREP_max=$ac_count + ac_cv_path_GREP="$ac_path_GREP" + ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break @@ -9319,64 +11145,218 @@ case `"$ac_path_FGREP" --version 2>&1` in rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac - $ac_path_FGREP_found && break 3 + $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS - if test -z "$ac_cv_path_FGREP"; then - as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + if test -z "$ac_cv_path_GREP"; then + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else - ac_cv_path_FGREP=$FGREP + ac_cv_path_GREP=$GREP fi - - fi + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 -$as_echo "$ac_cv_path_FGREP" >&6; } - FGREP="$ac_cv_path_FGREP" - - -test -z "$GREP" && GREP=grep - - - - - - - - - - - - - - - - - - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 +printf "%s\n" "$ac_cv_path_GREP" >&6; } + GREP="$ac_cv_path_GREP" -# Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then : - withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes -else - with_gnu_ld=no -fi -ac_prog=ld -if test yes = "$GCC"; then - # Check if gcc -print-prog-name=ld gives a path. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 -$as_echo_n "checking for ld used by $CC... " >&6; } - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return, which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +printf %s "checking for egrep... " >&6; } +if test ${ac_cv_path_EGREP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 + then ac_cv_path_EGREP="$GREP -E" + else + if test -z "$EGREP"; then + ac_path_EGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in egrep + do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_EGREP" || continue +# Check for GNU ac_path_EGREP and select it if it is found. + # Check for GNU $ac_path_EGREP +case `"$ac_path_EGREP" --version 2>&1` in #( +*GNU*) + ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; +#( +*) + ac_count=0 + printf %s 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + printf "%s\n" 'EGREP' >> "conftest.nl" + "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_EGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_EGREP="$ac_path_EGREP" + ac_path_EGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_EGREP=$EGREP +fi + + fi ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +printf "%s\n" "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" + + EGREP_TRADITIONAL=$EGREP + ac_cv_path_EGREP_TRADITIONAL=$EGREP + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +printf %s "checking for fgrep... " >&6; } +if test ${ac_cv_path_FGREP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 + then ac_cv_path_FGREP="$GREP -F" + else + if test -z "$FGREP"; then + ac_path_FGREP_found=false + # Loop through the user's path and test for each of PROGNAME-LIST + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in fgrep + do + for ac_exec_ext in '' $ac_executable_extensions; do + ac_path_FGREP="$as_dir$ac_prog$ac_exec_ext" + as_fn_executable_p "$ac_path_FGREP" || continue +# Check for GNU ac_path_FGREP and select it if it is found. + # Check for GNU $ac_path_FGREP +case `"$ac_path_FGREP" --version 2>&1` in #( +*GNU*) + ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; +#( +*) + ac_count=0 + printf %s 0123456789 >"conftest.in" + while : + do + cat "conftest.in" "conftest.in" >"conftest.tmp" + mv "conftest.tmp" "conftest.in" + cp "conftest.in" "conftest.nl" + printf "%s\n" 'FGREP' >> "conftest.nl" + "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break + diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break + as_fn_arith $ac_count + 1 && ac_count=$as_val + if test $ac_count -gt ${ac_path_FGREP_max-0}; then + # Best one so far, save it but keep looking for a better one + ac_cv_path_FGREP="$ac_path_FGREP" + ac_path_FGREP_max=$ac_count + fi + # 10*(2^10) chars as input seems more than enough + test $ac_count -gt 10 && break + done + rm -f conftest.in conftest.tmp conftest.nl conftest.out;; +esac + + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP +fi + + fi ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +printf "%s\n" "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" + + +test -z "$GREP" && GREP=grep + + + + + + + + + + + + + + + + + + + +# Check whether --with-gnu-ld was given. +if test ${with_gnu_ld+y} +then : + withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes +else case e in #( + e) with_gnu_ld=no ;; +esac +fi + +ac_prog=ld +if test yes = "$GCC"; then + # Check if gcc -print-prog-name=ld gives a path. + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 +printf %s "checking for ld used by $CC... " >&6; } + case $host in + *-*-mingw* | *-*-windows*) + # gcc leaves a trailing carriage return, which upsets mingw + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; + *) + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; + esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) @@ -9398,16 +11378,17 @@ $as_echo_n "checking for ld used by $CC... " >&6; } ;; esac elif test yes = "$with_gnu_ld"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 -$as_echo_n "checking for GNU ld... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 +printf %s "checking for GNU ld... " >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 -$as_echo_n "checking for non-GNU ld... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +printf %s "checking for non-GNU ld... " >&6; } fi -if ${lt_cv_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -z "$LD"; then +if test ${lt_cv_path_LD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs @@ -9430,24 +11411,26 @@ else IFS=$lt_save_ifs else lt_cv_path_LD=$LD # Let the user override the test with a path. -fi +fi ;; +esac fi LD=$lt_cv_path_LD if test -n "$LD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 -$as_echo "$LD" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 +printf "%s\n" "$LD" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 -$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if ${lt_cv_prog_gnu_ld+:} false; then : - $as_echo_n "(cached) " >&6 -else - # I'd rather use --version here, but apparently some GNU lds only accept -v. +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +printf %s "checking if the linker ($LD) is GNU ld... " >&6; } +if test ${lt_cv_prog_gnu_ld+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) lt_cv_prog_gnu_ld=yes @@ -9455,10 +11438,11 @@ case `$LD -v 2>&1 </dev/null` in *) lt_cv_prog_gnu_ld=no ;; +esac ;; esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 -$as_echo "$lt_cv_prog_gnu_ld" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 +printf "%s\n" "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld @@ -9469,12 +11453,13 @@ with_gnu_ld=$lt_cv_prog_gnu_ld -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 -$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } -if ${lt_cv_path_NM+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NM"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 +printf %s "checking for BSD- or MS-compatible name lister (nm)... " >&6; } +if test ${lt_cv_path_NM+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else @@ -9495,16 +11480,16 @@ else # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in - mingw*) lt_bad_file=conftest.nm/nofile ;; + mingw* | windows*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac - case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 @@ -9521,10 +11506,11 @@ else IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 -$as_echo "$lt_cv_path_NM" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 +printf "%s\n" "$lt_cv_path_NM" >&6; } if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else @@ -9537,38 +11523,44 @@ else do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DUMPBIN"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_DUMPBIN+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$DUMPBIN"; then ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 -$as_echo "$DUMPBIN" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +printf "%s\n" "$DUMPBIN" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -9581,38 +11573,44 @@ if test -z "$DUMPBIN"; then do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DUMPBIN"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_DUMPBIN+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_DUMPBIN"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN if test -n "$ac_ct_DUMPBIN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 -$as_echo "$ac_ct_DUMPBIN" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +printf "%s\n" "$ac_ct_DUMPBIN" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -9624,15 +11622,15 @@ done else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DUMPBIN=$ac_ct_DUMPBIN fi fi - case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; @@ -9653,12 +11651,13 @@ test -z "$NM" && NM=nm -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 -$as_echo_n "checking the name lister ($NM) interface... " >&6; } -if ${lt_cv_nm_interface+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_nm_interface="BSD nm" +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +printf %s "checking the name lister ($NM) interface... " >&6; } +if test ${lt_cv_nm_interface+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) @@ -9671,29 +11670,31 @@ else if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi - rm -f conftest* + rm -f conftest* ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 -$as_echo "$lt_cv_nm_interface" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +printf "%s\n" "$lt_cv_nm_interface" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 -$as_echo_n "checking whether ln -s works... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 +printf %s "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 -$as_echo "no, using $LN_S" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +printf "%s\n" "no, using $LN_S" >&6; } fi # find the maximum length of command line arguments -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 -$as_echo_n "checking the maximum length of command line arguments... " >&6; } -if ${lt_cv_sys_max_cmd_len+:} false; then : - $as_echo_n "(cached) " >&6 -else - i=0 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +printf %s "checking the maximum length of command line arguments... " >&6; } +if test ${lt_cv_sys_max_cmd_len+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) i=0 teststring=ABCD case $build_os in @@ -9705,14 +11706,14 @@ else lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. + gnu* | ironclad*) + # Under GNU Hurd and Ironclad, this test is not required because there + # is no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; - cygwin* | mingw* | cegcc*) + cygwin* | mingw* | windows* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, @@ -9734,7 +11735,7 @@ else lt_cv_sys_max_cmd_len=8192; ;; - bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` @@ -9777,7 +11778,7 @@ else sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` + lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi @@ -9815,15 +11816,16 @@ else fi ;; esac - + ;; +esac fi if test -n "$lt_cv_sys_max_cmd_len"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 -$as_echo "$lt_cv_sys_max_cmd_len" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +printf "%s\n" "$lt_cv_sys_max_cmd_len" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 -$as_echo "none" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none" >&5 +printf "%s\n" "none" >&6; } fi max_cmd_len=$lt_cv_sys_max_cmd_len @@ -9867,15 +11869,16 @@ esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 -$as_echo_n "checking how to convert $build file names to $host format... " >&6; } -if ${lt_cv_to_host_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $host in +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +printf %s "checking how to convert $build file names to $host format... " >&6; } +if test ${lt_cv_to_host_file_cmd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $host in *-*-mingw* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) @@ -9888,7 +11891,7 @@ else ;; *-*-cygwin* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) @@ -9903,53 +11906,58 @@ else lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac - + ;; +esac fi to_host_file_cmd=$lt_cv_to_host_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 -$as_echo "$lt_cv_to_host_file_cmd" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +printf "%s\n" "$lt_cv_to_host_file_cmd" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 -$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } -if ${lt_cv_to_tool_file_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - #assume ordinary cross tools, or native build. +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +printf %s "checking how to convert $build file names to toolchain format... " >&6; } +if test ${lt_cv_to_tool_file_cmd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) #assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in - *-*-mingw* ) + *-*-mingw* | *-*-windows* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac - + ;; +esac fi to_tool_file_cmd=$lt_cv_to_tool_file_cmd -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 -$as_echo "$lt_cv_to_tool_file_cmd" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +printf "%s\n" "$lt_cv_to_tool_file_cmd" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 -$as_echo_n "checking for $LD option to reload object files... " >&6; } -if ${lt_cv_ld_reload_flag+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_reload_flag='-r' +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +printf %s "checking for $LD option to reload object files... " >&6; } +if test ${lt_cv_ld_reload_flag+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_ld_reload_flag='-r' ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 -$as_echo "$lt_cv_ld_reload_flag" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 +printf "%s\n" "$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; @@ -9957,7 +11965,7 @@ case $reload_flag in esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi @@ -9979,41 +11987,97 @@ esac +# Extract the first word of "file", so it can be a program name with args. +set dummy file; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_FILECMD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$FILECMD"; then + ac_cv_prog_FILECMD="$FILECMD" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_FILECMD="file" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + test -z "$ac_cv_prog_FILECMD" && ac_cv_prog_FILECMD=":" +fi ;; +esac +fi +FILECMD=$ac_cv_prog_FILECMD +if test -n "$FILECMD"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $FILECMD" >&5 +printf "%s\n" "$FILECMD" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + + + + + + + if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_OBJDUMP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +printf "%s\n" "$OBJDUMP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -10022,38 +12086,44 @@ if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_OBJDUMP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +printf "%s\n" "$ac_ct_OBJDUMP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then @@ -10061,8 +12131,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP @@ -10081,12 +12151,13 @@ test -z "$OBJDUMP" && OBJDUMP=objdump -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 -$as_echo_n "checking how to recognize dependent libraries... " >&6; } -if ${lt_cv_deplibs_check_method+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_file_magic_cmd='$MAGIC_CMD' +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +printf %s "checking how to recognize dependent libraries... " >&6; } +if test ${lt_cv_deplibs_check_method+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support @@ -10094,7 +12165,6 @@ lt_cv_deplibs_check_method='unknown' # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure @@ -10111,7 +12181,7 @@ beos*) bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; @@ -10121,7 +12191,7 @@ cygwin*) lt_cv_file_magic_cmd='func_win32_libid' ;; -mingw* | pw32*) +mingw* | windows* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. @@ -10130,7 +12200,7 @@ mingw* | pw32*) lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64|pe-aarch64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; @@ -10145,14 +12215,14 @@ darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac @@ -10166,7 +12236,7 @@ haiku*) ;; hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' @@ -10203,7 +12273,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +*-mlibc) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else @@ -10213,7 +12287,7 @@ netbsd*) newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; @@ -10221,7 +12295,7 @@ newos6*) lt_cv_deplibs_check_method=pass_all ;; -openbsd* | bitrig*) +openbsd*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else @@ -10237,6 +12311,10 @@ rdos*) lt_cv_deplibs_check_method=pass_all ;; +serenity*) + lt_cv_deplibs_check_method=pass_all + ;; + solaris*) lt_cv_deplibs_check_method=pass_all ;; @@ -10279,16 +12357,17 @@ os2*) lt_cv_deplibs_check_method=pass_all ;; esac - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 -$as_echo "$lt_cv_deplibs_check_method" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +printf "%s\n" "$lt_cv_deplibs_check_method" >&6; } file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in - mingw* | pw32*) + mingw* | windows* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else @@ -10326,38 +12405,44 @@ test -z "$deplibs_check_method" && deplibs_check_method=unknown if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_DLLTOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +printf "%s\n" "$DLLTOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -10366,38 +12451,44 @@ if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_DLLTOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +printf "%s\n" "$ac_ct_DLLTOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then @@ -10405,8 +12496,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL @@ -10426,15 +12517,16 @@ test -z "$DLLTOOL" && DLLTOOL=dlltool -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 -$as_echo_n "checking how to associate runtime and link libraries... " >&6; } -if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_sharedlib_from_linklib_cmd='unknown' +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +printf %s "checking how to associate runtime and link libraries... " >&6; } +if test ${lt_cv_sharedlib_from_linklib_cmd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in @@ -10451,10 +12543,11 @@ cygwin* | mingw* | pw32* | cegcc*) lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 -$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +printf "%s\n" "$lt_cv_sharedlib_from_linklib_cmd" >&6; } sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO @@ -10465,86 +12558,202 @@ test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO if test -n "$ac_tool_prefix"; then - for ac_prog in ar - do - # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. -set dummy $ac_tool_prefix$ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then - ac_cv_prog_AR="$AR" # Let the user override the test. + # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. +set dummy ${ac_tool_prefix}ranlib; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_RANLIB+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$RANLIB"; then + ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AR="$ac_tool_prefix$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS +fi ;; +esac fi -fi -AR=$ac_cv_prog_AR -if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +printf "%s\n" "$RANLIB" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi - test -n "$AR" && break - done fi -if test -z "$AR"; then - ac_ct_AR=$AR - for ac_prog in ar -do +if test -z "$ac_cv_prog_RANLIB"; then + ac_ct_RANLIB=$RANLIB + # Extract the first word of "ranlib", so it can be a program name with args. +set dummy ranlib; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_RANLIB+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_RANLIB"; then + ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_ac_ct_RANLIB="ranlib" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi ;; +esac +fi +ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB +if test -n "$ac_ct_RANLIB"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 +printf "%s\n" "$ac_ct_RANLIB" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + if test "x$ac_ct_RANLIB" = x; then + RANLIB=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +ac_tool_warned=yes ;; +esac + RANLIB=$ac_ct_RANLIB + fi +else + RANLIB="$ac_cv_prog_RANLIB" +fi + +if test -n "$ac_tool_prefix"; then + for ac_prog in ar + do + # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. +set dummy $ac_tool_prefix$ac_prog; ac_word=$2 +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_AR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$AR"; then + ac_cv_prog_AR="$AR" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + +fi ;; +esac +fi +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +printf "%s\n" "$AR" >&6; } +else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +fi + + + test -n "$AR" && break + done +fi +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar +do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_AR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="$ac_prog" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +printf "%s\n" "$ac_ct_AR" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -10556,8 +12765,8 @@ done else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR @@ -10565,42 +12774,60 @@ esac fi : ${AR=ar} -: ${AR_FLAGS=cru} +# Use ARFLAGS variable as AR's operation code to sync the variable naming with +# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have +# higher priority because that's what people were doing historically (setting +# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS +# variable obsoleted/removed. +test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} +lt_ar_flags=$AR_FLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 -$as_echo_n "checking for archiver @FILE support... " >&6; } -if ${lt_cv_ar_at_file+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ar_at_file=no + + +# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override +# by AR_FLAGS because that was never working and AR_FLAGS is about to die. + + + + + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +printf %s "checking for archiver @FILE support... " >&6; } +if test ${lt_cv_ar_at_file+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_ar_at_file=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. @@ -10608,7 +12835,7 @@ if ac_fn_c_try_compile "$LINENO"; then : { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ @@ -10617,11 +12844,12 @@ if ac_fn_c_try_compile "$LINENO"; then : rm -f conftest.* libconftest.a fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 -$as_echo "$lt_cv_ar_at_file" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +printf "%s\n" "$lt_cv_ar_at_file" >&6; } if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= @@ -10638,38 +12866,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$STRIP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_STRIP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 -$as_echo "$STRIP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +printf "%s\n" "$STRIP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -10678,38 +12912,44 @@ if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_STRIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_STRIP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_STRIP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 -$as_echo "$ac_ct_STRIP" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +printf "%s\n" "$ac_ct_STRIP" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then @@ -10717,8 +12957,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP @@ -10734,97 +12974,6 @@ test -z "$STRIP" && STRIP=: -if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. -set dummy ${ac_tool_prefix}ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$RANLIB"; then - ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -RANLIB=$ac_cv_prog_RANLIB -if test -n "$RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 -$as_echo "$RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - -fi -if test -z "$ac_cv_prog_RANLIB"; then - ac_ct_RANLIB=$RANLIB - # Extract the first word of "ranlib", so it can be a program name with args. -set dummy ranlib; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_RANLIB"; then - ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_RANLIB="ranlib" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS - -fi -fi -ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB -if test -n "$ac_ct_RANLIB"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 -$as_echo "$ac_ct_RANLIB" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi - - if test "x$ac_ct_RANLIB" = x; then - RANLIB=":" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - RANLIB=$ac_ct_RANLIB - fi -else - RANLIB="$ac_cv_prog_RANLIB" -fi test -z "$RANLIB" && RANLIB=: @@ -10839,15 +12988,8 @@ old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then - case $host_os in - bitrig* | openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in @@ -10906,12 +13048,13 @@ compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 -$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } -if ${lt_cv_sys_global_symbol_pipe+:} false; then : - $as_echo_n "(cached) " >&6 -else - +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 +printf %s "checking command to parse $NM output from $compiler object... " >&6; } +if test ${lt_cv_sys_global_symbol_pipe+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] @@ -10926,7 +13069,7 @@ case $host_os in aix*) symcode='[BCDT]' ;; -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) @@ -10941,7 +13084,7 @@ osf*) symcode='[BCDEGQRST]' ;; solaris*) - symcode='[BDRT]' + symcode='[BCDRT]' ;; sco3.2v5*) symcode='[DT]' @@ -10965,7 +13108,7 @@ esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. - lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" @@ -10983,20 +13126,20 @@ fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ @@ -11005,7 +13148,7 @@ $lt_c_name_lib_hook\ # Handle CRLF in mingw tool chain opt_cr= case $build_os in -mingw*) +mingw* | windows*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac @@ -11020,7 +13163,7 @@ for ac_symprfx in "" "_"; do if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. - # Also find C++ and __fastcall symbols from MSVC++, + # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK '"\ " {last_section=section; section=\$ 3};"\ @@ -11038,9 +13181,9 @@ for ac_symprfx in "" "_"; do " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx" else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no @@ -11056,21 +13199,18 @@ void nm_test_func(void){} #ifdef __cplusplus } #endif -int main(){nm_test_var='a';nm_test_func();return(0);} +int main(void){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm - if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 - (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5 + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&5 && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -11138,7 +13278,7 @@ _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s conftest$ac_exeext; then pipe_works=yes fi @@ -11166,18 +13306,19 @@ _LT_EOF lt_cv_sys_global_symbol_pipe= fi done - + ;; +esac fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 -$as_echo "failed" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5 +printf "%s\n" "failed" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 -$as_echo "ok" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +printf "%s\n" "ok" >&6; } fi # Response file support. @@ -11223,14 +13364,16 @@ fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 -$as_echo_n "checking for sysroot... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +printf %s "checking for sysroot... " >&6; } # Check whether --with-sysroot was given. -if test "${with_sysroot+set}" = set; then : +if test ${with_sysroot+y} +then : withval=$with_sysroot; -else - with_sysroot=no +else case e in #( + e) with_sysroot=no ;; +esac fi @@ -11238,34 +13381,37 @@ lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` + # Trim trailing / since we'll always append absolute paths and we want + # to avoid //, if only for less confusing output for the user. + lt_sysroot=`$CC --print-sysroot 2>/dev/null | $SED 's:/\+$::'` fi ;; #( /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 -$as_echo "$with_sysroot" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 +printf "%s\n" "$with_sysroot" >&6; } as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 ;; esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 -$as_echo "${lt_sysroot:-no}" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +printf "%s\n" "${lt_sysroot:-no}" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 -$as_echo_n "checking for a working dd... " >&6; } -if ${ac_cv_path_lt_DD+:} false; then : - $as_echo_n "(cached) " >&6 -else - printf 0123456789abcdef0123456789abcdef >conftest.i +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 +printf %s "checking for a working dd... " >&6; } +if test ${ac_cv_path_lt_DD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} if test -z "$lt_DD"; then @@ -11275,10 +13421,15 @@ if test -z "$lt_DD"; then for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_prog in dd; do + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + for ac_prog in dd + do for ac_exec_ext in '' $ac_executable_extensions; do - ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" + ac_path_lt_DD="$as_dir$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_lt_DD" || continue if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ @@ -11296,18 +13447,20 @@ else ac_cv_path_lt_DD=$lt_DD fi -rm -f conftest.i conftest2.i conftest.out +rm -f conftest.i conftest2.i conftest.out ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 -$as_echo "$ac_cv_path_lt_DD" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 +printf "%s\n" "$ac_cv_path_lt_DD" >&6; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 -$as_echo_n "checking how to truncate binary pipes... " >&6; } -if ${lt_cv_truncate_bin+:} false; then : - $as_echo_n "(cached) " >&6 -else - printf 0123456789abcdef0123456789abcdef >conftest.i +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 +printf %s "checking how to truncate binary pipes... " >&6; } +if test ${lt_cv_truncate_bin+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then @@ -11315,10 +13468,11 @@ if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; the && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out -test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 -$as_echo "$lt_cv_truncate_bin" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 +printf "%s\n" "$lt_cv_truncate_bin" >&6; } @@ -11341,7 +13495,8 @@ func_cc_basename () } # Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then : +if test ${enable_libtool_lock+y} +then : enableval=$enable_libtool_lock; fi @@ -11357,9 +13512,9 @@ ia64-*-hpux*) if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; @@ -11377,10 +13532,10 @@ ia64-*-hpux*) if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then if test yes = "$lt_cv_prog_gnu_ld"; then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; @@ -11392,7 +13547,7 @@ ia64-*-hpux*) ;; esac else - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; @@ -11415,10 +13570,10 @@ mips64*-*linux*) if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then emul=elf - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; @@ -11426,7 +13581,7 @@ mips64*-*linux*) emul="${emul}64" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; @@ -11434,7 +13589,7 @@ mips64*-*linux*) emul="${emul}ltsmip" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; @@ -11445,7 +13600,7 @@ mips64*-*linux*) ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) +s390*-*linux*|s390*-*tpf*|sparc*-*linux*|x86_64-gnu*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when @@ -11456,16 +13611,16 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in + x86_64-*linux*|x86_64-gnu*) + case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; @@ -11493,7 +13648,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; - x86_64-*linux*) + x86_64-*linux*|x86_64-gnu*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) @@ -11519,12 +13674,13 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 -$as_echo_n "checking whether the C compiler needs -belf... " >&6; } -if ${lt_cv_cc_needs_belf+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_ext=c + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 +printf %s "checking whether the C compiler needs -belf... " >&6; } +if test ${lt_cv_cc_needs_belf+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' @@ -11534,29 +13690,32 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : lt_cv_cc_needs_belf=yes -else - lt_cv_cc_needs_belf=no +else case e in #( + e) lt_cv_cc_needs_belf=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 -$as_echo "$lt_cv_cc_needs_belf" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 +printf "%s\n" "$lt_cv_cc_needs_belf" >&6; } if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS @@ -11569,9 +13728,9 @@ $as_echo "$lt_cv_cc_needs_belf" >&6; } if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) @@ -11606,38 +13765,44 @@ need_locks=$enable_libtool_lock if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. set dummy ${ac_tool_prefix}mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$MANIFEST_TOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_MANIFEST_TOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$MANIFEST_TOOL"; then ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL if test -n "$MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 -$as_echo "$MANIFEST_TOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +printf "%s\n" "$MANIFEST_TOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -11646,38 +13811,44 @@ if test -z "$ac_cv_prog_MANIFEST_TOOL"; then ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL # Extract the first word of "mt", so it can be a program name with args. set dummy mt; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_MANIFEST_TOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_MANIFEST_TOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_MANIFEST_TOOL"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL if test -n "$ac_ct_MANIFEST_TOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 -$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +printf "%s\n" "$ac_ct_MANIFEST_TOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_MANIFEST_TOOL" = x; then @@ -11685,8 +13856,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL @@ -11696,23 +13867,25 @@ else fi test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 -$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } -if ${lt_cv_path_mainfest_tool+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_path_mainfest_tool=no +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +printf %s "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if test ${lt_cv_path_manifest_tool+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_path_manifest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&5 if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes + lt_cv_path_manifest_tool=yes fi - rm -f conftest* + rm -f conftest* ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 -$as_echo "$lt_cv_path_mainfest_tool" >&6; } -if test yes != "$lt_cv_path_mainfest_tool"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_manifest_tool" >&5 +printf "%s\n" "$lt_cv_path_manifest_tool" >&6; } +if test yes != "$lt_cv_path_manifest_tool"; then MANIFEST_TOOL=: fi @@ -11726,38 +13899,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DSYMUTIL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_DSYMUTIL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 -$as_echo "$DSYMUTIL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +printf "%s\n" "$DSYMUTIL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -11766,38 +13945,44 @@ if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DSYMUTIL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_DSYMUTIL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 -$as_echo "$ac_ct_DSYMUTIL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +printf "%s\n" "$ac_ct_DSYMUTIL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then @@ -11805,8 +13990,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL @@ -11818,38 +14003,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$NMEDIT"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_NMEDIT+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 -$as_echo "$NMEDIT" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +printf "%s\n" "$NMEDIT" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -11858,38 +14049,44 @@ if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_NMEDIT"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_NMEDIT+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_NMEDIT="nmedit" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 -$as_echo "$ac_ct_NMEDIT" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 +printf "%s\n" "$ac_ct_NMEDIT" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then @@ -11897,8 +14094,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT @@ -11910,38 +14107,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. set dummy ${ac_tool_prefix}lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$LIPO"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_LIPO+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_LIPO="${ac_tool_prefix}lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 -$as_echo "$LIPO" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 +printf "%s\n" "$LIPO" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -11950,38 +14153,44 @@ if test -z "$ac_cv_prog_LIPO"; then ac_ct_LIPO=$LIPO # Extract the first word of "lipo", so it can be a program name with args. set dummy lipo; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_LIPO+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_LIPO"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_LIPO+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_LIPO"; then ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_LIPO="lipo" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO if test -n "$ac_ct_LIPO"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 -$as_echo "$ac_ct_LIPO" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 +printf "%s\n" "$ac_ct_LIPO" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then @@ -11989,8 +14198,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac LIPO=$ac_ct_LIPO @@ -12002,38 +14211,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. set dummy ${ac_tool_prefix}otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_OTOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL="${ac_tool_prefix}otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 -$as_echo "$OTOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 +printf "%s\n" "$OTOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -12042,38 +14257,44 @@ if test -z "$ac_cv_prog_OTOOL"; then ac_ct_OTOOL=$OTOOL # Extract the first word of "otool", so it can be a program name with args. set dummy otool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_OTOOL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_OTOOL"; then ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL="otool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL if test -n "$ac_ct_OTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 -$as_echo "$ac_ct_OTOOL" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 +printf "%s\n" "$ac_ct_OTOOL" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then @@ -12081,8 +14302,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL=$ac_ct_OTOOL @@ -12094,38 +14315,44 @@ fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. set dummy ${ac_tool_prefix}otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OTOOL64"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_OTOOL64+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$OTOOL64"; then ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi OTOOL64=$ac_cv_prog_OTOOL64 if test -n "$OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 -$as_echo "$OTOOL64" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 +printf "%s\n" "$OTOOL64" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -12134,38 +14361,44 @@ if test -z "$ac_cv_prog_OTOOL64"; then ac_ct_OTOOL64=$OTOOL64 # Extract the first word of "otool64", so it can be a program name with args. set dummy otool64; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OTOOL64"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_OTOOL64+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_OTOOL64"; then ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL64="otool64" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 if test -n "$ac_ct_OTOOL64"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 -$as_echo "$ac_ct_OTOOL64" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 +printf "%s\n" "$ac_ct_OTOOL64" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_OTOOL64" = x; then @@ -12173,8 +14406,8 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL64=$ac_ct_OTOOL64 @@ -12209,12 +14442,13 @@ fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 -$as_echo_n "checking for -single_module linker flag... " >&6; } -if ${lt_cv_apple_cc_single_mod+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_apple_cc_single_mod=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 +printf %s "checking for -single_module linker flag... " >&6; } +if test ${lt_cv_apple_cc_single_mod+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE @@ -12240,61 +14474,106 @@ else fi rm -rf libconftest.dylib* rm -f conftest.* - fi + fi ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 -$as_echo "$lt_cv_apple_cc_single_mod" >&6; } - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 -$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } -if ${lt_cv_ld_exported_symbols_list+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 +printf "%s\n" "$lt_cv_apple_cc_single_mod" >&6; } + + # Feature test to disable chained fixups since it is not + # compatible with '-undefined dynamic_lookup' + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -no_fixup_chains linker flag" >&5 +printf %s "checking for -no_fixup_chains linker flag... " >&6; } +if test ${lt_cv_support_no_fixup_chains+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -Wl,-no_fixup_chains" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - lt_cv_ld_exported_symbols_list=yes -else - lt_cv_ld_exported_symbols_list=no +if ac_fn_c_try_link "$LINENO" +then : + lt_cv_support_no_fixup_chains=yes +else case e in #( + e) lt_cv_support_no_fixup_chains=no + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS + LDFLAGS=$save_LDFLAGS + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 -$as_echo "$lt_cv_ld_exported_symbols_list" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_support_no_fixup_chains" >&5 +printf "%s\n" "$lt_cv_support_no_fixup_chains" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 -$as_echo_n "checking for -force_load linker flag... " >&6; } -if ${lt_cv_ld_force_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_ld_force_load=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 +printf %s "checking for -exported_symbols_list linker flag... " >&6; } +if test ${lt_cv_ld_exported_symbols_list+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_ld_exported_symbols_list=no + save_LDFLAGS=$LDFLAGS + echo "_main" > conftest.sym + LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main (void) +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + lt_cv_ld_exported_symbols_list=yes +else case e in #( + e) lt_cv_ld_exported_symbols_list=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 +printf "%s\n" "$lt_cv_ld_exported_symbols_list" >&6; } + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +printf %s "checking for -force_load linker flag... " >&6; } +if test ${lt_cv_ld_force_load+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 - echo "$AR cru libconftest.a conftest.o" >&5 - $AR cru libconftest.a conftest.o 2>&5 + echo "$AR $AR_FLAGS libconftest.a conftest.o" >&5 + $AR $AR_FLAGS libconftest.a conftest.o 2>&5 echo "$RANLIB libconftest.a" >&5 $RANLIB libconftest.a 2>&5 cat > conftest.c << _LT_EOF -int main() { return 0;} +int main(void) { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err @@ -12308,32 +14587,47 @@ _LT_EOF fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 -$as_echo "$lt_cv_ld_force_load" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +printf "%s\n" "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[91]*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - 10.[012][,.]*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + darwin*) + case $MACOSX_DEPLOYMENT_TARGET,$host in + 10.[012],*|,*powerpc*-darwin[5-8]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + *) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' + if test yes = "$lt_cv_support_no_fixup_chains"; then + as_fn_append _lt_dar_allow_undefined ' $wl-no_fixup_chains' + fi + ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi + _lt_dar_needs_single_mod=no + case $host_os in + rhapsody* | darwin1.*) + _lt_dar_needs_single_mod=yes ;; + darwin*) + # When targeting Mac OS X 10.4 (darwin 8) or later, + # -single_module is the default and -multi_module is unsupported. + # The toolchain on macOS 10.14 (darwin 18) and later cannot + # target any OS version that needs -single_module. + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*-darwin[567].*|10.[0-3],*-darwin[5-9].*|10.[0-3],*-darwin1[0-7].*) + _lt_dar_needs_single_mod=yes ;; + esac + ;; + esac if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else @@ -12382,19 +14676,14 @@ func_munge_path_list () esac } -for ac_header in dlfcn.h -do : - ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default " -if test "x$ac_cv_header_dlfcn_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_DLFCN_H 1 -_ACEOF +if test "x$ac_cv_header_dlfcn_h" = xyes +then : + printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h fi -done - @@ -12410,7 +14699,8 @@ done # Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then : +if test ${enable_shared+y} +then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; @@ -12428,8 +14718,9 @@ if test "${enable_shared+set}" = set; then : IFS=$lt_save_ifs ;; esac -else - enable_shared=yes +else case e in #( + e) enable_shared=yes ;; +esac fi @@ -12441,7 +14732,8 @@ fi # Check whether --enable-static was given. -if test "${enable_static+set}" = set; then : +if test ${enable_static+y} +then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; @@ -12459,8 +14751,9 @@ if test "${enable_static+set}" = set; then : IFS=$lt_save_ifs ;; esac -else - enable_static=yes +else case e in #( + e) enable_static=yes ;; +esac fi @@ -12471,27 +14764,52 @@ fi - -# Check whether --with-pic was given. -if test "${with_pic+set}" = set; then : + # Check whether --enable-pic was given. +if test ${enable_pic+y} +then : + enableval=$enable_pic; lt_p=${PACKAGE-default} + case $enableval in + yes|no) pic_mode=$enableval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else case e in #( + e) # Check whether --with-pic was given. +if test ${with_pic+y} +then : withval=$with_pic; lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for lt_pkg in $withval; do - IFS=$lt_save_ifs - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS=$lt_save_ifs - ;; - esac -else - pic_mode=default + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac +else case e in #( + e) pic_mode=default ;; +esac +fi + + ;; +esac fi @@ -12502,7 +14820,8 @@ fi # Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then : +if test ${enable_fast_install+y} +then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; @@ -12520,8 +14839,9 @@ if test "${enable_fast_install+set}" = set; then : IFS=$lt_save_ifs ;; esac -else - enable_fast_install=yes +else case e in #( + e) enable_fast_install=yes ;; +esac fi @@ -12534,31 +14854,50 @@ fi shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[5-9]*,yes) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 -$as_echo_n "checking which variant of shared library versioning to provide... " >&6; } - -# Check whether --with-aix-soname was given. -if test "${with_aix_soname+set}" = set; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 +printf %s "checking which variant of shared library versioning to provide... " >&6; } + # Check whether --enable-aix-soname was given. +if test ${enable_aix_soname+y} +then : + enableval=$enable_aix_soname; case $enableval in + aix|svr4|both) + ;; + *) + as_fn_error $? "Unknown argument to --enable-aix-soname" "$LINENO" 5 + ;; + esac + lt_cv_with_aix_soname=$enable_aix_soname +else case e in #( + e) # Check whether --with-aix-soname was given. +if test ${with_aix_soname+y} +then : withval=$with_aix_soname; case $withval in - aix|svr4|both) - ;; - *) - as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 - ;; - esac - lt_cv_with_aix_soname=$with_aix_soname -else - if ${lt_cv_with_aix_soname+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_with_aix_soname=aix + aix|svr4|both) + ;; + *) + as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname +else case e in #( + e) if test ${lt_cv_with_aix_soname+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_with_aix_soname=aix ;; +esac +fi + ;; +esac fi - with_aix_soname=$lt_cv_with_aix_soname + enable_aix_soname=$lt_cv_with_aix_soname ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 -$as_echo "$with_aix_soname" >&6; } + with_aix_soname=$enable_aix_soname + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 +printf "%s\n" "$with_aix_soname" >&6; } if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', @@ -12640,12 +14979,13 @@ if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 -$as_echo_n "checking for objdir... " >&6; } -if ${lt_cv_objdir+:} false; then : - $as_echo_n "(cached) " >&6 -else - rm -f .libs 2>/dev/null +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 +printf %s "checking for objdir... " >&6; } +if test ${lt_cv_objdir+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs @@ -12653,19 +14993,18 @@ else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi -rmdir .libs 2>/dev/null +rmdir .libs 2>/dev/null ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 -$as_echo "$lt_cv_objdir" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 +printf "%s\n" "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir -cat >>confdefs.h <<_ACEOF -#define LT_OBJDIR "$lt_cv_objdir/" -_ACEOF +printf "%s\n" "#define LT_OBJDIR \"$lt_cv_objdir/\"" >>confdefs.h @@ -12686,8 +15025,8 @@ esac ofile=libtool can_build_shared=yes -# All known linkers require a '.a' archive for static linking (except MSVC, -# which needs '.lib'). +# All known linkers require a '.a' archive for static linking (except MSVC and +# ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld @@ -12711,12 +15050,13 @@ test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 -$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 +printf %s "checking for ${ac_tool_prefix}file... " >&6; } +if test ${lt_cv_path_MAGIC_CMD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; @@ -12759,16 +15099,17 @@ _LT_EOF IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; +esac ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +printf "%s\n" "$MAGIC_CMD" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -12777,12 +15118,13 @@ fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 -$as_echo_n "checking for file... " >&6; } -if ${lt_cv_path_MAGIC_CMD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MAGIC_CMD in + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for file" >&5 +printf %s "checking for file... " >&6; } +if test ${lt_cv_path_MAGIC_CMD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; @@ -12825,16 +15167,17 @@ _LT_EOF IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; +esac ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 -$as_echo "$MAGIC_CMD" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 +printf "%s\n" "$MAGIC_CMD" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -12868,7 +15211,7 @@ objext=$objext lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' +lt_simple_link_test_code='int main(void){return(0);}' @@ -12919,12 +15262,13 @@ if test yes = "$GCC"; then lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 -$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } -if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_rtti_exceptions=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 +printf %s "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } +if test ${lt_cv_prog_compiler_rtti_exceptions+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment @@ -12952,10 +15296,11 @@ else fi fi $RM conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 -$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +printf "%s\n" "$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" @@ -13008,7 +15353,7 @@ lt_prog_compiler_static= # PIC is the default for these OSes. ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style @@ -13111,7 +15456,7 @@ lt_prog_compiler_static= esac ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' @@ -13152,6 +15497,12 @@ lt_prog_compiler_static= lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; + *flang* | ftn | f18* | f95*) + # Flang compiler. + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -13196,7 +15547,7 @@ lt_prog_compiler_static= lt_prog_compiler_static='-qstaticlink' ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' @@ -13234,6 +15585,12 @@ lt_prog_compiler_static= lt_prog_compiler_static='-Bstatic' ;; + *-mlibc) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. @@ -13250,6 +15607,9 @@ lt_prog_compiler_static= lt_prog_compiler_static='-non_shared' ;; + serenity*) + ;; + solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' @@ -13312,27 +15672,30 @@ case $host_os in ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 -$as_echo_n "checking for $compiler option to produce PIC... " >&6; } -if ${lt_cv_prog_compiler_pic+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +printf %s "checking for $compiler option to produce PIC... " >&6; } +if test ${lt_cv_prog_compiler_pic+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_pic=$lt_prog_compiler_pic ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 -$as_echo "$lt_cv_prog_compiler_pic" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +printf "%s\n" "$lt_cv_prog_compiler_pic" >&6; } lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 -$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } -if ${lt_cv_prog_compiler_pic_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_pic_works=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if test ${lt_cv_prog_compiler_pic_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment @@ -13360,10 +15723,11 @@ else fi fi $RM conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 -$as_echo "$lt_cv_prog_compiler_pic_works" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works"; then case $lt_prog_compiler_pic in @@ -13391,12 +15755,13 @@ fi # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 -$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } -if ${lt_cv_prog_compiler_static_works+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_static_works=no +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test ${lt_cv_prog_compiler_static_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_static_works=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext @@ -13417,10 +15782,11 @@ else fi $RM -r conftest* LDFLAGS=$save_LDFLAGS - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 -$as_echo "$lt_cv_prog_compiler_static_works" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; } if test yes = "$lt_cv_prog_compiler_static_works"; then : @@ -13434,12 +15800,13 @@ fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test ${lt_cv_prog_compiler_c_o+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest @@ -13479,22 +15846,24 @@ else cd .. $RM -r conftest $RM conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 -$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } -if ${lt_cv_prog_compiler_c_o+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler_c_o=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 +printf %s "checking if $compiler supports -c -o file.$ac_objext... " >&6; } +if test ${lt_cv_prog_compiler_c_o+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest @@ -13534,10 +15903,11 @@ else cd .. $RM -r conftest $RM conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 -$as_echo "$lt_cv_prog_compiler_c_o" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 +printf "%s\n" "$lt_cv_prog_compiler_c_o" >&6; } @@ -13545,19 +15915,19 @@ $as_echo "$lt_cv_prog_compiler_c_o" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 -$as_echo_n "checking if we can lock with hard links... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 +printf %s "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 -$as_echo "$hard_links" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 +printf "%s\n" "$hard_links" >&6; } if test no = "$hard_links"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 -$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 +printf "%s\n" "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else @@ -13569,8 +15939,8 @@ fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 -$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 +printf %s "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } runpath_var= allow_undefined_flag= @@ -13613,21 +15983,18 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie extract_expsyms_cmds= case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time + cygwin* | mingw* | windows* | pw32* | cegcc*) + # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) + # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; - openbsd* | bitrig*) - with_gnu_ld=no - ;; esac ld_shlibs=yes @@ -13674,7 +16041,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie whole_archive_flag_spec= fi supports_anon_versioning=no - case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in + case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... @@ -13728,7 +16095,7 @@ _LT_EOF fi ;; - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' @@ -13738,6 +16105,7 @@ _LT_EOF enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' + file_list_spec='@' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' @@ -13757,7 +16125,7 @@ _LT_EOF haiku*) archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - link_all_deplibs=yes + link_all_deplibs=no ;; os2*) @@ -13784,8 +16152,9 @@ _LT_EOF cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes + file_list_spec='@' ;; interix[3-9]*) @@ -13800,7 +16169,7 @@ _LT_EOF # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) @@ -13843,7 +16212,7 @@ _LT_EOF compiler_needs_object=yes ;; esac - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes @@ -13855,13 +16224,14 @@ _LT_EOF if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) @@ -13871,7 +16241,7 @@ _LT_EOF archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi @@ -13882,7 +16252,12 @@ _LT_EOF fi ;; - netbsd*) + *-mlibc) + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -14003,7 +16378,7 @@ _LT_EOF if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no @@ -14125,21 +16500,23 @@ _LT_EOF if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test ${lt_cv_aix_libpath_+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { @@ -14154,12 +16531,13 @@ if ac_fn_c_try_link "$LINENO"; then : lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi - + ;; +esac fi aix_libpath=$lt_cv_aix_libpath_ @@ -14178,21 +16556,23 @@ fi if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else - if ${lt_cv_aix_libpath_+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + if test ${lt_cv_aix_libpath_+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { @@ -14207,12 +16587,13 @@ if ac_fn_c_try_link "$LINENO"; then : lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi - + ;; +esac fi aix_libpath=$lt_cv_aix_libpath_ @@ -14268,14 +16649,14 @@ fi export_dynamic_flag_spec=-rdynamic ;; - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in - cl*) - # Native MSVC + cl* | icl*) + # Native MSVC or ICC hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported always_export_symbols=yes @@ -14285,14 +16666,14 @@ fi # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + archive_cmds='$CC -Fe$output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + $CC -Fe$tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, )='true' @@ -14316,7 +16697,7 @@ fi fi' ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. @@ -14357,8 +16738,8 @@ fi output_verbose_link_cmd=func_echo_all archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + archive_expsym_cmds="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + module_expsym_cmds="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" else ld_shlibs=no @@ -14392,7 +16773,7 @@ fi ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes @@ -14458,12 +16839,13 @@ fi # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 -$as_echo_n "checking if $CC understands -b... " >&6; } -if ${lt_cv_prog_compiler__b+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_prog_compiler__b=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +printf %s "checking if $CC understands -b... " >&6; } +if test ${lt_cv_prog_compiler__b+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler__b=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -b" echo "$lt_simple_link_test_code" > conftest.$ac_ext @@ -14484,10 +16866,11 @@ else fi $RM -r conftest* LDFLAGS=$save_LDFLAGS - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 -$as_echo "$lt_cv_prog_compiler__b" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +printf "%s\n" "$lt_cv_prog_compiler__b" >&6; } if test yes = "$lt_cv_prog_compiler__b"; then archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' @@ -14527,28 +16910,32 @@ fi # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 -$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } -if ${lt_cv_irix_exported_symbol+:} false; then : - $as_echo_n "(cached) " >&6 -else - save_LDFLAGS=$LDFLAGS + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +printf %s "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if test ${lt_cv_irix_exported_symbol+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo (void) { return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : lt_cv_irix_exported_symbol=yes -else - lt_cv_irix_exported_symbol=no +else case e in #( + e) lt_cv_irix_exported_symbol=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - LDFLAGS=$save_LDFLAGS + LDFLAGS=$save_LDFLAGS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 -$as_echo "$lt_cv_irix_exported_symbol" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +printf "%s\n" "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi @@ -14569,11 +16956,15 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' ;; esac ;; - netbsd*) + *-mlibc) + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -14595,7 +16986,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } *nto* | *qnx*) ;; - openbsd* | bitrig*) + openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no @@ -14638,8 +17029,9 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' - old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + old_archive_from_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes + file_list_spec='@' ;; osf3*) @@ -14673,6 +17065,9 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } hardcode_libdir_separator=: ;; + serenity*) + ;; + solaris*) no_undefined_flag=' -z defs' if test yes = "$GCC"; then @@ -14828,8 +17223,8 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 -$as_echo "$ld_shlibs" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 +printf "%s\n" "$ld_shlibs" >&6; } test no = "$ld_shlibs" && can_build_shared=no with_gnu_ld=$with_gnu_ld @@ -14865,18 +17260,19 @@ x|xyes) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 -$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } -if ${lt_cv_archive_cmds_need_lc+:} false; then : - $as_echo_n "(cached) " >&6 -else - $RM conftest* + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 +printf %s "checking whether -lc should be explicitly linked in... " >&6; } +if test ${lt_cv_archive_cmds_need_lc+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest @@ -14894,7 +17290,7 @@ else if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc=no @@ -14906,10 +17302,11 @@ else cat conftest.err 1>&5 fi $RM conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 -$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +printf "%s\n" "$lt_cv_archive_cmds_need_lc" >&6; } archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac @@ -15068,8 +17465,8 @@ esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 -$as_echo_n "checking dynamic linker characteristics... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 +printf %s "checking dynamic linker characteristics... " >&6; } if test yes = "$GCC"; then case $host_os in @@ -15077,7 +17474,7 @@ if test yes = "$GCC"; then *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in - mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; + mingw* | windows* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` @@ -15135,7 +17532,7 @@ BEGIN {RS = " "; FS = "/|\n";} { # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + mingw* | windows* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([A-Za-z]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` @@ -15209,7 +17606,7 @@ aix[4-9]*) # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl - # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # linker flag in LDFLAGS as well, or --enable-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the @@ -15303,7 +17700,7 @@ bsdi[45]*) # libtool to hard-code these into programs ;; -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no @@ -15314,15 +17711,29 @@ cygwin* | mingw* | pw32* | cegcc*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' + # If user builds GCC with multilib enabled, + # it should just install on $(libdir) + # not on $(libdir)/../bin or 32 bits dlls would override 64 bit ones. + if test xyes = x"$multilib"; then + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + $install_prog $dir/$dlname $destdir/$dlname~ + chmod a+x $destdir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib $destdir/$dlname'\'' || exit \$?; + fi' + else + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + fi postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' @@ -15331,30 +17742,30 @@ cygwin* | mingw* | pw32* | cegcc*) case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; - mingw* | cegcc*) + mingw* | windows* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' + library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; - *,cl*) - # Native MSVC + *,cl* | *,icl*) + # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in - mingw*) + mingw* | windows*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' @@ -15367,7 +17778,7 @@ cygwin* | mingw* | pw32* | cegcc*) done IFS=$lt_save_ifs # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form @@ -15404,7 +17815,7 @@ cygwin* | mingw* | pw32* | cegcc*) ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; @@ -15437,7 +17848,7 @@ dgux*) shlibpath_var=LD_LIBRARY_PATH ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then @@ -15461,7 +17872,28 @@ freebsd* | dragonfly*) need_version=yes ;; esac + case $host_cpu in + powerpc64) + # On FreeBSD bi-arch platforms, a different variable is used for 32-bit + # binaries. See <https://man.freebsd.org/cgi/man.cgi?query=ld.so>. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int test_pointer_size[sizeof (void *) - 5]; + +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : shlibpath_var=LD_LIBRARY_PATH +else case e in #( + e) shlibpath_var=LD_32_LIBRARY_PATH ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ;; + *) + shlibpath_var=LD_LIBRARY_PATH + ;; + esac case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes @@ -15491,8 +17923,9 @@ haiku*) soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes + sys_lib_search_path_spec='/boot/system/non-packaged/develop/lib /boot/system/develop/lib' + sys_lib_dlsearch_path_spec='/boot/home/config/non-packaged/lib /boot/home/config/lib /boot/system/non-packaged/lib /boot/system/lib' + hardcode_into_libs=no ;; hpux9* | hpux10* | hpux11*) @@ -15602,7 +18035,7 @@ linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no - library_names_spec='$libname$release$shared_ext' + library_names_spec='$libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH @@ -15614,8 +18047,9 @@ linux*android*) hardcode_into_libs=yes dynamic_linker='Android linker' - # Don't embed -rpath directories since the linker doesn't support them. - hardcode_libdir_flag_spec='-L$libdir' + # -rpath works at least for libraries that are not overridden by + # libraries installed in system locations. + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' ;; # This must be glibc/ELF. @@ -15630,10 +18064,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH - if ${lt_cv_shlibpath_overrides_runpath+:} false; then : - $as_echo_n "(cached) " >&6 -else - lt_cv_shlibpath_overrides_runpath=no + if test ${lt_cv_shlibpath_overrides_runpath+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ @@ -15642,23 +18077,26 @@ else /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : +if ac_fn_c_try_link "$LINENO" +then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null +then : lt_cv_shlibpath_overrides_runpath=yes fi fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir - + ;; +esac fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath @@ -15668,7 +18106,7 @@ fi # before this can be enabled. hardcode_into_libs=yes - # Ideally, we could use ldconfig to report *all* directores which are + # Ideally, we could use ldconfig to report *all* directories which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, @@ -15688,6 +18126,18 @@ fi dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -15706,6 +18156,18 @@ netbsd*) hardcode_into_libs=yes ;; +*-mlibc) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='mlibc ld.so' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' @@ -15725,7 +18187,7 @@ newsos6) dynamic_linker='ldqnx.so' ;; -openbsd* | bitrig*) +openbsd*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no @@ -15785,6 +18247,17 @@ rdos*) dynamic_linker=no ;; +serenity*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + dynamic_linker='SerenityOS LibELF' + ;; + solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no @@ -15810,84 +18283,574 @@ sunos4*) need_version=yes ;; -sysv4 | sysv4.3*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; +sysv4 | sysv4.3*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + case $host_vendor in + sni) + shlibpath_overrides_runpath=no + need_lib_prefix=no + runpath_var=LD_RUN_PATH + ;; + siemens) + need_lib_prefix=no + ;; + motorola) + need_lib_prefix=no + need_version=no + shlibpath_overrides_runpath=no + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' + ;; + esac + ;; + +sysv4*MP*) + if test -d /usr/nec; then + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' + shlibpath_var=LD_LIBRARY_PATH + fi + ;; + +sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + version_type=sco + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + if test yes = "$with_gnu_ld"; then + sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' + else + sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' + case $host_os in + sco3.2v5*) + sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" + ;; + esac + fi + sys_lib_dlsearch_path_spec='/usr/lib' + ;; + +tpf*) + # TPF is a cross-target only. Preferred cross-host = GNU/Linux. + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + +uts4*) + version_type=linux # correct to gnu/linux during the next big refactor + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + ;; + +emscripten*) + version_type=none + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + dynamic_linker="Emscripten linker" + lt_prog_compiler_wl= +lt_prog_compiler_pic= +lt_prog_compiler_static= + + + if test yes = "$GCC"; then + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_static='-static' + + case $host_os in + aix*) + # All AIX code is PIC. + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + fi + lt_prog_compiler_pic='-fPIC' + ;; + + amigaos*) + case $host_cpu in + powerpc) + # see comment about AmigaOS4 .so support + lt_prog_compiler_pic='-fPIC' + ;; + m68k) + # FIXME: we need at least 68020 code to build shared libraries, but + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. + lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' + ;; + esac + ;; + + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) + # PIC is the default for these OSes. + ;; + + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + # Although the cygwin gcc ignores -fPIC, still need this for old-style + # (--disable-auto-import) libraries + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + ;; + + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + + hpux*) + # PIC is the default for 64-bit PA HP-UX, but not for 32-bit + # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag + # sets the default TLS model and affects inlining. + case $host_cpu in + hppa*64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + ;; + + interix[3-9]*) + # Interix 3.x gcc -fpic/-fPIC options generate broken code. + # Instead, we relocate shared libraries at runtime. + ;; + + msdosdjgpp*) + # Just because we use GCC doesn't mean we suddenly get shared libraries + # on systems that don't support them. + lt_prog_compiler_can_build_shared=no + enable_shared=no + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic=-Kconform_pic + fi + ;; + + *) + lt_prog_compiler_pic='-fPIC' + ;; + esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + if test -n "$lt_prog_compiler_pic"; then + lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" + fi + ;; + esac + else + # PORTME Check for flag to pass linker flags through the system compiler. + case $host_os in + aix*) + lt_prog_compiler_wl='-Wl,' + if test ia64 = "$host_cpu"; then + # AIX 5 now supports IA64 processor + lt_prog_compiler_static='-Bstatic' + else + lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' + fi + ;; + + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + lt_prog_compiler_pic='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) + # This hack is so that the source file can tell whether it is being + # built for inclusion in a dll (and should export symbols for example). + lt_prog_compiler_pic='-DDLL_EXPORT' + case $host_os in + os2*) + lt_prog_compiler_static='$wl-static' + ;; + esac + ;; + + hpux9* | hpux10* | hpux11*) + lt_prog_compiler_wl='-Wl,' + # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but + # not for PA HP-UX. + case $host_cpu in + hppa*64*|ia64*) + # +Z the default + ;; + *) + lt_prog_compiler_pic='+Z' + ;; + esac + # Is there a better lt_prog_compiler_static that works with the bundled CC? + lt_prog_compiler_static='$wl-a ${wl}archive' + ;; + + irix5* | irix6* | nonstopux*) + lt_prog_compiler_wl='-Wl,' + # PIC (with -KPIC) is the default. + lt_prog_compiler_static='-non_shared' + ;; + + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) + case $cc_basename in + # old Intel for x86_64, which still supported -KPIC. + ecc*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-static' + ;; + *flang* | ftn | f18* | f95*) + # Flang compiler. + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # icc used to be incompatible with GCC. + # ICC 10 doesn't accept -KPIC any more. + icc* | ifort*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + # Lahey Fortran 8.1. + lf95*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='--shared' + lt_prog_compiler_static='--static' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) + # Portland Group compilers (*not* the Pentium gcc compiler, + # which looks to be a dead project) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + ccc*) + lt_prog_compiler_wl='-Wl,' + # All Alpha code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-qpic' + lt_prog_compiler_static='-qstaticlink' + ;; + *) + case `$CC -V 2>&1 | $SED 5q` in + *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) + # Sun Fortran 8.3 passes all unrecognized flags to the linker + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='' + ;; + *Sun\ F* | *Sun*Fortran*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Qoption ld ' + ;; + *Sun\ C*) + # Sun C 5.9 + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + lt_prog_compiler_wl='-Wl,' + ;; + *Intel*\ [CF]*Compiler*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + *Portland\ Group*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fpic' + lt_prog_compiler_static='-Bstatic' + ;; + esac + ;; + esac + ;; + + newsos6) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + *-mlibc) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-fPIC' + lt_prog_compiler_static='-static' + ;; + + *nto* | *qnx*) + # QNX uses GNU C++, but need to define -shared option too, otherwise + # it will coredump. + lt_prog_compiler_pic='-fPIC -shared' + ;; + + osf3* | osf4* | osf5*) + lt_prog_compiler_wl='-Wl,' + # All OSF/1 code is PIC. + lt_prog_compiler_static='-non_shared' + ;; + + rdos*) + lt_prog_compiler_static='-non_shared' + ;; + + serenity*) + ;; + + solaris*) + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + case $cc_basename in + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) + lt_prog_compiler_wl='-Qoption ld ';; + *) + lt_prog_compiler_wl='-Wl,';; + esac + ;; + + sunos4*) + lt_prog_compiler_wl='-Qoption ld ' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4 | sysv4.2uw2* | sysv4.3*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + sysv4*MP*) + if test -d /usr/nec; then + lt_prog_compiler_pic='-Kconform_pic' + lt_prog_compiler_static='-Bstatic' + fi + ;; + + sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_pic='-KPIC' + lt_prog_compiler_static='-Bstatic' + ;; + + unicos*) + lt_prog_compiler_wl='-Wl,' + lt_prog_compiler_can_build_shared=no + ;; + + uts4*) + lt_prog_compiler_pic='-pic' + lt_prog_compiler_static='-Bstatic' + ;; + + *) + lt_prog_compiler_can_build_shared=no + ;; + esac + fi + +case $host_os in + # For platforms that do not support PIC, -DPIC is meaningless: + *djgpp*) + lt_prog_compiler_pic= + ;; + *) + lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" + ;; +esac + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +printf %s "checking for $compiler option to produce PIC... " >&6; } +if test ${lt_cv_prog_compiler_pic+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_pic=$lt_prog_compiler_pic ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +printf "%s\n" "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic + +# +# Check to make sure the PIC flag actually works. +# +if test -n "$lt_prog_compiler_pic"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 +printf %s "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } +if test ${lt_cv_prog_compiler_pic_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_pic_works=no + ac_outfile=conftest.$ac_objext + echo "$lt_simple_compile_test_code" > conftest.$ac_ext + lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment + # Insert the option either (1) after the last *FLAGS variable, or + # (2) before a word containing "conftest.", or (3) at the end. + # Note that $ac_compile itself does not contain backslashes and begins + # with a dollar sign (not a hyphen), so the echo should work correctly. + # The option is referenced via a variable to avoid confusing sed. + lt_compile=`echo "$ac_compile" | $SED \ + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_pic_works=yes + fi + fi + $RM conftest* + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 +printf "%s\n" "$lt_cv_prog_compiler_pic_works" >&6; } + +if test yes = "$lt_cv_prog_compiler_pic_works"; then + case $lt_prog_compiler_pic in + "" | " "*) ;; + *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; + esac +else + lt_prog_compiler_pic= + lt_prog_compiler_can_build_shared=no +fi + +fi + + + + + +# +# Check to make sure the static flag actually works. +# +wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 +printf %s "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } +if test ${lt_cv_prog_compiler_static_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) lt_cv_prog_compiler_static_works=no + save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS $lt_tmp_static_flag" + echo "$lt_simple_link_test_code" > conftest.$ac_ext + if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then + # The linker can only warn and ignore the option if not recognized + # So say no if there are warnings + if test -s conftest.err; then + # Append any errors to the config.log. + cat conftest.err 1>&5 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler_static_works=yes + fi + else + lt_cv_prog_compiler_static_works=yes + fi + fi + $RM -r conftest* + LDFLAGS=$save_LDFLAGS + ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 +printf "%s\n" "$lt_cv_prog_compiler_static_works" >&6; } -sysv4*MP*) - if test -d /usr/nec; then - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' - soname_spec='$libname$shared_ext.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; +if test yes = "$lt_cv_prog_compiler_static_works"; then + : +else + lt_prog_compiler_static= +fi -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=sco - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - if test yes = "$with_gnu_ld"; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; -tpf*) - # TPF is a cross-target only. Preferred cross-host = GNU/Linux. - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; -uts4*) - version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' - soname_spec='$libname$release$shared_ext$major' - shlibpath_var=LD_LIBRARY_PATH +='-fPIC' + archive_cmds='$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib' + archive_expsym_cmds='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib -s EXPORTED_FUNCTIONS=@$output_objdir/$soname.expsym' + archive_cmds_need_lc=no + no_undefined_flag= ;; *) dynamic_linker=no ;; esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 -$as_echo "$dynamic_linker" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 +printf "%s\n" "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" @@ -16008,8 +18971,8 @@ configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH - { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 -$as_echo_n "checking how to hardcode library paths into programs... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 +printf %s "checking how to hardcode library paths into programs... " >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || test -n "$runpath_var" || @@ -16033,8 +18996,8 @@ else # directories. hardcode_action=unsupported fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 -$as_echo "$hardcode_action" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +printf "%s\n" "$hardcode_action" >&6; } if test relink = "$hardcode_action" || test yes = "$inherit_rpath"; then @@ -16066,7 +19029,7 @@ else lt_cv_dlopen_self=yes ;; - mingw* | pw32* | cegcc*) + mingw* | windows* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; @@ -16078,50 +19041,59 @@ else darwin*) # if libdl is installed we need to link against it - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +printf %s "checking for dlopen in -ldl... " >&6; } +if test ${ac_cv_lib_dl_dlopen+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char dlopen (); +char dlopen (void); int -main () +main (void) { return dlopen (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no +else case e in #( + e) ac_cv_lib_dl_dlopen=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes +then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl -else - +else case e in #( + e) lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes - + ;; +esac fi ;; @@ -16136,183 +19108,222 @@ fi *) ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" -if test "x$ac_cv_func_shl_load" = xyes; then : +if test "x$ac_cv_func_shl_load" = xyes +then : lt_cv_dlopen=shl_load -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 -$as_echo_n "checking for shl_load in -ldld... " >&6; } -if ${ac_cv_lib_dld_shl_load+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +printf %s "checking for shl_load in -ldld... " >&6; } +if test ${ac_cv_lib_dld_shl_load+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char shl_load (); +char shl_load (void); int -main () +main (void) { return shl_load (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_dld_shl_load=yes -else - ac_cv_lib_dld_shl_load=no +else case e in #( + e) ac_cv_lib_dld_shl_load=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 -$as_echo "$ac_cv_lib_dld_shl_load" >&6; } -if test "x$ac_cv_lib_dld_shl_load" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 +printf "%s\n" "$ac_cv_lib_dld_shl_load" >&6; } +if test "x$ac_cv_lib_dld_shl_load" = xyes +then : lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld -else - ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" -if test "x$ac_cv_func_dlopen" = xyes; then : +else case e in #( + e) ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes +then : lt_cv_dlopen=dlopen -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 -$as_echo_n "checking for dlopen in -ldl... " >&6; } -if ${ac_cv_lib_dl_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +printf %s "checking for dlopen in -ldl... " >&6; } +if test ${ac_cv_lib_dl_dlopen+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char dlopen (); +char dlopen (void); int -main () +main (void) { return dlopen (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_dl_dlopen=yes -else - ac_cv_lib_dl_dlopen=no +else case e in #( + e) ac_cv_lib_dl_dlopen=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 -$as_echo "$ac_cv_lib_dl_dlopen" >&6; } -if test "x$ac_cv_lib_dl_dlopen" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes +then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 -$as_echo_n "checking for dlopen in -lsvld... " >&6; } -if ${ac_cv_lib_svld_dlopen+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +printf %s "checking for dlopen in -lsvld... " >&6; } +if test ${ac_cv_lib_svld_dlopen+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char dlopen (); +char dlopen (void); int -main () +main (void) { return dlopen (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_svld_dlopen=yes -else - ac_cv_lib_svld_dlopen=no +else case e in #( + e) ac_cv_lib_svld_dlopen=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 -$as_echo "$ac_cv_lib_svld_dlopen" >&6; } -if test "x$ac_cv_lib_svld_dlopen" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +printf "%s\n" "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes +then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 -$as_echo_n "checking for dld_link in -ldld... " >&6; } -if ${ac_cv_lib_dld_dld_link+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +printf %s "checking for dld_link in -ldld... " >&6; } +if test ${ac_cv_lib_dld_dld_link+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ + builtin and then its argument prototype would still apply. + The 'extern "C"' is for builds by C++ compilers; + although this is not generally supported in C code supporting it here + has little cost and some practical benefit (sr 110532). */ #ifdef __cplusplus extern "C" #endif -char dld_link (); +char dld_link (void); int -main () +main (void) { return dld_link (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_dld_dld_link=yes -else - ac_cv_lib_dld_dld_link=no +else case e in #( + e) ac_cv_lib_dld_dld_link=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_check_lib_save_LIBS +LIBS=$ac_check_lib_save_LIBS ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 -$as_echo "$ac_cv_lib_dld_dld_link" >&6; } -if test "x$ac_cv_lib_dld_dld_link" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 +printf "%s\n" "$ac_cv_lib_dld_dld_link" >&6; } +if test "x$ac_cv_lib_dld_dld_link" = xyes +then : lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld fi - + ;; +esac fi - + ;; +esac fi - + ;; +esac fi - + ;; +esac fi - + ;; +esac fi ;; @@ -16335,12 +19346,13 @@ fi save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 -$as_echo_n "checking whether a program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test yes = "$cross_compiling"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +printf %s "checking whether a program can dlopen itself... " >&6; } +if test ${lt_cv_dlopen_self+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test yes = "$cross_compiling"; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 @@ -16390,11 +19402,11 @@ else /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); +int fnord (void) __attribute__((visibility("default"))); #endif -int fnord () { return 42; } -int main () +int fnord (void) { return 42; } +int main (void) { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; @@ -16418,7 +19430,7 @@ _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? @@ -16434,19 +19446,21 @@ _LT_EOF fi rm -fr conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 -$as_echo "$lt_cv_dlopen_self" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 +printf "%s\n" "$lt_cv_dlopen_self" >&6; } if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 -$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } -if ${lt_cv_dlopen_self_static+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test yes = "$cross_compiling"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 +printf %s "checking whether a statically linked program can dlopen itself... " >&6; } +if test ${lt_cv_dlopen_self_static+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test yes = "$cross_compiling"; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 @@ -16496,11 +19510,11 @@ else /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); +int fnord (void) __attribute__((visibility("default"))); #endif -int fnord () { return 42; } -int main () +int fnord (void) { return 42; } +int main (void) { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; @@ -16524,7 +19538,7 @@ _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? @@ -16540,10 +19554,11 @@ _LT_EOF fi rm -fr conftest* - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 -$as_echo "$lt_cv_dlopen_self_static" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 +printf "%s\n" "$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS=$save_CPPFLAGS @@ -16581,32 +19596,43 @@ fi striplib= old_striplib= -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 -$as_echo_n "checking whether stripping libraries is possible... " >&6; } -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 +printf %s "checking whether stripping libraries is possible... " >&6; } +if test -z "$STRIP"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +else + if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + else + case $host_os in + darwin*) + # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - fi - ;; - *) - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - ;; - esac + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + ;; + freebsd*) + if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + else + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + fi + ;; + *) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ;; + esac + fi fi @@ -16621,13 +19647,13 @@ fi # Report what library types will actually be built - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 -$as_echo_n "checking if libtool supports shared libraries... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 -$as_echo "$can_build_shared" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +printf %s "checking if libtool supports shared libraries... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +printf "%s\n" "$can_build_shared" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 -$as_echo_n "checking whether to build shared libraries... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 +printf %s "checking whether to build shared libraries... " >&6; } test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and @@ -16651,15 +19677,15 @@ $as_echo_n "checking whether to build shared libraries... " >&6; } fi ;; esac - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 -$as_echo "$enable_shared" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 +printf "%s\n" "$enable_shared" >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 -$as_echo_n "checking whether to build static libraries... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 +printf %s "checking whether to build static libraries... " >&6; } # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 -$as_echo "$enable_static" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 +printf "%s\n" "$enable_static" >&6; } @@ -16701,38 +19727,44 @@ CC=$lt_save_CC if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. set dummy ${ac_tool_prefix}ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AR"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_AR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_AR="${ac_tool_prefix}ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi AR=$ac_cv_prog_AR if test -n "$AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 -$as_echo "$AR" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +printf "%s\n" "$AR" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi @@ -16741,38 +19773,44 @@ if test -z "$ac_cv_prog_AR"; then ac_ct_AR=$AR # Extract the first word of "ar", so it can be a program name with args. set dummy ar; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AR+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AR"; then +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_prog_ac_ct_AR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="ar" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS -fi +fi ;; +esac fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 -$as_echo "$ac_ct_AR" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +printf "%s\n" "$ac_ct_AR" >&6; } else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi if test "x$ac_ct_AR" = x; then @@ -16780,60 +19818,265 @@ fi else case $cross_compiling:$ac_tool_warned in yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 +printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac - AR=$ac_ct_AR - fi -else - AR="$ac_cv_prog_AR" + AR=$ac_ct_AR + fi +else + AR="$ac_cv_prog_AR" +fi + + + +target_cpu_aarch64=no +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ARM64 target" >&5 +printf %s "checking for ARM64 target... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#ifndef __aarch64__ +#error Not aarch64 +#endif +#include <arm_neon.h> + +int +main (void) +{ +(void) 0 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + target_cpu_aarch64=yes +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + target_cpu_aarch64=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + +if test "x$EMSCRIPTEN" = "x" +then : + + + if test "x$target_cpu_aarch64" = "xyes" +then : + + have_armcrypto=no + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ARM crypto instructions set" >&5 +printf %s "checking for ARM crypto instructions set... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifndef __ARM_FEATURE_CRYPTO + # define __ARM_FEATURE_CRYPTO 1 + #endif + #ifndef __ARM_FEATURE_AES + # define __ARM_FEATURE_AES 1 + #endif + + #include <arm_neon.h> + + #ifdef __clang__ + # pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) + #elif defined(__GNUC__) + # pragma GCC target("+simd+crypto") + #endif + +int +main (void) +{ + + int64x2_t x = { 0, 0 }; + vaeseq_u8(vmovq_n_u8(0), vmovq_n_u8(0)); + vmull_high_p64(vreinterpretq_p64_s64(x), vreinterpretq_p64_s64(x)); + + #ifdef __clang__ + # pragma clang attribute pop + #endif + (void) 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + have_armcrypto=yes + +else case e in #( + e) + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + oldcflags="$CFLAGS" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -march=armv8-a+crypto+aes" >&5 +printf %s "checking whether C compiler accepts -march=armv8-a+crypto+aes... " >&6; } +if test ${ax_cv_check_cflags___march_armv8_apcryptopaes+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ax_check_save_flags=$CFLAGS + CFLAGS="$CFLAGS -march=armv8-a+crypto+aes" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <time.h> +int +main (void) +{ +time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + ax_cv_check_cflags___march_armv8_apcryptopaes=yes +else case e in #( + e) ax_cv_check_cflags___march_armv8_apcryptopaes=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS=$ax_check_save_flags ;; +esac +fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___march_armv8_apcryptopaes" >&5 +printf "%s\n" "$ax_cv_check_cflags___march_armv8_apcryptopaes" >&6; } +if test "x$ax_cv_check_cflags___march_armv8_apcryptopaes" = xyes +then : + + CFLAGS="$CFLAGS -march=armv8-a+crypto+aes" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ARM crypto instructions set with -march=armv8-a+crypto+aes" >&5 +printf %s "checking for ARM crypto instructions set with -march=armv8-a+crypto+aes... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + + #ifdef __clang__ + # pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) + #elif defined(__GNUC__) + # pragma GCC target("+simd+crypto") + #endif + #ifndef __ARM_FEATURE_CRYPTO + # define __ARM_FEATURE_CRYPTO 1 + #endif + #ifndef __ARM_FEATURE_AES + # define __ARM_FEATURE_AES 1 + #endif + + #include <arm_neon.h> + +int +main (void) +{ + + int64x2_t x = { 0, 0 }; + vaeseq_u8(vmovq_n_u8(0), vmovq_n_u8(0)); + vmull_high_p64(vreinterpretq_p64_s64(x), vreinterpretq_p64_s64(x)); + + #ifdef __clang__ + # pragma clang attribute pop + #endif + (void) 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes - with addition of -march=armv8-a+crypto+aes" >&5 +printf "%s\n" "yes - with addition of -march=armv8-a+crypto+aes" >&6; } + have_armcrypto=yes + CFLAGS_ARMCRYPTO="-march=armv8-a+crypto+aes" + +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + CFLAGS="$oldcflags" + +else case e in #( + e) : ;; +esac fi + ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + if test "$have_armcrypto" = "yes" +then : +printf "%s\n" "#define HAVE_ARMCRYPTO 1" >>confdefs.h -if test "x$EMSCRIPTEN" = "x"; then : +fi +fi oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mmmx" >&5 -$as_echo_n "checking whether C compiler accepts -mmmx... " >&6; } -if ${ax_cv_check_cflags___mmmx+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mmmx" >&5 +printf %s "checking whether C compiler accepts -mmmx... " >&6; } +if test ${ax_cv_check_cflags___mmmx+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mmmx" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mmmx=yes -else - ax_cv_check_cflags___mmmx=no +else case e in #( + e) ax_cv_check_cflags___mmmx=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mmmx" >&5 -$as_echo "$ax_cv_check_cflags___mmmx" >&6; } -if test "x$ax_cv_check_cflags___mmmx" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mmmx" >&5 +printf "%s\n" "$ax_cv_check_cflags___mmmx" >&6; } +if test "x$ax_cv_check_cflags___mmmx" = xyes +then : CFLAGS="$CFLAGS -mmmx" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MMX instructions set" >&5 -$as_echo_n "checking for MMX instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for MMX instructions set" >&5 +printf %s "checking for MMX instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -16841,101 +20084,118 @@ $as_echo_n "checking for MMX instructions set... " >&6; } #include <mmintrin.h> int -main () +main (void) { __m64 x = _mm_setzero_si64(); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_MMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mmmx" >&5 -$as_echo_n "checking whether C compiler accepts -mmmx... " >&6; } -if ${ax_cv_check_cflags___mmmx+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_MMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mmmx" >&5 +printf %s "checking whether C compiler accepts -mmmx... " >&6; } +if test ${ax_cv_check_cflags___mmmx+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mmmx" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mmmx=yes -else - ax_cv_check_cflags___mmmx=no +else case e in #( + e) ax_cv_check_cflags___mmmx=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mmmx" >&5 -$as_echo "$ax_cv_check_cflags___mmmx" >&6; } -if test "x$ax_cv_check_cflags___mmmx" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mmmx" >&5 +printf "%s\n" "$ax_cv_check_cflags___mmmx" >&6; } +if test "x$ax_cv_check_cflags___mmmx" = xyes +then : CFLAGS_MMX="-mmmx" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse2" >&5 -$as_echo_n "checking whether C compiler accepts -msse2... " >&6; } -if ${ax_cv_check_cflags___msse2+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse2" >&5 +printf %s "checking whether C compiler accepts -msse2... " >&6; } +if test ${ax_cv_check_cflags___msse2+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse2=yes -else - ax_cv_check_cflags___msse2=no +else case e in #( + e) ax_cv_check_cflags___msse2=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse2" >&5 -$as_echo "$ax_cv_check_cflags___msse2" >&6; } -if test "x$ax_cv_check_cflags___msse2" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse2" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse2" >&6; } +if test "x$ax_cv_check_cflags___msse2" = xyes +then : CFLAGS="$CFLAGS -msse2" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSE2 instructions set" >&5 -$as_echo_n "checking for SSE2 instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSE2 instructions set" >&5 +printf %s "checking for SSE2 instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -16946,7 +20206,7 @@ $as_echo_n "checking for SSE2 instructions set... " >&6; } #include <emmintrin.h> int -main () +main (void) { __m128d x = _mm_setzero_pd(); __m128i z = _mm_srli_epi64(_mm_setzero_si128(), 26); @@ -16954,94 +20214,111 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_EMMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse2" >&5 -$as_echo_n "checking whether C compiler accepts -msse2... " >&6; } -if ${ax_cv_check_cflags___msse2+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_EMMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse2" >&5 +printf %s "checking whether C compiler accepts -msse2... " >&6; } +if test ${ax_cv_check_cflags___msse2+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse2=yes -else - ax_cv_check_cflags___msse2=no +else case e in #( + e) ax_cv_check_cflags___msse2=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse2" >&5 -$as_echo "$ax_cv_check_cflags___msse2" >&6; } -if test "x$ax_cv_check_cflags___msse2" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse2" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse2" >&6; } +if test "x$ax_cv_check_cflags___msse2" = xyes +then : CFLAGS_SSE2="-msse2" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse3" >&5 -$as_echo_n "checking whether C compiler accepts -msse3... " >&6; } -if ${ax_cv_check_cflags___msse3+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse3" >&5 +printf %s "checking whether C compiler accepts -msse3... " >&6; } +if test ${ax_cv_check_cflags___msse3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse3" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse3=yes -else - ax_cv_check_cflags___msse3=no +else case e in #( + e) ax_cv_check_cflags___msse3=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse3" >&5 -$as_echo "$ax_cv_check_cflags___msse3" >&6; } -if test "x$ax_cv_check_cflags___msse3" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse3" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse3" >&6; } +if test "x$ax_cv_check_cflags___msse3" = xyes +then : CFLAGS="$CFLAGS -msse3" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSE3 instructions set" >&5 -$as_echo_n "checking for SSE3 instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSE3 instructions set" >&5 +printf %s "checking for SSE3 instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17049,7 +20326,7 @@ $as_echo_n "checking for SSE3 instructions set... " >&6; } #include <pmmintrin.h> int -main () +main (void) { __m128 x = _mm_addsub_ps(_mm_cvtpd_ps(_mm_setzero_pd()), _mm_cvtpd_ps(_mm_setzero_pd())); @@ -17057,94 +20334,111 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_PMMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse3" >&5 -$as_echo_n "checking whether C compiler accepts -msse3... " >&6; } -if ${ax_cv_check_cflags___msse3+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_PMMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse3" >&5 +printf %s "checking whether C compiler accepts -msse3... " >&6; } +if test ${ax_cv_check_cflags___msse3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse3" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse3=yes -else - ax_cv_check_cflags___msse3=no +else case e in #( + e) ax_cv_check_cflags___msse3=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse3" >&5 -$as_echo "$ax_cv_check_cflags___msse3" >&6; } -if test "x$ax_cv_check_cflags___msse3" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse3" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse3" >&6; } +if test "x$ax_cv_check_cflags___msse3" = xyes +then : CFLAGS_SSE3="-msse3" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mssse3" >&5 -$as_echo_n "checking whether C compiler accepts -mssse3... " >&6; } -if ${ax_cv_check_cflags___mssse3+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mssse3" >&5 +printf %s "checking whether C compiler accepts -mssse3... " >&6; } +if test ${ax_cv_check_cflags___mssse3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mssse3" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mssse3=yes -else - ax_cv_check_cflags___mssse3=no +else case e in #( + e) ax_cv_check_cflags___mssse3=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mssse3" >&5 -$as_echo "$ax_cv_check_cflags___mssse3" >&6; } -if test "x$ax_cv_check_cflags___mssse3" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mssse3" >&5 +printf "%s\n" "$ax_cv_check_cflags___mssse3" >&6; } +if test "x$ax_cv_check_cflags___mssse3" = xyes +then : CFLAGS="$CFLAGS -mssse3" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSSE3 instructions set" >&5 -$as_echo_n "checking for SSSE3 instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSSE3 instructions set" >&5 +printf %s "checking for SSSE3 instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17152,101 +20446,118 @@ $as_echo_n "checking for SSSE3 instructions set... " >&6; } #include <tmmintrin.h> int -main () +main (void) { __m64 x = _mm_abs_pi32(_m_from_int(0)); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_TMMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mssse3" >&5 -$as_echo_n "checking whether C compiler accepts -mssse3... " >&6; } -if ${ax_cv_check_cflags___mssse3+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_TMMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mssse3" >&5 +printf %s "checking whether C compiler accepts -mssse3... " >&6; } +if test ${ax_cv_check_cflags___mssse3+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mssse3" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mssse3=yes -else - ax_cv_check_cflags___mssse3=no +else case e in #( + e) ax_cv_check_cflags___mssse3=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mssse3" >&5 -$as_echo "$ax_cv_check_cflags___mssse3" >&6; } -if test "x$ax_cv_check_cflags___mssse3" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mssse3" >&5 +printf "%s\n" "$ax_cv_check_cflags___mssse3" >&6; } +if test "x$ax_cv_check_cflags___mssse3" = xyes +then : CFLAGS_SSSE3="-mssse3" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse4.1" >&5 -$as_echo_n "checking whether C compiler accepts -msse4.1... " >&6; } -if ${ax_cv_check_cflags___msse4_1+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse4.1" >&5 +printf %s "checking whether C compiler accepts -msse4.1... " >&6; } +if test ${ax_cv_check_cflags___msse4_1+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse4.1" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse4_1=yes -else - ax_cv_check_cflags___msse4_1=no +else case e in #( + e) ax_cv_check_cflags___msse4_1=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse4_1" >&5 -$as_echo "$ax_cv_check_cflags___msse4_1" >&6; } -if test "x$ax_cv_check_cflags___msse4_1" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse4_1" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse4_1" >&6; } +if test "x$ax_cv_check_cflags___msse4_1" = xyes +then : CFLAGS="$CFLAGS -msse4.1" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSE4.1 instructions set" >&5 -$as_echo_n "checking for SSE4.1 instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SSE4.1 instructions set" >&5 +printf %s "checking for SSE4.1 instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17254,101 +20565,118 @@ $as_echo_n "checking for SSE4.1 instructions set... " >&6; } #include <smmintrin.h> int -main () +main (void) { __m128i x = _mm_minpos_epu16(_mm_setzero_si128()); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_SMMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse4.1" >&5 -$as_echo_n "checking whether C compiler accepts -msse4.1... " >&6; } -if ${ax_cv_check_cflags___msse4_1+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_SMMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -msse4.1" >&5 +printf %s "checking whether C compiler accepts -msse4.1... " >&6; } +if test ${ax_cv_check_cflags___msse4_1+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -msse4.1" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___msse4_1=yes -else - ax_cv_check_cflags___msse4_1=no +else case e in #( + e) ax_cv_check_cflags___msse4_1=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse4_1" >&5 -$as_echo "$ax_cv_check_cflags___msse4_1" >&6; } -if test "x$ax_cv_check_cflags___msse4_1" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___msse4_1" >&5 +printf "%s\n" "$ax_cv_check_cflags___msse4_1" >&6; } +if test "x$ax_cv_check_cflags___msse4_1" = xyes +then : CFLAGS_SSE41="-msse4.1" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx" >&5 -$as_echo_n "checking whether C compiler accepts -mavx... " >&6; } -if ${ax_cv_check_cflags___mavx+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx" >&5 +printf %s "checking whether C compiler accepts -mavx... " >&6; } +if test ${ax_cv_check_cflags___mavx+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx=yes -else - ax_cv_check_cflags___mavx=no +else case e in #( + e) ax_cv_check_cflags___mavx=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx" >&5 -$as_echo "$ax_cv_check_cflags___mavx" >&6; } -if test "x$ax_cv_check_cflags___mavx" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx" >&6; } +if test "x$ax_cv_check_cflags___mavx" = xyes +then : CFLAGS="$CFLAGS -mavx" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVX instructions set" >&5 -$as_echo_n "checking for AVX instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for AVX instructions set" >&5 +printf %s "checking for AVX instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17356,101 +20684,118 @@ $as_echo_n "checking for AVX instructions set... " >&6; } #include <immintrin.h> int -main () +main (void) { _mm256_zeroall(); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_AVXINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx" >&5 -$as_echo_n "checking whether C compiler accepts -mavx... " >&6; } -if ${ax_cv_check_cflags___mavx+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_AVXINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx" >&5 +printf %s "checking whether C compiler accepts -mavx... " >&6; } +if test ${ax_cv_check_cflags___mavx+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx=yes -else - ax_cv_check_cflags___mavx=no +else case e in #( + e) ax_cv_check_cflags___mavx=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx" >&5 -$as_echo "$ax_cv_check_cflags___mavx" >&6; } -if test "x$ax_cv_check_cflags___mavx" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx" >&6; } +if test "x$ax_cv_check_cflags___mavx" = xyes +then : CFLAGS_AVX="-mavx" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx2" >&5 -$as_echo_n "checking whether C compiler accepts -mavx2... " >&6; } -if ${ax_cv_check_cflags___mavx2+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx2" >&5 +printf %s "checking whether C compiler accepts -mavx2... " >&6; } +if test ${ax_cv_check_cflags___mavx2+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx2=yes -else - ax_cv_check_cflags___mavx2=no +else case e in #( + e) ax_cv_check_cflags___mavx2=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx2" >&5 -$as_echo "$ax_cv_check_cflags___mavx2" >&6; } -if test "x$ax_cv_check_cflags___mavx2" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx2" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx2" >&6; } +if test "x$ax_cv_check_cflags___mavx2" = xyes +then : CFLAGS="$CFLAGS -mavx2" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVX2 instructions set" >&5 -$as_echo_n "checking for AVX2 instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for AVX2 instructions set" >&5 +printf %s "checking for AVX2 instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17458,7 +20803,7 @@ $as_echo_n "checking for AVX2 instructions set... " >&6; } #include <immintrin.h> int -main () +main (void) { __m256 x = _mm256_set1_ps(3.14); @@ -17469,50 +20814,58 @@ return _mm256_movemask_ps(_mm256_cmp_ps(x, y, _CMP_NEQ_OQ)); return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_AVX2INTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx2" >&5 -$as_echo_n "checking whether C compiler accepts -mavx2... " >&6; } -if ${ax_cv_check_cflags___mavx2+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_AVX2INTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx2" >&5 +printf %s "checking whether C compiler accepts -mavx2... " >&6; } +if test ${ax_cv_check_cflags___mavx2+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx2" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx2=yes -else - ax_cv_check_cflags___mavx2=no +else case e in #( + e) ax_cv_check_cflags___mavx2=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx2" >&5 -$as_echo "$ax_cv_check_cflags___mavx2" >&6; } -if test "x$ax_cv_check_cflags___mavx2" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx2" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx2" >&6; } +if test "x$ax_cv_check_cflags___mavx2" = xyes +then : CFLAGS_AVX2="-mavx2" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _mm256_broadcastsi128_si256 is correctly defined" >&5 -$as_echo_n "checking if _mm256_broadcastsi128_si256 is correctly defined... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if _mm256_broadcastsi128_si256 is correctly defined" >&5 +printf %s "checking if _mm256_broadcastsi128_si256 is correctly defined... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17520,71 +20873,83 @@ $as_echo_n "checking if _mm256_broadcastsi128_si256 is correctly defined... " >& #include <immintrin.h> int -main () +main (void) { __m256i y = _mm256_broadcastsi128_si256(_mm_setzero_si128()); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - -$as_echo "#define _mm256_broadcastsi128_si256 _mm_broadcastsi128_si256" >>confdefs.h - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + +printf "%s\n" "#define _mm256_broadcastsi128_si256 _mm_broadcastsi128_si256" >>confdefs.h + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx512f" >&5 -$as_echo_n "checking whether C compiler accepts -mavx512f... " >&6; } -if ${ax_cv_check_cflags___mavx512f+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx512f" >&5 +printf %s "checking whether C compiler accepts -mavx512f... " >&6; } +if test ${ax_cv_check_cflags___mavx512f+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx512f" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx512f=yes -else - ax_cv_check_cflags___mavx512f=no +else case e in #( + e) ax_cv_check_cflags___mavx512f=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx512f" >&5 -$as_echo "$ax_cv_check_cflags___mavx512f" >&6; } -if test "x$ax_cv_check_cflags___mavx512f" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx512f" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx512f" >&6; } +if test "x$ax_cv_check_cflags___mavx512f" = xyes +then : CFLAGS="$CFLAGS -mavx512f" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVX512F instructions set" >&5 -$as_echo_n "checking for AVX512F instructions set... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for AVX512F instructions set" >&5 +printf %s "checking for AVX512F instructions set... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17592,7 +20957,7 @@ $as_echo_n "checking for AVX512F instructions set... " >&6; } #include <immintrin.h> int -main () +main (void) { @@ -17615,169 +20980,200 @@ __m512i y = _mm512_permutexvar_epi64(_mm512_setr_epi64(0, 1, 4, 5, 2, 3, 6, 7), return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_AVX512FINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx512f" >&5 -$as_echo_n "checking whether C compiler accepts -mavx512f... " >&6; } -if ${ax_cv_check_cflags___mavx512f+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_AVX512FINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mavx512f" >&5 +printf %s "checking whether C compiler accepts -mavx512f... " >&6; } +if test ${ax_cv_check_cflags___mavx512f+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mavx512f" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mavx512f=yes -else - ax_cv_check_cflags___mavx512f=no +else case e in #( + e) ax_cv_check_cflags___mavx512f=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx512f" >&5 -$as_echo "$ax_cv_check_cflags___mavx512f" >&6; } -if test "x$ax_cv_check_cflags___mavx512f" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mavx512f" >&5 +printf "%s\n" "$ax_cv_check_cflags___mavx512f" >&6; } +if test "x$ax_cv_check_cflags___mavx512f" = xyes +then : CFLAGS_AVX512F="-mavx512f" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - as_CACHEVAR=`$as_echo "ax_cv_check_cflags__$CFLAGS -mno-avx512f" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -mno-avx512f" >&5 -$as_echo_n "checking whether C compiler accepts $CFLAGS -mno-avx512f... " >&6; } -if eval \${$as_CACHEVAR+:} false; then : - $as_echo_n "(cached) " >&6 -else - +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + as_CACHEVAR=`printf "%s\n" "ax_cv_check_cflags__$CFLAGS -mno-avx512f" | sed "$as_sed_sh"` +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts $CFLAGS -mno-avx512f" >&5 +printf %s "checking whether C compiler accepts $CFLAGS -mno-avx512f... " >&6; } +if eval test \${$as_CACHEVAR+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS $CFLAGS -mno-avx512f" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : eval "$as_CACHEVAR=yes" -else - eval "$as_CACHEVAR=no" +else case e in #( + e) eval "$as_CACHEVAR=no" ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi eval ac_res=\$$as_CACHEVAR - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_CACHEVAR"\" = x"yes"; then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf "%s\n" "$ac_res" >&6; } +if eval test \"x\$"$as_CACHEVAR"\" = x"yes" +then : CFLAGS="$CFLAGS -mno-avx512f" -else - : +else case e in #( + e) : ;; +esac fi - + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -maes" >&5 -$as_echo_n "checking whether C compiler accepts -maes... " >&6; } -if ${ax_cv_check_cflags___maes+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -maes" >&5 +printf %s "checking whether C compiler accepts -maes... " >&6; } +if test ${ax_cv_check_cflags___maes+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -maes" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___maes=yes -else - ax_cv_check_cflags___maes=no +else case e in #( + e) ax_cv_check_cflags___maes=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___maes" >&5 -$as_echo "$ax_cv_check_cflags___maes" >&6; } -if test "x$ax_cv_check_cflags___maes" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___maes" >&5 +printf "%s\n" "$ax_cv_check_cflags___maes" >&6; } +if test "x$ax_cv_check_cflags___maes" = xyes +then : CFLAGS="$CFLAGS -maes" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mpclmul" >&5 -$as_echo_n "checking whether C compiler accepts -mpclmul... " >&6; } -if ${ax_cv_check_cflags___mpclmul+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mpclmul" >&5 +printf %s "checking whether C compiler accepts -mpclmul... " >&6; } +if test ${ax_cv_check_cflags___mpclmul+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mpclmul" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mpclmul=yes -else - ax_cv_check_cflags___mpclmul=no +else case e in #( + e) ax_cv_check_cflags___mpclmul=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mpclmul" >&5 -$as_echo "$ax_cv_check_cflags___mpclmul" >&6; } -if test "x$ax_cv_check_cflags___mpclmul" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mpclmul" >&5 +printf "%s\n" "$ax_cv_check_cflags___mpclmul" >&6; } +if test "x$ax_cv_check_cflags___mpclmul" = xyes +then : CFLAGS="$CFLAGS -mpclmul" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AESNI instructions set and PCLMULQDQ" >&5 -$as_echo_n "checking for AESNI instructions set and PCLMULQDQ... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for AESNI instructions set and PCLMULQDQ" >&5 +printf %s "checking for AESNI instructions set and PCLMULQDQ... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17786,7 +21182,7 @@ $as_echo_n "checking for AESNI instructions set and PCLMULQDQ... " >&6; } #include <wmmintrin.h> int -main () +main (void) { __m128i x = _mm_aesimc_si128(_mm_setzero_si128()); __m128i y = _mm_clmulepi64_si128(_mm_setzero_si128(), _mm_setzero_si128(), 0); @@ -17794,131 +21190,155 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_WMMINTRIN_H 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -maes" >&5 -$as_echo_n "checking whether C compiler accepts -maes... " >&6; } -if ${ax_cv_check_cflags___maes+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_WMMINTRIN_H 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -maes" >&5 +printf %s "checking whether C compiler accepts -maes... " >&6; } +if test ${ax_cv_check_cflags___maes+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -maes" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___maes=yes -else - ax_cv_check_cflags___maes=no +else case e in #( + e) ax_cv_check_cflags___maes=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___maes" >&5 -$as_echo "$ax_cv_check_cflags___maes" >&6; } -if test "x$ax_cv_check_cflags___maes" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___maes" >&5 +printf "%s\n" "$ax_cv_check_cflags___maes" >&6; } +if test "x$ax_cv_check_cflags___maes" = xyes +then : CFLAGS_AESNI="-maes" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mpclmul" >&5 -$as_echo_n "checking whether C compiler accepts -mpclmul... " >&6; } -if ${ax_cv_check_cflags___mpclmul+:} false; then : - $as_echo_n "(cached) " >&6 -else - + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mpclmul" >&5 +printf %s "checking whether C compiler accepts -mpclmul... " >&6; } +if test ${ax_cv_check_cflags___mpclmul+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mpclmul" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mpclmul=yes -else - ax_cv_check_cflags___mpclmul=no +else case e in #( + e) ax_cv_check_cflags___mpclmul=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mpclmul" >&5 -$as_echo "$ax_cv_check_cflags___mpclmul" >&6; } -if test "x$ax_cv_check_cflags___mpclmul" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mpclmul" >&5 +printf "%s\n" "$ax_cv_check_cflags___mpclmul" >&6; } +if test "x$ax_cv_check_cflags___mpclmul" = xyes +then : CFLAGS_PCLMUL="-mpclmul" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" - oldcflags="$CFLAGS" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mrdrnd" >&5 -$as_echo_n "checking whether C compiler accepts -mrdrnd... " >&6; } -if ${ax_cv_check_cflags___mrdrnd+:} false; then : - $as_echo_n "(cached) " >&6 -else - + oldcflags="$CFLAGS" + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mrdrnd" >&5 +printf %s "checking whether C compiler accepts -mrdrnd... " >&6; } +if test ${ax_cv_check_cflags___mrdrnd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mrdrnd" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mrdrnd=yes -else - ax_cv_check_cflags___mrdrnd=no +else case e in #( + e) ax_cv_check_cflags___mrdrnd=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mrdrnd" >&5 -$as_echo "$ax_cv_check_cflags___mrdrnd" >&6; } -if test "x$ax_cv_check_cflags___mrdrnd" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mrdrnd" >&5 +printf "%s\n" "$ax_cv_check_cflags___mrdrnd" >&6; } +if test "x$ax_cv_check_cflags___mrdrnd" = xyes +then : CFLAGS="$CFLAGS -mrdrnd" -else - : +else case e in #( + e) : ;; +esac fi - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RDRAND" >&5 -$as_echo_n "checking for RDRAND... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for RDRAND" >&5 +printf %s "checking for RDRAND... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -17926,61 +21346,71 @@ $as_echo_n "checking for RDRAND... " >&6; } #include <immintrin.h> int -main () +main (void) { unsigned long long x; _rdrand64_step(&x); ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - -$as_echo "#define HAVE_RDRAND 1" >>confdefs.h - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mrdrnd" >&5 -$as_echo_n "checking whether C compiler accepts -mrdrnd... " >&6; } -if ${ax_cv_check_cflags___mrdrnd+:} false; then : - $as_echo_n "(cached) " >&6 -else - +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + +printf "%s\n" "#define HAVE_RDRAND 1" >>confdefs.h + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether C compiler accepts -mrdrnd" >&5 +printf %s "checking whether C compiler accepts -mrdrnd... " >&6; } +if test ${ax_cv_check_cflags___mrdrnd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_check_save_flags=$CFLAGS CFLAGS="$CFLAGS -mrdrnd" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <time.h> int -main () +main (void) { time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x + ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ax_cv_check_cflags___mrdrnd=yes -else - ax_cv_check_cflags___mrdrnd=no +else case e in #( + e) ax_cv_check_cflags___mrdrnd=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - CFLAGS=$ax_check_save_flags + CFLAGS=$ax_check_save_flags ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mrdrnd" >&5 -$as_echo "$ax_cv_check_cflags___mrdrnd" >&6; } -if test "x$ax_cv_check_cflags___mrdrnd" = xyes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ax_cv_check_cflags___mrdrnd" >&5 +printf "%s\n" "$ax_cv_check_cflags___mrdrnd" >&6; } +if test "x$ax_cv_check_cflags___mrdrnd" = xyes +then : CFLAGS_RDRAND="-mrdrnd" -else - : +else case e in #( + e) : ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$oldcflags" @@ -17998,73 +21428,117 @@ fi -for ac_header in sys/mman.h sys/random.h intrin.h -do : - as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" -if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF + +ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_mman_h" = xyes +then : + printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h fi +ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_param_h" = xyes +then : + printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h -done +fi +ac_fn_c_check_header_compile "$LINENO" "sys/random.h" "ac_cv_header_sys_random_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_random_h" = xyes +then : + printf "%s\n" "#define HAVE_SYS_RANDOM_H 1" >>confdefs.h + +fi +ac_fn_c_check_header_compile "$LINENO" "intrin.h" "ac_cv_header_intrin_h" "$ac_includes_default" +if test "x$ac_cv_header_intrin_h" = xyes +then : + printf "%s\n" "#define HAVE_INTRIN_H 1" >>confdefs.h + +fi +ac_fn_c_check_header_compile "$LINENO" "sys/auxv.h" "ac_cv_header_sys_auxv_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_auxv_h" = xyes +then : + printf "%s\n" "#define HAVE_SYS_AUXV_H 1" >>confdefs.h + +fi +ac_fn_c_check_header_compile "$LINENO" "CommonCrypto/CommonRandom.h" "ac_cv_header_CommonCrypto_CommonRandom_h" "$ac_includes_default" +if test "x$ac_cv_header_CommonCrypto_CommonRandom_h" = xyes +then : + printf "%s\n" "#define HAVE_COMMONCRYPTO_COMMONRANDOM_H 1" >>confdefs.h -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if _xgetbv() is available" >&5 -$as_echo_n "checking if _xgetbv() is available... " >&6; } +fi + +ac_fn_c_check_header_compile "$LINENO" "cet.h" "ac_cv_header_cet_h" "$ac_includes_default" +if test "x$ac_cv_header_cet_h" = xyes +then : + printf "%s\n" "#define HAVE_CET_H 1" >>confdefs.h + +fi +ac_fn_c_check_header_compile "$LINENO" "threads.h" "ac_cv_header_threads_h" "$ac_includes_default" +if test "x$ac_cv_header_threads_h" = xyes +then : + printf "%s\n" "#define HAVE_THREADS_H 1" >>confdefs.h + +fi + + +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if _xgetbv() is available" >&5 +printf %s "checking if _xgetbv() is available... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <intrin.h> int -main () +main (void) { (void) _xgetbv(0) ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE__XGETBV 1" >>confdefs.h +printf "%s\n" "#define HAVE__XGETBV 1" >>confdefs.h -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 -$as_echo_n "checking for inline... " >&6; } -if ${ac_cv_c_inline+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_inline=no +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 +printf %s "checking for inline... " >&6; } +if test ${ac_cv_c_inline+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; -static $ac_kw foo_t static_foo () {return 0; } -$ac_kw foo_t foo () {return 0; } +static $ac_kw foo_t static_foo (void) {return 0; } +$ac_kw foo_t foo (void) {return 0; } #endif _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_c_inline=$ac_kw fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext test "$ac_cv_c_inline" != no && break done - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 -$as_echo "$ac_cv_c_inline" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 +printf "%s\n" "$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; @@ -18088,12 +21562,13 @@ case $host_cpu in #( *) : ;; esac - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 -$as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if ${ac_cv_c_bigendian+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_cv_c_bigendian=unknown + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +printf %s "checking whether byte ordering is bigendian... " >&6; } +if test ${ac_cv_c_bigendian+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_c_bigendian=unknown # See if we're dealing with a universal compiler. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18103,7 +21578,8 @@ else typedef int dummy; _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : # Check for potential -arch flags. It is not universal unless # there are at least two -arch flags with different values. @@ -18127,7 +21603,7 @@ if ac_fn_c_try_compile "$LINENO"; then : fi done fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext if test $ac_cv_c_bigendian = unknown; then # See if sys/param.h defines the BYTE_ORDER macro. cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -18136,10 +21612,10 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext #include <sys/param.h> int -main () +main (void) { -#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ - && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \\ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \\ && LITTLE_ENDIAN) bogus endian macros #endif @@ -18148,7 +21624,8 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : # It does; now see whether it defined to BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18156,7 +21633,7 @@ if ac_fn_c_try_compile "$LINENO"; then : #include <sys/param.h> int -main () +main (void) { #if BYTE_ORDER != BIG_ENDIAN not big endian @@ -18166,14 +21643,16 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_c_bigendian=yes -else - ac_cv_c_bigendian=no +else case e in #( + e) ac_cv_c_bigendian=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). @@ -18182,7 +21661,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext #include <limits.h> int -main () +main (void) { #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) bogus endian macros @@ -18192,14 +21671,15 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : # It does; now see whether it defined to _BIG_ENDIAN or not. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <limits.h> int -main () +main (void) { #ifndef _BIG_ENDIAN not big endian @@ -18209,50 +21689,55 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : +if ac_fn_c_try_compile "$LINENO" +then : ac_cv_c_bigendian=yes -else - ac_cv_c_bigendian=no +else case e in #( + e) ac_cv_c_bigendian=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext fi if test $ac_cv_c_bigendian = unknown; then # Compile a test program. - if test "$cross_compiling" = yes; then : + if test "$cross_compiling" = yes +then : # Try to guess by grepping values from an object file. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -short int ascii_mm[] = +unsigned short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; - short int ascii_ii[] = + unsigned short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; int use_ascii (int i) { return ascii_mm[i] + ascii_ii[i]; } - short int ebcdic_ii[] = + unsigned short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; - short int ebcdic_mm[] = + unsigned short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; int use_ebcdic (int i) { return ebcdic_mm[i] + ebcdic_ii[i]; } - extern int foo; - -int -main () -{ -return use_ascii (foo) == use_ebcdic (foo); - ; - return 0; -} + int + main (int argc, char **argv) + { + /* Intimidate the compiler so that it does not + optimize the arrays away. */ + char *p = argv[0]; + ascii_mm[1] = *p++; ebcdic_mm[1] = *p++; + ascii_ii[1] = *p++; ebcdic_ii[1] = *p++; + return use_ascii (argc) == use_ebcdic (*p); + } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then +if ac_fn_c_try_link "$LINENO" +then : + if grep BIGenDianSyS conftest$ac_exeext >/dev/null; then ac_cv_c_bigendian=yes fi - if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if grep LiTTleEnDian conftest$ac_exeext >/dev/null ; then if test "$ac_cv_c_bigendian" = unknown; then ac_cv_c_bigendian=no else @@ -18261,13 +21746,14 @@ if ac_fn_c_try_compile "$LINENO"; then : fi fi fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int -main () +main (void) { /* Are we little or big endian? From Harbison&Steele. */ @@ -18283,27 +21769,31 @@ main () return 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : +if ac_fn_c_try_run "$LINENO" +then : ac_cv_c_bigendian=no -else - ac_cv_c_bigendian=yes +else case e in #( + e) ac_cv_c_bigendian=yes ;; +esac fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac fi - fi + fi ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 -$as_echo "$ac_cv_c_bigendian" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +printf "%s\n" "$ac_cv_c_bigendian" >&6; } case $ac_cv_c_bigendian in #( yes) -$as_echo "#define NATIVE_BIG_ENDIAN 1" >>confdefs.h +printf "%s\n" "#define NATIVE_BIG_ENDIAN 1" >>confdefs.h ;; #( no) -$as_echo "#define NATIVE_LITTLE_ENDIAN 1" >>confdefs.h +printf "%s\n" "#define NATIVE_LITTLE_ENDIAN 1" >>confdefs.h ;; #( universal) as_fn_error $? "universal endianness is not supported - compile separately and use lipo(1)" "$LINENO" 5 @@ -18314,8 +21804,8 @@ $as_echo "#define NATIVE_LITTLE_ENDIAN 1" >>confdefs.h esac -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __STDC_LIMIT_MACROS is required" >&5 -$as_echo_n "checking whether __STDC_LIMIT_MACROS is required... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether __STDC_LIMIT_MACROS is required" >&5 +printf %s "checking whether __STDC_LIMIT_MACROS is required... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18323,7 +21813,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext #include <stdint.h> int -main () +main (void) { (void) SIZE_MAX; @@ -18333,25 +21823,28 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } CPPFLAGS="$CPPFLAGS -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS" - + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use inline asm code" >&5 -$as_echo_n "checking whether we can use inline asm code... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can use inline asm code" >&5 +printf %s "checking whether we can use inline asm code... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { int a = 42; @@ -18362,30 +21855,32 @@ __asm__ __volatile__ ("" : : "r"(pnt) : "memory"); return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_INLINE_ASM 1" >>confdefs.h +printf "%s\n" "#define HAVE_INLINE_ASM 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext HAVE_AMD64_ASM_V=0 -if test "$enable_asm" != "no"; then : +if test "$enable_asm" != "no" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use x86_64 asm code" >&5 -$as_echo_n "checking whether we can use x86_64 asm code... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can use x86_64 asm code" >&5 +printf %s "checking whether we can use x86_64 asm code... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { #if defined(__amd64) || defined(__amd64__) || defined(__x86_64__) @@ -18408,18 +21903,21 @@ __asm__ __volatile__ ("pxor %%xmm12, %%xmm6 \n" return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_AMD64_ASM 1" >>confdefs.h +printf "%s\n" "#define HAVE_AMD64_ASM 1" >>confdefs.h HAVE_AMD64_ASM_V=1 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext fi if test $HAVE_AMD64_ASM_V = 1; then @@ -18433,16 +21931,17 @@ fi HAVE_AVX_ASM_V=0 -if test "$enable_asm" != "no"; then : +if test "$enable_asm" != "no" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can assemble AVX opcodes" >&5 -$as_echo_n "checking whether we can assemble AVX opcodes... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we can assemble AVX opcodes" >&5 +printf %s "checking whether we can assemble AVX opcodes... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { #if defined(__amd64) || defined(__amd64__) || defined(__x86_64__) @@ -18459,18 +21958,21 @@ __asm__ __volatile__ ("vpunpcklqdq %xmm0,%xmm13,%xmm0"); return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_AVX_ASM 1" >>confdefs.h +printf "%s\n" "#define HAVE_AVX_ASM 1" >>confdefs.h HAVE_AVX_ASM_V=1 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext fi if test $HAVE_AVX_ASM_V = 1; then @@ -18483,8 +21985,8 @@ fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for 128-bit arithmetic" >&5 -$as_echo_n "checking for 128-bit arithmetic... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for 128-bit arithmetic" >&5 +printf %s "checking for 128-bit arithmetic... " >&6; } HAVE_TI_MODE_V=0 cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18515,7 +22017,7 @@ void fcontract(uint128_t *t) { } int -main () +main (void) { (void) fcontract; @@ -18524,18 +22026,20 @@ main () return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_compile "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_TI_MODE 1" >>confdefs.h +printf "%s\n" "#define HAVE_TI_MODE 1" >>confdefs.h HAVE_TI_MODE_V=1 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext if test $HAVE_TI_MODE_V = 1; then HAVE_TI_MODE_TRUE= HAVE_TI_MODE_FALSE='#' @@ -18547,15 +22051,16 @@ fi HAVE_CPUID_V=0 -if test "$enable_asm" != "no"; then : +if test "$enable_asm" != "no" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cpuid instruction" >&5 -$as_echo_n "checking for cpuid instruction... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for cpuid instruction" >&5 +printf %s "checking for cpuid instruction... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { unsigned int cpu_info[4]; @@ -18568,32 +22073,36 @@ __asm__ __volatile__ ("xchgl %%ebx, %k1; cpuid; xchgl %%ebx, %k1" : return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_CPUID 1" >>confdefs.h +printf "%s\n" "#define HAVE_CPUID 1" >>confdefs.h HAVE_CPUID_V=1 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext fi asm_hide_symbol="unsupported" -if test "$enable_asm" != "no"; then : +if test "$enable_asm" != "no" +then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the .private_extern asm directive is supported" >&5 -$as_echo_n "checking if the .private_extern asm directive is supported... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the .private_extern asm directive is supported" >&5 +printf %s "checking if the .private_extern asm directive is supported... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { __asm__ __volatile__ (".private_extern dummy_symbol \n" @@ -18609,24 +22118,26 @@ __asm__ __volatile__ (".private_extern dummy_symbol \n" return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } asm_hide_symbol=".private_extern" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the .hidden asm directive is supported" >&5 -$as_echo_n "checking if the .hidden asm directive is supported... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the .hidden asm directive is supported" >&5 +printf %s "checking if the .hidden asm directive is supported... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { __asm__ __volatile__ (".hidden dummy_symbol \n" @@ -18642,38 +22153,41 @@ __asm__ __volatile__ (".hidden dummy_symbol \n" return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - if test "$asm_hide_symbol" = "unsupported"; then : +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + if test "$asm_hide_symbol" = "unsupported" +then : asm_hide_symbol=".hidden" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: unable to reliably tag symbols as private" >&5 -$as_echo "$as_me: unable to reliably tag symbols as private" >&6;} - asm_hide_symbol="unsupported" +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: unable to reliably tag symbols as private" >&5 +printf "%s\n" "$as_me: unable to reliably tag symbols as private" >&6;} + asm_hide_symbol="unsupported" ;; +esac fi -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - if test "$asm_hide_symbol" != "unsupported"; then : + if test "$asm_hide_symbol" != "unsupported" +then : -cat >>confdefs.h <<_ACEOF -#define ASM_HIDE_SYMBOL $asm_hide_symbol -_ACEOF +printf "%s\n" "#define ASM_HIDE_SYMBOL $asm_hide_symbol" >>confdefs.h fi fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if weak symbols are supported" >&5 -$as_echo_n "checking if weak symbols are supported... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if weak symbols are supported" >&5 +printf %s "checking if weak symbols are supported... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -18684,7 +22198,7 @@ __attribute__((weak)) void __dummy(void *x) { } void f(void *x) { __dummy(x); } int -main () +main (void) { @@ -18692,115 +22206,143 @@ main () return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h +printf "%s\n" "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if data alignment is required" >&5 -$as_echo_n "checking if data alignment is required... " >&6; } -aligned_access_required=yes -case $host_cpu in #( - i?86|amd64|x86_64|powerpc*|s390*) : - aligned_access_required=no ;; #( - arm*) : - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if atomic operations are supported" >&5 +printf %s "checking if atomic operations are supported... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifndef __ARM_FEATURE_UNALIGNED -# error data alignment is required -#endif - int -main () +main (void) { +static volatile int _sodium_lock; +__sync_lock_test_and_set(&_sodium_lock, 1); +__sync_lock_release(&_sodium_lock); + + ; return 0; } _ACEOF -if ac_fn_c_try_compile "$LINENO"; then : - aligned_access_required=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - ;; #( - *) : - ;; -esac -if test "x$aligned_access_required" = "xyes"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define CPU_UNALIGNED_ACCESS 1" >>confdefs.h +printf "%s\n" "#define HAVE_ATOMIC_OPS 1" >>confdefs.h +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if atomic operations are supported" >&5 -$as_echo_n "checking if atomic operations are supported... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if C11 memory fences are supported" >&5 +printf %s "checking if C11 memory fences are supported... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include <stdatomic.h> + int -main () +main (void) { -static volatile int _sodium_lock; -__sync_lock_test_and_set(&_sodium_lock, 1); -__sync_lock_release(&_sodium_lock); +atomic_thread_fence(memory_order_acquire); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } -$as_echo "#define HAVE_ATOMIC_OPS 1" >>confdefs.h +printf "%s\n" "#define HAVE_C11_MEMORY_FENCES 1" >>confdefs.h -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if gcc memory fences are supported" >&5 +printf %s "checking if gcc memory fences are supported... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main (void) +{ -ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" -if test "x$ac_cv_type_size_t" = xyes; then : +__atomic_thread_fence(__ATOMIC_ACQUIRE); -else -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int + ; + return 0; +} _ACEOF +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } +printf "%s\n" "#define HAVE_GCC_MEMORY_FENCES 1" >>confdefs.h + +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext + + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes +then : + +else case e in #( + e) +printf "%s\n" "#define size_t unsigned int" >>confdefs.h + ;; +esac fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 -$as_echo_n "checking for working alloca.h... " >&6; } -if ${ac_cv_working_alloca_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 +printf %s "checking for working alloca.h... " >&6; } +if test ${ac_cv_working_alloca_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <alloca.h> int -main () +main (void) { char *p = (char *) alloca (2 * sizeof (int)); if (p) return 0; @@ -18808,52 +22350,54 @@ char *p = (char *) alloca (2 * sizeof (int)); return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_working_alloca_h=yes -else - ac_cv_working_alloca_h=no +else case e in #( + e) ac_cv_working_alloca_h=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 -$as_echo "$ac_cv_working_alloca_h" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 +printf "%s\n" "$ac_cv_working_alloca_h" >&6; } if test $ac_cv_working_alloca_h = yes; then -$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h +printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 -$as_echo_n "checking for alloca... " >&6; } -if ${ac_cv_func_alloca_works+:} false; then : - $as_echo_n "(cached) " >&6 -else +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 +printf %s "checking for alloca... " >&6; } +if test ${ac_cv_func_alloca_works+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_func_alloca_works=$ac_cv_working_alloca_h +if test "$ac_cv_func_alloca_works" != yes +then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#ifdef __GNUC__ -# define alloca __builtin_alloca -#else -# ifdef _MSC_VER +#include <stdlib.h> +#include <stddef.h> +#ifndef alloca +# ifdef __GNUC__ +# define alloca __builtin_alloca +# elif defined _MSC_VER # include <malloc.h> # define alloca _alloca # else -# ifdef HAVE_ALLOCA_H -# include <alloca.h> -# else -# ifdef _AIX - #pragma alloca -# else -# ifndef alloca /* predefined by HP cc +Olibcalls */ -void *alloca (size_t); -# endif -# endif +# ifdef __cplusplus +extern "C" # endif +void *alloca (size_t); # endif #endif int -main () +main (void) { char *p = (char *) alloca (1); if (p) return 0; @@ -18861,20 +22405,21 @@ char *p = (char *) alloca (1); return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_func_alloca_works=yes -else - ac_cv_func_alloca_works=no fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext +fi ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 -$as_echo "$ac_cv_func_alloca_works" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 +printf "%s\n" "$ac_cv_func_alloca_works" >&6; } if test $ac_cv_func_alloca_works = yes; then -$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h +printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h else # The SVR3 libPW and SVR4 libucb both contain incompatible functions @@ -18884,59 +22429,20 @@ else ALLOCA=\${LIBOBJDIR}alloca.$ac_objext -$as_echo "#define C_ALLOCA 1" >>confdefs.h - - -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 -$as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } -if ${ac_cv_os_cray+:} false; then : - $as_echo_n "(cached) " >&6 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#if defined CRAY && ! defined CRAY2 -webecray -#else -wenotbecray -#endif - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "webecray" >/dev/null 2>&1; then : - ac_cv_os_cray=yes -else - ac_cv_os_cray=no -fi -rm -f conftest* - -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 -$as_echo "$ac_cv_os_cray" >&6; } -if test $ac_cv_os_cray = yes; then - for ac_func in _getb67 GETB67 getb67; do - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - -cat >>confdefs.h <<_ACEOF -#define CRAY_STACKSEG_END $ac_func -_ACEOF - - break -fi +printf "%s\n" "#define C_ALLOCA 1" >>confdefs.h - done -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 -$as_echo_n "checking stack direction for C alloca... " >&6; } -if ${ac_cv_c_stack_direction+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then : +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 +printf %s "checking stack direction for C alloca... " >&6; } +if test ${ac_cv_c_stack_direction+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test "$cross_compiling" = yes +then : ac_cv_c_stack_direction=0 -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext +else case e in #( + e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int @@ -18956,54 +22462,89 @@ main (int argc, char **argv) return find_stack_direction (0, argc + !argv + 20) < 0; } _ACEOF -if ac_fn_c_try_run "$LINENO"; then : +if ac_fn_c_try_run "$LINENO" +then : ac_cv_c_stack_direction=1 -else - ac_cv_c_stack_direction=-1 +else case e in #( + e) ac_cv_c_stack_direction=-1 ;; +esac fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext + conftest.$ac_objext conftest.beam conftest.$ac_ext ;; +esac +fi + ;; +esac fi +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 +printf "%s\n" "$ac_cv_c_stack_direction" >&6; } +printf "%s\n" "#define STACK_DIRECTION $ac_cv_c_stack_direction" >>confdefs.h + fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 -$as_echo "$ac_cv_c_stack_direction" >&6; } -cat >>confdefs.h <<_ACEOF -#define STACK_DIRECTION $ac_cv_c_stack_direction -_ACEOF +if test "x$EMSCRIPTEN" = "x" +then : + + ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random" +if test "x$ac_cv_func_arc4random" = xyes +then : + printf "%s\n" "#define HAVE_ARC4RANDOM 1" >>confdefs.h fi +ac_fn_c_check_func "$LINENO" "arc4random_buf" "ac_cv_func_arc4random_buf" +if test "x$ac_cv_func_arc4random_buf" = xyes +then : + printf "%s\n" "#define HAVE_ARC4RANDOM_BUF 1" >>confdefs.h -if test "x$EMSCRIPTEN" = "x"; then : +fi - for ac_func in arc4random arc4random_buf -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF + if test "x$WASI" = "x" +then : + + ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap" +if test "x$ac_cv_func_mmap" = xyes +then : + printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h fi -done +ac_fn_c_check_func "$LINENO" "mlock" "ac_cv_func_mlock" +if test "x$ac_cv_func_mlock" = xyes +then : + printf "%s\n" "#define HAVE_MLOCK 1" >>confdefs.h - for ac_func in mmap mlock madvise mprotect -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +fi +ac_fn_c_check_func "$LINENO" "madvise" "ac_cv_func_madvise" +if test "x$ac_cv_func_madvise" = xyes +then : + printf "%s\n" "#define HAVE_MADVISE 1" >>confdefs.h + +fi +ac_fn_c_check_func "$LINENO" "mprotect" "ac_cv_func_mprotect" +if test "x$ac_cv_func_mprotect" = xyes +then : + printf "%s\n" "#define HAVE_MPROTECT 1" >>confdefs.h + +fi + + ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise" +if test "x$ac_cv_func_raise" = xyes +then : + printf "%s\n" "#define HAVE_RAISE 1" >>confdefs.h fi -done + ac_fn_c_check_func "$LINENO" "sysconf" "ac_cv_func_sysconf" +if test "x$ac_cv_func_sysconf" = xyes +then : + printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getrandom with a standard API" >&5 -$as_echo_n "checking for getrandom with a standard API... " >&6; } +fi + + +fi + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getrandom with a standard API" >&5 +printf %s "checking for getrandom with a standard API... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -19016,40 +22557,40 @@ $as_echo_n "checking for getrandom with a standard API... " >&6; } #endif int -main () +main (void) { unsigned char buf; -(void) getrandom((void *) &buf, 1U, 0U); +if (&getrandom != NULL) { + (void) getrandom((void *) &buf, 1U, 0U); +} ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - for ac_func in getrandom -do : - ac_fn_c_check_func "$LINENO" "getrandom" "ac_cv_func_getrandom" -if test "x$ac_cv_func_getrandom" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETRANDOM 1 -_ACEOF +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + ac_fn_c_check_func "$LINENO" "getrandom" "ac_cv_func_getrandom" +if test "x$ac_cv_func_getrandom" = xyes +then : + printf "%s\n" "#define HAVE_GETRANDOM 1" >>confdefs.h fi -done - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getentropy with a standard API" >&5 -$as_echo_n "checking for getentropy with a standard API... " >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getentropy with a standard API" >&5 +printf %s "checking for getentropy with a standard API... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -19062,405 +22603,159 @@ $as_echo_n "checking for getentropy with a standard API... " >&6; } #endif int -main () +main (void) { -#ifdef __APPLE__ -# error getentropy() is currently disabled on Apple operating systems -#endif - unsigned char buf; -(void) getentropy((void *) &buf, 1U); +if (&getentropy != NULL) { + (void) getentropy((void *) &buf, 1U); +} ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } - for ac_func in getentropy -do : - ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy" -if test "x$ac_cv_func_getentropy" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_GETENTROPY 1 -_ACEOF - -fi -done - -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } - -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext - -fi -for ac_func in posix_memalign getpid nanosleep -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - -for ac_func in memset_s explicit_bzero explicit_memset -do : - as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" -if eval test \"x\$"$as_ac_var"\" = x"yes"; then : - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done - - - - -TEST_LDFLAGS='' -if test "x$EMSCRIPTEN" != "x"; then : - - EXEEXT=.js - TEST_LDFLAGS='--memory-init-file 0 --pre-js pre.js.inc -s RESERVED_FUNCTION_POINTERS=8' - -fi +if ac_fn_c_try_link "$LINENO" +then : + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf "%s\n" "yes" >&6; } + ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy" +if test "x$ac_cv_func_getentropy" = xyes +then : + printf "%s\n" "#define HAVE_GETENTROPY 1" >>confdefs.h - if test "x$EMSCRIPTEN" != "x"; then - EMSCRIPTEN_TRUE= - EMSCRIPTEN_FALSE='#' -else - EMSCRIPTEN_TRUE='#' - EMSCRIPTEN_FALSE= fi - if test "x$WASI" != "x"; then - WASI_TRUE= - WASI_FALSE='#' -else - WASI_TRUE='#' - WASI_FALSE= +else case e in #( + e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf "%s\n" "no" >&6; } + ;; +esac fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +fi +if test "x$WASI" = "x" +then : -$as_echo "#define CONFIGURED 1" >>confdefs.h + ac_fn_c_check_func "$LINENO" "getpid" "ac_cv_func_getpid" +if test "x$ac_cv_func_getpid" = xyes +then : + printf "%s\n" "#define HAVE_GETPID 1" >>confdefs.h +fi + ac_fn_c_check_func "$LINENO" "getauxval" "ac_cv_func_getauxval" +if test "x$ac_cv_func_getauxval" = xyes +then : + printf "%s\n" "#define HAVE_GETAUXVAL 1" >>confdefs.h +fi +ac_fn_c_check_func "$LINENO" "elf_aux_info" "ac_cv_func_elf_aux_info" +if test "x$ac_cv_func_elf_aux_info" = xyes +then : + printf "%s\n" "#define HAVE_ELF_AUX_INFO 1" >>confdefs.h -enable_win32_dll=yes +fi -case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args. -set dummy ${ac_tool_prefix}as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$AS"; then - ac_cv_prog_AS="$AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_AS="${ac_tool_prefix}as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS fi -fi -AS=$ac_cv_prog_AS -if test -n "$AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 -$as_echo "$AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +ac_fn_c_check_func "$LINENO" "posix_memalign" "ac_cv_func_posix_memalign" +if test "x$ac_cv_func_posix_memalign" = xyes +then : + printf "%s\n" "#define HAVE_POSIX_MEMALIGN 1" >>confdefs.h fi -if test -z "$ac_cv_prog_AS"; then - ac_ct_AS=$AS - # Extract the first word of "as", so it can be a program name with args. -set dummy as; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_AS+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_AS"; then - ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_AS="as" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +ac_fn_c_check_func "$LINENO" "nanosleep" "ac_cv_func_nanosleep" +if test "x$ac_cv_func_nanosleep" = xyes +then : + printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h fi -fi -ac_ct_AS=$ac_cv_prog_ac_ct_AS -if test -n "$ac_ct_AS"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5 -$as_echo "$ac_ct_AS" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime" +if test "x$ac_cv_func_clock_gettime" = xyes +then : + printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h - if test "x$ac_ct_AS" = x; then - AS="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - AS=$ac_ct_AS - fi -else - AS="$ac_cv_prog_AS" fi - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. -set dummy ${ac_tool_prefix}dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$DLLTOOL"; then - ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS -fi -fi -DLLTOOL=$ac_cv_prog_DLLTOOL -if test -n "$DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 -$as_echo "$DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +if test "x$WASI" = "x" +then : + ac_fn_c_check_func "$LINENO" "memset_s" "ac_cv_func_memset_s" +if test "x$ac_cv_func_memset_s" = xyes +then : + printf "%s\n" "#define HAVE_MEMSET_S 1" >>confdefs.h fi -if test -z "$ac_cv_prog_DLLTOOL"; then - ac_ct_DLLTOOL=$DLLTOOL - # Extract the first word of "dlltool", so it can be a program name with args. -set dummy dlltool; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_DLLTOOL"; then - ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_DLLTOOL="dlltool" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS +ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero" +if test "x$ac_cv_func_explicit_bzero" = xyes +then : + printf "%s\n" "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h fi +ac_fn_c_check_func "$LINENO" "memset_explicit" "ac_cv_func_memset_explicit" +if test "x$ac_cv_func_memset_explicit" = xyes +then : + printf "%s\n" "#define HAVE_MEMSET_EXPLICIT 1" >>confdefs.h + fi -ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL -if test -n "$ac_ct_DLLTOOL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 -$as_echo "$ac_ct_DLLTOOL" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi +ac_fn_c_check_func "$LINENO" "explicit_memset" "ac_cv_func_explicit_memset" +if test "x$ac_cv_func_explicit_memset" = xyes +then : + printf "%s\n" "#define HAVE_EXPLICIT_MEMSET 1" >>confdefs.h - if test "x$ac_ct_DLLTOOL" = x; then - DLLTOOL="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - DLLTOOL=$ac_ct_DLLTOOL - fi -else - DLLTOOL="$ac_cv_prog_DLLTOOL" fi - if test -n "$ac_tool_prefix"; then - # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. -set dummy ${ac_tool_prefix}objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$OBJDUMP"; then - ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS fi -fi -OBJDUMP=$ac_cv_prog_OBJDUMP -if test -n "$OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 -$as_echo "$OBJDUMP" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } -fi -fi -if test -z "$ac_cv_prog_OBJDUMP"; then - ac_ct_OBJDUMP=$OBJDUMP - # Extract the first word of "objdump", so it can be a program name with args. -set dummy objdump; ac_word=$2 -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_OBJDUMP"; then - ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_prog_ac_ct_OBJDUMP="objdump" - $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done - done -IFS=$as_save_IFS + +TEST_LDFLAGS='' +if test "x$EMSCRIPTEN" != "x" +then : + + EXEEXT=.js + TEST_LDFLAGS='--pre-js pre.js.inc -s RESERVED_FUNCTION_POINTERS=8' fi -fi -ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP -if test -n "$ac_ct_OBJDUMP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 -$as_echo "$ac_ct_OBJDUMP" >&6; } + + if test "x$EMSCRIPTEN" != "x"; then + EMSCRIPTEN_TRUE= + EMSCRIPTEN_FALSE='#' else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + EMSCRIPTEN_TRUE='#' + EMSCRIPTEN_FALSE= fi - if test "x$ac_ct_OBJDUMP" = x; then - OBJDUMP="false" - else - case $cross_compiling:$ac_tool_warned in -yes:) -{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 -$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} -ac_tool_warned=yes ;; -esac - OBJDUMP=$ac_ct_OBJDUMP - fi + if test "x$WASI" != "x"; then + WASI_TRUE= + WASI_FALSE='#' else - OBJDUMP="$ac_cv_prog_OBJDUMP" + WASI_TRUE='#' + WASI_FALSE= fi - ;; -esac - -test -z "$AS" && AS=as - - +printf "%s\n" "#define CONFIGURED 1" >>confdefs.h -test -z "$DLLTOOL" && DLLTOOL=dlltool - - -test -z "$OBJDUMP" && OBJDUMP=objdump - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gcc/ld supports -Wl,--output-def" >&5 -$as_echo_n "checking if gcc/ld supports -Wl,--output-def... " >&6; } -if ${gl_cv_ld_output_def+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test "$enable_shared" = no; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if gcc/ld supports -Wl,--output-def" >&5 +printf %s "checking if gcc/ld supports -Wl,--output-def... " >&6; } +if test ${gl_cv_ld_output_def+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test "$enable_shared" = no; then gl_cv_ld_output_def="not needed, shared libraries are disabled" else gl_ldflags_save=$LDFLAGS @@ -19469,26 +22764,29 @@ else /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : gl_cv_ld_output_def=yes -else - gl_cv_ld_output_def=no +else case e in #( + e) gl_cv_ld_output_def=no ;; +esac fi -rm -f core conftest.err conftest.$ac_objext \ +rm -f core conftest.err conftest.$ac_objext conftest.beam \ conftest$ac_exeext conftest.$ac_ext rm -f conftest.def LDFLAGS="$gl_ldflags_save" - fi + fi ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_ld_output_def" >&5 -$as_echo "$gl_cv_ld_output_def" >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_ld_output_def" >&5 +printf "%s\n" "$gl_cv_ld_output_def" >&6; } if test "x$gl_cv_ld_output_def" = "xyes"; then HAVE_LD_OUTPUT_DEF_TRUE= HAVE_LD_OUTPUT_DEF_FALSE='#' @@ -19502,13 +22800,14 @@ fi -if test "x$ENABLE_CWFLAGS" = "xyes"; then : +if test "x$ENABLE_CWFLAGS" = "xyes" +then : CFLAGS="$CFLAGS $CWFLAGS" fi -ac_config_files="$ac_config_files Makefile builds/Makefile contrib/Makefile dist-build/Makefile libsodium.pc libsodium-uninstalled.pc msvc-scripts/Makefile src/Makefile src/libsodium/Makefile src/libsodium/include/Makefile src/libsodium/include/sodium/version.h test/default/Makefile test/Makefile" +ac_config_files="$ac_config_files Makefile builds/Makefile contrib/Makefile dist-build/Makefile libsodium.pc libsodium-uninstalled.pc src/Makefile src/libsodium/Makefile src/libsodium/include/Makefile src/libsodium/include/sodium/version.h test/default/Makefile test/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure @@ -19520,8 +22819,8 @@ cat >confcache <<\_ACEOF # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # -# `ac_cv_env_foo' variables (set or unset) will be overridden when -# loading this file, other *unset* `ac_cv_foo' will be assigned the +# 'ac_cv_env_foo' variables (set or unset) will be overridden when +# loading this file, other *unset* 'ac_cv_foo' will be assigned the # following values. _ACEOF @@ -19537,8 +22836,8 @@ _ACEOF case $ac_val in #( *${as_nl}*) case $ac_var in #( - *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 -$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; + *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 +printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( @@ -19551,14 +22850,14 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) - # `set' does not quote correctly, so add quotes: double-quote + # 'set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) - # `set' quotes correctly as required by POSIX, so do not add quotes. + # 'set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | @@ -19568,15 +22867,15 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; /^ac_cv_env_/b end t clear :clear - s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ + s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 -$as_echo "$as_me: updating cache $cache_file" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 +printf "%s\n" "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else @@ -19590,8 +22889,8 @@ $as_echo "$as_me: updating cache $cache_file" >&6;} fi fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 -$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 +printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache @@ -19622,9 +22921,7 @@ s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g t quote b any :quote -s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g -s/\[/\\&/g -s/\]/\\&/g +s/[][ `~#$^&*(){}\\|;'\''"<>?]/\\&/g s/\$/$$/g H :any @@ -19644,7 +22941,7 @@ U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' - ac_i=`$as_echo "$ac_i" | sed "$ac_script"` + ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" @@ -19655,14 +22952,26 @@ LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 -$as_echo_n "checking that generated files are newer than configure... " >&6; } +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 +printf %s "checking that generated files are newer than configure... " >&6; } if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 -$as_echo "done" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: done" >&5 +printf "%s\n" "done" >&6; } +case $enable_silent_rules in # ((( + yes) AM_DEFAULT_VERBOSITY=0;; + no) AM_DEFAULT_VERBOSITY=1;; +esac +if test $am_cv_make_support_nested_variables = yes; then + AM_V='$(V)' + AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' +else + AM_V=$AM_DEFAULT_VERBOSITY + AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY +fi + if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' @@ -19683,6 +22992,10 @@ if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then + as_fn_error $? "conditional \"am__fastdepCCAS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${MINIMAL_TRUE}" && test -z "${MINIMAL_FALSE}"; then as_fn_error $? "conditional \"MINIMAL\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -19691,10 +23004,6 @@ if test -z "${VALGRIND_ENABLED_TRUE}" && test -z "${VALGRIND_ENABLED_FALSE}"; th as_fn_error $? "conditional \"VALGRIND_ENABLED\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi -if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then - as_fn_error $? "conditional \"am__fastdepCCAS\" was never defined. -Usually this means the macro was only invoked conditionally." "$LINENO" 5 -fi if test -z "${HAVE_AMD64_ASM_TRUE}" && test -z "${HAVE_AMD64_ASM_FALSE}"; then as_fn_error $? "conditional \"HAVE_AMD64_ASM\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -19724,8 +23033,8 @@ fi ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" -{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 -$as_echo "$as_me: creating $CONFIG_STATUS" >&6;} +{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 +printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL @@ -19748,63 +23057,65 @@ cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh -if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : +if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 +then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST -else - case `(set -o) 2>/dev/null` in #( +else case e in #( + e) case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; +esac ;; esac fi + +# Reset variables that may have inherited troublesome values from +# the environment. + +# IFS needs to be set, to space, tab, and newline, in precisely that order. +# (If _AS_PATH_WALK were called with IFS unset, it would have the +# side effect of setting IFS to empty, thus disabling word splitting.) +# Quoting is to prevent editors from complaining about space-tab. as_nl=' ' export as_nl -# Printing a long string crashes Solaris 7 /usr/bin/printf. -as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo -as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo -# Prefer a ksh shell builtin over an external printf program on Solaris, -# but without wasting forks for bash or zsh. -if test -z "$BASH_VERSION$ZSH_VERSION" \ - && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='print -r --' - as_echo_n='print -rn --' -elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then - as_echo='printf %s\n' - as_echo_n='printf %s' -else - if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then - as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' - as_echo_n='/usr/ucb/echo -n' - else - as_echo_body='eval expr "X$1" : "X\\(.*\\)"' - as_echo_n_body='eval - arg=$1; - case $arg in #( - *"$as_nl"*) - expr "X$arg" : "X\\(.*\\)$as_nl"; - arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; - esac; - expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" - ' - export as_echo_n_body - as_echo_n='sh -c $as_echo_n_body as_echo' - fi - export as_echo_body - as_echo='sh -c $as_echo_body as_echo' -fi +IFS=" "" $as_nl" + +PS1='$ ' +PS2='> ' +PS4='+ ' + +# Ensure predictable behavior from utilities with locale-dependent output. +LC_ALL=C +export LC_ALL +LANGUAGE=C +export LANGUAGE + +# We cannot yet rely on "unset" to work, but we need these variables +# to be unset--not just set to an empty or harmless value--now, to +# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct +# also avoids known problems related to "unset" and subshell syntax +# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). +for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH +do eval test \${$as_var+y} \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : +done + +# Ensure that fds 0, 1, and 2 are open. +if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi +if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi +if (exec 3>&2) ; then :; else exec 2>/dev/null; fi # The user is always right. -if test "${PATH_SEPARATOR+set}" != set; then +if ${PATH_SEPARATOR+false} :; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || @@ -19813,13 +23124,6 @@ if test "${PATH_SEPARATOR+set}" != set; then fi -# IFS -# We need space, tab and new line, in precisely that order. Quoting is -# there to prevent editors from complaining about space-tab. -# (If _AS_PATH_WALK were called with IFS unset, it would disable word -# splitting by setting IFS to empty value.) -IFS=" "" $as_nl" - # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( @@ -19828,43 +23132,27 @@ case $0 in #(( for as_dir in $PATH do IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + case $as_dir in #((( + '') as_dir=./ ;; + */) ;; + *) as_dir=$as_dir/ ;; + esac + test -r "$as_dir$0" && as_myself=$as_dir$0 && break done IFS=$as_save_IFS ;; esac -# We did not find ourselves, most probably we were run as `sh COMMAND' +# We did not find ourselves, most probably we were run as 'sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then - $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 + printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi -# Unset variables that we do not need and which cause bugs (e.g. in -# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" -# suppresses any "Segmentation fault" message there. '((' could -# trigger a bug in pdksh 5.2.14. -for as_var in BASH_ENV ENV MAIL MAILPATH -do eval test x\${$as_var+set} = xset \ - && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : -done -PS1='$ ' -PS2='> ' -PS4='+ ' - -# NLS nuisances. -LC_ALL=C -export LC_ALL -LANGUAGE=C -export LANGUAGE - -# CDPATH. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] @@ -19877,9 +23165,9 @@ as_fn_error () as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi - $as_echo "$as_me: error: $2" >&2 + printf "%s\n" "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error @@ -19910,22 +23198,25 @@ as_fn_unset () { eval $1=; unset $1;} } as_unset=as_fn_unset + # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. -if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null +then : eval 'as_fn_append () { eval $1+=\$2 }' -else - as_fn_append () +else case e in #( + e) as_fn_append () { eval $1=\$$1\$2 - } + } ;; +esac fi # as_fn_append # as_fn_arith ARG... @@ -19933,16 +23224,18 @@ fi # as_fn_append # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. -if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null +then : eval 'as_fn_arith () { as_val=$(( $* )) }' -else - as_fn_arith () +else case e in #( + e) as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` - } + } ;; +esac fi # as_fn_arith @@ -19969,7 +23262,7 @@ as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$0" | +printf "%s\n" X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q @@ -19991,6 +23284,10 @@ as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits + +# Determine whether it's possible to make 'echo' print without a newline. +# These variables are no longer used directly by Autoconf, but are AC_SUBSTed +# for compatibility with existing Makefiles. ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) @@ -20004,6 +23301,12 @@ case `echo -n x` in #((((( ECHO_N='-n';; esac +# For backward compatibility with old third-party macros, we provide +# the shell variables $as_echo and $as_echo_n. New code should use +# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. +as_echo='printf %s\n' +as_echo_n='printf %s' + rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file @@ -20015,9 +23318,9 @@ if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: - # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. - # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. - # In both cases, we have to default to `cp -pR'. + # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail. + # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable. + # In both cases, we have to default to 'cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then @@ -20045,7 +23348,7 @@ as_fn_mkdir_p () as_dirs= while :; do case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( + *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" @@ -20054,7 +23357,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | +printf "%s\n" X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -20098,10 +23401,12 @@ as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. -as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" +as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g" +as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated # Sed expression to map a string onto a valid variable name. -as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" +as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g" +as_tr_sh="eval sed '$as_sed_sh'" # deprecated exec 6>&1 @@ -20116,8 +23421,8 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by libsodium $as_me 1.0.18, which was -generated by GNU Autoconf 2.69. Invocation command line was +This file was extended by libsodium $as_me 1.0.20, which was +generated by GNU Autoconf 2.72. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -20145,7 +23450,7 @@ _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ -\`$as_me' instantiates files and other configuration actions +'$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. @@ -20168,17 +23473,19 @@ Configuration commands: $config_commands Report bugs to <https://github.com/jedisct1/libsodium/issues>. -libsodium home page: <https://github.com/jedisct1/libsodium>." +libsodium home page: <https://libsodium.org>." _ACEOF +ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"` +ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"` cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -libsodium config.status 1.0.18 -configured by $0, generated by GNU Autoconf 2.69, +libsodium config.status 1.0.20 +configured by $0, generated by GNU Autoconf 2.72, with options \\"\$ac_cs_config\\" -Copyright (C) 2012 Free Software Foundation, Inc. +Copyright (C) 2023 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." @@ -20218,28 +23525,28 @@ do -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) - $as_echo "$ac_cs_version"; exit ;; + printf "%s\n" "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) - $as_echo "$ac_cs_config"; exit ;; + printf "%s\n" "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in - *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; + *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --he | --h | --help | --hel | -h ) - $as_echo "$ac_cs_usage"; exit ;; + printf "%s\n" "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. - -*) as_fn_error $? "unrecognized option: \`$1' -Try \`$0 --help' for more information." ;; + -*) as_fn_error $? "unrecognized option: '$1' +Try '$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; @@ -20260,7 +23567,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift - \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 + \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" @@ -20274,7 +23581,7 @@ exec 5>>config.log sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX - $as_echo "$ac_log" + printf "%s\n" "$ac_log" } >&5 _ACEOF @@ -20326,6 +23633,7 @@ lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_q lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +FILECMD='`$ECHO "$FILECMD" | $SED "$delay_single_quote_subst"`' OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' @@ -20334,6 +23642,7 @@ want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +lt_ar_flags='`$ECHO "$lt_ar_flags" | $SED "$delay_single_quote_subst"`' AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' @@ -20427,7 +23736,6 @@ enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_sub enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' -AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' @@ -20455,6 +23763,7 @@ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ +FILECMD \ OBJDUMP \ deplibs_check_method \ file_magic_cmd \ @@ -20463,7 +23772,6 @@ want_nocaseglob \ DLLTOOL \ sharedlib_from_linklib_cmd \ AR \ -AR_FLAGS \ archiver_list_spec \ STRIP \ RANLIB \ @@ -20509,8 +23817,7 @@ soname_spec \ install_override_mode \ finish_eval \ old_striplib \ -striplib \ -AS; do +striplib; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes @@ -20585,7 +23892,6 @@ do "dist-build/Makefile") CONFIG_FILES="$CONFIG_FILES dist-build/Makefile" ;; "libsodium.pc") CONFIG_FILES="$CONFIG_FILES libsodium.pc" ;; "libsodium-uninstalled.pc") CONFIG_FILES="$CONFIG_FILES libsodium-uninstalled.pc" ;; - "msvc-scripts/Makefile") CONFIG_FILES="$CONFIG_FILES msvc-scripts/Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "src/libsodium/Makefile") CONFIG_FILES="$CONFIG_FILES src/libsodium/Makefile" ;; "src/libsodium/include/Makefile") CONFIG_FILES="$CONFIG_FILES src/libsodium/include/Makefile" ;; @@ -20593,7 +23899,7 @@ do "test/default/Makefile") CONFIG_FILES="$CONFIG_FILES test/default/Makefile" ;; "test/Makefile") CONFIG_FILES="$CONFIG_FILES test/Makefile" ;; - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + *) as_fn_error $? "invalid argument: '$ac_config_target'" "$LINENO" 5;; esac done @@ -20603,8 +23909,8 @@ done # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then - test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files - test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands + test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files + test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree @@ -20612,7 +23918,7 @@ fi # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: -# after its creation but before its name has been assigned to `$tmp'. +# after its creation but before its name has been assigned to '$tmp'. $debug || { tmp= ac_tmp= @@ -20636,7 +23942,7 @@ ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. -# This happens for instance with `./config.status config.h'. +# This happens for instance with './config.status config.h'. if test -n "$CONFIG_FILES"; then @@ -20802,7 +24108,7 @@ do esac case $ac_mode$ac_tag in :[FHL]*:*);; - :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; + :L* | :C*:*) as_fn_error $? "invalid tag '$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac @@ -20824,33 +24130,33 @@ do -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, - # because $ac_f cannot contain `:'. + # because $ac_f cannot contain ':'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || - as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; + as_fn_error 1 "cannot find input file: '$ac_f'" "$LINENO" 5;; esac - case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac + case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done - # Let's still pretend it is `configure' which instantiates (i.e., don't + # Let's still pretend it is 'configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` - $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' + printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" - { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 -$as_echo "$as_me: creating $ac_file" >&6;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 +printf "%s\n" "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) - ac_sed_conf_input=`$as_echo "$configure_input" | + ac_sed_conf_input=`printf "%s\n" "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac @@ -20867,7 +24173,7 @@ $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$ac_file" | +printf "%s\n" X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -20891,9 +24197,9 @@ $as_echo X"$ac_file" | case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) - ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` + ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. - ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` + ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; @@ -20955,8 +24261,8 @@ ac_sed_dataroot=' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 -$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 +printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' @@ -20969,7 +24275,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 esac _ACEOF -# Neutralize VPATH when `$srcdir' = `.'. +# Neutralize VPATH when '$srcdir' = '.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 @@ -21000,9 +24306,9 @@ test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable 'datarootdir' which seems to be undefined. Please make sure it is defined" >&5 -$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' +printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable 'datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" @@ -21014,8 +24320,8 @@ which seems to be undefined. Please make sure it is defined" >&2;} ;; - :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 -$as_echo "$as_me: executing $ac_file commands" >&6;} + :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 +printf "%s\n" "$as_me: executing $ac_file commands" >&6;} ;; esac @@ -21041,7 +24347,7 @@ esac for am_mf do # Strip MF so we end up with the name of the file. - am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'` + am_mf=`printf "%s\n" "$am_mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line @@ -21053,7 +24359,7 @@ $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$am_mf" : 'X\(//\)[^/]' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$am_mf" | +printf "%s\n" X"$am_mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q @@ -21075,7 +24381,7 @@ $as_echo X"$am_mf" | $as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X/"$am_mf" | +printf "%s\n" X/"$am_mf" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q @@ -21100,13 +24406,15 @@ $as_echo X/"$am_mf" | (exit $ac_status); } || am_rc=$? done if test $am_rc -ne 0; then - { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} + { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5 +printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;} as_fn_error $? "Something went wrong bootstrapping makefile fragments - for automatic dependency tracking. Try re-running configure with the + for automatic dependency tracking. If GNU make was not used, consider + re-running the configure script with MAKE=\"gmake\" (or whatever is + necessary). You can also try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking). -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } fi { am_dirpart=; unset am_dirpart;} { am_filepart=; unset am_filepart;} @@ -21130,19 +24438,18 @@ See \`config.log' for more details" "$LINENO" 5; } cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 -# Copyright (C) 2014 Free Software Foundation, Inc. +# Copyright (C) 2024 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of of the License, or +# the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you @@ -21250,6 +24557,9 @@ to_host_file_cmd=$lt_cv_to_host_file_cmd # convert \$build files to toolchain format. to_tool_file_cmd=$lt_cv_to_tool_file_cmd +# A file(cmd) program that detects file types. +FILECMD=$lt_FILECMD + # An object symbol dumper. OBJDUMP=$lt_OBJDUMP @@ -21274,8 +24584,11 @@ sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd # The archiver. AR=$lt_AR +# Flags to create an archive (by configure). +lt_ar_flags=$lt_ar_flags + # Flags to create an archive. -AR_FLAGS=$lt_AR_FLAGS +AR_FLAGS=\${ARFLAGS-"\$lt_ar_flags"} # How to feed a file listing to the archiver. archiver_list_spec=$lt_archiver_list_spec @@ -21433,9 +24746,6 @@ dlopen_self_static=$enable_dlopen_self_static old_striplib=$lt_old_striplib striplib=$lt_striplib -# Assembler program. -AS=$lt_AS - # The linker used to build libraries. LD=$lt_LD @@ -21520,7 +24830,7 @@ hardcode_direct=$hardcode_direct # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is -# "absolute",i.e impossible to change by setting \$shlibpath_var if the +# "absolute",i.e. impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute @@ -21646,6 +24956,7 @@ _LT_EOF esac + ltmain=$ac_aux_dir/ltmain.sh @@ -21653,7 +24964,7 @@ ltmain=$ac_aux_dir/ltmain.sh # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ + $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || @@ -21695,7 +25006,8 @@ if test "$no_create" != yes; then $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 -$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 +printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi + diff --git a/subprojects/libsodium/configure.ac b/subprojects/libsodium/configure.ac @@ -1,12 +1,10 @@ -AC_PREREQ([2.65]) -AC_INIT([libsodium],[1.0.18], - [https://github.com/jedisct1/libsodium/issues], - [libsodium], - [https://github.com/jedisct1/libsodium]) +AC_PREREQ([2.69]) +AC_INIT([libsodium],[1.0.20],[https://github.com/jedisct1/libsodium/issues],[libsodium],[https://libsodium.org]) AC_CONFIG_AUX_DIR([build-aux]) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_SRCDIR([src/libsodium/sodium/version.c]) AC_CANONICAL_HOST +AC_CANONICAL_TARGET AM_INIT_AUTOMAKE([1.11 dist-bzip2 tar-ustar foreign subdir-objects]) m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) AM_MAINTAINER_MODE @@ -14,10 +12,10 @@ AM_DEP_TRACK AC_SUBST(VERSION) -SODIUM_LIBRARY_VERSION_MAJOR=10 -SODIUM_LIBRARY_VERSION_MINOR=3 -DLL_VERSION=24 -SODIUM_LIBRARY_VERSION=26:0:3 +SODIUM_LIBRARY_VERSION_MAJOR=26 +SODIUM_LIBRARY_VERSION_MINOR=2 +DLL_VERSION=26 +SODIUM_LIBRARY_VERSION=28:0:2 # | | | # +------+ | +---+ # | | | @@ -44,6 +42,22 @@ AS_IF([pwd | fgrep ' ' > /dev/null 2>&1], [AC_MSG_ERROR([The build directory contains whitespaces - This can cause tests/installation to fail due to limitations of some libtool versions])] ) +sodium_CFLAGS=${CFLAGS+set} +: ${CFLAGS=""} + +AC_PROG_CC +AM_PROG_AS +AC_USE_SYSTEM_EXTENSIONS + +dnl Default optimization flags + +if test "$sodium_CFLAGS" != "set" ; then + AX_CHECK_COMPILE_FLAG([-O3], [CFLAGS="$CFLAGS -O3"], + [AX_CHECK_COMPILE_FLAG([-O2], [CFLAGS="$CFLAGS -O2"], + [AX_CHECK_COMPILE_FLAG([-O1], [CFLAGS="$CFLAGS -O1"], + [AX_CHECK_COMPILE_FLAG([-O], [CFLAGS="$CFLAGS -O"])])])]) +fi + dnl Switches AC_ARG_ENABLE(ssp, @@ -77,7 +91,7 @@ AS_IF([test "x$EMSCRIPTEN" != "x"], [ enable_asm="no" AC_MSG_WARN([compiling to JavaScript - asm implementations disabled]) ], [ - AC_MSG_WARN([EMSCRIPTEN environment variable defined, but emcc doesn't appear to be used - Assuming compilation to native code]) + AC_MSG_WARN([EMSCRIPTEN environment variable defined, but emcc doesn\'t appear to be used - Assuming compilation to native code]) CFLAGS="$CFLAGS -U__EMSCRIPTEN__" unset EMSCRIPTEN ]) @@ -87,7 +101,7 @@ AC_ARG_ENABLE(pie, [AS_HELP_STRING(--disable-pie,Do not produce position independent executables)], enable_pie=$enableval, enable_pie="maybe") -AS_CASE([$host_os], [mingw*|cygwin*|msys], [enable_pie="no"]) +AS_CASE([$host_os], [mingw*|cygwin*|msys|eabi*], [enable_pie="no"]) AC_ARG_ENABLE(blocking-random, [AS_HELP_STRING(--enable-blocking-random,Enable this switch only if /dev/urandom is totally broken on the target platform)], @@ -115,8 +129,8 @@ AC_ARG_ENABLE(minimal, AM_CONDITIONAL([MINIMAL], [test x$enable_minimal = xyes]) AC_SUBST(SODIUM_LIBRARY_MINIMAL_DEF) -AC_ARG_WITH(pthreads, AC_HELP_STRING([--with-pthreads], - [use pthreads library, or --without-pthreads to disable threading support.]), +AC_ARG_WITH(pthreads, AS_HELP_STRING([--with-pthreads], + [use pthreads library, or --without-pthreads to disable threading support]), [ ], [withval="yes"]) AS_IF([test "x$withval" = "xyes"], [ @@ -195,11 +209,11 @@ AC_ARG_ENABLE(opt, [AS_HELP_STRING(--enable-opt,Optimize for the native CPU - The resulting library will be faster but not portable)], [ AS_IF([test "x$enableval" = "xyes"], [ - AX_CHECK_COMPILE_FLAG([-Ofast], [CFLAGS="$CFLAGS -Ofast"]) AX_CHECK_COMPILE_FLAG([-ftree-vectorize], [CFLAGS="$CFLAGS -ftree-vectorize"]) AX_CHECK_COMPILE_FLAG([-ftree-slp-vectorize], [CFLAGS="$CFLAGS -ftree-slp-vectorize"]) AX_CHECK_COMPILE_FLAG([-fomit-frame-pointer], [CFLAGS="$CFLAGS -fomit-frame-pointer"]) AX_CHECK_COMPILE_FLAG([-march=native], [CFLAGS="$CFLAGS -march=native"]) + AX_CHECK_COMPILE_FLAG([-mtune=native], [CFLAGS="$CFLAGS -mtune=native"]) ]) ]) @@ -210,22 +224,16 @@ AX_VALGRIND_CHECK dnl Checks -AC_PROG_CC_C99 -AM_PROG_AS -AC_USE_SYSTEM_EXTENSIONS AC_C_VARARRAYS AC_CHECK_DEFINE([__wasi__], [WASI="yes"], []) -AC_CHECK_DEFINE([_FORTIFY_SOURCE], [], [ - AX_CHECK_COMPILE_FLAG([-D_FORTIFY_SOURCE=2], - [CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=2"]) -]) +AS_CASE([$host_os], [linux-gnu], [AX_ADD_FORTIFY_SOURCE], [ ]) AX_CHECK_COMPILE_FLAG([-fvisibility=hidden], [CFLAGS="$CFLAGS -fvisibility=hidden"]) -AS_CASE([$host_os], [cygwin*|mingw*|msys|pw32*|cegcc*], [ ], [ +AS_CASE([$host_os], [cygwin*|mingw*|msys|pw32*|cegcc*|eabi*], [ ], [ AX_CHECK_COMPILE_FLAG([-fPIC], [CFLAGS="$CFLAGS -fPIC"]) ]) @@ -262,7 +270,7 @@ int main(void) { return 0; } LIBTOOL_OLD_FLAGS="$LIBTOOL_EXTRA_FLAGS" LIBTOOL_EXTRA_FLAGS="$LIBTOOL_EXTRA_FLAGS -version-info $SODIUM_LIBRARY_VERSION" AC_ARG_ENABLE(soname-versions, - [AC_HELP_STRING([--enable-soname-versions], [enable soname versions (must be disabled for Android) (default: enabled)])], + [AS_HELP_STRING([--enable-soname-versions], [enable soname versions (must be disabled for Android) (default: enabled)])], [ AS_IF([test "x$enableval" = "xno"], [ LIBTOOL_EXTRA_FLAGS="$LIBTOOL_OLD_FLAGS -avoid-version" @@ -278,7 +286,7 @@ AS_CASE([$host_os], ]) AS_CASE([$host_os], - [cygwin*|mingw*|msys|pw32*|cegcc*], [ + [cygwin*|mingw*|msys|pw32*|cegcc*|eabi*], [ AX_CHECK_COMPILE_FLAG([-fno-asynchronous-unwind-tables], [ [CFLAGS="$CFLAGS -fno-asynchronous-unwind-tables"] ]) @@ -287,7 +295,7 @@ AS_CASE([$host_os], AS_IF([test "x$enable_ssp" != "xno"],[ AS_CASE([$host_os], - [cygwin*|mingw*|msys|pw32*|cegcc*|haiku|none], [ ], + [solaris*|cygwin*|mingw*|msys|pw32*|cegcc*|haiku|none|eabi*], [ ], [*], [ AX_CHECK_COMPILE_FLAG([-fstack-protector], [ AX_CHECK_LINK_FLAG([-fstack-protector], @@ -297,15 +305,16 @@ AS_CASE([$host_os], ]) ]) -AC_ARG_VAR([CWFLAGS], [define to compilation flags for generating extra warnings]) - AX_CHECK_COMPILE_FLAG([$CFLAGS -Wall], [CWFLAGS="$CFLAGS -Wall"]) -AX_CHECK_COMPILE_FLAG([$CFLAGS -Wextra], [CWFLAGS="$CFLAGS -Wextra"]) +AX_CHECK_COMPILE_FLAG([$CFLAGS -Wno-deprecated-declarations], [CFLAGS="$CFLAGS -Wno-deprecated-declarations"]) +AX_CHECK_COMPILE_FLAG([$CFLAGS -Wno-unknown-pragmas], [CFLAGS="$CFLAGS -Wno-unknown-pragmas"]) + +AC_ARG_VAR([CWFLAGS], [compilation flags for generating extra warnings]) AC_MSG_CHECKING(for clang) AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ #ifndef __clang__ -#error Not clang +#error Not clang nor zig cc #endif ]])], [AC_MSG_RESULT(yes) @@ -315,6 +324,8 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ [AC_MSG_RESULT(no) ]) +AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wextra], [CWFLAGS="$WCFLAGS -Wextra"]) +AX_CHECK_COMPILE_FLAG([$CWFLAGS -Warray-bounds], [CWFLAGS="$CWFLAGS -Warray-bounds"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wbad-function-cast], [CWFLAGS="$CWFLAGS -Wbad-function-cast"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wcast-qual], [CWFLAGS="$CWFLAGS -Wcast-qual"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wdiv-by-zero], [CWFLAGS="$CWFLAGS -Wdiv-by-zero"]) @@ -343,9 +354,11 @@ AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wswitch-enum], [CWFLAGS="$CWFLAGS -Wswitch-enum AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wvariable-decl], [CWFLAGS="$CWFLAGS -Wvariable-decl"]) AX_CHECK_COMPILE_FLAG([$CWFLAGS -Wwrite-strings], [CWFLAGS="$CWFLAGS -Wwrite-strings"]) -AX_CHECK_LINK_FLAG([-Wl,-z,relro], [LDFLAGS="$LDFLAGS -Wl,-z,relro"]) -AX_CHECK_LINK_FLAG([-Wl,-z,now], [LDFLAGS="$LDFLAGS -Wl,-z,now"]) -AX_CHECK_LINK_FLAG([-Wl,-z,noexecstack], [LDFLAGS="$LDFLAGS -Wl,-z,noexecstack"]) +AS_IF([test "x$EMSCRIPTEN" = "x"], [ + AX_CHECK_LINK_FLAG([-Wl,-z,relro], [LDFLAGS="$LDFLAGS -Wl,-z,relro"]) + AX_CHECK_LINK_FLAG([-Wl,-z,now], [LDFLAGS="$LDFLAGS -Wl,-z,now"]) + AX_CHECK_LINK_FLAG([-Wl,-z,noexecstack], [LDFLAGS="$LDFLAGS -Wl,-z,noexecstack"]) +]) AX_CHECK_CATCHABLE_SEGV AX_CHECK_CATCHABLE_ABRT @@ -362,14 +375,102 @@ AC_SUBST(LIBTOOL_DEPS) AC_ARG_VAR([AR], [path to the ar utility]) AC_CHECK_TOOL([AR], [ar], [ar]) -dnl Checks for headers +dnl Checks for headers and codegen feature flags + +target_cpu_aarch64=no +AC_MSG_CHECKING(for ARM64 target) +AC_LINK_IFELSE( + [AC_LANG_PROGRAM([ +#ifndef __aarch64__ +#error Not aarch64 +#endif +#include <arm_neon.h> + ], [(void) 0])], + [AC_MSG_RESULT(yes) + target_cpu_aarch64=yes], + [AC_MSG_RESULT(no) + target_cpu_aarch64=no]) AS_IF([test "x$EMSCRIPTEN" = "x"], [ + AS_IF([test "x$target_cpu_aarch64" = "xyes"], [ + have_armcrypto=no + AC_MSG_CHECKING(for ARM crypto instructions set) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ + #ifndef __ARM_FEATURE_CRYPTO + # define __ARM_FEATURE_CRYPTO 1 + #endif + #ifndef __ARM_FEATURE_AES + # define __ARM_FEATURE_AES 1 + #endif + + #include <arm_neon.h> + + #ifdef __clang__ + # pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) + #elif defined(__GNUC__) + # pragma GCC target("+simd+crypto") + #endif + ]], [[ + int64x2_t x = { 0, 0 }; + vaeseq_u8(vmovq_n_u8(0), vmovq_n_u8(0)); + vmull_high_p64(vreinterpretq_p64_s64(x), vreinterpretq_p64_s64(x)); + + #ifdef __clang__ + # pragma clang attribute pop + #endif + (void) 0 + ]])], + [ + AC_MSG_RESULT(yes) + have_armcrypto=yes + ], + [ + AC_MSG_RESULT(no) + oldcflags="$CFLAGS" + AX_CHECK_COMPILE_FLAG([-march=armv8-a+crypto+aes], [ + CFLAGS="$CFLAGS -march=armv8-a+crypto+aes" + AC_MSG_CHECKING(for ARM crypto instructions set with -march=armv8-a+crypto+aes) + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ + #ifdef __clang__ + # pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) + #elif defined(__GNUC__) + # pragma GCC target("+simd+crypto") + #endif + #ifndef __ARM_FEATURE_CRYPTO + # define __ARM_FEATURE_CRYPTO 1 + #endif + #ifndef __ARM_FEATURE_AES + # define __ARM_FEATURE_AES 1 + #endif + + #include <arm_neon.h> + ]], [[ + int64x2_t x = { 0, 0 }; + vaeseq_u8(vmovq_n_u8(0), vmovq_n_u8(0)); + vmull_high_p64(vreinterpretq_p64_s64(x), vreinterpretq_p64_s64(x)); + + #ifdef __clang__ + # pragma clang attribute pop + #endif + (void) 0 + ]])], + [ + AC_MSG_RESULT(yes - with addition of -march=armv8-a+crypto+aes) + have_armcrypto=yes + CFLAGS_ARMCRYPTO="-march=armv8-a+crypto+aes" + ], + [AC_MSG_RESULT(no)]) + CFLAGS="$oldcflags" + ]) + ]) + AS_IF([test "$have_armcrypto" = "yes"],[AC_DEFINE([HAVE_ARMCRYPTO], [1], [ARM crypto extensions are available])]) + ]) + oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mmmx], [CFLAGS="$CFLAGS -mmmx"]) AC_MSG_CHECKING(for MMX instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("mmx") #include <mmintrin.h> ]], [[ __m64 x = _mm_setzero_si64(); ]])], @@ -382,7 +483,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-msse2], [CFLAGS="$CFLAGS -msse2"]) AC_MSG_CHECKING(for SSE2 instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("sse2") #ifndef __SSE2__ # define __SSE2__ @@ -399,7 +500,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-msse3], [CFLAGS="$CFLAGS -msse3"]) AC_MSG_CHECKING(for SSE3 instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("sse3") #include <pmmintrin.h> ]], [[ __m128 x = _mm_addsub_ps(_mm_cvtpd_ps(_mm_setzero_pd()), @@ -413,7 +514,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mssse3], [CFLAGS="$CFLAGS -mssse3"]) AC_MSG_CHECKING(for SSSE3 instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("ssse3") #include <tmmintrin.h> ]], [[ __m64 x = _mm_abs_pi32(_m_from_int(0)); ]])], @@ -426,7 +527,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-msse4.1], [CFLAGS="$CFLAGS -msse4.1"]) AC_MSG_CHECKING(for SSE4.1 instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("sse4.1") #include <smmintrin.h> ]], [[ __m128i x = _mm_minpos_epu16(_mm_setzero_si128()); ]])], @@ -439,7 +540,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mavx], [CFLAGS="$CFLAGS -mavx"]) AC_MSG_CHECKING(for AVX instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("avx") #include <immintrin.h> ]], [[ _mm256_zeroall(); ]])], @@ -452,7 +553,7 @@ AS_IF([test "x$EMSCRIPTEN" = "x"], [ oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mavx2], [CFLAGS="$CFLAGS -mavx2"]) AC_MSG_CHECKING(for AVX2 instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("avx2") #include <immintrin.h> ]], [[ @@ -464,7 +565,7 @@ return _mm256_movemask_ps(_mm256_cmp_ps(x, y, _CMP_NEQ_OQ)); AC_DEFINE([HAVE_AVX2INTRIN_H], [1], [AVX2 is available]) AX_CHECK_COMPILE_FLAG([-mavx2], [CFLAGS_AVX2="-mavx2"]) AC_MSG_CHECKING(if _mm256_broadcastsi128_si256 is correctly defined) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("avx2") #include <immintrin.h> ]], [[ __m256i y = _mm256_broadcastsi128_si256(_mm_setzero_si128()); ]])], @@ -479,7 +580,7 @@ return _mm256_movemask_ps(_mm256_cmp_ps(x, y, _CMP_NEQ_OQ)); oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mavx512f], [CFLAGS="$CFLAGS -mavx512f"]) AC_MSG_CHECKING(for AVX512F instructions set) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("avx512f") #include <immintrin.h> ]], [[ @@ -512,7 +613,7 @@ __m512i y = _mm512_permutexvar_epi64(_mm512_setr_epi64(0, 1, 4, 5, 2, 3, 6, 7), AX_CHECK_COMPILE_FLAG([-maes], [CFLAGS="$CFLAGS -maes"]) AX_CHECK_COMPILE_FLAG([-mpclmul], [CFLAGS="$CFLAGS -mpclmul"]) AC_MSG_CHECKING(for AESNI instructions set and PCLMULQDQ) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("aes") #pragma GCC target("pclmul") #include <wmmintrin.h> @@ -529,7 +630,7 @@ __m512i y = _mm512_permutexvar_epi64(_mm512_setr_epi64(0, 1, 4, 5, 2, 3, 6, 7), oldcflags="$CFLAGS" AX_CHECK_COMPILE_FLAG([-mrdrnd], [CFLAGS="$CFLAGS -mrdrnd"]) AC_MSG_CHECKING(for RDRAND) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #pragma GCC target("rdrnd") #include <immintrin.h> ]], [[ unsigned long long x; _rdrand64_step(&x); ]])], @@ -542,6 +643,7 @@ __m512i y = _mm512_permutexvar_epi64(_mm512_setr_epi64(0, 1, 4, 5, 2, 3, 6, 7), ]) +AC_SUBST(CFLAGS_ARMCRYPTO) AC_SUBST(CFLAGS_MMX) AC_SUBST(CFLAGS_SSE2) AC_SUBST(CFLAGS_SSE3) @@ -554,7 +656,9 @@ AC_SUBST(CFLAGS_AESNI) AC_SUBST(CFLAGS_PCLMUL) AC_SUBST(CFLAGS_RDRAND) -AC_CHECK_HEADERS([sys/mman.h sys/random.h intrin.h]) +AC_CHECK_HEADERS([sys/mman.h sys/param.h sys/random.h intrin.h sys/auxv.h]) +AC_CHECK_HEADERS([CommonCrypto/CommonRandom.h]) +AC_CHECK_HEADERS([cet.h threads.h]) AC_MSG_CHECKING([if _xgetbv() is available]) AC_LINK_IFELSE( @@ -578,7 +682,7 @@ AC_C_BIGENDIAN( ) AC_MSG_CHECKING(whether __STDC_LIMIT_MACROS is required) -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ +AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #include <limits.h> #include <stdint.h> ]], [[ @@ -605,7 +709,7 @@ __asm__ __volatile__ ("" : : "r"(pnt) : "memory"); HAVE_AMD64_ASM_V=0 AS_IF([test "$enable_asm" != "no"],[ AC_MSG_CHECKING(whether we can use x86_64 asm code) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ #if defined(__amd64) || defined(__amd64__) || defined(__x86_64__) # if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__) || defined(_WIN32) || defined(_WIN64) @@ -634,7 +738,7 @@ AC_SUBST(HAVE_AMD64_ASM_V) HAVE_AVX_ASM_V=0 AS_IF([test "$enable_asm" != "no"],[ AC_MSG_CHECKING(whether we can assemble AVX opcodes) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ #if defined(__amd64) || defined(__amd64__) || defined(__x86_64__) # if defined(__CYGWIN__) || defined(__MINGW32__) || defined(__MINGW64__) || defined(_WIN32) || defined(_WIN64) @@ -694,7 +798,7 @@ AC_SUBST(HAVE_TI_MODE_V) HAVE_CPUID_V=0 AS_IF([test "$enable_asm" != "no"],[ AC_MSG_CHECKING(for cpuid instruction) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ unsigned int cpu_info[4]; __asm__ __volatile__ ("xchgl %%ebx, %k1; cpuid; xchgl %%ebx, %k1" : "=a" (cpu_info[0]), "=&r" (cpu_info[1]), @@ -762,23 +866,6 @@ void f(void *x) { __dummy(x); } AC_DEFINE([HAVE_WEAK_SYMBOLS], [1], [weak symbols are supported])], [AC_MSG_RESULT(no)]) -AC_MSG_CHECKING(if data alignment is required) -aligned_access_required=yes -AS_CASE([$host_cpu], - [i?86|amd64|x86_64|powerpc*|s390*], - [aligned_access_required=no], - [arm*], - [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ -#ifndef __ARM_FEATURE_UNALIGNED -# error data alignment is required -#endif - ]], [[]])], [aligned_access_required=no], [])] -) -AS_IF([test "x$aligned_access_required" = "xyes"], - [AC_MSG_RESULT(yes)], - [AC_MSG_RESULT(no) - AC_DEFINE([CPU_UNALIGNED_ACCESS], [1], [unaligned memory access is supported])]) - AC_MSG_CHECKING(if atomic operations are supported) AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ static volatile int _sodium_lock; @@ -790,13 +877,36 @@ __sync_lock_release(&_sodium_lock); AC_DEFINE([HAVE_ATOMIC_OPS], [1], [atomic operations are supported])], [AC_MSG_RESULT(no)]) +AC_MSG_CHECKING(if C11 memory fences are supported) +AC_LINK_IFELSE([AC_LANG_PROGRAM([[ +#include <stdatomic.h> + ]], [[ +atomic_thread_fence(memory_order_acquire); +]] +)], +[AC_MSG_RESULT(yes) + AC_DEFINE([HAVE_C11_MEMORY_FENCES], [1], [C11 memory fences are supported])], +[AC_MSG_RESULT(no)]) + +AC_MSG_CHECKING(if gcc memory fences are supported) +AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ +__atomic_thread_fence(__ATOMIC_ACQUIRE); +]] +)], +[AC_MSG_RESULT(yes) + AC_DEFINE([HAVE_GCC_MEMORY_FENCES], [1], [GCC memory fences are supported])], +[AC_MSG_RESULT(no)]) + dnl Checks for functions and headers AC_FUNC_ALLOCA AS_IF([test "x$EMSCRIPTEN" = "x"],[ AC_CHECK_FUNCS([arc4random arc4random_buf]) - AC_CHECK_FUNCS([mmap mlock madvise mprotect]) - + AS_IF([test "x$WASI" = "x"],[ + AC_CHECK_FUNCS([mmap mlock madvise mprotect]) + AC_CHECK_FUNCS([raise]) + AC_CHECK_FUNCS([sysconf]) + ]) AC_MSG_CHECKING(for getrandom with a standard API) AC_LINK_IFELSE([AC_LANG_PROGRAM([[ #include <stdlib.h> @@ -808,7 +918,9 @@ AS_IF([test "x$EMSCRIPTEN" = "x"],[ #endif ]], [[ unsigned char buf; -(void) getrandom((void *) &buf, 1U, 0U); +if (&getrandom != NULL) { + (void) getrandom((void *) &buf, 1U, 0U); +} ]])], [AC_MSG_RESULT(yes) AC_CHECK_FUNCS([getrandom])], @@ -825,27 +937,34 @@ unsigned char buf; # include <sys/random.h> #endif ]], [[ -#ifdef __APPLE__ -# error getentropy() is currently disabled on Apple operating systems -#endif - unsigned char buf; -(void) getentropy((void *) &buf, 1U); +if (&getentropy != NULL) { + (void) getentropy((void *) &buf, 1U); +} ]])], [AC_MSG_RESULT(yes) AC_CHECK_FUNCS([getentropy])], [AC_MSG_RESULT(no) ]) ]) -AC_CHECK_FUNCS([posix_memalign getpid nanosleep]) -AC_CHECK_FUNCS([memset_s explicit_bzero explicit_memset]) + +AS_IF([test "x$WASI" = "x"],[ + AC_CHECK_FUNCS([getpid]) + AC_CHECK_FUNCS([getauxval elf_aux_info]) +]) + +AC_CHECK_FUNCS([posix_memalign nanosleep clock_gettime]) + +AS_IF([test "x$WASI" = "x"],[ + AC_CHECK_FUNCS([memset_s explicit_bzero memset_explicit explicit_memset]) +]) AC_SUBST([LIBTOOL_EXTRA_FLAGS]) TEST_LDFLAGS='' AS_IF([test "x$EMSCRIPTEN" != "x"],[ EXEEXT=.js - TEST_LDFLAGS='--memory-init-file 0 --pre-js pre.js.inc -s RESERVED_FUNCTION_POINTERS=8' + TEST_LDFLAGS='--pre-js pre.js.inc -s RESERVED_FUNCTION_POINTERS=8' ]) AC_SUBST(TEST_LDFLAGS) AM_CONDITIONAL([EMSCRIPTEN], [test "x$EMSCRIPTEN" != "x"]) @@ -855,8 +974,7 @@ AC_DEFINE([CONFIGURED], [1], [the build system was properly configured]) dnl Libtool. -LT_INIT([dlopen]) -AC_LIBTOOL_WIN32_DLL +LT_INIT([dlopen win32-dll]) gl_LD_OUTPUT_DEF dnl Output. @@ -876,7 +994,6 @@ AC_CONFIG_FILES([Makefile dist-build/Makefile libsodium.pc libsodium-uninstalled.pc - msvc-scripts/Makefile src/Makefile src/libsodium/Makefile src/libsodium/include/Makefile diff --git a/subprojects/libsodium/contrib/Findsodium.cmake b/subprojects/libsodium/contrib/Findsodium.cmake @@ -213,7 +213,7 @@ if(sodium_INCLUDE_DIR) string( REGEX REPLACE - ".*#[ \t]*define[ \t]*sodium_VERSION_STRING_STRING[ \t]*\"([^\n]*)\".*" + ".*define[ \t]+SODIUM_VERSION_STRING[^\"]+\"([^\"]+)\".*" "\\1" sodium_VERSION_STRING "${_VERSION_HEADER_CONTENT}") @@ -231,6 +231,10 @@ find_package_handle_standard_args(sodium VERSION_VAR sodium_VERSION_STRING) +if (NOT sodium_FOUND) + return() +endif() + # mark file paths as advanced mark_as_advanced(sodium_INCLUDE_DIR) mark_as_advanced(sodium_LIBRARY_DEBUG) diff --git a/subprojects/libsodium/contrib/Makefile.in b/subprojects/libsodium/contrib/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,9 +89,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = contrib ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -125,6 +129,10 @@ am__can_run_installinfo = \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -133,7 +141,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -145,6 +152,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -157,6 +165,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -173,8 +183,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -217,6 +229,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -242,8 +255,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -277,11 +292,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -328,6 +348,11 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: tags TAGS: ctags CTAGS: @@ -396,12 +421,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-am + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-am + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-am + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-am + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-am + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am @@ -470,7 +515,12 @@ uninstall-am: .MAKE: install-am install-strip -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ +.PHONY: all all-am check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ @@ -488,3 +538,10 @@ uninstall-am: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/dist-build/Makefile.am b/subprojects/libsodium/dist-build/Makefile.am @@ -1,16 +1,14 @@ EXTRA_DIST = \ android-build.sh \ - android-arm.sh \ + android-aar.sh \ android-armv7-a.sh \ android-armv8-a.sh \ - android-mips32.sh \ - android-mips64.sh \ android-x86.sh \ android-x86_64.sh \ emscripten.sh \ - ios.sh \ + apple-xcframework.sh \ + macos.sh \ msys2-win32.sh \ msys2-win64.sh \ - watchos.sh \ wasm32-wasi.sh diff --git a/subprojects/libsodium/dist-build/Makefile.in b/subprojects/libsodium/dist-build/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,9 +89,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = dist-build ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -125,6 +129,10 @@ am__can_run_installinfo = \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -133,7 +141,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -145,6 +152,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -157,6 +165,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -173,8 +183,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -217,6 +229,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -242,8 +255,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -277,11 +292,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -289,18 +309,16 @@ valgrind_enabled_tools = @valgrind_enabled_tools@ valgrind_tools = @valgrind_tools@ EXTRA_DIST = \ android-build.sh \ - android-arm.sh \ + android-aar.sh \ android-armv7-a.sh \ android-armv8-a.sh \ - android-mips32.sh \ - android-mips64.sh \ android-x86.sh \ android-x86_64.sh \ emscripten.sh \ - ios.sh \ + apple-xcframework.sh \ + macos.sh \ msys2-win32.sh \ msys2-win64.sh \ - watchos.sh \ wasm32-wasi.sh all: all-am @@ -341,6 +359,11 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: tags TAGS: ctags CTAGS: @@ -409,12 +432,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-am + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-am + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-am + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-am + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-am + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am @@ -483,7 +526,12 @@ uninstall-am: .MAKE: install-am install-strip -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ +.PHONY: all all-am check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-generic clean-libtool \ cscopelist-am ctags-am distclean distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ @@ -501,3 +549,10 @@ uninstall-am: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/dist-build/android-aar.sh b/subprojects/libsodium/dist-build/android-aar.sh @@ -0,0 +1,194 @@ +#! /bin/sh + +# Create an AAR with libsodium in all combinations of static | shared | minimal | full. +# +# To simplify linking, library variants have distinct names: sodium, sodium-static, sodium-minimal and sodium-minimal-static. + +SODIUM_VERSION="1.0.20.0" + +if [ -z "$ANDROID_NDK_HOME" ]; then + echo "ANDROID_NDK_HOME must be set to the directory containing the Android NDK." + exit 1 +fi + +if [ ! -f "${ANDROID_NDK_HOME}/ndk-build" ]; then + echo "The ANDROID_NDK_HOME directory does not contain an 'ndk-build' file." + exit 1 +fi + +if [ ! -d "${ANDROID_NDK_HOME}/toolchains" ]; then + echo "The ANDROID_NDK_HOME directory does not contain a 'toolchains' directory." + exit 1 +fi + +if [ ! -f "${ANDROID_NDK_HOME}/source.properties" ]; then + echo "The ANDROID_NDK_HOME directory does not contain a 'source.properties' file." + exit 1 +fi + +NDK_VERSION=$(grep "Pkg.Revision = " <"${ANDROID_NDK_HOME}/source.properties" | cut -f 2 -d '=' | cut -f 2 -d' ' | cut -f 1 -d'.') +DEST_PATH=$(mktemp -d) + +if [ -z "$NDK_PLATFORM" ]; then + export NDK_PLATFORM="android-21" + echo "Compiling for default platform: [${NDK_PLATFORM}]" + echo "That can be changed by setting an NDK_PLATFORM environment variable." +fi + +SDK_VERSION=$(echo "$NDK_PLATFORM" | cut -f2 -d"-") +if [ -z "$NDK_VERSION" ]; then + echo "Failed to determine the NDK version." + exit 1 +fi +if [ -z "$SDK_VERSION" ]; then + echo "Failed to determine the SDK version." + exit 1 +fi +echo "NDK version: [$NDK_VERSION]" +echo "SDK version: [$SDK_VERSION]" + +echo + +if which zip >/dev/null; then + echo "The 'zip' command is installed." +else + echo "The 'zip' command is not installed. Please install it before running this script." + exit 1 +fi + +cd "$(dirname "$0")/../" || exit + +trap 'kill -TERM -$$' INT + +make_abi_json() { + echo "{\"abi\":\"${NDK_ARCH}\",\"api\":${SDK_VERSION},\"ndk\":${NDK_VERSION},\"stl\":\"none\"}" >"$1/abi.json" +} + +make_prefab_json() { + echo "{\"name\":\"sodium\",\"schema_version\":1,\"dependencies\":[],\"version\":\"$SODIUM_VERSION\"}" >"$1/prefab.json" +} + +make_manifest() { + echo "<manifest xmlns:android=\"http://schemas.android.com/apk/res/android\" package=\"com.android.ndk.thirdparty.sodium\" android:versionCode=\"1\" android:versionName=\"1.0\"> + <uses-sdk android:minSdkVersion=\"$SDK_VERSION\" android:targetSdkVersion=\"$SDK_VERSION\"/> +</manifest>" >"${1}/AndroidManifest.xml" +} + +make_prefab_structure() { + for variant_dirs in "prefab" "prefab/modules" "META-INF"; do + mkdir "${DEST_PATH}/${variant_dirs}" + done + + make_prefab_json "${DEST_PATH}/prefab" + make_manifest "${DEST_PATH}" + cp "LICENSE" "${DEST_PATH}/META-INF" + + for variant in \ + "prefab/modules/sodium" "prefab/modules/sodium-static" \ + "prefab/modules/sodium-minimal" "prefab/modules/sodium-minimal-static"; do + mkdir "${DEST_PATH}/${variant}" + + if [ "$variant" = "prefab/modules/sodium-minimal" ]; then + echo "{\"library_name\":\"libsodium\"}" >"${DEST_PATH}/${variant}/module.json" + else + echo "{}" >"${DEST_PATH}/${variant}/module.json" + fi + + mkdir "${DEST_PATH}/${variant}/libs" + + for arch in "arm64-v8a" "armeabi-v7a" "x86" "x86_64"; do + mkdir "$DEST_PATH/${variant}/libs/android.${arch}" + mkdir "$DEST_PATH/${variant}/libs/android.${arch}/include" + NDK_ARCH="$arch" + + make_abi_json "$DEST_PATH/${variant}/libs/android.${arch}" + done + done +} + +copy_libs() { + SRC_DIR="libsodium-android-${1}" + + SHARED_DEST_DIR="${DEST_PATH}/prefab/modules/sodium${3}/libs/android.${2}" + STATIC_DEST_DIR="${DEST_PATH}/prefab/modules/sodium${3}-static/libs/android.${2}" + + cp -r "${SRC_DIR}/include" "$SHARED_DEST_DIR" + cp -r "${SRC_DIR}/include" "$STATIC_DEST_DIR" + cp "${SRC_DIR}/lib/libsodium.so" "${SHARED_DEST_DIR}/libsodium.so" + cp "${SRC_DIR}/lib/libsodium.a" "${STATIC_DEST_DIR}/libsodium${3}-static.a" + + rm -r "$SRC_DIR" +} + +build_all() { + dist-build/android-armv7-a.sh + dist-build/android-armv8-a.sh + dist-build/android-x86_64.sh + dist-build/android-x86.sh +} + +make_prefab_structure + +build_all + +copy_libs "armv7-a" "armeabi-v7a" "-minimal" +copy_libs "armv8-a+crypto" "arm64-v8a" "-minimal" +copy_libs "i686" "x86" "-minimal" +copy_libs "westmere" "x86_64" "-minimal" + +LIBSODIUM_FULL_BUILD="Y" +export LIBSODIUM_FULL_BUILD + +build_all + +copy_libs "armv7-a" "armeabi-v7a" +copy_libs "armv8-a+crypto" "arm64-v8a" +copy_libs "i686" "x86" +copy_libs "westmere" "x86_64" + +AAR_PATH="$(pwd)/libsodium-${SODIUM_VERSION}.aar" +cd "$DEST_PATH" || exit +rm "$AAR_PATH" +zip -9 -r "$AAR_PATH" META-INF prefab AndroidManifest.xml +cd .. || exit +rm -r "$DEST_PATH" + +echo " + +Congrats you have built an AAR containing libsodium! +The build used a min Android SDK of version $SDK_VERSION +You can build for a different SDK version by specifying NDK_PLATFORM=\"android-{SDK_VERSION}\" +as an environment variable before running this script but the defaults should be fine. + +To use the aar with +gradle or cmake (as set by default for Android Studio projects): + +- Edit the app/build.gradle file to add: + + android { + buildFeatures { + prefab true + } + } + + and + + dependencies { + implementation fileTree(dir:'path/to/aar/',include:['libsodium-$SODIUM_VERSION.aar']) + } + + Optionally, store multiple AAR files in the same folder and include '*.aar' + +- Edit your module's CMakeLists.txt file to add: + + find_package(sodium REQUIRED CONFIG) + +- Then, specify 'sodium::x' as an item in the relevant 'target_link_libraries' statement. + The first part is the AAR name and should be 'sodium'. + The second part ('x', to be replaced) should be set to: + - 'sodium' for the full shared library, + - 'sodium-static' for the full static library + - 'sodium-minimal' for the minimal shared library, or + - 'sodium-minimal-static' for the minimal static library. + + " diff --git a/subprojects/libsodium/dist-build/android-arm.sh b/subprojects/libsodium/dist-build/android-arm.sh @@ -1,4 +0,0 @@ -#!/bin/sh -export TARGET_ARCH=armv6 -export CFLAGS="-Os -mthumb -marm -march=${TARGET_ARCH}" -ARCH=arm HOST_COMPILER=arm-linux-androideabi "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-armv7-a.sh b/subprojects/libsodium/dist-build/android-armv7-a.sh @@ -1,4 +1,5 @@ #!/bin/sh export TARGET_ARCH=armv7-a export CFLAGS="-Os -mfloat-abi=softfp -mfpu=vfpv3-d16 -mthumb -marm -march=${TARGET_ARCH}" -ARCH=arm HOST_COMPILER=arm-linux-androideabi "$(dirname "$0")/android-build.sh" +export LDFLAGS="-Wl,-z,max-page-size=16384" +ARCH=arm HOST_COMPILER=armv7a-linux-androideabi "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-armv8-a.sh b/subprojects/libsodium/dist-build/android-armv8-a.sh @@ -1,4 +1,5 @@ #!/bin/sh -export TARGET_ARCH=armv8-a +export TARGET_ARCH=armv8-a+crypto export CFLAGS="-Os -march=${TARGET_ARCH}" -NDK_PLATFORM=android-21 ARCH=arm64 HOST_COMPILER=aarch64-linux-android "$(dirname "$0")/android-build.sh" +export LDFLAGS="-Wl,-z,max-page-size=16384" +ARCH=arm64 HOST_COMPILER=aarch64-linux-android "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-build.sh b/subprojects/libsodium/dist-build/android-build.sh @@ -1,16 +1,17 @@ #! /bin/sh if [ -z "$NDK_PLATFORM" ]; then - export NDK_PLATFORM="android-16" + echo "No NDK_PLATFORM specified, set to value such as \"android-{Min_SDK_VERSION}\" or just use android-aar.sh" + exit fi +SDK_VERSION=$(echo "$NDK_PLATFORM" | cut -f2 -d"-") export NDK_PLATFORM_COMPAT="${NDK_PLATFORM_COMPAT:-${NDK_PLATFORM}}" -export NDK_API_VERSION=$(echo "$NDK_PLATFORM" | sed 's/^android-//') -export NDK_API_VERSION_COMPAT=$(echo "$NDK_PLATFORM_COMPAT" | sed 's/^android-//') +export NDK_API_VERSION="$(echo "$NDK_PLATFORM" | sed 's/^android-//')" +export NDK_API_VERSION_COMPAT="$(echo "$NDK_PLATFORM_COMPAT" | sed 's/^android-//')" if [ -z "$ANDROID_NDK_HOME" ]; then - echo "You should probably set ANDROID_NDK_HOME to the directory containing" - echo "the Android NDK" - exit + echo "ANDROID_NDK_HOME must be set to the directory containing the Android NDK." + exit 1 fi if [ ! -f ./configure ]; then @@ -18,20 +19,18 @@ if [ ! -f ./configure ]; then exit 1 fi -if [ "x$TARGET_ARCH" = 'x' ] || [ "x$ARCH" = 'x' ] || [ "x$HOST_COMPILER" = 'x' ]; then +if [ -z "$TARGET_ARCH" ] || [ -z "$ARCH" ] || [ -z "$HOST_COMPILER" ]; then echo "You shouldn't use android-build.sh directly, use android-[arch].sh instead" >&2 exit 1 fi -export MAKE_TOOLCHAIN="${ANDROID_NDK_HOME}/build/tools/make_standalone_toolchain.py" - export PREFIX="$(pwd)/libsodium-android-${TARGET_ARCH}" -export TOOLCHAIN_DIR="$(pwd)/android-toolchain-${TARGET_ARCH}" -export PATH="${PATH}:${TOOLCHAIN_DIR}/bin" +export TOOLCHAIN_OS_DIR="$(uname | tr '[:upper:]' '[:lower:]')-x86_64/" +export TOOLCHAIN_DIR="$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/${TOOLCHAIN_OS_DIR}" -export CC=${CC:-"${HOST_COMPILER}-clang"} +export PATH="${PATH}:${TOOLCHAIN_DIR}/bin" -rm -rf "${TOOLCHAIN_DIR}" "${PREFIX}" +export CC=${CC:-"${HOST_COMPILER}${SDK_VERSION}-clang"} echo echo "Warnings related to headers being present but not usable are due to functions" @@ -47,10 +46,6 @@ else fi echo -env - PATH="$PATH" \ - "$MAKE_TOOLCHAIN" --force --api="$NDK_API_VERSION_COMPAT" \ - --arch="$ARCH" --install-dir="$TOOLCHAIN_DIR" || exit 1 - if [ -z "$LIBSODIUM_FULL_BUILD" ]; then export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" else @@ -58,29 +53,32 @@ else fi ./configure \ - --disable-soname-versions \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --host="${HOST_COMPILER}" \ - --prefix="${PREFIX}" \ - --with-sysroot="${TOOLCHAIN_DIR}/sysroot" || exit 1 + --disable-soname-versions \ + --disable-pie \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ + --host="${HOST_COMPILER}" \ + --prefix="${PREFIX}" \ + --with-sysroot="${TOOLCHAIN_DIR}/sysroot" || exit 1 +if [ -z "$NDK_PLATFORM" ]; then + echo "Aborting" + exit 1 +fi if [ "$NDK_PLATFORM" != "$NDK_PLATFORM_COMPAT" ]; then - egrep '^#define ' config.log | sort -u > config-def-compat.log + grep -E '^#define ' config.log | sort -u >config-def-compat.log echo echo "Configuring again for platform [${NDK_PLATFORM}]" echo - env - PATH="$PATH" \ - "$MAKE_TOOLCHAIN" --force --api="$NDK_API_VERSION" \ - --arch="$ARCH" --install-dir="$TOOLCHAIN_DIR" || exit 1 ./configure \ - --disable-soname-versions \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --host="${HOST_COMPILER}" \ - --prefix="${PREFIX}" \ - --with-sysroot="${TOOLCHAIN_DIR}/sysroot" || exit 1 + --disable-soname-versions \ + --disable-pie \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ + --host="${HOST_COMPILER}" \ + --prefix="${PREFIX}" \ + --with-sysroot="${TOOLCHAIN_DIR}/sysroot" || exit 1 - egrep '^#define ' config.log | sort -u > config-def.log + grep -E '^#define ' config.log | sort -u >config-def.log if ! cmp config-def.log config-def-compat.log; then echo "Platform [${NDK_PLATFORM}] is not backwards-compatible with [${NDK_PLATFORM_COMPAT}]" >&2 diff -u config-def.log config-def-compat.log >&2 @@ -89,10 +87,9 @@ if [ "$NDK_PLATFORM" != "$NDK_PLATFORM_COMPAT" ]; then rm -f config-def.log config-def-compat.log fi - NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) PROCESSORS=${NPROCESSORS:-3} -make clean && \ -make -j${PROCESSORS} install && \ -echo "libsodium has been installed into ${PREFIX}" +make clean && + make -j"${PROCESSORS}" install && + echo "libsodium has been installed into ${PREFIX}" diff --git a/subprojects/libsodium/dist-build/android-mips32.sh b/subprojects/libsodium/dist-build/android-mips32.sh @@ -1,4 +0,0 @@ -#!/bin/sh -export TARGET_ARCH=mips32 -export CFLAGS="-Os" -ARCH=mips HOST_COMPILER=mipsel-linux-android "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-mips64.sh b/subprojects/libsodium/dist-build/android-mips64.sh @@ -1,4 +0,0 @@ -#!/bin/sh -export TARGET_ARCH=mips64r6 -export CFLAGS="-Os -march=${TARGET_ARCH}" -CC="mips64el-linux-android-gcc" NDK_PLATFORM=android-21 ARCH=mips64 HOST_COMPILER=mips64el-linux-android "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-x86.sh b/subprojects/libsodium/dist-build/android-x86.sh @@ -1,4 +1,5 @@ #!/bin/sh export TARGET_ARCH=i686 export CFLAGS="-Os -march=${TARGET_ARCH}" +export LDFLAGS="-Wl,-z,max-page-size=16384" ARCH=x86 HOST_COMPILER=i686-linux-android "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/android-x86_64.sh b/subprojects/libsodium/dist-build/android-x86_64.sh @@ -1,4 +1,5 @@ #!/bin/sh export TARGET_ARCH=westmere export CFLAGS="-Os -march=${TARGET_ARCH}" -NDK_PLATFORM=android-21 ARCH=x86_64 HOST_COMPILER=x86_64-linux-android "$(dirname "$0")/android-build.sh" +export LDFLAGS="-Wl,-z,max-page-size=16384" +ARCH=x86_64 HOST_COMPILER=x86_64-linux-android "$(dirname "$0")/android-build.sh" diff --git a/subprojects/libsodium/dist-build/apple-xcframework.sh b/subprojects/libsodium/dist-build/apple-xcframework.sh @@ -0,0 +1,628 @@ +#! /bin/sh + +export PREFIX="$(pwd)/libsodium-apple" +export MACOS_ARM64_PREFIX="${PREFIX}/tmp/macos-arm64" +export MACOS_ARM64E_PREFIX="${PREFIX}/tmp/macos-arm64e" +export MACOS_X86_64_PREFIX="${PREFIX}/tmp/macos-x86_64" +export IOS32_PREFIX="${PREFIX}/tmp/ios32" +export IOS32s_PREFIX="${PREFIX}/tmp/ios32s" +export IOS64_PREFIX="${PREFIX}/tmp/ios64" +export IOS64E_PREFIX="${PREFIX}/tmp/ios64e" +export IOS_SIMULATOR_ARM64_PREFIX="${PREFIX}/tmp/ios-simulator-arm64" +export IOS_SIMULATOR_ARM64E_PREFIX="${PREFIX}/tmp/ios-simulator-arm64e" +export IOS_SIMULATOR_I386_PREFIX="${PREFIX}/tmp/ios-simulator-i386" +export IOS_SIMULATOR_X86_64_PREFIX="${PREFIX}/tmp/ios-simulator-x86_64" +export WATCHOS32_PREFIX="${PREFIX}/tmp/watchos32" +export WATCHOS64_32_PREFIX="${PREFIX}/tmp/watchos64_32" +export WATCHOS64_PREFIX="${PREFIX}/tmp/watchos64" +export WATCHOS64E_PREFIX="${PREFIX}/tmp/watchos64e" +export WATCHOS_SIMULATOR_ARM64_PREFIX="${PREFIX}/tmp/watchos-simulator-arm64" +export WATCHOS_SIMULATOR_ARM64E_PREFIX="${PREFIX}/tmp/watchos-simulator-arm64e" +export WATCHOS_SIMULATOR_I386_PREFIX="${PREFIX}/tmp/watchos-simulator-i386" +export WATCHOS_SIMULATOR_X86_64_PREFIX="${PREFIX}/tmp/watchos-simulator-x86_64" +export TVOS_PREFIX="${PREFIX}/tmp/tvos" +export TVOSE_PREFIX="${PREFIX}/tmp/tvose" +export TVOS_SIMULATOR_ARM64_PREFIX="${PREFIX}/tmp/tvos-simulator-arm64" +export TVOS_SIMULATOR_ARM64E_PREFIX="${PREFIX}/tmp/tvos-simulator-arm644" +export TVOS_SIMULATOR_X86_64_PREFIX="${PREFIX}/tmp/tvos-simulator-x86_64" +export VISIONOS_PREFIX="${PREFIX}/tmp/visionos" +export VISIONOSE_PREFIX="${PREFIX}/tmp/visionose" +export VISIONOS_SIMULATOR_PREFIX="${PREFIX}/tmp/visionos-simulator" +export VISIONOSE_SIMULATOR_PREFIX="${PREFIX}/tmp/visionose-simulator" +export CATALYST_ARM64_PREFIX="${PREFIX}/tmp/catalyst-arm64" +export CATALYST_ARM64E_PREFIX="${PREFIX}/tmp/catalyst-arm64e" +export CATALYST_X86_64_PREFIX="${PREFIX}/tmp/catalyst-x86_64" +export LOG_FILE="${PREFIX}/tmp/build_log" +export XCODEDIR="$(xcode-select -p)" + +export MACOS_VERSION_MIN=${MACOS_VERSION_MIN-"10.10"} +export IOS_VERSION_MIN=${IOS_VERSION_MIN-"9.0.0"} +export IOS_SIMULATOR_VERSION_MIN=${IOS_SIMULATOR_VERSION_MIN-$IOS_VERSION_MIN} +export WATCHOS_VERSION_MIN=${WATCHOS_VERSION_MIN-"4.0.0"} +export WATCHOS_SIMULATOR_VERSION_MIN=${WATCHOS_SIMULATOR_VERSION_MIN-$WATCHOS_VERSION_MIN} +export TVOS_VERSION_MIN=${TVOS_VERSION_MIN-"9.0.0"} +export TVOS_SIMULATOR_VERSION_MIN=${TVOS_SIMULATOR_VERSION_MIN-$TVOS_VERSION_MIN} + +echo +echo "Warnings related to headers being present but not usable are due to functions" +echo "that didn't exist in the specified minimum iOS version level." +echo "They can be safely ignored." +echo +echo "Define the LIBSODIUM_MINIMAL_BUILD environment variable to build a" +echo "library without deprecated/undocumented/low-level functions." +echo +echo "Define the LIBSODIUM_SKIP_SIMULATORS environment variable to skip building" +echo "the simulators libraries (iOS, watchOS, tvOS, visionOS simulators)." +echo + +if [ "$LIBSODIUM_MINIMAL_BUILD" ]; then + export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" +else + export LIBSODIUM_ENABLE_MINIMAL_FLAG="" +fi + +IOS32_SUPPORTED=false +[ "$(echo "$IOS_VERSION_MIN" | cut -d'.' -f1)" -lt "11" ] && IOS32_SUPPORTED=true + +I386_SIMULATOR_SUPPORTED=false +[ "$(echo "$IOS_SIMULATOR_VERSION_MIN" | cut -d'.' -f1)" -lt "11" ] && I386_SIMULATOR_SUPPORTED=true + +VISIONOS_SUPPORTED=false +[ -d "${XCODEDIR}/Platforms/XROS.platform" ] && VISIONOS_SUPPORTED=true + +NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) +PROCESSORS=${NPROCESSORS:-3} + +swift_module_map() { + echo 'module Clibsodium {' + echo ' header "sodium.h"' + echo ' export *' + echo '}' +} + +build_macos() { + export BASEDIR="${XCODEDIR}/Platforms/MacOSX.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + + ## macOS arm64 + export CFLAGS="-O3 -arch arm64 -mmacosx-version-min=${MACOS_VERSION_MIN}" + export LDFLAGS="-arch arm64 -mmacosx-version-min=${MACOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$MACOS_ARM64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## macOS arm64e + export CFLAGS="-O3 -arch arm64e -mmacosx-version-min=${MACOS_VERSION_MIN}" + export LDFLAGS="-arch arm64e -mmacosx-version-min=${MACOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$MACOS_ARM64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## macOS x86_64 + export CFLAGS="-O3 -arch x86_64 -mmacosx-version-min=${MACOS_VERSION_MIN}" + export LDFLAGS="-arch x86_64 -mmacosx-version-min=${MACOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=x86_64-apple-darwin23 --prefix="$MACOS_X86_64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_ios() { + export BASEDIR="${XCODEDIR}/Platforms/iPhoneOS.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/iPhoneOS.sdk" + + if [ "$IOS32_SUPPORTED" = true ]; then + ## 32-bit iOS + export CFLAGS="-O3 -mthumb -arch armv7 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch armv7 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=arm-apple-darwin23 --prefix="$IOS32_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 32-bit armv7s iOS + export CFLAGS="-O3 -mthumb -arch armv7s -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch armv7s -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=arm-apple-darwin23 --prefix="$IOS32s_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + fi + + ## 64-bit iOS + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + export LDFLAGS="-arch arm64 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$IOS64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 64-bit iOS arm64e + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + export LDFLAGS="-arch arm64e -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$IOS64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_ios_simulator() { + export BASEDIR="${XCODEDIR}/Platforms/iPhoneSimulator.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/iPhoneSimulator.sdk" + + ## arm64 simulator + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$IOS_SIMULATOR_ARM64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## arm64e simulator + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64e -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$IOS_SIMULATOR_ARM64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + if [ "$I386_SIMULATOR_SUPPORTED" = true ]; then + ## i386 simulator + export CFLAGS="-O3 -arch i386 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch i386 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=i686-apple-darwin23 --prefix="$IOS_SIMULATOR_I386_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + fi + + ## x86_64 simulator + export CFLAGS="-O3 -arch x86_64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch x86_64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=x86_64-apple-darwin23 --prefix="$IOS_SIMULATOR_X86_64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} + make -j${PROCESSORS} install || exit 1 +} + +build_watchos() { + export BASEDIR="${XCODEDIR}/Platforms/WatchOS.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/WatchOS.sdk" + + # 32-bit watchOS + export CFLAGS="-O3 -mthumb -arch armv7k -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch armv7k -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=arm-apple-darwin23 --prefix="$WATCHOS32_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 64-bit arm64_32 watchOS + export CFLAGS="-O3 -mthumb -arch arm64_32 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch arm64_32 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$WATCHOS64_32_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 64-bit arm64 watchOS + export CFLAGS="-O3 -mthumb -arch arm64 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch arm64 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$WATCHOS64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 64-bit arm64e watchOS + export CFLAGS="-O3 -mthumb -arch arm64e -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + export LDFLAGS="-mthumb -arch arm64e -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$WATCHOS64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_watchos_simulator() { + export BASEDIR="${XCODEDIR}/Platforms/WatchSimulator.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/WatchSimulator.sdk" + + ## arm64 simulator + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$WATCHOS_SIMULATOR_ARM64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## arm64e simulator + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64e -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$WATCHOS_SIMULATOR_ARM64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## i386 simulator + export CFLAGS="-O3 -arch i386 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch i386 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=i686-apple-darwin23 --prefix="$WATCHOS_SIMULATOR_I386_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## x86_64 simulator + export CFLAGS="-O3 -arch x86_64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch x86_64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=x86_64-apple-darwin23 --prefix="$WATCHOS_SIMULATOR_X86_64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_tvos() { + export BASEDIR="${XCODEDIR}/Platforms/AppleTVOS.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/AppleTVOS.sdk" + + ## 64-bit tvOS + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK} -mtvos-version-min=${TVOS_VERSION_MIN}" + export LDFLAGS="-arch arm64 -isysroot ${SDK} -mtvos-version-min=${TVOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$TVOS_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## 64-bit tvOS + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK} -mtvos-version-min=${TVOS_VERSION_MIN}" + export LDFLAGS="-arch arm64e -isysroot ${SDK} -mtvos-version-min=${TVOS_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$TVOSE_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_tvos_simulator() { + export BASEDIR="${XCODEDIR}/Platforms/AppleTVSimulator.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/AppleTVSimulator.sdk" + + ## arm64 simulator + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64 -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$TVOS_SIMULATOR_ARM64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## arm64e simulator + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch arm64e -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$TVOS_SIMULATOR_ARM64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## x86_64 simulator + export CFLAGS="-O3 -arch x86_64 -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + export LDFLAGS="-arch x86_64 -isysroot ${SDK} -mtvos-simulator-version-min=${TVOS_SIMULATOR_VERSION_MIN}" + + make distclean >/dev/null 2>&1 + ./configure --host=x86_64-apple-darwin23 --prefix="$TVOS_SIMULATOR_X86_64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} + make -j${PROCESSORS} install || exit 1 +} + +build_visionos() { + export BASEDIR="${XCODEDIR}/Platforms/XROS.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/XROS.sdk" + + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK}" + export LDFLAGS="-arch arm64 -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$VISIONOS_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK}" + export LDFLAGS="-arch arm64e -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$VISIONOSE_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_visionos_simulator() { + export BASEDIR="${XCODEDIR}/Platforms/XRSimulator.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/XRSimulator.sdk" + + export CFLAGS="-O3 -arch arm64 -isysroot ${SDK}" + export LDFLAGS="-arch arm64 -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$VISIONOS_SIMULATOR_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + export CFLAGS="-O3 -arch arm64e -isysroot ${SDK}" + export LDFLAGS="-arch arm64e -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-darwin23 --prefix="$VISIONOSE_SIMULATOR_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +build_catalyst() { + export BASEDIR="${XCODEDIR}/Platforms/MacOSX.platform/Developer" + export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" + export SDK="${BASEDIR}/SDKs/MacOSX.sdk" + + ## arm64 catalyst + export CFLAGS="-O3 -arch arm64 -target arm64-apple-ios13.1-macabi -isysroot ${SDK}" + export LDFLAGS="-arch arm64 -target arm64-apple-ios13.1-macabi -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-ios --prefix="$CATALYST_ARM64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## arm64e catalyst + export CFLAGS="-O3 -arch arm64e -target arm64e-apple-ios13.1-macabi -isysroot ${SDK}" + export LDFLAGS="-arch arm64e -target arm64e-apple-ios13.1-macabi -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=aarch64-apple-ios --prefix="$CATALYST_ARM64E_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 + + ## x86_64 catalyst + export CFLAGS="-O3 -arch x86_64 -target x86_64-apple-ios13.1-macabi -isysroot ${SDK}" + export LDFLAGS="-arch x86_64 -target x86_64-apple-ios13.1-macabi -isysroot ${SDK}" + + make distclean >/dev/null 2>&1 + ./configure --host=x86_64-apple-ios --prefix="$CATALYST_X86_64_PREFIX" \ + ${LIBSODIUM_ENABLE_MINIMAL_FLAG} || exit 1 + make -j${PROCESSORS} install || exit 1 +} + +mkdir -p "${PREFIX}/tmp" + +echo "Building for macOS..." +build_macos >"$LOG_FILE" 2>&1 || exit 1 +echo "Building for iOS..." +build_ios >"$LOG_FILE" 2>&1 || exit 1 +echo "Building for watchOS..." +build_watchos >"$LOG_FILE" 2>&1 || exit 1 +echo "Building for tvOS..." +build_tvos >"$LOG_FILE" 2>&1 || exit 1 +echo "Building for Catalyst..." +build_catalyst >"$LOG_FILE" 2>&1 || exit 1 +if [ "$VISIONOS_SUPPORTED" = true ]; then + echo "Building for visionOS..." + build_visionos >"$LOG_FILE" 2>&1 || exit 1 +fi + +if [ -z "$LIBSODIUM_SKIP_SIMULATORS" ]; then + echo "Building for the iOS simulator..." + build_ios_simulator >"$LOG_FILE" 2>&1 || exit 1 + echo "Building for the watchOS simulator..." + build_watchos_simulator >"$LOG_FILE" 2>&1 || exit 1 + echo "Building for the tvOS simulator..." + build_tvos_simulator >"$LOG_FILE" 2>&1 || exit 1 + if [ "$VISIONOS_SUPPORTED" = true ]; then + echo "Building for the visionOS simulator..." + build_visionos_simulator >"$LOG_FILE" 2>&1 || exit 1 + fi +else + echo "[Skipping the simulators]" +fi + +echo "Adding the Clibsodium module map for Swift..." + +find "$PREFIX" -name "include" -type d -print | while read -r f; do + swift_module_map >"${f}/module.modulemap" +done + +echo "Bundling macOS targets..." + +mkdir -p "${PREFIX}/macos/lib" +cp -a "${MACOS_X86_64_PREFIX}/include" "${PREFIX}/macos/" +for ext in a dylib; do + lipo -create \ + "${MACOS_ARM64_PREFIX}/lib/libsodium.${ext}" \ + "${MACOS_ARM64E_PREFIX}/lib/libsodium.${ext}" \ + "${MACOS_X86_64_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/macos/lib/libsodium.${ext}" +done + +echo "Bundling iOS targets..." + +mkdir -p "${PREFIX}/ios/lib" +cp -a "${IOS64_PREFIX}/include" "${PREFIX}/ios/" +for ext in a dylib; do + LIBRARY_PATHS="$IOS64_PREFIX/lib/libsodium.${ext}" + LIBRARY_PATHS="$LIBRARY_PATHS $IOS64E_PREFIX/lib/libsodium.${ext}" + if [ "$IOS32_SUPPORTED" = true ]; then + LIBRARY_PATHS="$LIBRARY_PATHS $IOS32_PREFIX/lib/libsodium.${ext}" + LIBRARY_PATHS="$LIBRARY_PATHS $IOS32s_PREFIX/lib/libsodium.${ext}" + fi + lipo -create \ + ${LIBRARY_PATHS} \ + -output "$PREFIX/ios/lib/libsodium.${ext}" +done + +echo "Bundling watchOS targets..." + +mkdir -p "${PREFIX}/watchos/lib" +cp -a "${WATCHOS64_32_PREFIX}/include" "${PREFIX}/watchos/" +for ext in a dylib; do + lipo -create \ + "${WATCHOS32_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS64_32_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS64_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS64E_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/watchos/lib/libsodium.${ext}" +done + +echo "Bundling tvOS targets..." + +mkdir -p "${PREFIX}/tvos/lib" +cp -a "${TVOS_PREFIX}/include" "${PREFIX}/tvos/" +for ext in a dylib; do + lipo -create \ + "$TVOS_PREFIX/lib/libsodium.${ext}" \ + "$TVOSE_PREFIX/lib/libsodium.${ext}" \ + -output "$PREFIX/tvos/lib/libsodium.${ext}" +done + +if [ "$VISIONOS_SUPPORTED" = true ]; then + echo "Bundling visionOS targets..." + + mkdir -p "${PREFIX}/visionos/lib" + cp -a "${VISIONOS_PREFIX}/include" "${PREFIX}/visionos/" + for ext in a dylib; do + lipo -create \ + "$VISIONOS_PREFIX/lib/libsodium.${ext}" \ + "$VISIONOSE_PREFIX/lib/libsodium.${ext}" \ + -output "$PREFIX/visionos/lib/libsodium.${ext}" + done +fi + +echo "Bundling Catalyst targets..." + +mkdir -p "${PREFIX}/catalyst/lib" +cp -a "${CATALYST_X86_64_PREFIX}/include" "${PREFIX}/catalyst/" +for ext in a dylib; do + if [ ! -f "${CATALYST_X86_64_PREFIX}/lib/libsodium.${ext}" ]; then + continue + fi + lipo -create \ + "${CATALYST_ARM64_PREFIX}/lib/libsodium.${ext}" \ + "${CATALYST_ARM64E_PREFIX}/lib/libsodium.${ext}" \ + "${CATALYST_X86_64_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/catalyst/lib/libsodium.${ext}" +done + +if [ -z "$LIBSODIUM_SKIP_SIMULATORS" ]; then + echo "Bundling iOS simulators..." + + mkdir -p "${PREFIX}/ios-simulators/lib" + cp -a "${IOS_SIMULATOR_X86_64_PREFIX}/include" "${PREFIX}/ios-simulators/" + for ext in a dylib; do + LIBRARY_PATHS="${IOS_SIMULATOR_ARM64_PREFIX}/lib/libsodium.${ext}" + LIBRARY_PATHS="$LIBRARY_PATHS ${IOS_SIMULATOR_ARM64E_PREFIX}/lib/libsodium.${ext}" + LIBRARY_PATHS="$LIBRARY_PATHS ${IOS_SIMULATOR_X86_64_PREFIX}/lib/libsodium.${ext}" + if [ "$I386_SIMULATOR_SUPPORTED" = true ]; then + LIBRARY_PATHS="$LIBRARY_PATHS ${IOS_SIMULATOR_I386_PREFIX}/lib/libsodium.${ext}" + fi + lipo -create \ + ${LIBRARY_PATHS} \ + -output "${PREFIX}/ios-simulators/lib/libsodium.${ext}" || exit 1 + done + + echo "Bundling watchOS simulators..." + + mkdir -p "${PREFIX}/watchos-simulators/lib" + cp -a "${WATCHOS_SIMULATOR_X86_64_PREFIX}/include" "${PREFIX}/watchos-simulators/" + for ext in a dylib; do + lipo -create \ + "${WATCHOS_SIMULATOR_ARM64_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS_SIMULATOR_ARM64E_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS_SIMULATOR_I386_PREFIX}/lib/libsodium.${ext}" \ + "${WATCHOS_SIMULATOR_X86_64_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/watchos-simulators/lib/libsodium.${ext}" + done + + echo "Bundling tvOS simulators..." + + mkdir -p "${PREFIX}/tvos-simulators/lib" + cp -a "${TVOS_SIMULATOR_X86_64_PREFIX}/include" "${PREFIX}/tvos-simulators/" + for ext in a dylib; do + lipo -create \ + "${TVOS_SIMULATOR_ARM64_PREFIX}/lib/libsodium.${ext}" \ + "${TVOS_SIMULATOR_ARM64E_PREFIX}/lib/libsodium.${ext}" \ + "${TVOS_SIMULATOR_X86_64_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/tvos-simulators/lib/libsodium.${ext}" || exit 1 + done + + if [ "$VISIONOS_SUPPORTED" = true ]; then + echo "Bundling visionOS simulators..." + + mkdir -p "${PREFIX}/visionos-simulators/lib" + cp -a "${VISIONOS_SIMULATOR_PREFIX}/include" "${PREFIX}/visionos-simulators/" + for ext in a dylib; do + lipo -create \ + "${VISIONOS_SIMULATOR_PREFIX}/lib/libsodium.${ext}" \ + "${VISIONOSE_SIMULATOR_PREFIX}/lib/libsodium.${ext}" \ + -output "${PREFIX}/visionos-simulators/lib/libsodium.${ext}" || exit 1 + done + fi +fi + +echo "Creating Clibsodium.xcframework..." + +rm -rf "${PREFIX}/Clibsodium.xcframework" + +XCFRAMEWORK_ARGS="" +for f in macos ios watchos tvos visionos catalyst; do + if [ "$VISIONOS_SUPPORTED" = false ] && [ "$f" = "visionos" ]; then + continue + fi + XCFRAMEWORK_ARGS="${XCFRAMEWORK_ARGS} -library $(readlink -f ${PREFIX}/${f}/lib/libsodium.a)" + XCFRAMEWORK_ARGS="${XCFRAMEWORK_ARGS} -headers $(readlink -f ${PREFIX}/${f}/include)" +done +if [ -z "$LIBSODIUM_SKIP_SIMULATORS" ]; then + for f in ios-simulators watchos-simulators tvos-simulators visionos-simulators; do + if [ "$VISIONOS_SUPPORTED" = false ] && [ "$f" = "visionos-simulators" ]; then + continue + fi + XCFRAMEWORK_ARGS="${XCFRAMEWORK_ARGS} -library $(readlink -f ${PREFIX}/${f}/lib/libsodium.a)" + XCFRAMEWORK_ARGS="${XCFRAMEWORK_ARGS} -headers $(readlink -f ${PREFIX}/${f}/include)" + done +fi +xcodebuild -create-xcframework \ + ${XCFRAMEWORK_ARGS} \ + -output "${PREFIX}/Clibsodium.xcframework" >/dev/null + +ls -ld -- "$PREFIX" +ls -l -- "$PREFIX" +ls -l -- "$PREFIX/Clibsodium.xcframework" + +echo "Done!" + +# Cleanup +rm -rf -- "$PREFIX/tmp" +make distclean >/dev/null diff --git a/subprojects/libsodium/dist-build/emscripten-symbols.def b/subprojects/libsodium/dist-build/emscripten-symbols.def @@ -1,3 +1,23 @@ +_crypto_aead_aegis128l_abytes 1 1 +_crypto_aead_aegis128l_decrypt 1 1 +_crypto_aead_aegis128l_decrypt_detached 1 1 +_crypto_aead_aegis128l_encrypt 1 1 +_crypto_aead_aegis128l_encrypt_detached 1 1 +_crypto_aead_aegis128l_keybytes 1 1 +_crypto_aead_aegis128l_keygen 1 1 +_crypto_aead_aegis128l_messagebytes_max 1 1 +_crypto_aead_aegis128l_npubbytes 1 1 +_crypto_aead_aegis128l_nsecbytes 1 1 +_crypto_aead_aegis256_abytes 1 1 +_crypto_aead_aegis256_decrypt 1 1 +_crypto_aead_aegis256_decrypt_detached 1 1 +_crypto_aead_aegis256_encrypt 1 1 +_crypto_aead_aegis256_encrypt_detached 1 1 +_crypto_aead_aegis256_keybytes 1 1 +_crypto_aead_aegis256_keygen 1 1 +_crypto_aead_aegis256_messagebytes_max 1 1 +_crypto_aead_aegis256_npubbytes 1 1 +_crypto_aead_aegis256_nsecbytes 1 1 _crypto_aead_aes256gcm_abytes 0 0 _crypto_aead_aes256gcm_beforenm 0 0 _crypto_aead_aes256gcm_decrypt 0 0 @@ -8,7 +28,7 @@ _crypto_aead_aes256gcm_encrypt 0 0 _crypto_aead_aes256gcm_encrypt_afternm 0 0 _crypto_aead_aes256gcm_encrypt_detached 0 0 _crypto_aead_aes256gcm_encrypt_detached_afternm 0 0 -_crypto_aead_aes256gcm_is_available 0 0 +_crypto_aead_aes256gcm_is_available 1 1 _crypto_aead_aes256gcm_keybytes 0 0 _crypto_aead_aes256gcm_keygen 0 0 _crypto_aead_aes256gcm_messagebytes_max 0 0 @@ -145,7 +165,7 @@ _crypto_box_seedbytes 1 1 _crypto_box_zerobytes 0 1 _crypto_core_ed25519_add 0 1 _crypto_core_ed25519_bytes 0 1 -_crypto_core_ed25519_from_hash 0 1 +_crypto_core_ed25519_from_hash 0 0 _crypto_core_ed25519_from_uniform 0 1 _crypto_core_ed25519_hashbytes 0 1 _crypto_core_ed25519_is_valid_point 0 1 @@ -154,6 +174,7 @@ _crypto_core_ed25519_random 0 1 _crypto_core_ed25519_scalar_add 0 1 _crypto_core_ed25519_scalar_complement 0 1 _crypto_core_ed25519_scalar_invert 0 1 +_crypto_core_ed25519_scalar_is_canonical 0 1 _crypto_core_ed25519_scalar_mul 0 1 _crypto_core_ed25519_scalar_negate 0 1 _crypto_core_ed25519_scalar_random 0 1 @@ -182,6 +203,7 @@ _crypto_core_ristretto255_random 0 1 _crypto_core_ristretto255_scalar_add 0 1 _crypto_core_ristretto255_scalar_complement 0 1 _crypto_core_ristretto255_scalar_invert 0 1 +_crypto_core_ristretto255_scalar_is_canonical 0 1 _crypto_core_ristretto255_scalar_mul 0 1 _crypto_core_ristretto255_scalar_negate 0 1 _crypto_core_ristretto255_scalar_random 0 1 @@ -258,6 +280,26 @@ _crypto_kdf_bytes_max 1 1 _crypto_kdf_bytes_min 1 1 _crypto_kdf_contextbytes 1 1 _crypto_kdf_derive_from_key 1 1 +_crypto_kdf_hkdf_sha256_bytes_max 1 1 +_crypto_kdf_hkdf_sha256_bytes_min 1 1 +_crypto_kdf_hkdf_sha256_expand 1 1 +_crypto_kdf_hkdf_sha256_extract 1 1 +_crypto_kdf_hkdf_sha256_extract_final 1 1 +_crypto_kdf_hkdf_sha256_extract_init 1 1 +_crypto_kdf_hkdf_sha256_statebytes 1 1 +_crypto_kdf_hkdf_sha256_extract_update 1 1 +_crypto_kdf_hkdf_sha256_keybytes 1 1 +_crypto_kdf_hkdf_sha256_keygen 1 1 +_crypto_kdf_hkdf_sha512_bytes_max 1 1 +_crypto_kdf_hkdf_sha512_bytes_min 1 1 +_crypto_kdf_hkdf_sha512_expand 1 1 +_crypto_kdf_hkdf_sha512_extract 1 1 +_crypto_kdf_hkdf_sha512_extract_final 1 1 +_crypto_kdf_hkdf_sha512_extract_init 1 1 +_crypto_kdf_hkdf_sha512_statebytes 1 1 +_crypto_kdf_hkdf_sha512_extract_update 1 1 +_crypto_kdf_hkdf_sha512_keybytes 1 1 +_crypto_kdf_hkdf_sha512_keygen 1 1 _crypto_kdf_keybytes 1 1 _crypto_kdf_keygen 1 1 _crypto_kdf_primitive 0 1 @@ -289,10 +331,10 @@ _crypto_onetimeauth_primitive 0 1 _crypto_onetimeauth_statebytes 0 1 _crypto_onetimeauth_update 0 1 _crypto_onetimeauth_verify 0 1 -_crypto_pwhash 1 1 -_crypto_pwhash_alg_argon2i13 1 1 -_crypto_pwhash_alg_argon2id13 1 1 -_crypto_pwhash_alg_default 1 1 +_crypto_pwhash 0 1 +_crypto_pwhash_alg_argon2i13 0 1 +_crypto_pwhash_alg_argon2id13 0 1 +_crypto_pwhash_alg_default 0 1 _crypto_pwhash_argon2i 0 1 _crypto_pwhash_argon2i_alg_argon2i13 0 1 _crypto_pwhash_argon2i_bytes_max 0 1 @@ -337,22 +379,22 @@ _crypto_pwhash_argon2id_str_needs_rehash 0 1 _crypto_pwhash_argon2id_str_verify 0 1 _crypto_pwhash_argon2id_strbytes 0 1 _crypto_pwhash_argon2id_strprefix 0 1 -_crypto_pwhash_bytes_max 1 1 -_crypto_pwhash_bytes_min 1 1 -_crypto_pwhash_memlimit_interactive 1 1 -_crypto_pwhash_memlimit_max 1 1 -_crypto_pwhash_memlimit_min 1 1 -_crypto_pwhash_memlimit_moderate 1 1 -_crypto_pwhash_memlimit_sensitive 1 1 -_crypto_pwhash_opslimit_interactive 1 1 -_crypto_pwhash_opslimit_max 1 1 -_crypto_pwhash_opslimit_min 1 1 -_crypto_pwhash_opslimit_moderate 1 1 -_crypto_pwhash_opslimit_sensitive 1 1 -_crypto_pwhash_passwd_max 1 1 -_crypto_pwhash_passwd_min 1 1 +_crypto_pwhash_bytes_max 0 1 +_crypto_pwhash_bytes_min 0 1 +_crypto_pwhash_memlimit_interactive 0 1 +_crypto_pwhash_memlimit_max 0 1 +_crypto_pwhash_memlimit_min 0 1 +_crypto_pwhash_memlimit_moderate 0 1 +_crypto_pwhash_memlimit_sensitive 0 1 +_crypto_pwhash_opslimit_interactive 0 1 +_crypto_pwhash_opslimit_max 0 1 +_crypto_pwhash_opslimit_min 0 1 +_crypto_pwhash_opslimit_moderate 0 1 +_crypto_pwhash_opslimit_sensitive 0 1 +_crypto_pwhash_passwd_max 0 1 +_crypto_pwhash_passwd_min 0 1 _crypto_pwhash_primitive 0 1 -_crypto_pwhash_saltbytes 1 1 +_crypto_pwhash_saltbytes 0 1 _crypto_pwhash_scryptsalsa208sha256 0 1 _crypto_pwhash_scryptsalsa208sha256_bytes_max 0 1 _crypto_pwhash_scryptsalsa208sha256_bytes_min 0 1 @@ -373,12 +415,12 @@ _crypto_pwhash_scryptsalsa208sha256_str_needs_rehash 0 1 _crypto_pwhash_scryptsalsa208sha256_str_verify 0 1 _crypto_pwhash_scryptsalsa208sha256_strbytes 0 1 _crypto_pwhash_scryptsalsa208sha256_strprefix 0 1 -_crypto_pwhash_str 1 1 -_crypto_pwhash_str_alg 1 1 -_crypto_pwhash_str_needs_rehash 1 1 -_crypto_pwhash_str_verify 1 1 -_crypto_pwhash_strbytes 1 1 -_crypto_pwhash_strprefix 1 1 +_crypto_pwhash_str 0 1 +_crypto_pwhash_str_alg 0 1 +_crypto_pwhash_str_needs_rehash 0 1 +_crypto_pwhash_str_verify 0 1 +_crypto_pwhash_strbytes 0 1 +_crypto_pwhash_strprefix 0 1 _crypto_scalarmult 1 1 _crypto_scalarmult_base 1 1 _crypto_scalarmult_bytes 1 1 @@ -591,6 +633,7 @@ _sodium_mprotect_readwrite 0 0 _sodium_munlock 0 0 _sodium_pad 1 1 _sodium_runtime_has_aesni 0 0 +_sodium_runtime_has_armcrypto 0 0 _sodium_runtime_has_avx 0 0 _sodium_runtime_has_avx2 0 0 _sodium_runtime_has_avx512f 0 0 diff --git a/subprojects/libsodium/dist-build/emscripten.sh b/subprojects/libsodium/dist-build/emscripten.sh @@ -1,12 +1,13 @@ #! /bin/sh export MAKE_FLAGS='-j4' -export EXPORTED_FUNCTIONS_STANDARD='["_malloc","_free","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_verify","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_generichash","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_pwhash","_crypto_pwhash_alg_argon2i13","_crypto_pwhash_alg_argon2id13","_crypto_pwhash_alg_default","_crypto_pwhash_bytes_max","_crypto_pwhash_bytes_min","_crypto_pwhash_memlimit_interactive","_crypto_pwhash_memlimit_max","_crypto_pwhash_memlimit_min","_crypto_pwhash_memlimit_moderate","_crypto_pwhash_memlimit_sensitive","_crypto_pwhash_opslimit_interactive","_crypto_pwhash_opslimit_max","_crypto_pwhash_opslimit_min","_crypto_pwhash_opslimit_moderate","_crypto_pwhash_opslimit_sensitive","_crypto_pwhash_passwd_max","_crypto_pwhash_passwd_min","_crypto_pwhash_saltbytes","_crypto_pwhash_str","_crypto_pwhash_str_alg","_crypto_pwhash_str_needs_rehash","_crypto_pwhash_str_verify","_crypto_pwhash_strbytes","_crypto_pwhash_strprefix","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]' -export EXPORTED_FUNCTIONS_SUMO='["_malloc","_free","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_hmacsha256","_crypto_auth_hmacsha256_bytes","_crypto_auth_hmacsha256_final","_crypto_auth_hmacsha256_init","_crypto_auth_hmacsha256_keybytes","_crypto_auth_hmacsha256_keygen","_crypto_auth_hmacsha256_statebytes","_crypto_auth_hmacsha256_update","_crypto_auth_hmacsha256_verify","_crypto_auth_hmacsha512","_crypto_auth_hmacsha512256","_crypto_auth_hmacsha512256_bytes","_crypto_auth_hmacsha512256_final","_crypto_auth_hmacsha512256_init","_crypto_auth_hmacsha512256_keybytes","_crypto_auth_hmacsha512256_keygen","_crypto_auth_hmacsha512256_statebytes","_crypto_auth_hmacsha512256_update","_crypto_auth_hmacsha512256_verify","_crypto_auth_hmacsha512_bytes","_crypto_auth_hmacsha512_final","_crypto_auth_hmacsha512_init","_crypto_auth_hmacsha512_keybytes","_crypto_auth_hmacsha512_keygen","_crypto_auth_hmacsha512_statebytes","_crypto_auth_hmacsha512_update","_crypto_auth_hmacsha512_verify","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_primitive","_crypto_auth_verify","_crypto_box","_crypto_box_afternm","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_boxzerobytes","_crypto_box_curve25519xchacha20poly1305_beforenm","_crypto_box_curve25519xchacha20poly1305_beforenmbytes","_crypto_box_curve25519xchacha20poly1305_detached","_crypto_box_curve25519xchacha20poly1305_detached_afternm","_crypto_box_curve25519xchacha20poly1305_easy","_crypto_box_curve25519xchacha20poly1305_easy_afternm","_crypto_box_curve25519xchacha20poly1305_keypair","_crypto_box_curve25519xchacha20poly1305_macbytes","_crypto_box_curve25519xchacha20poly1305_messagebytes_max","_crypto_box_curve25519xchacha20poly1305_noncebytes","_crypto_box_curve25519xchacha20poly1305_open_detached","_crypto_box_curve25519xchacha20poly1305_open_detached_afternm","_crypto_box_curve25519xchacha20poly1305_open_easy","_crypto_box_curve25519xchacha20poly1305_open_easy_afternm","_crypto_box_curve25519xchacha20poly1305_publickeybytes","_crypto_box_curve25519xchacha20poly1305_seal","_crypto_box_curve25519xchacha20poly1305_seal_open","_crypto_box_curve25519xchacha20poly1305_sealbytes","_crypto_box_curve25519xchacha20poly1305_secretkeybytes","_crypto_box_curve25519xchacha20poly1305_seed_keypair","_crypto_box_curve25519xchacha20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305","_crypto_box_curve25519xsalsa20poly1305_afternm","_crypto_box_curve25519xsalsa20poly1305_beforenm","_crypto_box_curve25519xsalsa20poly1305_beforenmbytes","_crypto_box_curve25519xsalsa20poly1305_boxzerobytes","_crypto_box_curve25519xsalsa20poly1305_keypair","_crypto_box_curve25519xsalsa20poly1305_macbytes","_crypto_box_curve25519xsalsa20poly1305_messagebytes_max","_crypto_box_curve25519xsalsa20poly1305_noncebytes","_crypto_box_curve25519xsalsa20poly1305_open","_crypto_box_curve25519xsalsa20poly1305_open_afternm","_crypto_box_curve25519xsalsa20poly1305_publickeybytes","_crypto_box_curve25519xsalsa20poly1305_secretkeybytes","_crypto_box_curve25519xsalsa20poly1305_seed_keypair","_crypto_box_curve25519xsalsa20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305_zerobytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open","_crypto_box_open_afternm","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_primitive","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_box_zerobytes","_crypto_core_ed25519_add","_crypto_core_ed25519_bytes","_crypto_core_ed25519_from_hash","_crypto_core_ed25519_from_uniform","_crypto_core_ed25519_hashbytes","_crypto_core_ed25519_is_valid_point","_crypto_core_ed25519_nonreducedscalarbytes","_crypto_core_ed25519_random","_crypto_core_ed25519_scalar_add","_crypto_core_ed25519_scalar_complement","_crypto_core_ed25519_scalar_invert","_crypto_core_ed25519_scalar_mul","_crypto_core_ed25519_scalar_negate","_crypto_core_ed25519_scalar_random","_crypto_core_ed25519_scalar_reduce","_crypto_core_ed25519_scalar_sub","_crypto_core_ed25519_scalarbytes","_crypto_core_ed25519_sub","_crypto_core_ed25519_uniformbytes","_crypto_core_hchacha20","_crypto_core_hchacha20_constbytes","_crypto_core_hchacha20_inputbytes","_crypto_core_hchacha20_keybytes","_crypto_core_hchacha20_outputbytes","_crypto_core_hsalsa20","_crypto_core_hsalsa20_constbytes","_crypto_core_hsalsa20_inputbytes","_crypto_core_hsalsa20_keybytes","_crypto_core_hsalsa20_outputbytes","_crypto_core_ristretto255_add","_crypto_core_ristretto255_bytes","_crypto_core_ristretto255_from_hash","_crypto_core_ristretto255_hashbytes","_crypto_core_ristretto255_is_valid_point","_crypto_core_ristretto255_nonreducedscalarbytes","_crypto_core_ristretto255_random","_crypto_core_ristretto255_scalar_add","_crypto_core_ristretto255_scalar_complement","_crypto_core_ristretto255_scalar_invert","_crypto_core_ristretto255_scalar_mul","_crypto_core_ristretto255_scalar_negate","_crypto_core_ristretto255_scalar_random","_crypto_core_ristretto255_scalar_reduce","_crypto_core_ristretto255_scalar_sub","_crypto_core_ristretto255_scalarbytes","_crypto_core_ristretto255_sub","_crypto_core_salsa20","_crypto_core_salsa2012","_crypto_core_salsa2012_constbytes","_crypto_core_salsa2012_inputbytes","_crypto_core_salsa2012_keybytes","_crypto_core_salsa2012_outputbytes","_crypto_core_salsa208","_crypto_core_salsa208_constbytes","_crypto_core_salsa208_inputbytes","_crypto_core_salsa208_keybytes","_crypto_core_salsa208_outputbytes","_crypto_core_salsa20_constbytes","_crypto_core_salsa20_inputbytes","_crypto_core_salsa20_keybytes","_crypto_core_salsa20_outputbytes","_crypto_generichash","_crypto_generichash_blake2b","_crypto_generichash_blake2b_bytes","_crypto_generichash_blake2b_bytes_max","_crypto_generichash_blake2b_bytes_min","_crypto_generichash_blake2b_final","_crypto_generichash_blake2b_init","_crypto_generichash_blake2b_init_salt_personal","_crypto_generichash_blake2b_keybytes","_crypto_generichash_blake2b_keybytes_max","_crypto_generichash_blake2b_keybytes_min","_crypto_generichash_blake2b_keygen","_crypto_generichash_blake2b_personalbytes","_crypto_generichash_blake2b_salt_personal","_crypto_generichash_blake2b_saltbytes","_crypto_generichash_blake2b_statebytes","_crypto_generichash_blake2b_update","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_primitive","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_hash_primitive","_crypto_hash_sha256","_crypto_hash_sha256_bytes","_crypto_hash_sha256_final","_crypto_hash_sha256_init","_crypto_hash_sha256_statebytes","_crypto_hash_sha256_update","_crypto_hash_sha512","_crypto_hash_sha512_bytes","_crypto_hash_sha512_final","_crypto_hash_sha512_init","_crypto_hash_sha512_statebytes","_crypto_hash_sha512_update","_crypto_kdf_blake2b_bytes_max","_crypto_kdf_blake2b_bytes_min","_crypto_kdf_blake2b_contextbytes","_crypto_kdf_blake2b_derive_from_key","_crypto_kdf_blake2b_keybytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kdf_primitive","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_primitive","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_onetimeauth","_crypto_onetimeauth_bytes","_crypto_onetimeauth_final","_crypto_onetimeauth_init","_crypto_onetimeauth_keybytes","_crypto_onetimeauth_keygen","_crypto_onetimeauth_poly1305","_crypto_onetimeauth_poly1305_bytes","_crypto_onetimeauth_poly1305_final","_crypto_onetimeauth_poly1305_init","_crypto_onetimeauth_poly1305_keybytes","_crypto_onetimeauth_poly1305_keygen","_crypto_onetimeauth_poly1305_statebytes","_crypto_onetimeauth_poly1305_update","_crypto_onetimeauth_poly1305_verify","_crypto_onetimeauth_primitive","_crypto_onetimeauth_statebytes","_crypto_onetimeauth_update","_crypto_onetimeauth_verify","_crypto_pwhash","_crypto_pwhash_alg_argon2i13","_crypto_pwhash_alg_argon2id13","_crypto_pwhash_alg_default","_crypto_pwhash_argon2i","_crypto_pwhash_argon2i_alg_argon2i13","_crypto_pwhash_argon2i_bytes_max","_crypto_pwhash_argon2i_bytes_min","_crypto_pwhash_argon2i_memlimit_interactive","_crypto_pwhash_argon2i_memlimit_max","_crypto_pwhash_argon2i_memlimit_min","_crypto_pwhash_argon2i_memlimit_moderate","_crypto_pwhash_argon2i_memlimit_sensitive","_crypto_pwhash_argon2i_opslimit_interactive","_crypto_pwhash_argon2i_opslimit_max","_crypto_pwhash_argon2i_opslimit_min","_crypto_pwhash_argon2i_opslimit_moderate","_crypto_pwhash_argon2i_opslimit_sensitive","_crypto_pwhash_argon2i_passwd_max","_crypto_pwhash_argon2i_passwd_min","_crypto_pwhash_argon2i_saltbytes","_crypto_pwhash_argon2i_str","_crypto_pwhash_argon2i_str_needs_rehash","_crypto_pwhash_argon2i_str_verify","_crypto_pwhash_argon2i_strbytes","_crypto_pwhash_argon2i_strprefix","_crypto_pwhash_argon2id","_crypto_pwhash_argon2id_alg_argon2id13","_crypto_pwhash_argon2id_bytes_max","_crypto_pwhash_argon2id_bytes_min","_crypto_pwhash_argon2id_memlimit_interactive","_crypto_pwhash_argon2id_memlimit_max","_crypto_pwhash_argon2id_memlimit_min","_crypto_pwhash_argon2id_memlimit_moderate","_crypto_pwhash_argon2id_memlimit_sensitive","_crypto_pwhash_argon2id_opslimit_interactive","_crypto_pwhash_argon2id_opslimit_max","_crypto_pwhash_argon2id_opslimit_min","_crypto_pwhash_argon2id_opslimit_moderate","_crypto_pwhash_argon2id_opslimit_sensitive","_crypto_pwhash_argon2id_passwd_max","_crypto_pwhash_argon2id_passwd_min","_crypto_pwhash_argon2id_saltbytes","_crypto_pwhash_argon2id_str","_crypto_pwhash_argon2id_str_needs_rehash","_crypto_pwhash_argon2id_str_verify","_crypto_pwhash_argon2id_strbytes","_crypto_pwhash_argon2id_strprefix","_crypto_pwhash_bytes_max","_crypto_pwhash_bytes_min","_crypto_pwhash_memlimit_interactive","_crypto_pwhash_memlimit_max","_crypto_pwhash_memlimit_min","_crypto_pwhash_memlimit_moderate","_crypto_pwhash_memlimit_sensitive","_crypto_pwhash_opslimit_interactive","_crypto_pwhash_opslimit_max","_crypto_pwhash_opslimit_min","_crypto_pwhash_opslimit_moderate","_crypto_pwhash_opslimit_sensitive","_crypto_pwhash_passwd_max","_crypto_pwhash_passwd_min","_crypto_pwhash_primitive","_crypto_pwhash_saltbytes","_crypto_pwhash_scryptsalsa208sha256","_crypto_pwhash_scryptsalsa208sha256_bytes_max","_crypto_pwhash_scryptsalsa208sha256_bytes_min","_crypto_pwhash_scryptsalsa208sha256_ll","_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive","_crypto_pwhash_scryptsalsa208sha256_memlimit_max","_crypto_pwhash_scryptsalsa208sha256_memlimit_min","_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive","_crypto_pwhash_scryptsalsa208sha256_opslimit_max","_crypto_pwhash_scryptsalsa208sha256_opslimit_min","_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_passwd_max","_crypto_pwhash_scryptsalsa208sha256_passwd_min","_crypto_pwhash_scryptsalsa208sha256_saltbytes","_crypto_pwhash_scryptsalsa208sha256_str","_crypto_pwhash_scryptsalsa208sha256_str_needs_rehash","_crypto_pwhash_scryptsalsa208sha256_str_verify","_crypto_pwhash_scryptsalsa208sha256_strbytes","_crypto_pwhash_scryptsalsa208sha256_strprefix","_crypto_pwhash_str","_crypto_pwhash_str_alg","_crypto_pwhash_str_needs_rehash","_crypto_pwhash_str_verify","_crypto_pwhash_strbytes","_crypto_pwhash_strprefix","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_curve25519","_crypto_scalarmult_curve25519_base","_crypto_scalarmult_curve25519_bytes","_crypto_scalarmult_curve25519_scalarbytes","_crypto_scalarmult_ed25519","_crypto_scalarmult_ed25519_base","_crypto_scalarmult_ed25519_base_noclamp","_crypto_scalarmult_ed25519_bytes","_crypto_scalarmult_ed25519_noclamp","_crypto_scalarmult_ed25519_scalarbytes","_crypto_scalarmult_primitive","_crypto_scalarmult_ristretto255","_crypto_scalarmult_ristretto255_base","_crypto_scalarmult_ristretto255_bytes","_crypto_scalarmult_ristretto255_scalarbytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox","_crypto_secretbox_boxzerobytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretbox_primitive","_crypto_secretbox_xchacha20poly1305_detached","_crypto_secretbox_xchacha20poly1305_easy","_crypto_secretbox_xchacha20poly1305_keybytes","_crypto_secretbox_xchacha20poly1305_macbytes","_crypto_secretbox_xchacha20poly1305_messagebytes_max","_crypto_secretbox_xchacha20poly1305_noncebytes","_crypto_secretbox_xchacha20poly1305_open_detached","_crypto_secretbox_xchacha20poly1305_open_easy","_crypto_secretbox_xsalsa20poly1305","_crypto_secretbox_xsalsa20poly1305_boxzerobytes","_crypto_secretbox_xsalsa20poly1305_keybytes","_crypto_secretbox_xsalsa20poly1305_keygen","_crypto_secretbox_xsalsa20poly1305_macbytes","_crypto_secretbox_xsalsa20poly1305_messagebytes_max","_crypto_secretbox_xsalsa20poly1305_noncebytes","_crypto_secretbox_xsalsa20poly1305_open","_crypto_secretbox_xsalsa20poly1305_zerobytes","_crypto_secretbox_zerobytes","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_shorthash_primitive","_crypto_shorthash_siphash24","_crypto_shorthash_siphash24_bytes","_crypto_shorthash_siphash24_keybytes","_crypto_shorthash_siphashx24","_crypto_shorthash_siphashx24_bytes","_crypto_shorthash_siphashx24_keybytes","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519","_crypto_sign_ed25519_bytes","_crypto_sign_ed25519_detached","_crypto_sign_ed25519_keypair","_crypto_sign_ed25519_messagebytes_max","_crypto_sign_ed25519_open","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_publickeybytes","_crypto_sign_ed25519_secretkeybytes","_crypto_sign_ed25519_seed_keypair","_crypto_sign_ed25519_seedbytes","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_ed25519_sk_to_pk","_crypto_sign_ed25519_sk_to_seed","_crypto_sign_ed25519_verify_detached","_crypto_sign_ed25519ph_final_create","_crypto_sign_ed25519ph_final_verify","_crypto_sign_ed25519ph_init","_crypto_sign_ed25519ph_statebytes","_crypto_sign_ed25519ph_update","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_primitive","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_crypto_stream","_crypto_stream_chacha20","_crypto_stream_chacha20_ietf","_crypto_stream_chacha20_ietf_keybytes","_crypto_stream_chacha20_ietf_keygen","_crypto_stream_chacha20_ietf_messagebytes_max","_crypto_stream_chacha20_ietf_noncebytes","_crypto_stream_chacha20_ietf_xor","_crypto_stream_chacha20_ietf_xor_ic","_crypto_stream_chacha20_keybytes","_crypto_stream_chacha20_keygen","_crypto_stream_chacha20_messagebytes_max","_crypto_stream_chacha20_noncebytes","_crypto_stream_chacha20_xor","_crypto_stream_chacha20_xor_ic","_crypto_stream_keybytes","_crypto_stream_keygen","_crypto_stream_messagebytes_max","_crypto_stream_noncebytes","_crypto_stream_primitive","_crypto_stream_salsa20","_crypto_stream_salsa2012","_crypto_stream_salsa2012_keybytes","_crypto_stream_salsa2012_keygen","_crypto_stream_salsa2012_messagebytes_max","_crypto_stream_salsa2012_noncebytes","_crypto_stream_salsa2012_xor","_crypto_stream_salsa208","_crypto_stream_salsa208_keybytes","_crypto_stream_salsa208_keygen","_crypto_stream_salsa208_messagebytes_max","_crypto_stream_salsa208_noncebytes","_crypto_stream_salsa208_xor","_crypto_stream_salsa20_keybytes","_crypto_stream_salsa20_keygen","_crypto_stream_salsa20_messagebytes_max","_crypto_stream_salsa20_noncebytes","_crypto_stream_salsa20_xor","_crypto_stream_salsa20_xor_ic","_crypto_stream_xchacha20","_crypto_stream_xchacha20_keybytes","_crypto_stream_xchacha20_keygen","_crypto_stream_xchacha20_messagebytes_max","_crypto_stream_xchacha20_noncebytes","_crypto_stream_xchacha20_xor","_crypto_stream_xchacha20_xor_ic","_crypto_stream_xor","_crypto_stream_xsalsa20","_crypto_stream_xsalsa20_keybytes","_crypto_stream_xsalsa20_keygen","_crypto_stream_xsalsa20_messagebytes_max","_crypto_stream_xsalsa20_noncebytes","_crypto_stream_xsalsa20_xor","_crypto_stream_xsalsa20_xor_ic","_crypto_verify_16","_crypto_verify_16_bytes","_crypto_verify_32","_crypto_verify_32_bytes","_crypto_verify_64","_crypto_verify_64_bytes","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_implementation_name","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]' +export EXPORTED_FUNCTIONS_STANDARD='["_malloc","_free","_crypto_aead_aegis128l_abytes","_crypto_aead_aegis128l_decrypt","_crypto_aead_aegis128l_decrypt_detached","_crypto_aead_aegis128l_encrypt","_crypto_aead_aegis128l_encrypt_detached","_crypto_aead_aegis128l_keybytes","_crypto_aead_aegis128l_keygen","_crypto_aead_aegis128l_messagebytes_max","_crypto_aead_aegis128l_npubbytes","_crypto_aead_aegis128l_nsecbytes","_crypto_aead_aegis256_abytes","_crypto_aead_aegis256_decrypt","_crypto_aead_aegis256_decrypt_detached","_crypto_aead_aegis256_encrypt","_crypto_aead_aegis256_encrypt_detached","_crypto_aead_aegis256_keybytes","_crypto_aead_aegis256_keygen","_crypto_aead_aegis256_messagebytes_max","_crypto_aead_aegis256_npubbytes","_crypto_aead_aegis256_nsecbytes","_crypto_aead_aes256gcm_is_available","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_verify","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_generichash","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_hkdf_sha256_bytes_max","_crypto_kdf_hkdf_sha256_bytes_min","_crypto_kdf_hkdf_sha256_expand","_crypto_kdf_hkdf_sha256_extract","_crypto_kdf_hkdf_sha256_extract_final","_crypto_kdf_hkdf_sha256_extract_init","_crypto_kdf_hkdf_sha256_extract_update","_crypto_kdf_hkdf_sha256_keybytes","_crypto_kdf_hkdf_sha256_keygen","_crypto_kdf_hkdf_sha256_statebytes","_crypto_kdf_hkdf_sha512_bytes_max","_crypto_kdf_hkdf_sha512_bytes_min","_crypto_kdf_hkdf_sha512_expand","_crypto_kdf_hkdf_sha512_extract","_crypto_kdf_hkdf_sha512_extract_final","_crypto_kdf_hkdf_sha512_extract_init","_crypto_kdf_hkdf_sha512_extract_update","_crypto_kdf_hkdf_sha512_keybytes","_crypto_kdf_hkdf_sha512_keygen","_crypto_kdf_hkdf_sha512_statebytes","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]' +export EXPORTED_FUNCTIONS_SUMO='["_malloc","_free","_crypto_aead_aegis128l_abytes","_crypto_aead_aegis128l_decrypt","_crypto_aead_aegis128l_decrypt_detached","_crypto_aead_aegis128l_encrypt","_crypto_aead_aegis128l_encrypt_detached","_crypto_aead_aegis128l_keybytes","_crypto_aead_aegis128l_keygen","_crypto_aead_aegis128l_messagebytes_max","_crypto_aead_aegis128l_npubbytes","_crypto_aead_aegis128l_nsecbytes","_crypto_aead_aegis256_abytes","_crypto_aead_aegis256_decrypt","_crypto_aead_aegis256_decrypt_detached","_crypto_aead_aegis256_encrypt","_crypto_aead_aegis256_encrypt_detached","_crypto_aead_aegis256_keybytes","_crypto_aead_aegis256_keygen","_crypto_aead_aegis256_messagebytes_max","_crypto_aead_aegis256_npubbytes","_crypto_aead_aegis256_nsecbytes","_crypto_aead_aes256gcm_is_available","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_hmacsha256","_crypto_auth_hmacsha256_bytes","_crypto_auth_hmacsha256_final","_crypto_auth_hmacsha256_init","_crypto_auth_hmacsha256_keybytes","_crypto_auth_hmacsha256_keygen","_crypto_auth_hmacsha256_statebytes","_crypto_auth_hmacsha256_update","_crypto_auth_hmacsha256_verify","_crypto_auth_hmacsha512","_crypto_auth_hmacsha512256","_crypto_auth_hmacsha512256_bytes","_crypto_auth_hmacsha512256_final","_crypto_auth_hmacsha512256_init","_crypto_auth_hmacsha512256_keybytes","_crypto_auth_hmacsha512256_keygen","_crypto_auth_hmacsha512256_statebytes","_crypto_auth_hmacsha512256_update","_crypto_auth_hmacsha512256_verify","_crypto_auth_hmacsha512_bytes","_crypto_auth_hmacsha512_final","_crypto_auth_hmacsha512_init","_crypto_auth_hmacsha512_keybytes","_crypto_auth_hmacsha512_keygen","_crypto_auth_hmacsha512_statebytes","_crypto_auth_hmacsha512_update","_crypto_auth_hmacsha512_verify","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_primitive","_crypto_auth_verify","_crypto_box","_crypto_box_afternm","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_boxzerobytes","_crypto_box_curve25519xchacha20poly1305_beforenm","_crypto_box_curve25519xchacha20poly1305_beforenmbytes","_crypto_box_curve25519xchacha20poly1305_detached","_crypto_box_curve25519xchacha20poly1305_detached_afternm","_crypto_box_curve25519xchacha20poly1305_easy","_crypto_box_curve25519xchacha20poly1305_easy_afternm","_crypto_box_curve25519xchacha20poly1305_keypair","_crypto_box_curve25519xchacha20poly1305_macbytes","_crypto_box_curve25519xchacha20poly1305_messagebytes_max","_crypto_box_curve25519xchacha20poly1305_noncebytes","_crypto_box_curve25519xchacha20poly1305_open_detached","_crypto_box_curve25519xchacha20poly1305_open_detached_afternm","_crypto_box_curve25519xchacha20poly1305_open_easy","_crypto_box_curve25519xchacha20poly1305_open_easy_afternm","_crypto_box_curve25519xchacha20poly1305_publickeybytes","_crypto_box_curve25519xchacha20poly1305_seal","_crypto_box_curve25519xchacha20poly1305_seal_open","_crypto_box_curve25519xchacha20poly1305_sealbytes","_crypto_box_curve25519xchacha20poly1305_secretkeybytes","_crypto_box_curve25519xchacha20poly1305_seed_keypair","_crypto_box_curve25519xchacha20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305","_crypto_box_curve25519xsalsa20poly1305_afternm","_crypto_box_curve25519xsalsa20poly1305_beforenm","_crypto_box_curve25519xsalsa20poly1305_beforenmbytes","_crypto_box_curve25519xsalsa20poly1305_boxzerobytes","_crypto_box_curve25519xsalsa20poly1305_keypair","_crypto_box_curve25519xsalsa20poly1305_macbytes","_crypto_box_curve25519xsalsa20poly1305_messagebytes_max","_crypto_box_curve25519xsalsa20poly1305_noncebytes","_crypto_box_curve25519xsalsa20poly1305_open","_crypto_box_curve25519xsalsa20poly1305_open_afternm","_crypto_box_curve25519xsalsa20poly1305_publickeybytes","_crypto_box_curve25519xsalsa20poly1305_secretkeybytes","_crypto_box_curve25519xsalsa20poly1305_seed_keypair","_crypto_box_curve25519xsalsa20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305_zerobytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open","_crypto_box_open_afternm","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_primitive","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_box_zerobytes","_crypto_core_ed25519_add","_crypto_core_ed25519_bytes","_crypto_core_ed25519_from_uniform","_crypto_core_ed25519_hashbytes","_crypto_core_ed25519_is_valid_point","_crypto_core_ed25519_nonreducedscalarbytes","_crypto_core_ed25519_random","_crypto_core_ed25519_scalar_add","_crypto_core_ed25519_scalar_complement","_crypto_core_ed25519_scalar_invert","_crypto_core_ed25519_scalar_mul","_crypto_core_ed25519_scalar_negate","_crypto_core_ed25519_scalar_random","_crypto_core_ed25519_scalar_reduce","_crypto_core_ed25519_scalar_sub","_crypto_core_ed25519_scalarbytes","_crypto_core_ed25519_sub","_crypto_core_ed25519_uniformbytes","_crypto_core_hchacha20","_crypto_core_hchacha20_constbytes","_crypto_core_hchacha20_inputbytes","_crypto_core_hchacha20_keybytes","_crypto_core_hchacha20_outputbytes","_crypto_core_hsalsa20","_crypto_core_hsalsa20_constbytes","_crypto_core_hsalsa20_inputbytes","_crypto_core_hsalsa20_keybytes","_crypto_core_hsalsa20_outputbytes","_crypto_core_ristretto255_add","_crypto_core_ristretto255_bytes","_crypto_core_ristretto255_from_hash","_crypto_core_ristretto255_hashbytes","_crypto_core_ristretto255_is_valid_point","_crypto_core_ristretto255_nonreducedscalarbytes","_crypto_core_ristretto255_random","_crypto_core_ristretto255_scalar_add","_crypto_core_ristretto255_scalar_complement","_crypto_core_ristretto255_scalar_invert","_crypto_core_ristretto255_scalar_mul","_crypto_core_ristretto255_scalar_negate","_crypto_core_ristretto255_scalar_random","_crypto_core_ristretto255_scalar_reduce","_crypto_core_ristretto255_scalar_sub","_crypto_core_ristretto255_scalarbytes","_crypto_core_ristretto255_sub","_crypto_core_salsa20","_crypto_core_salsa2012","_crypto_core_salsa2012_constbytes","_crypto_core_salsa2012_inputbytes","_crypto_core_salsa2012_keybytes","_crypto_core_salsa2012_outputbytes","_crypto_core_salsa208","_crypto_core_salsa208_constbytes","_crypto_core_salsa208_inputbytes","_crypto_core_salsa208_keybytes","_crypto_core_salsa208_outputbytes","_crypto_core_salsa20_constbytes","_crypto_core_salsa20_inputbytes","_crypto_core_salsa20_keybytes","_crypto_core_salsa20_outputbytes","_crypto_generichash","_crypto_generichash_blake2b","_crypto_generichash_blake2b_bytes","_crypto_generichash_blake2b_bytes_max","_crypto_generichash_blake2b_bytes_min","_crypto_generichash_blake2b_final","_crypto_generichash_blake2b_init","_crypto_generichash_blake2b_init_salt_personal","_crypto_generichash_blake2b_keybytes","_crypto_generichash_blake2b_keybytes_max","_crypto_generichash_blake2b_keybytes_min","_crypto_generichash_blake2b_keygen","_crypto_generichash_blake2b_personalbytes","_crypto_generichash_blake2b_salt_personal","_crypto_generichash_blake2b_saltbytes","_crypto_generichash_blake2b_statebytes","_crypto_generichash_blake2b_update","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_primitive","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_hash_primitive","_crypto_hash_sha256","_crypto_hash_sha256_bytes","_crypto_hash_sha256_final","_crypto_hash_sha256_init","_crypto_hash_sha256_statebytes","_crypto_hash_sha256_update","_crypto_hash_sha512","_crypto_hash_sha512_bytes","_crypto_hash_sha512_final","_crypto_hash_sha512_init","_crypto_hash_sha512_statebytes","_crypto_hash_sha512_update","_crypto_kdf_blake2b_bytes_max","_crypto_kdf_blake2b_bytes_min","_crypto_kdf_blake2b_contextbytes","_crypto_kdf_blake2b_derive_from_key","_crypto_kdf_blake2b_keybytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_hkdf_sha256_bytes_max","_crypto_kdf_hkdf_sha256_bytes_min","_crypto_kdf_hkdf_sha256_expand","_crypto_kdf_hkdf_sha256_extract","_crypto_kdf_hkdf_sha256_extract_final","_crypto_kdf_hkdf_sha256_extract_init","_crypto_kdf_hkdf_sha256_extract_update","_crypto_kdf_hkdf_sha256_keybytes","_crypto_kdf_hkdf_sha256_keygen","_crypto_kdf_hkdf_sha256_statebytes","_crypto_kdf_hkdf_sha512_bytes_max","_crypto_kdf_hkdf_sha512_bytes_min","_crypto_kdf_hkdf_sha512_expand","_crypto_kdf_hkdf_sha512_extract","_crypto_kdf_hkdf_sha512_extract_final","_crypto_kdf_hkdf_sha512_extract_init","_crypto_kdf_hkdf_sha512_extract_update","_crypto_kdf_hkdf_sha512_keybytes","_crypto_kdf_hkdf_sha512_keygen","_crypto_kdf_hkdf_sha512_statebytes","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kdf_primitive","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_primitive","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_onetimeauth","_crypto_onetimeauth_bytes","_crypto_onetimeauth_final","_crypto_onetimeauth_init","_crypto_onetimeauth_keybytes","_crypto_onetimeauth_keygen","_crypto_onetimeauth_poly1305","_crypto_onetimeauth_poly1305_bytes","_crypto_onetimeauth_poly1305_final","_crypto_onetimeauth_poly1305_init","_crypto_onetimeauth_poly1305_keybytes","_crypto_onetimeauth_poly1305_keygen","_crypto_onetimeauth_poly1305_statebytes","_crypto_onetimeauth_poly1305_update","_crypto_onetimeauth_poly1305_verify","_crypto_onetimeauth_primitive","_crypto_onetimeauth_statebytes","_crypto_onetimeauth_update","_crypto_onetimeauth_verify","_crypto_pwhash","_crypto_pwhash_alg_argon2i13","_crypto_pwhash_alg_argon2id13","_crypto_pwhash_alg_default","_crypto_pwhash_argon2i","_crypto_pwhash_argon2i_alg_argon2i13","_crypto_pwhash_argon2i_bytes_max","_crypto_pwhash_argon2i_bytes_min","_crypto_pwhash_argon2i_memlimit_interactive","_crypto_pwhash_argon2i_memlimit_max","_crypto_pwhash_argon2i_memlimit_min","_crypto_pwhash_argon2i_memlimit_moderate","_crypto_pwhash_argon2i_memlimit_sensitive","_crypto_pwhash_argon2i_opslimit_interactive","_crypto_pwhash_argon2i_opslimit_max","_crypto_pwhash_argon2i_opslimit_min","_crypto_pwhash_argon2i_opslimit_moderate","_crypto_pwhash_argon2i_opslimit_sensitive","_crypto_pwhash_argon2i_passwd_max","_crypto_pwhash_argon2i_passwd_min","_crypto_pwhash_argon2i_saltbytes","_crypto_pwhash_argon2i_str","_crypto_pwhash_argon2i_str_needs_rehash","_crypto_pwhash_argon2i_str_verify","_crypto_pwhash_argon2i_strbytes","_crypto_pwhash_argon2i_strprefix","_crypto_pwhash_argon2id","_crypto_pwhash_argon2id_alg_argon2id13","_crypto_pwhash_argon2id_bytes_max","_crypto_pwhash_argon2id_bytes_min","_crypto_pwhash_argon2id_memlimit_interactive","_crypto_pwhash_argon2id_memlimit_max","_crypto_pwhash_argon2id_memlimit_min","_crypto_pwhash_argon2id_memlimit_moderate","_crypto_pwhash_argon2id_memlimit_sensitive","_crypto_pwhash_argon2id_opslimit_interactive","_crypto_pwhash_argon2id_opslimit_max","_crypto_pwhash_argon2id_opslimit_min","_crypto_pwhash_argon2id_opslimit_moderate","_crypto_pwhash_argon2id_opslimit_sensitive","_crypto_pwhash_argon2id_passwd_max","_crypto_pwhash_argon2id_passwd_min","_crypto_pwhash_argon2id_saltbytes","_crypto_pwhash_argon2id_str","_crypto_pwhash_argon2id_str_needs_rehash","_crypto_pwhash_argon2id_str_verify","_crypto_pwhash_argon2id_strbytes","_crypto_pwhash_argon2id_strprefix","_crypto_pwhash_bytes_max","_crypto_pwhash_bytes_min","_crypto_pwhash_memlimit_interactive","_crypto_pwhash_memlimit_max","_crypto_pwhash_memlimit_min","_crypto_pwhash_memlimit_moderate","_crypto_pwhash_memlimit_sensitive","_crypto_pwhash_opslimit_interactive","_crypto_pwhash_opslimit_max","_crypto_pwhash_opslimit_min","_crypto_pwhash_opslimit_moderate","_crypto_pwhash_opslimit_sensitive","_crypto_pwhash_passwd_max","_crypto_pwhash_passwd_min","_crypto_pwhash_primitive","_crypto_pwhash_saltbytes","_crypto_pwhash_scryptsalsa208sha256","_crypto_pwhash_scryptsalsa208sha256_bytes_max","_crypto_pwhash_scryptsalsa208sha256_bytes_min","_crypto_pwhash_scryptsalsa208sha256_ll","_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive","_crypto_pwhash_scryptsalsa208sha256_memlimit_max","_crypto_pwhash_scryptsalsa208sha256_memlimit_min","_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive","_crypto_pwhash_scryptsalsa208sha256_opslimit_max","_crypto_pwhash_scryptsalsa208sha256_opslimit_min","_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_passwd_max","_crypto_pwhash_scryptsalsa208sha256_passwd_min","_crypto_pwhash_scryptsalsa208sha256_saltbytes","_crypto_pwhash_scryptsalsa208sha256_str","_crypto_pwhash_scryptsalsa208sha256_str_needs_rehash","_crypto_pwhash_scryptsalsa208sha256_str_verify","_crypto_pwhash_scryptsalsa208sha256_strbytes","_crypto_pwhash_scryptsalsa208sha256_strprefix","_crypto_pwhash_str","_crypto_pwhash_str_alg","_crypto_pwhash_str_needs_rehash","_crypto_pwhash_str_verify","_crypto_pwhash_strbytes","_crypto_pwhash_strprefix","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_curve25519","_crypto_scalarmult_curve25519_base","_crypto_scalarmult_curve25519_bytes","_crypto_scalarmult_curve25519_scalarbytes","_crypto_scalarmult_ed25519","_crypto_scalarmult_ed25519_base","_crypto_scalarmult_ed25519_base_noclamp","_crypto_scalarmult_ed25519_bytes","_crypto_scalarmult_ed25519_noclamp","_crypto_scalarmult_ed25519_scalarbytes","_crypto_scalarmult_primitive","_crypto_scalarmult_ristretto255","_crypto_scalarmult_ristretto255_base","_crypto_scalarmult_ristretto255_bytes","_crypto_scalarmult_ristretto255_scalarbytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox","_crypto_secretbox_boxzerobytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretbox_primitive","_crypto_secretbox_xchacha20poly1305_detached","_crypto_secretbox_xchacha20poly1305_easy","_crypto_secretbox_xchacha20poly1305_keybytes","_crypto_secretbox_xchacha20poly1305_macbytes","_crypto_secretbox_xchacha20poly1305_messagebytes_max","_crypto_secretbox_xchacha20poly1305_noncebytes","_crypto_secretbox_xchacha20poly1305_open_detached","_crypto_secretbox_xchacha20poly1305_open_easy","_crypto_secretbox_xsalsa20poly1305","_crypto_secretbox_xsalsa20poly1305_boxzerobytes","_crypto_secretbox_xsalsa20poly1305_keybytes","_crypto_secretbox_xsalsa20poly1305_keygen","_crypto_secretbox_xsalsa20poly1305_macbytes","_crypto_secretbox_xsalsa20poly1305_messagebytes_max","_crypto_secretbox_xsalsa20poly1305_noncebytes","_crypto_secretbox_xsalsa20poly1305_open","_crypto_secretbox_xsalsa20poly1305_zerobytes","_crypto_secretbox_zerobytes","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_shorthash_primitive","_crypto_shorthash_siphash24","_crypto_shorthash_siphash24_bytes","_crypto_shorthash_siphash24_keybytes","_crypto_shorthash_siphashx24","_crypto_shorthash_siphashx24_bytes","_crypto_shorthash_siphashx24_keybytes","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519","_crypto_sign_ed25519_bytes","_crypto_sign_ed25519_detached","_crypto_sign_ed25519_keypair","_crypto_sign_ed25519_messagebytes_max","_crypto_sign_ed25519_open","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_publickeybytes","_crypto_sign_ed25519_secretkeybytes","_crypto_sign_ed25519_seed_keypair","_crypto_sign_ed25519_seedbytes","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_ed25519_sk_to_pk","_crypto_sign_ed25519_sk_to_seed","_crypto_sign_ed25519_verify_detached","_crypto_sign_ed25519ph_final_create","_crypto_sign_ed25519ph_final_verify","_crypto_sign_ed25519ph_init","_crypto_sign_ed25519ph_statebytes","_crypto_sign_ed25519ph_update","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_primitive","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_crypto_stream","_crypto_stream_chacha20","_crypto_stream_chacha20_ietf","_crypto_stream_chacha20_ietf_keybytes","_crypto_stream_chacha20_ietf_keygen","_crypto_stream_chacha20_ietf_messagebytes_max","_crypto_stream_chacha20_ietf_noncebytes","_crypto_stream_chacha20_ietf_xor","_crypto_stream_chacha20_ietf_xor_ic","_crypto_stream_chacha20_keybytes","_crypto_stream_chacha20_keygen","_crypto_stream_chacha20_messagebytes_max","_crypto_stream_chacha20_noncebytes","_crypto_stream_chacha20_xor","_crypto_stream_chacha20_xor_ic","_crypto_stream_keybytes","_crypto_stream_keygen","_crypto_stream_messagebytes_max","_crypto_stream_noncebytes","_crypto_stream_primitive","_crypto_stream_salsa20","_crypto_stream_salsa2012","_crypto_stream_salsa2012_keybytes","_crypto_stream_salsa2012_keygen","_crypto_stream_salsa2012_messagebytes_max","_crypto_stream_salsa2012_noncebytes","_crypto_stream_salsa2012_xor","_crypto_stream_salsa208","_crypto_stream_salsa208_keybytes","_crypto_stream_salsa208_keygen","_crypto_stream_salsa208_messagebytes_max","_crypto_stream_salsa208_noncebytes","_crypto_stream_salsa208_xor","_crypto_stream_salsa20_keybytes","_crypto_stream_salsa20_keygen","_crypto_stream_salsa20_messagebytes_max","_crypto_stream_salsa20_noncebytes","_crypto_stream_salsa20_xor","_crypto_stream_salsa20_xor_ic","_crypto_stream_xchacha20","_crypto_stream_xchacha20_keybytes","_crypto_stream_xchacha20_keygen","_crypto_stream_xchacha20_messagebytes_max","_crypto_stream_xchacha20_noncebytes","_crypto_stream_xchacha20_xor","_crypto_stream_xchacha20_xor_ic","_crypto_stream_xor","_crypto_stream_xsalsa20","_crypto_stream_xsalsa20_keybytes","_crypto_stream_xsalsa20_keygen","_crypto_stream_xsalsa20_messagebytes_max","_crypto_stream_xsalsa20_noncebytes","_crypto_stream_xsalsa20_xor","_crypto_stream_xsalsa20_xor_ic","_crypto_verify_16","_crypto_verify_16_bytes","_crypto_verify_32","_crypto_verify_32_bytes","_crypto_verify_64","_crypto_verify_64_bytes","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_implementation_name","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]' export EXPORTED_RUNTIME_METHODS='["UTF8ToString","getValue","setValue"]' -export MAX_MEMORY=16777216 -export MAX_MEMORY_SUMO=16777216 -export MAX_MEMORY_TESTS=16777216 +export JS_RESERVED_MEMORY_STANDARD=16MB +export JS_RESERVED_MEMORY_SUMO=48MB +export JS_RESERVED_MEMORY_TESTS=16MB +export WASM_INITIAL_MEMORY=4MB export LDFLAGS="-s RESERVED_FUNCTION_POINTERS=8" export LDFLAGS="${LDFLAGS} -s ALLOW_MEMORY_GROWTH=1" export LDFLAGS="${LDFLAGS} -s SINGLE_FILE=1" @@ -14,37 +15,43 @@ export LDFLAGS="${LDFLAGS} -s ASSERTIONS=0" export LDFLAGS="${LDFLAGS} -s AGGRESSIVE_VARIABLE_ELIMINATION=1 -s ALIASING_FUNCTION_POINTERS=1" export LDFLAGS="${LDFLAGS} -s DISABLE_EXCEPTION_CATCHING=1" export LDFLAGS="${LDFLAGS} -s ELIMINATE_DUPLICATE_FUNCTIONS=1" -export CFLAGS="-Os" +export LDFLAGS="${LDFLAGS} -s NODEJS_CATCH_EXIT=0" +export LDFLAGS="${LDFLAGS} -s NODEJS_CATCH_REJECTION=0" echo -if [ "x$1" = "x--standard" ]; then +if [ "$1" = "--standard" ]; then export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_STANDARD" - export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST} -s TOTAL_MEMORY=${MAX_MEMORY}" + export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST}" + export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_STANDARD}" export PREFIX="$(pwd)/libsodium-js" export DONE_FILE="$(pwd)/js.done" export CONFIG_EXTRA="--enable-minimal" export DIST='yes' echo "Building a standard distribution in [${PREFIX}]" -elif [ "x$1" = "x--sumo" ]; then +elif [ "$1" = "--sumo" ]; then export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO" - export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST} -s TOTAL_MEMORY=${MAX_MEMORY_SUMO}" + export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST}" + export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_SUMO}" export PREFIX="$(pwd)/libsodium-js-sumo" export DONE_FILE="$(pwd)/js-sumo.done" export DIST='yes' echo "Building a sumo distribution in [${PREFIX}]" -elif [ "x$1" = "x--browser-tests" ]; then +elif [ "$1" = "--browser-tests" ]; then export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO" - export LDFLAGS="${LDFLAGS} -s TOTAL_MEMORY=${MAX_MEMORY_TESTS}" + export CPPFLAGS="${CPPFLAGS} -s FORCE_FILESYSTEM=1" + export LDFLAGS="${LDFLAGS}" + export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_TESTS}" export PREFIX="$(pwd)/libsodium-js-tests" export DONE_FILE="$(pwd)/js-tests-browser.done" export BROWSER_TESTS='yes' export DIST='no' echo "Building tests for web browsers in [${PREFIX}]" -elif [ "x$1" = "x--tests" ]; then +elif [ "$1" = "--tests" ]; then echo "Building for testing" export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO" - export CPPFLAGS="${CPPFLAGS} -DBENCHMARKS -DITERATIONS=10" - export LDFLAGS="${LDFLAGS} -s TOTAL_MEMORY=${MAX_MEMORY_TESTS}" + export CPPFLAGS="${CPPFLAGS} -s FORCE_FILESYSTEM=1 -DBENCHMARKS -DITERATIONS=10" + export LDFLAGS="${LDFLAGS}" + export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_TESTS}" export PREFIX="$(pwd)/libsodium-js-tests" export DONE_FILE="$(pwd)/js-tests.done" export DIST='no' @@ -55,31 +62,30 @@ else echo exit 1 fi -export JS_EXPORTS_FLAGS="-s EXPORTED_FUNCTIONS=${EXPORTED_FUNCTIONS} -s EXTRA_EXPORTED_RUNTIME_METHODS=${EXPORTED_RUNTIME_METHODS}" +export JS_EXPORTS_FLAGS="-s EXPORTED_FUNCTIONS=${EXPORTED_FUNCTIONS} -s EXPORTED_RUNTIME_METHODS=${EXPORTED_RUNTIME_METHODS}" rm -f "$DONE_FILE" echo emconfigure ./configure $CONFIG_EXTRA --disable-shared --prefix="$PREFIX" \ - --without-pthreads \ - --disable-ssp --disable-asm --disable-pie \ - CFLAGS="$CFLAGS" && \ -emmake make clean + --without-pthreads \ + --disable-ssp --disable-asm --disable-pie && + emmake make clean [ $? = 0 ] || exit 1 if [ "$DIST" = yes ]; then - emccLibsodium () { + emccLibsodium() { outFile="${1}" shift - emcc "$CFLAGS" --llvm-lto 1 $CPPFLAGS $LDFLAGS $JS_EXPORTS_FLAGS ${@} \ + emcc "$CFLAGS" --llvm-lto 1 $CPPFLAGS $LDFLAGS $JS_EXPORTS_FLAGS "${@}" \ "${PREFIX}/lib/libsodium.a" -o "${outFile}" || exit 1 } emmake make $MAKE_FLAGS install || exit 1 - emccLibsodium "${PREFIX}/lib/libsodium.asm.tmp.js" -Oz -s WASM=0 -s RUNNING_JS_OPTS=1 - emccLibsodium "${PREFIX}/lib/libsodium.wasm.tmp.js" -O3 -s WASM=1 + emccLibsodium "${PREFIX}/lib/libsodium.asm.tmp.js" -Oz -s WASM=0 $LDFLAGS_JS + emccLibsodium "${PREFIX}/lib/libsodium.wasm.tmp.js" -O3 -s WASM=1 -s EVAL_CTORS=1 -s INITIAL_MEMORY=${WASM_INITIAL_MEMORY} - cat > "${PREFIX}/lib/libsodium.js" <<- EOM + cat >"${PREFIX}/lib/libsodium.js" <<-EOM var Module; if (typeof Module === 'undefined') { Module = {}; @@ -92,9 +98,6 @@ if [ "$DIST" = yes ]; then root = window; } } - if (typeof root['sodium'] === 'object' && typeof root['sodium']['totalMemory'] === 'number') { - Module['TOTAL_MEMORY'] = root['sodium']['totalMemory']; - } var _Module = Module; Module.ready = new Promise(function(resolve, reject) { var Module = _Module; @@ -115,17 +118,28 @@ if [ "$DIST" = yes ]; then } }; Module.useBackupModule = function() { - var Module = _Module; - Object.keys(Module).forEach(function(k) { - if (k !== 'getRandomValue') { - delete Module[k]; - } + return new Promise(function(resolve, reject) { + var Module = {}; + Module.onAbort = reject; + + Module.onRuntimeInitialized = function() { + Object.keys(_Module).forEach(function(k) { + if (k !== 'getRandomValue') { + delete _Module[k]; + } + }); + Object.keys(Module).forEach(function(k) { + _Module[k] = Module[k]; + }); + resolve(); + }; + + $(sed "s|use asm||g" "${PREFIX}/lib/libsodium.asm.tmp.js") }); - $(cat "${PREFIX}/lib/libsodium.asm.tmp.js" | sed 's|use asm||g') }; $(cat "${PREFIX}/lib/libsodium.wasm.tmp.js") }).catch(function() { - _Module.useBackupModule(); + return _Module.useBackupModule(); }); EOM @@ -135,54 +149,55 @@ EOM exit 0 fi -if test "x$NODE" = x; then - for candidate in /usr/local/bin/node /usr/local/bin/nodejs /usr/bin/node /usr/bin/nodejs node nodejs; do +if test "$NODE" = ""; then + for candidate in bun nodejs node /usr/local/bin/bun /usr/local/bin/nodejs /usr/local/bin/node; do case $($candidate --version 2>&1) in #( - v*) - NODE=$candidate - break ;; + v*) + NODE=$candidate + break + ;; esac done fi if [ "x$BROWSER_TESTS" != "x" ]; then - echo 'Compiling the test suite for web browsers...' && \ - emmake make $MAKE_FLAGS CPPFLAGS="$CPPFLAGS -DBROWSER_TESTS=1" check > /dev/null 2>&1 + echo 'Compiling the test suite for web browsers...' && + emmake make $MAKE_FLAGS CPPFLAGS="$CPPFLAGS -DBROWSER_TESTS=1" check >/dev/null 2>&1 else - if test "x$NODE" = x; then + if test "$NODE" = ""; then echo 'node.js not found - test suite skipped' >&2 exit 1 fi echo "Using [${NODE}] as a Javascript runtime" - echo 'Compiling the test suite...' && \ - emmake make $MAKE_FLAGS check > /dev/null 2>&1 + echo 'Compiling the test suite...' && + emmake make $MAKE_FLAGS check >/dev/null 2>&1 fi if [ "x$BROWSER_TESTS" != "x" ]; then echo 'Creating the test suite for web browsers' ( - cd test/default && \ - mkdir -p browser && \ - rm -f browser/tests.txt && \ - for file in *.js; do - fgrep -v "#! /usr/bin/env ${NODE}" "$file" > "browser/${file}" - tname=$(echo "$file" | sed 's/.js$//') - cp -f "${tname}.exp" "browser/${tname}.exp" - sed "s/{{tname}}/${tname}/" index.html.tpl > "browser/${tname}.html" - echo "${tname}.html" >> "browser/tests.txt" - done + cd test/default && + mkdir -p browser && + rm -f browser/tests.txt && + for file in *.js; do + grep -Fv "#! /usr/bin/env ${NODE}" "$file" >"browser/${file}" + tname=$(echo "$file" | sed 's/.js$//') + cp -f "${tname}.exp" "browser/${tname}.exp" + sed "s/{{tname}}/${tname}/" index.html.tpl >"browser/${tname}.html" + echo "${tname}.html" >>"browser/tests.txt" + done touch "$DONE_FILE" ) else echo 'Running the test suite' ( - cd test/default && \ - for file in *.js; do - echo "#! /usr/bin/env ${NODE}" > "${file}.tmp" - fgrep -v "#! /usr/bin/env ${NODE}" "$file" >> "${file}.tmp" - chmod +x "${file}.tmp" - mv -f "${file}.tmp" "$file" - done + cd test/default && + for file in *.js; do + echo "#! /usr/bin/env ${NODE}" >"${file}.tmp" + grep -Fv "#! /usr/bin/env ${NODE}" "$file" >>"${file}.tmp" + chmod +x "${file}.tmp" + mv -f "${file}.tmp" "$file" + done ) make $MAKE_FLAGS check || exit 1 touch "$DONE_FILE" diff --git a/subprojects/libsodium/dist-build/generate-emscripten-symbols.sh b/subprojects/libsodium/dist-build/generate-emscripten-symbols.sh @@ -2,6 +2,8 @@ set -e +LIBSODIUM=${LIBSODIUM:-/tmp/sodium/lib/libsodium.26.dylib} + symbols() { { SUMO="$1" @@ -15,11 +17,11 @@ symbols() { else eval "defined_${symbol}=no" fi - done < emscripten-symbols.def + done <emscripten-symbols.def - /usr/bin/nm /usr/local/lib/libsodium.23.dylib | \ - fgrep ' T _' | \ - cut -d' ' -f3 | { + /usr/bin/nm "$LIBSODIUM" | + fgrep ' T _' | + cut -d' ' -f3 | { while read symbol; do eval "found=\$defined_${symbol}" if [ "$found" = "yes" ]; then @@ -32,11 +34,11 @@ symbols() { fi done } - } | \ - sort | \ + } | + sort | { out='"_malloc","_free"' - while read symbol ; do + while read symbol; do if [ ! -z "$out" ]; then out="${out}," fi @@ -47,11 +49,11 @@ symbols() { } out=$(symbols standard) -sed s/EXPORTED_FUNCTIONS_STANDARD=\'.*\'/EXPORTED_FUNCTIONS_STANDARD=\'${out}\'/ < emscripten.sh > emscripten.sh.tmp && \ +sed s/EXPORTED_FUNCTIONS_STANDARD=\'.*\'/EXPORTED_FUNCTIONS_STANDARD=\'${out}\'/ <emscripten.sh >emscripten.sh.tmp && mv -f emscripten.sh.tmp emscripten.sh out=$(symbols sumo) -sed s/EXPORTED_FUNCTIONS_SUMO=\'.*\'/EXPORTED_FUNCTIONS_SUMO=\'${out}\'/ < emscripten.sh > emscripten.sh.tmp && \ +sed s/EXPORTED_FUNCTIONS_SUMO=\'.*\'/EXPORTED_FUNCTIONS_SUMO=\'${out}\'/ <emscripten.sh >emscripten.sh.tmp && mv -f emscripten.sh.tmp emscripten.sh chmod +x emscripten.sh diff --git a/subprojects/libsodium/dist-build/ios.sh b/subprojects/libsodium/dist-build/ios.sh @@ -1,135 +0,0 @@ -#! /bin/sh -# -# Step 1. -# Configure for base system so simulator is covered -# -# Step 2. -# Make for iOS and iOS simulator -# -# Step 3. -# Merge libs into final version for xcode import - -export PREFIX="$(pwd)/libsodium-ios" -export IOS32_PREFIX="$PREFIX/tmp/ios32" -export IOS32s_PREFIX="$PREFIX/tmp/ios32s" -export IOS64_PREFIX="$PREFIX/tmp/ios64" -export SIMULATOR32_PREFIX="$PREFIX/tmp/simulator32" -export SIMULATOR64_PREFIX="$PREFIX/tmp/simulator64" -export XCODEDIR=$(xcode-select -p) - -export IOS_SIMULATOR_VERSION_MIN=${IOS_SIMULATOR_VERSION_MIN-"6.0.0"} -export IOS_VERSION_MIN=${IOS_VERSION_MIN-"6.0.0"} - -echo -echo "Warnings related to headers being present but not usable are due to functions" -echo "that didn't exist in the specified minimum iOS version level." -echo "They can be safely ignored." -echo - -mkdir -p $SIMULATOR32_PREFIX $SIMULATOR64_PREFIX $IOS32_PREFIX $IOS32s_PREFIX $IOS64_PREFIX || exit 1 - -# Build for the simulator -export BASEDIR="${XCODEDIR}/Platforms/iPhoneSimulator.platform/Developer" -export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" -export SDK="${BASEDIR}/SDKs/iPhoneSimulator.sdk" - -## i386 simulator -export CFLAGS="-O2 -arch i386 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" -export LDFLAGS="-arch i386 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" - -make distclean > /dev/null - -if [ -z "$LIBSODIUM_FULL_BUILD" ]; then - export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" -else - export LIBSODIUM_ENABLE_MINIMAL_FLAG="" -fi - -./configure --host=i686-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$SIMULATOR32_PREFIX" || exit 1 - - -NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) -PROCESSORS=${NPROCESSORS:-3} - -make -j${PROCESSORS} install || exit 1 - -## x86_64 simulator -export CFLAGS="-O2 -arch x86_64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" -export LDFLAGS="-arch x86_64 -isysroot ${SDK} -mios-simulator-version-min=${IOS_SIMULATOR_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=x86_64-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$SIMULATOR64_PREFIX" - -make -j${PROCESSORS} install || exit 1 - -# Build for iOS -export BASEDIR="${XCODEDIR}/Platforms/iPhoneOS.platform/Developer" -export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" -export SDK="${BASEDIR}/SDKs/iPhoneOS.sdk" - -## 32-bit iOS -export CFLAGS="-fembed-bitcode -O2 -mthumb -arch armv7 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" -export LDFLAGS="-fembed-bitcode -mthumb -arch armv7 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=arm-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$IOS32_PREFIX" || exit 1 - -make -j${PROCESSORS} install || exit 1 - -## 32-bit armv7s iOS -export CFLAGS="-fembed-bitcode -O2 -mthumb -arch armv7s -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" -export LDFLAGS="-fembed-bitcode -mthumb -arch armv7s -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=arm-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$IOS32s_PREFIX" || exit 1 - -make -j${PROCESSORS} install || exit 1 - -## 64-bit iOS -export CFLAGS="-fembed-bitcode -O2 -arch arm64 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN} -fembed-bitcode" -export LDFLAGS="-fembed-bitcode -arch arm64 -isysroot ${SDK} -mios-version-min=${IOS_VERSION_MIN} -fembed-bitcode" - -make distclean > /dev/null - -./configure --host=arm-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$IOS64_PREFIX" || exit 1 - -make -j${PROCESSORS} install || exit 1 - -# Create universal binary and include folder -rm -fr -- "$PREFIX/include" "$PREFIX/libsodium.a" 2> /dev/null -mkdir -p -- "$PREFIX/lib" -lipo -create \ - "$SIMULATOR32_PREFIX/lib/libsodium.a" \ - "$SIMULATOR64_PREFIX/lib/libsodium.a" \ - "$IOS32_PREFIX/lib/libsodium.a" \ - "$IOS32s_PREFIX/lib/libsodium.a" \ - "$IOS64_PREFIX/lib/libsodium.a" \ - -output "$PREFIX/lib/libsodium.a" -mv -f -- "$IOS32_PREFIX/include" "$PREFIX/" - -echo -echo "libsodium has been installed into $PREFIX" -echo -file -- "$PREFIX/lib/libsodium.a" - -# Cleanup -rm -rf -- "$PREFIX/tmp" -make distclean > /dev/null diff --git a/subprojects/libsodium/dist-build/macos.sh b/subprojects/libsodium/dist-build/macos.sh @@ -0,0 +1,26 @@ +#! /bin/sh + +export PREFIX="$(pwd)/libsodium-osx" +export MACOS_VERSION_MIN=${MACOS_VERSION_MIN-"10.10"} + +if [ -z "$LIBSODIUM_FULL_BUILD" ]; then + export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" +else + export LIBSODIUM_ENABLE_MINIMAL_FLAG="" +fi + +NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) +PROCESSORS=${NPROCESSORS:-3} + +mkdir -p $PREFIX || exit 1 + +export CFLAGS="-mmacosx-version-min=${MACOS_VERSION_MIN} -O3" +export LDFLAGS="-mmacosx-version-min=${MACOS_VERSION_MIN}" + +make distclean >/dev/null +./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ + --prefix="$PREFIX" || exit 1 +make -j${PROCESSORS} check && make -j${PROCESSORS} install || exit 1 + +# Cleanup +make distclean >/dev/null diff --git a/subprojects/libsodium/dist-build/msys2-win32.sh b/subprojects/libsodium/dist-build/msys2-win32.sh @@ -1,9 +1,9 @@ #! /bin/sh -export CFLAGS="-Ofast -fomit-frame-pointer -m32 -march=pentium3 -mtune=westmere" +export CFLAGS="-O3 -fomit-frame-pointer -m32 -march=pentium3 -mtune=westmere" export PREFIX="$(pwd)/libsodium-win32" -if (i686-w64-mingw32-gcc --version > /dev/null 2>&1) then +if (i686-w64-mingw32-gcc --version >/dev/null 2>&1); then echo MinGW found else echo Please install mingw-w64-i686-gcc >&2 @@ -11,8 +11,8 @@ else fi ./configure --prefix="$PREFIX" --exec-prefix="$PREFIX" \ - --host=i686-w64-mingw32 && \ -make clean && \ -make && \ -make check && \ -make install + --host=i686-w64-mingw32 && + make clean && + make && + make check && + make install diff --git a/subprojects/libsodium/dist-build/msys2-win64.sh b/subprojects/libsodium/dist-build/msys2-win64.sh @@ -1,9 +1,9 @@ #! /bin/sh -export CFLAGS="-Ofast -fomit-frame-pointer -m64 -mtune=westmere" +export CFLAGS="-O3 -fomit-frame-pointer -m64 -mtune=westmere" export PREFIX="$(pwd)/libsodium-win64" -if (x86_64-w64-mingw32-gcc --version > /dev/null 2>&1) then +if (x86_64-w64-mingw32-gcc --version >/dev/null 2>&1); then echo MinGW found else echo Please install mingw-w64-x86_64-gcc >&2 @@ -11,8 +11,8 @@ else fi ./configure --prefix="$PREFIX" --exec-prefix="$PREFIX" \ - --host=x86_64-w64-mingw32 && \ -make clean && \ -make && \ -make check && \ -make install + --host=x86_64-w64-mingw32 && + make clean && + make && + make check && + make install diff --git a/subprojects/libsodium/dist-build/osx.sh b/subprojects/libsodium/dist-build/osx.sh @@ -1,30 +0,0 @@ -#! /bin/sh - -export PREFIX="$(pwd)/libsodium-osx" -export OSX_VERSION_MIN=${OSX_VERSION_MIN-"10.8"} -export OSX_CPU_ARCH=${OSX_CPU_ARCH-"core2"} - -mkdir -p $PREFIX || exit 1 - -export CFLAGS="-arch x86_64 -mmacosx-version-min=${OSX_VERSION_MIN} -march=${OSX_CPU_ARCH} -O2 -g" -export LDFLAGS="-arch x86_64 -mmacosx-version-min=${OSX_VERSION_MIN} -march=${OSX_CPU_ARCH}" - -make distclean > /dev/null - -if [ -z "$LIBSODIUM_FULL_BUILD" ]; then - export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" -else - export LIBSODIUM_ENABLE_MINIMAL_FLAG="" -fi - -./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$PREFIX" || exit 1 - - -NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) -PROCESSORS=${NPROCESSORS:-3} - -make -j${PROCESSORS} check && make -j${PROCESSORS} install || exit 1 - -# Cleanup -make distclean > /dev/null diff --git a/subprojects/libsodium/dist-build/wasm32-wasi.sh b/subprojects/libsodium/dist-build/wasm32-wasi.sh @@ -1,31 +1,24 @@ #! /bin/sh -if [ -z "$WASI_SYSROOT" ]; then - export WASI_SYSROOT="/opt/wasi-sysroot" -fi - -export PATH="/usr/local/opt/llvm/bin:$PATH" +export PATH="/opt/zig/bin:/opt/zig:/opt/homebrew/bin:$PATH" export PREFIX="$(pwd)/libsodium-wasm32-wasi" mkdir -p $PREFIX || exit 1 -export CC="clang" -export CFLAGS="-DED25519_NONDETERMINISTIC=1 --target=wasm32-wasi --sysroot=${WASI_SYSROOT} -O2" -export LDFLAGS="-s -Wl,--no-threads" -export NM="llvm-nm" -export AR="llvm-ar" -export RANLIB="llvm-ranlib" -export STRIP="llvm-strip" - -make distclean > /dev/null +export CC="zig cc" +export CFLAGS="--target=wasm32-wasi -O3" +export LDFLAGS="-s" +export AR="zig ar" +export RANLIB="zig ranlib" -grep -q -F -- 'wasi' build-aux/config.sub || \ - sed -i -e 's/-nacl\*)/-nacl*|-wasi)/' build-aux/config.sub +make distclean >/dev/null if [ "x$1" = "x--bench" ]; then export BENCHMARKS=1 - export CPPFLAGS="-DBENCHMARKS -DITERATIONS=100" + export CPPFLAGS="-DBENCHMARKS -DITERATIONS=200" +else + export CPPFLAGS="-DED25519_NONDETERMINISTIC=1" fi if [ -n "$LIBSODIUM_MINIMAL_BUILD" ]; then @@ -34,16 +27,19 @@ else export LIBSODIUM_ENABLE_MINIMAL_FLAG="" fi -./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$PREFIX" --with-sysroot="$WASI_SYSROOT" \ - --host=wasm32-wasi \ - --disable-ssp --disable-shared || exit 1 +if ! ./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ + --prefix="$PREFIX" \ + --host=wasm32-wasi \ + --disable-pie --disable-ssp --disable-shared --without-pthreads; then + cat config.log + exit 1 +fi NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) PROCESSORS=${NPROCESSORS:-3} if [ -z "$BENCHMARKS" ]; then - make -j${PROCESSORS} check && make install && make distclean > /dev/null + make -j${PROCESSORS} check && make install && make distclean >/dev/null else make -j${PROCESSORS} && make check fi diff --git a/subprojects/libsodium/dist-build/watchos.sh b/subprojects/libsodium/dist-build/watchos.sh @@ -1,114 +0,0 @@ -#! /bin/sh -# -# Step 1. -# Configure for base system so simulator is covered -# -# Step 2. -# Make for watchOS and watchOS simulator -# -# Step 3. -# Merge libs into final version for xcode import - -export PREFIX="$(pwd)/libsodium-watchos" -export WATCHOS32_PREFIX="$PREFIX/tmp/watchos32" -export WATCHOS64_32_PREFIX="$PREFIX/tmp/watchos64_32" -export SIMULATOR32_PREFIX="$PREFIX/tmp/simulator32" -export SIMULATOR64_PREFIX="$PREFIX/tmp/simulator64" -export XCODEDIR=$(xcode-select -p) - -export WATCHOS_SIMULATOR_VERSION_MIN=${WATCHOS_SIMULATOR_VERSION_MIN-"4.0.0"} -export WATCHOS_VERSION_MIN=${WATCHOS_VERSION_MIN-"4.0.0"} - -mkdir -p $SIMULATOR32_PREFIX $SIMULATOR64_PREFIX $WATCHOS32_PREFIX $WATCHOS64_32_PREFIX || exit 1 - -# Build for the simulator -export BASEDIR="${XCODEDIR}/Platforms/WatchSimulator.platform/Developer" -export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" -export SDK="${BASEDIR}/SDKs/WatchSimulator.sdk" - -## i386 simulator -export CFLAGS="-O2 -arch i386 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" -export LDFLAGS="-arch i386 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" - -make distclean > /dev/null - -if [ -z "$LIBSODIUM_FULL_BUILD" ]; then - export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal" -else - export LIBSODIUM_ENABLE_MINIMAL_FLAG="" -fi - -./configure --host=i686-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$SIMULATOR32_PREFIX" || exit 1 - - -NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null) -PROCESSORS=${NPROCESSORS:-3} - -make -j${PROCESSORS} install || exit 1 - -## x86_64 simulator -export CFLAGS="-O2 -arch x86_64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" -export LDFLAGS="-arch x86_64 -isysroot ${SDK} -mwatchos-simulator-version-min=${WATCHOS_SIMULATOR_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=x86_64-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$SIMULATOR64_PREFIX" - -make -j${PROCESSORS} install || exit 1 - -# Build for watchOS -export BASEDIR="${XCODEDIR}/Platforms/WatchOS.platform/Developer" -export PATH="${BASEDIR}/usr/bin:$BASEDIR/usr/sbin:$PATH" -export SDK="${BASEDIR}/SDKs/WatchOS.sdk" - -## 32-bit watchOS -export CFLAGS="-fembed-bitcode -O2 -mthumb -arch armv7k -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" -export LDFLAGS="-fembed-bitcode -mthumb -arch armv7k -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=arm-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$WATCHOS32_PREFIX" || exit 1 - -make -j${PROCESSORS} install || exit 1 - -## 64-bit arm64_32 watchOS -export CFLAGS="-fembed-bitcode -O2 -mthumb -arch arm64_32 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" -export LDFLAGS="-fembed-bitcode -mthumb -arch arm64_32 -isysroot ${SDK} -mwatchos-version-min=${WATCHOS_VERSION_MIN}" - -make distclean > /dev/null - -./configure --host=arm-apple-darwin10 \ - --disable-shared \ - ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \ - --prefix="$WATCHOS64_32_PREFIX" || exit 1 - -make -j${PROCESSORS} install || exit 1 - -# Create universal binary and include folder -rm -fr -- "$PREFIX/include" "$PREFIX/libsodium.a" 2> /dev/null -mkdir -p -- "$PREFIX/lib" -lipo -create \ - "$SIMULATOR32_PREFIX/lib/libsodium.a" \ - "$SIMULATOR64_PREFIX/lib/libsodium.a" \ - "$WATCHOS32_PREFIX/lib/libsodium.a" \ - "$WATCHOS64_32_PREFIX/lib/libsodium.a" \ - -output "$PREFIX/lib/libsodium.a" -mv -f -- "$WATCHOS32_PREFIX/include" "$PREFIX/" - -echo -echo "libsodium has been installed into $PREFIX" -echo -file -- "$PREFIX/lib/libsodium.a" - -# Cleanup -rm -rf -- "$PREFIX/tmp" -make distclean > /dev/null diff --git a/subprojects/libsodium/lgtm.yml b/subprojects/libsodium/lgtm.yml @@ -2,5 +2,5 @@ extraction: cpp: configure: command: - - ./autogen.sh - - ./configure -\ No newline at end of file + - ./autogen.sh -s + - ./configure diff --git a/subprojects/libsodium/libsodium.sln b/subprojects/libsodium/libsodium.sln @@ -1,40 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 14 -VisualStudioVersion = 14.0.23107.0 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libsodium", "libsodium.vcxproj", "{A185B162-6CB6-4502-B03F-B56F7699A8D9}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Win32 = Debug|Win32 - Debug|x64 = Debug|x64 - DebugDLL|Win32 = DebugDLL|Win32 - DebugDLL|x64 = DebugDLL|x64 - Release|Win32 = Release|Win32 - Release|x64 = Release|x64 - ReleaseDLL|Win32 = ReleaseDLL|Win32 - ReleaseDLL|x64 = ReleaseDLL|x64 - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|Win32.ActiveCfg = Debug|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|Win32.Build.0 = Debug|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|x64.ActiveCfg = Debug|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Debug|x64.Build.0 = Debug|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|Win32.ActiveCfg = DebugDLL|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|Win32.Build.0 = DebugDLL|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|x64.ActiveCfg = DebugDLL|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.DebugDLL|x64.Build.0 = DebugDLL|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|Win32.ActiveCfg = Release|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|Win32.Build.0 = Release|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|x64.ActiveCfg = Release|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.Release|x64.Build.0 = Release|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|Win32.ActiveCfg = ReleaseDLL|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|Win32.Build.0 = ReleaseDLL|Win32 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|x64.ActiveCfg = ReleaseDLL|x64 - {A185B162-6CB6-4502-B03F-B56F7699A8D9}.ReleaseDLL|x64.Build.0 = ReleaseDLL|x64 - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/subprojects/libsodium/libsodium.vcxproj b/subprojects/libsodium/libsodium.vcxproj @@ -1,565 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> - <ItemGroup Label="ProjectConfigurations"> - <ProjectConfiguration Include="DebugDLL|Win32"> - <Configuration>DebugDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugDLL|x64"> - <Configuration>DebugDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="Debug|Win32"> - <Configuration>Debug</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="Debug|x64"> - <Configuration>Debug</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> - <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="Release|Win32"> - <Configuration>Release</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="Release|x64"> - <Configuration>Release</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - </ItemGroup> - <PropertyGroup Label="Globals"> - <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> - <Keyword>Win32Proj</Keyword> - <RootNamespace>libsodium</RootNamespace> - </PropertyGroup> - <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> - <ConfigurationType>StaticLibrary</ConfigurationType> - <UseDebugLibraries>true</UseDebugLibraries> - <CharacterSet>MultiByte</CharacterSet> - <WholeProgramOptimization>false</WholeProgramOptimization> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'" Label="Configuration"> - <ConfigurationType>DynamicLibrary</ConfigurationType> - <UseDebugLibraries>true</UseDebugLibraries> - <CharacterSet>MultiByte</CharacterSet> - <WholeProgramOptimization>false</WholeProgramOptimization> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> - <ConfigurationType>StaticLibrary</ConfigurationType> - <UseDebugLibraries>true</UseDebugLibraries> - <CharacterSet>MultiByte</CharacterSet> - <WholeProgramOptimization>false</WholeProgramOptimization> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'" Label="Configuration"> - <ConfigurationType>DynamicLibrary</ConfigurationType> - <UseDebugLibraries>true</UseDebugLibraries> - <CharacterSet>MultiByte</CharacterSet> - <WholeProgramOptimization>false</WholeProgramOptimization> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> - <ConfigurationType>StaticLibrary</ConfigurationType> - <UseDebugLibraries>false</UseDebugLibraries> - <WholeProgramOptimization>true</WholeProgramOptimization> - <CharacterSet>MultiByte</CharacterSet> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'" Label="Configuration"> - <ConfigurationType>DynamicLibrary</ConfigurationType> - <UseDebugLibraries>false</UseDebugLibraries> - <WholeProgramOptimization>true</WholeProgramOptimization> - <CharacterSet>MultiByte</CharacterSet> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> - <ConfigurationType>StaticLibrary</ConfigurationType> - <UseDebugLibraries>false</UseDebugLibraries> - <WholeProgramOptimization>true</WholeProgramOptimization> - <CharacterSet>MultiByte</CharacterSet> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'" Label="Configuration"> - <ConfigurationType>DynamicLibrary</ConfigurationType> - <UseDebugLibraries>false</UseDebugLibraries> - <WholeProgramOptimization>true</WholeProgramOptimization> - <CharacterSet>MultiByte</CharacterSet> - <PlatformToolset>v140</PlatformToolset> - </PropertyGroup> - <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> - <ImportGroup Label="ExtensionSettings"> - </ImportGroup> - <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <ImportGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'" Label="PropertySheets"> - <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> - <Import Project="msvc-scripts\sodium.props" /> - </ImportGroup> - <PropertyGroup Label="UserMacros" /> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> - <LinkIncremental>true</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'"> - <LinkIncremental>true</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> - <LinkIncremental>true</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'"> - <LinkIncremental>true</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> - <LinkIncremental>false</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'"> - <LinkIncremental>false</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> - <LinkIncremental>false</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'"> - <LinkIncremental>false</LinkIncremental> - <OutDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\</OutDir> - <IntDir>$(SolutionDir)Build\$(Configuration)\$(Platform)\Intermediate\</IntDir> - </PropertyGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> - <ClCompile> - <PrecompiledHeader> - </PrecompiledHeader> - <WarningLevel>Level3</WarningLevel> - <Optimization>Disabled</Optimization> - <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|Win32'"> - <ClCompile> - <PrecompiledHeader> - </PrecompiledHeader> - <WarningLevel>Level3</WarningLevel> - <Optimization>Disabled</Optimization> - <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> - <ClCompile> - <PrecompiledHeader> - </PrecompiledHeader> - <WarningLevel>Level3</WarningLevel> - <Optimization>Disabled</Optimization> - <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DebugDLL|x64'"> - <ClCompile> - <PrecompiledHeader> - </PrecompiledHeader> - <WarningLevel>Level3</WarningLevel> - <Optimization>Disabled</Optimization> - <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> - <ClCompile> - <WarningLevel>Level3</WarningLevel> - <PrecompiledHeader> - </PrecompiledHeader> - <Optimization>Full</Optimization> - <FunctionLevelLinking>true</FunctionLevelLinking> - <IntrinsicFunctions>true</IntrinsicFunctions> - <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreaded</RuntimeLibrary> - <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - <EnableCOMDATFolding>true</EnableCOMDATFolding> - <OptimizeReferences>true</OptimizeReferences> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|Win32'"> - <ClCompile> - <WarningLevel>Level3</WarningLevel> - <PrecompiledHeader> - </PrecompiledHeader> - <Optimization>Full</Optimization> - <FunctionLevelLinking>true</FunctionLevelLinking> - <IntrinsicFunctions>true</IntrinsicFunctions> - <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> - <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - <EnableCOMDATFolding>true</EnableCOMDATFolding> - <OptimizeReferences>true</OptimizeReferences> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> - <ClCompile> - <WarningLevel>Level3</WarningLevel> - <PrecompiledHeader> - </PrecompiledHeader> - <Optimization>MaxSpeed</Optimization> - <FunctionLevelLinking>true</FunctionLevelLinking> - <IntrinsicFunctions>true</IntrinsicFunctions> - <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreaded</RuntimeLibrary> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - <EnableCOMDATFolding>true</EnableCOMDATFolding> - <OptimizeReferences>true</OptimizeReferences> - </Link> - </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='ReleaseDLL|x64'"> - <ClCompile> - <WarningLevel>Level3</WarningLevel> - <PrecompiledHeader> - </PrecompiledHeader> - <Optimization>MaxSpeed</Optimization> - <FunctionLevelLinking>true</FunctionLevelLinking> - <IntrinsicFunctions>true</IntrinsicFunctions> - <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> - <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> - </ClCompile> - <Link> - <SubSystem>Console</SubSystem> - <GenerateDebugInformation>true</GenerateDebugInformation> - <EnableCOMDATFolding>true</EnableCOMDATFolding> - <OptimizeReferences>true</OptimizeReferences> - </Link> - </ItemDefinitionGroup> - <ItemGroup> - <ClCompile Include="src\libsodium\crypto_generichash\crypto_generichash.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\generichash_blake2.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c" /> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c" /> - <ClCompile Include="src\libsodium\crypto_kx\crypto_kx.c" /> - <ClCompile Include="src\libsodium\crypto_sign\crypto_sign.c" /> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\sign_ed25519.c" /> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\obsolete.c" /> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\sign.c" /> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\keypair.c" /> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\open.c" /> - <ClCompile Include="src\libsodium\crypto_secretbox\crypto_secretbox.c" /> - <ClCompile Include="src\libsodium\crypto_secretbox\crypto_secretbox_easy.c" /> - <ClCompile Include="src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\crypto_pwhash.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\blake2b-long.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-core.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-encoding.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c" /> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c" /> - <ClCompile Include="src\libsodium\crypto_verify\sodium\verify.c" /> - <ClCompile Include="src\libsodium\crypto_auth\crypto_auth.c" /> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c" /> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c" /> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c" /> - <ClCompile Include="src\libsodium\crypto_kdf\crypto_kdf.c" /> - <ClCompile Include="src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c" /> - <ClCompile Include="src\libsodium\crypto_shorthash\crypto_shorthash.c" /> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c" /> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c" /> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c" /> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\crypto_scalarmult.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c" /> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c" /> - <ClCompile Include="src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c" /> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c" /> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c" /> - <ClCompile Include="src\libsodium\randombytes\randombytes.c" /> - <ClCompile Include="src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c" /> - <ClCompile Include="src\libsodium\randombytes\internal\randombytes_internal_random.c" /> - <ClCompile Include="src\libsodium\crypto_box\crypto_box_easy.c" /> - <ClCompile Include="src\libsodium\crypto_box\crypto_box_seal.c" /> - <ClCompile Include="src\libsodium\crypto_box\crypto_box.c" /> - <ClCompile Include="src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c" /> - <ClCompile Include="src\libsodium\sodium\codecs.c" /> - <ClCompile Include="src\libsodium\sodium\runtime.c" /> - <ClCompile Include="src\libsodium\sodium\core.c" /> - <ClCompile Include="src\libsodium\sodium\utils.c" /> - <ClCompile Include="src\libsodium\sodium\version.c" /> - <ClCompile Include="src\libsodium\crypto_stream\crypto_stream.c" /> - <ClCompile Include="src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c" /> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\stream_chacha20.c" /> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c" /> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c" /> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\stream_salsa20.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa208\stream_salsa208.c" /> - <ClCompile Include="src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c" /> - <ClCompile Include="src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c" /> - <ClCompile Include="src\libsodium\crypto_hash\crypto_hash.c" /> - <ClCompile Include="src\libsodium\crypto_hash\sha512\hash_sha512.c" /> - <ClCompile Include="src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c" /> - <ClCompile Include="src\libsodium\crypto_hash\sha256\hash_sha256.c" /> - <ClCompile Include="src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c" /> - <ClCompile Include="src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c" /> - <ClCompile Include="src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c" /> - <ClCompile Include="src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c" /> - <ClCompile Include="src\libsodium\crypto_core\hchacha20\core_hchacha20.c" /> - <ClCompile Include="src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c" /> - <ClCompile Include="src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c" /> - <ClCompile Include="src\libsodium\crypto_core\ed25519\core_ed25519.c" /> - <ClCompile Include="src\libsodium\crypto_core\ed25519\core_ristretto255.c" /> - <ClCompile Include="src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c" /> - </ItemGroup> - <ItemGroup> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h" /> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h" /> - <ClInclude Include="src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h" /> - <ClInclude Include="src\libsodium\include\sodium.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa2012.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth.h" /> - <ClInclude Include="src\libsodium\include\sodium\utils.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_hchacha20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash_sha512.h" /> - <ClInclude Include="src\libsodium\include\sodium\core.h" /> - <ClInclude Include="src\libsodium\include\sodium\export.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_shorthash_siphash24.h" /> - <ClInclude Include="src\libsodium\include\sodium\randombytes.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash_sha256.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha512.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_kx.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_kdf.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha256.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_box.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_32.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_ristretto255.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_xchacha20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa208.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha512256.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\randombytes_sysrandom.h" /> - <ClInclude Include="src\libsodium\include\sodium\runtime.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa208.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_aes256gcm.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa2012.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_16.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_chacha20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_xsalsa20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_hsalsa20.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_kdf_blake2b.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_curve25519.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_shorthash.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_argon2id.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign_ed25519.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_onetimeauth.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_64.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_ed25519.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_argon2i.h" /> - <ClInclude Include="src\libsodium\include\sodium\randombytes_internal_random.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_generichash.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_ed25519.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_generichash_blake2b.h" /> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\sse2_64_32.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\common.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\mutex.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\chacha20_ietf_ext.h" /> - <ClInclude Include="src\libsodium\include\sodium\private\implementations.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2-encoding.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blake2b-long.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2-core.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h" /> - <ClInclude Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h" /> - <ClInclude Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h" /> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h" /> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h" /> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h" /> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h" /> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h" /> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\stream_chacha20.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u4.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u0.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u1.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h" /> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u8.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\stream_salsa20.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u4.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u0.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u1.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u8.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h" /> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h" /> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h" /> - <ClInclude Include="builds\msvc\resource.h" /> - </ItemGroup> - <ItemGroup> - <ResourceCompile Include="builds\msvc\resource.rc"> - </ResourceCompile> - </ItemGroup> - <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> - <ImportGroup Label="ExtensionTargets"> - </ImportGroup> -</Project> diff --git a/subprojects/libsodium/libsodium.vcxproj.filters b/subprojects/libsodium/libsodium.vcxproj.filters @@ -1,729 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> - <ItemGroup> - <Filter Include="Source Files"> - <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier> - <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions> - </Filter> - <Filter Include="Header Files"> - <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier> - <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions> - </Filter> - <Filter Include="Resource Files"> - <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier> - <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions> - </Filter> - </ItemGroup> - <ItemGroup> - <ClCompile Include="src\libsodium\crypto_generichash\crypto_generichash.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\generichash_blake2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\generichash_blake2b.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_kx\crypto_kx.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\crypto_sign.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\sign_ed25519.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\obsolete.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\sign.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\keypair.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_sign\ed25519\ref10\open.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_secretbox\crypto_secretbox.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_secretbox\crypto_secretbox_easy.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_secretbox\xsalsa20poly1305\secretbox_xsalsa20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_secretbox\xchacha20poly1305\secretbox_xchacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\crypto_pwhash.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\blake2b-long.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-core.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx512f.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-ssse3.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\pwhash_argon2i.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\pwhash_argon2id.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-fill-block-avx2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\argon2\argon2-encoding.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\scrypt_platform.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt-common.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pwhash_scryptsalsa208sha256.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\nosse\pwhash_scryptsalsa208sha256_nosse.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\sse\pwhash_scryptsalsa208sha256_sse.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_verify\sodium\verify.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_auth\crypto_auth.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha512\auth_hmacsha512.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha512256\auth_hmacsha512256.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_auth\hmacsha256\auth_hmacsha256.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_kdf\crypto_kdf.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_kdf\blake2b\kdf_blake2b.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_shorthash\crypto_shorthash.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\shorthash_siphash24.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\shorthash_siphashx24.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphashx24_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash24_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\crypto_scalarmult.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\ristretto255\ref10\scalarmult_ristretto255_ref10.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\ed25519\ref10\scalarmult_ed25519_ref10.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe_frombytes_sandy2x.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_invert.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_onetimeauth\crypto_onetimeauth.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\randombytes\randombytes.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\randombytes\sysrandom\randombytes_sysrandom.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\randombytes\internal\randombytes_internal_random.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\crypto_box_easy.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\crypto_box_seal.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\crypto_box.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\curve25519xsalsa20poly1305\box_curve25519xsalsa20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\curve25519xchacha20poly1305\box_curve25519xchacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_box\curve25519xchacha20poly1305\box_seal_curve25519xchacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\sodium\codecs.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\sodium\runtime.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\sodium\core.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\sodium\utils.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\sodium\version.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\crypto_stream.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\xchacha20\stream_xchacha20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\stream_chacha20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\stream_salsa20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa2012\stream_salsa2012.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa2012\ref\stream_salsa2012_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa208\stream_salsa208.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\salsa208\ref\stream_salsa208_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_stream\xsalsa20\stream_xsalsa20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_hash\crypto_hash.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_hash\sha512\hash_sha512.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_hash\sha512\cp\hash_sha512_cp.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_hash\sha256\hash_sha256.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_hash\sha256\cp\hash_sha256_cp.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_aead\xchacha20poly1305\sodium\aead_xchacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_aead\aes256gcm\aesni\aead_aes256gcm_aesni.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_aead\chacha20poly1305\sodium\aead_chacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_secretstream\xchacha20poly1305\secretstream_xchacha20poly1305.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\salsa\ref\core_salsa_ref.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\hchacha20\core_hchacha20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\hsalsa20\core_hsalsa20.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\hsalsa20\ref2\core_hsalsa20_ref2.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\ed25519\core_ed25519.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\ed25519\core_ristretto255.c"> - <Filter>Source Files</Filter> - </ClCompile> - <ClCompile Include="src\libsodium\crypto_core\ed25519\ref10\ed25519_ref10.c"> - <Filter>Source Files</Filter> - </ClCompile> - </ItemGroup> - <ItemGroup> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-avx2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-ssse3.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-load-sse41.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-avx2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_generichash\blake2b\ref\blake2b-compress-sse41.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_sign\ed25519\ref10\sign_ed25519_ref10.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa2012.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\utils.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_hchacha20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash_sha512.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\core.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\export.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_shorthash_siphash24.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\randombytes.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash_sha256.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha512.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_xchacha20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_onetimeauth_poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_ristretto255.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_kx.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_hash.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_kdf.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha256.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_box.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_32.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_ristretto255.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_xchacha20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa208.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_auth_hmacsha512256.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_chacha20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\randombytes_sysrandom.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\runtime.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_salsa208.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_aead_aes256gcm.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_salsa2012.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox_xchacha20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_16.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_chacha20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_stream_xsalsa20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_hsalsa20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_kdf_blake2b.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_curve25519.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_shorthash.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_argon2id.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretstream_xchacha20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_scryptsalsa208sha256.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign_ed25519.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_onetimeauth.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_verify_64.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_box_curve25519xchacha20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_core_ed25519.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_pwhash_argon2i.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\randombytes_internal_random.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_generichash.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox_xsalsa20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_secretbox.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_scalarmult_ed25519.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_box_curve25519xsalsa20poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_generichash_blake2b.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\crypto_sign_edwards25519sha512batch.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10_fe_25_5.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\ed25519_ref10_fe_51.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\sse2_64_32.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\common.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\mutex.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\chacha20_ietf_ext.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\include\sodium\private\implementations.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-ref.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-avx2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-ssse3.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2-encoding.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blake2b-long.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\blamka-round-avx512f.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\argon2\argon2-core.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\crypto_scrypt.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_pwhash\scryptsalsa208sha256\pbkdf2-sha256.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_shorthash\siphash24\ref\shorthash_siphash_ref.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\scalarmult_curve25519.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\consts_namespace.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_namespace.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base_namespace.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\curve25519_sandy2x.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\fe51_namespace.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\sandy2x\ladder_base.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_scalarmult\curve25519\ref10\x25519_ref10.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\onetimeauth_poly1305.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna64.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\donna\poly1305_donna32.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_onetimeauth\poly1305\sse2\poly1305_sse2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\stream_chacha20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\ref\chacha20_ref.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u4.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-ssse3.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u0.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u1.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\chacha20_dolbeau-avx2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\chacha20\dolbeau\u8.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\stream_salsa20.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\ref\salsa20_ref.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u4.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u0.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u1.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-avx2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\u8.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6int\salsa20_xmm6int-sse2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_stream\salsa20\xmm6\salsa20_xmm6.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\constants.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\fe.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_25_5\base.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\constants.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\fe.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\base2.h"> - <Filter>Header Files</Filter> - </ClInclude> - <ClInclude Include="src\libsodium\crypto_core\ed25519\ref10\fe_51\base.h"> - <Filter>Header Files</Filter> - </ClInclude> - </ItemGroup> -</Project> diff --git a/subprojects/libsodium/logo.png b/subprojects/libsodium/logo.png Binary files differ. diff --git a/subprojects/libsodium/m4/ax_add_fortify_source.m4 b/subprojects/libsodium/m4/ax_add_fortify_source.m4 @@ -0,0 +1,119 @@ +# =========================================================================== +# https://www.gnu.org/software/autoconf-archive/ax_add_fortify_source.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_ADD_FORTIFY_SOURCE +# +# DESCRIPTION +# +# Check whether -D_FORTIFY_SOURCE=2 can be added to CPPFLAGS without macro +# redefinition warnings, other cpp warnings or linker. Some distributions +# (such as Ubuntu or Gentoo Linux) enable _FORTIFY_SOURCE globally in +# their compilers, leading to unnecessary warnings in the form of +# +# <command-line>:0:0: error: "_FORTIFY_SOURCE" redefined [-Werror] +# <built-in>: note: this is the location of the previous definition +# +# which is a problem if -Werror is enabled. This macro checks whether +# _FORTIFY_SOURCE is already defined, and if not, adds -D_FORTIFY_SOURCE=2 +# to CPPFLAGS. +# +# Newer mingw-w64 msys2 package comes with a bug in +# headers-git-7.0.0.5546.d200317d-1. It broke -D_FORTIFY_SOURCE support, +# and would need -lssp or -fstack-protector. See +# https://github.com/msys2/MINGW-packages/issues/5803. Try to actually +# link it. +# +# LICENSE +# +# Copyright (c) 2017 David Seifert <soap@gentoo.org> +# Copyright (c) 2019, 2023 Reini Urban <rurban@cpan.org> +# +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. + +#serial 10 + +AC_DEFUN([AX_ADD_FORTIFY_SOURCE],[ + ac_save_cflags=$CFLAGS + ac_cwerror_flag=yes + AX_CHECK_COMPILE_FLAG([-Werror],[CFLAGS="$CFLAGS -Werror"]) + ax_add_fortify_3_failed= + AC_MSG_CHECKING([whether to add -D_FORTIFY_SOURCE=3 to CPPFLAGS]) + AC_LINK_IFELSE([ + AC_LANG_PROGRAM([], + [[ + #ifndef _FORTIFY_SOURCE + return 0; + #else + _FORTIFY_SOURCE_already_defined; + #endif + ]] + )], + AC_LINK_IFELSE([ + AC_LANG_SOURCE([[ + #define _FORTIFY_SOURCE 3 + #include <string.h> + int main(void) { + char *s = " "; + strcpy(s, "x"); + return strlen(s)-1; + } + ]] + )], + [ + AC_MSG_RESULT([yes]) + CFLAGS=$ac_save_cflags + CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=3" + ], [ + AC_MSG_RESULT([no]) + ax_add_fortify_3_failed=1 + ], + ), + [ + AC_MSG_RESULT([no]) + ax_add_fortify_3_failed=1 + ]) + if test -n "$ax_add_fortify_3_failed" + then + AC_MSG_CHECKING([whether to add -D_FORTIFY_SOURCE=2 to CPPFLAGS]) + AC_LINK_IFELSE([ + AC_LANG_PROGRAM([], + [[ + #ifndef _FORTIFY_SOURCE + return 0; + #else + _FORTIFY_SOURCE_already_defined; + #endif + ]] + )], + AC_LINK_IFELSE([ + AC_LANG_SOURCE([[ + #define _FORTIFY_SOURCE 2 + #include <string.h> + int main(void) { + char *s = " "; + strcpy(s, "x"); + return strlen(s)-1; + } + ]] + )], + [ + AC_MSG_RESULT([yes]) + CFLAGS=$ac_save_cflags + CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=2" + ], [ + AC_MSG_RESULT([no]) + CFLAGS=$ac_save_cflags + ], + ), + [ + AC_MSG_RESULT([no]) + CFLAGS=$ac_save_cflags + ]) + fi +]) diff --git a/subprojects/libsodium/m4/ax_check_catchable_abrt.m4 b/subprojects/libsodium/m4/ax_check_catchable_abrt.m4 @@ -11,7 +11,7 @@ AC_DEFUN([AX_CHECK_CATCHABLE_ABRT], [dnl AC_PREREQ(2.64) AS_VAR_PUSHDEF([CACHEVAR], [ax_cv_check_[]_AC_LANG_ABBREV[]CATCHABLE_ABRT])dnl - AC_CACHE_CHECK([whether SIGABRT can be caught when using the _AC_LANG compiler], CACHEVAR, [ + AC_CACHE_CHECK([whether SIGABRT can be caught], CACHEVAR, [ AC_RUN_IFELSE([ AC_LANG_PROGRAM([[ #include <signal.h> diff --git a/subprojects/libsodium/m4/ax_check_catchable_segv.m4 b/subprojects/libsodium/m4/ax_check_catchable_segv.m4 @@ -11,7 +11,7 @@ AC_DEFUN([AX_CHECK_CATCHABLE_SEGV], [dnl AC_PREREQ(2.64) AS_VAR_PUSHDEF([CACHEVAR], [ax_cv_check_[]_AC_LANG_ABBREV[]CATCHABLE_SEGV])dnl - AC_CACHE_CHECK([whether segmentation violations can be caught when using the _AC_LANG compiler], CACHEVAR, [ + AC_CACHE_CHECK([whether segmentation violations can be caught], CACHEVAR, [ AC_RUN_IFELSE([ AC_LANG_PROGRAM([[ #include <signal.h> @@ -21,9 +21,14 @@ static void sig(int _) { exit(0); } volatile unsigned char * volatile x = (volatile unsigned char *) malloc(8); size_t i; +#ifdef SIGPROT +signal(SIGPROT, sig); +#endif signal(SIGSEGV, sig); signal(SIGBUS, sig); #if !defined(__SANITIZE_ADDRESS__) && !defined(__EMSCRIPTEN__) +*((volatile unsigned char *) -1) = 0xd0; +*((volatile unsigned char *) 1) = 0xd0; for (i = 0; i < 10000000; i += 1024) { x[-i] = x[i] = (unsigned char) i; } #endif free((void *) x); diff --git a/subprojects/libsodium/m4/ax_check_compile_flag.m4 b/subprojects/libsodium/m4/ax_check_compile_flag.m4 @@ -1,10 +1,10 @@ # =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html +# https://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html # =========================================================================== # # SYNOPSIS # -# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS]) +# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) # # DESCRIPTION # @@ -29,33 +29,12 @@ # Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de> # Copyright (c) 2011 Maarten Bosmans <mkbosmans@gmail.com> # -# This program is free software: you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation, either version 3 of the License, or (at your -# option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -# Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program. If not, see <https://www.gnu.org/licenses/>. -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. -#serial 5 +#serial 6 AC_DEFUN([AX_CHECK_COMPILE_FLAG], [AC_PREREQ(2.64)dnl for _AC_LANG_PREFIX and AS_VAR_IF @@ -63,8 +42,9 @@ AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" - AC_TRY_LINK([#include <time.h>], - [time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x], + AC_LINK_IFELSE([m4_default([$5],[AC_LANG_PROGRAM( +[#include <time.h>], [time_t x; int fodder = 0; if (fodder > -1000 && time(&x)) return (int) x] + )])], [AS_VAR_SET(CACHEVAR,[yes])], [AS_VAR_SET(CACHEVAR,[no])]) _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) diff --git a/subprojects/libsodium/m4/ax_check_define.m4 b/subprojects/libsodium/m4/ax_check_define.m4 @@ -18,33 +18,12 @@ # # Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de> # -# This program is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 3 of the License, or (at your -# option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -# Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program. If not, see <https://www.gnu.org/licenses/>. -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. +# Copying and distribution of this file, with or without modification, are +# permitted in any medium without royalty provided the copyright notice +# and this notice are preserved. This file is offered as-is, without any +# warranty. -#serial 9 +#serial 11 AU_ALIAS([AC_CHECK_DEFINED], [AC_CHECK_DEFINE]) AC_DEFUN([AC_CHECK_DEFINE],[ @@ -53,6 +32,7 @@ AC_CACHE_CHECK([for $1 defined], ac_var, AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ #ifdef $1 int ok; + (void)ok; #else choke me #endif @@ -68,6 +48,7 @@ AC_CACHE_CHECK([for $2 defined in $1], ac_var, AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <$1>]], [[ #ifdef $2 int ok; + (void)ok; #else choke me #endif diff --git a/subprojects/libsodium/m4/ax_check_gnu_make.m4 b/subprojects/libsodium/m4/ax_check_gnu_make.m4 @@ -4,7 +4,7 @@ # # SYNOPSIS # -# AX_CHECK_GNU_MAKE() +# AX_CHECK_GNU_MAKE([run-if-true],[run-if-false]) # # DESCRIPTION # @@ -13,6 +13,10 @@ # * The makefile variable `ifGNUmake' is set to the empty string, otherwise # it is set to "#". This is useful for including a special features in a # Makefile, which cannot be handled by other versions of make. +# * The makefile variable `ifnGNUmake' is set to #, otherwise +# it is set to the empty string. This is useful for including a special +# features in a Makefile, which can be handled +# by other versions of make or to specify else like clause. # * The variable `_cv_gnu_make_command` is set to the command to invoke # GNU make if it exists, the empty string otherwise. # * The variable `ax_cv_gnu_make_command` is set to the command to invoke @@ -20,6 +24,8 @@ # * If GNU Make is found, its version is extracted from the output of # `make --version` as the last field of a record of space-separated # columns and saved into the variable `ax_check_gnu_make_version`. +# * Additionally if GNU Make is found, run shell code run-if-true +# else run shell code run-if-false. # # Here is an example of its use: # @@ -31,6 +37,8 @@ # # @ifGNUmake@ ifeq ($(DEPEND),$(wildcard $(DEPEND))) # @ifGNUmake@ include $(DEPEND) +# @ifGNUmake@ else +# fallback code # @ifGNUmake@ endif # # Then configure.in would normally contain: @@ -61,7 +69,7 @@ # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 9 +#serial 12 AC_DEFUN([AX_CHECK_GNU_MAKE],dnl [AC_PROG_AWK @@ -79,6 +87,9 @@ dnl Search all the common names for GNU make done ;]) dnl If there was a GNU version, then set @ifGNUmake@ to the empty string, '#' otherwise AS_VAR_IF([_cv_gnu_make_command], [""], [AS_VAR_SET([ifGNUmake], ["#"])], [AS_VAR_SET([ifGNUmake], [""])]) + AS_VAR_IF([_cv_gnu_make_command], [""], [AS_VAR_SET([ifnGNUmake], [""])], [AS_VAR_SET([ifnGNUmake], ["#"])]) AS_VAR_IF([_cv_gnu_make_command], [""], [AS_UNSET(ax_cv_gnu_make_command)], [AS_VAR_SET([ax_cv_gnu_make_command], [${_cv_gnu_make_command}])]) + AS_VAR_IF([_cv_gnu_make_command], [""],[$2],[$1]) AC_SUBST([ifGNUmake]) + AC_SUBST([ifnGNUmake]) ]) diff --git a/subprojects/libsodium/m4/ax_pthread.m4 b/subprojects/libsodium/m4/ax_pthread.m4 @@ -14,20 +14,24 @@ # flags that are needed. (The user can also force certain compiler # flags/libs to be tested by setting these environment variables.) # -# Also sets PTHREAD_CC to any special C compiler that is needed for -# multi-threaded programs (defaults to the value of CC otherwise). (This -# is necessary on AIX to use the special cc_r compiler alias.) +# Also sets PTHREAD_CC and PTHREAD_CXX to any special C compiler that is +# needed for multi-threaded programs (defaults to the value of CC +# respectively CXX otherwise). (This is necessary on e.g. AIX to use the +# special cc_r/CC_r compiler alias.) # # NOTE: You are assumed to not only compile your program with these flags, # but also to link with them as well. For example, you might link with # $PTHREAD_CC $CFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS $LIBS +# $PTHREAD_CXX $CXXFLAGS $PTHREAD_CFLAGS $LDFLAGS ... $PTHREAD_LIBS $LIBS # # If you are only building threaded programs, you may wish to use these # variables in your default LIBS, CFLAGS, and CC: # # LIBS="$PTHREAD_LIBS $LIBS" # CFLAGS="$CFLAGS $PTHREAD_CFLAGS" +# CXXFLAGS="$CXXFLAGS $PTHREAD_CFLAGS" # CC="$PTHREAD_CC" +# CXX="$PTHREAD_CXX" # # In addition, if the PTHREAD_CREATE_JOINABLE thread-attribute constant # has a nonstandard name, this macro defines PTHREAD_CREATE_JOINABLE to @@ -55,6 +59,7 @@ # # Copyright (c) 2008 Steven G. Johnson <stevenj@alum.mit.edu> # Copyright (c) 2011 Daniel Richard G. <skunk@iSKUNK.ORG> +# Copyright (c) 2019 Marc Stevens <marc.stevens@cwi.nl> # # This program is free software: you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by the @@ -82,7 +87,7 @@ # modified version of the Autoconf Macro, you may extend this special # exception to the GPL to apply to your modified version as well. -#serial 24 +#serial 31 AU_ALIAS([ACX_PTHREAD], [AX_PTHREAD]) AC_DEFUN([AX_PTHREAD], [ @@ -104,6 +109,7 @@ if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then ax_pthread_save_CFLAGS="$CFLAGS" ax_pthread_save_LIBS="$LIBS" AS_IF([test "x$PTHREAD_CC" != "x"], [CC="$PTHREAD_CC"]) + AS_IF([test "x$PTHREAD_CXX" != "x"], [CXX="$PTHREAD_CXX"]) CFLAGS="$CFLAGS $PTHREAD_CFLAGS" LIBS="$PTHREAD_LIBS $LIBS" AC_MSG_CHECKING([for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS]) @@ -123,10 +129,12 @@ fi # (e.g. DEC) have both -lpthread and -lpthreads, where one of the # libraries is broken (non-POSIX). -# Create a list of thread flags to try. Items starting with a "-" are -# C compiler flags, and other items are library names, except for "none" -# which indicates that we try without any flags at all, and "pthread-config" -# which is a program returning the flags for the Pth emulation library. +# Create a list of thread flags to try. Items with a "," contain both +# C compiler flags (before ",") and linker flags (after ","). Other items +# starting with a "-" are C compiler flags, and remaining items are +# library names, except for "none" which indicates that we try without +# any flags at all, and "pthread-config" which is a program returning +# the flags for the Pth emulation library. ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config" @@ -194,14 +202,47 @@ case $host_os in # that too in a future libc.) So we'll check first for the # standard Solaris way of linking pthreads (-mt -lpthread). - ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags" + ax_pthread_flags="-mt,-lpthread pthread $ax_pthread_flags" ;; esac +# Are we compiling with Clang? + +AC_CACHE_CHECK([whether $CC is Clang], + [ax_cv_PTHREAD_CLANG], + [ax_cv_PTHREAD_CLANG=no + # Note that Autoconf sets GCC=yes for Clang as well as GCC + if test "x$GCC" = "xyes"; then + AC_EGREP_CPP([AX_PTHREAD_CC_IS_CLANG], + [/* Note: Clang 2.7 lacks __clang_[a-z]+__ */ +# if defined(__clang__) && defined(__llvm__) + AX_PTHREAD_CC_IS_CLANG +# endif + ], + [ax_cv_PTHREAD_CLANG=yes]) + fi + ]) +ax_pthread_clang="$ax_cv_PTHREAD_CLANG" + + # GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC) +# Note that for GCC and Clang -pthread generally implies -lpthread, +# except when -nostdlib is passed. +# This is problematic using libtool to build C++ shared libraries with pthread: +# [1] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=25460 +# [2] https://bugzilla.redhat.com/show_bug.cgi?id=661333 +# [3] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=468555 +# To solve this, first try -pthread together with -lpthread for GCC + AS_IF([test "x$GCC" = "xyes"], - [ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"]) + [ax_pthread_flags="-pthread,-lpthread -pthread -pthreads $ax_pthread_flags"]) + +# Clang takes -pthread (never supported any other flag), but we'll try with -lpthread first + +AS_IF([test "x$ax_pthread_clang" = "xyes"], + [ax_pthread_flags="-pthread,-lpthread -pthread"]) + # The presence of a feature test macro requesting re-entrant function # definitions is, on some systems, a strong hint that pthreads support is @@ -224,25 +265,86 @@ AS_IF([test "x$ax_pthread_check_macro" = "x--"], [ax_pthread_check_cond=0], [ax_pthread_check_cond="!defined($ax_pthread_check_macro)"]) -# Are we compiling with Clang? -AC_CACHE_CHECK([whether $CC is Clang], - [ax_cv_PTHREAD_CLANG], - [ax_cv_PTHREAD_CLANG=no - # Note that Autoconf sets GCC=yes for Clang as well as GCC - if test "x$GCC" = "xyes"; then - AC_EGREP_CPP([AX_PTHREAD_CC_IS_CLANG], - [/* Note: Clang 2.7 lacks __clang_[a-z]+__ */ -# if defined(__clang__) && defined(__llvm__) - AX_PTHREAD_CC_IS_CLANG -# endif - ], - [ax_cv_PTHREAD_CLANG=yes]) - fi - ]) -ax_pthread_clang="$ax_cv_PTHREAD_CLANG" +if test "x$ax_pthread_ok" = "xno"; then +for ax_pthread_try_flag in $ax_pthread_flags; do + + case $ax_pthread_try_flag in + none) + AC_MSG_CHECKING([whether pthreads work without any flags]) + ;; + + *,*) + PTHREAD_CFLAGS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\1/"` + PTHREAD_LIBS=`echo $ax_pthread_try_flag | sed "s/^\(.*\),\(.*\)$/\2/"` + AC_MSG_CHECKING([whether pthreads work with "$PTHREAD_CFLAGS" and "$PTHREAD_LIBS"]) + ;; + + -*) + AC_MSG_CHECKING([whether pthreads work with $ax_pthread_try_flag]) + PTHREAD_CFLAGS="$ax_pthread_try_flag" + ;; + + pthread-config) + AC_CHECK_PROG([ax_pthread_config], [pthread-config], [yes], [no]) + AS_IF([test "x$ax_pthread_config" = "xno"], [continue]) + PTHREAD_CFLAGS="`pthread-config --cflags`" + PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" + ;; + + *) + AC_MSG_CHECKING([for the pthreads library -l$ax_pthread_try_flag]) + PTHREAD_LIBS="-l$ax_pthread_try_flag" + ;; + esac + + ax_pthread_save_CFLAGS="$CFLAGS" + ax_pthread_save_LIBS="$LIBS" + CFLAGS="$CFLAGS $PTHREAD_CFLAGS" + LIBS="$PTHREAD_LIBS $LIBS" + + # Check for various functions. We must include pthread.h, + # since some functions may be macros. (On the Sequent, we + # need a special flag -Kthread to make this header compile.) + # We check for pthread_join because it is in -lpthread on IRIX + # while pthread_create is in libc. We check for pthread_attr_init + # due to DEC craziness with -lpthreads. We check for + # pthread_cleanup_push because it is one of the few pthread + # functions on Solaris that doesn't have a non-functional libc stub. + # We try pthread_create on general principles. + + AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <pthread.h> +# if $ax_pthread_check_cond +# error "$ax_pthread_check_macro must be defined" +# endif + static void *some_global = NULL; + static void routine(void *a) + { + /* To avoid any unused-parameter or + unused-but-set-parameter warning. */ + some_global = a; + } + static void *start_routine(void *a) { return a; }], + [pthread_t th; pthread_attr_t attr; + pthread_create(&th, 0, start_routine, 0); + pthread_join(th, 0); + pthread_attr_init(&attr); + pthread_cleanup_push(routine, 0); + pthread_cleanup_pop(0) /* ; */])], + [ax_pthread_ok=yes], + []) + + CFLAGS="$ax_pthread_save_CFLAGS" + LIBS="$ax_pthread_save_LIBS" + + AC_MSG_RESULT([$ax_pthread_ok]) + AS_IF([test "x$ax_pthread_ok" = "xyes"], [break]) + + PTHREAD_LIBS="" + PTHREAD_CFLAGS="" +done +fi -ax_pthread_clang_warning=no # Clang needs special handling, because older versions handle the -pthread # option in a rather... idiosyncratic way @@ -261,11 +363,6 @@ if test "x$ax_pthread_clang" = "xyes"; then # -pthread does define _REENTRANT, and while the Darwin headers # ignore this macro, third-party headers might not.) - PTHREAD_CFLAGS="-pthread" - PTHREAD_LIBS= - - ax_pthread_ok=yes - # However, older versions of Clang make a point of warning the user # that, in an invocation where only linking and no compilation is # taking place, the -pthread option has no effect ("argument unused @@ -294,7 +391,7 @@ if test "x$ax_pthread_clang" = "xyes"; then # step ax_pthread_save_ac_link="$ac_link" ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g' - ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"` + ax_pthread_link_step=`AS_ECHO(["$ac_link"]) | sed "$ax_pthread_sed"` ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)" ax_pthread_save_CFLAGS="$CFLAGS" for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do @@ -320,78 +417,7 @@ if test "x$ax_pthread_clang" = "xyes"; then fi # $ax_pthread_clang = yes -if test "x$ax_pthread_ok" = "xno"; then -for ax_pthread_try_flag in $ax_pthread_flags; do - - case $ax_pthread_try_flag in - none) - AC_MSG_CHECKING([whether pthreads work without any flags]) - ;; - - -mt,pthread) - AC_MSG_CHECKING([whether pthreads work with -mt -lpthread]) - PTHREAD_CFLAGS="-mt" - PTHREAD_LIBS="-lpthread" - ;; - - -*) - AC_MSG_CHECKING([whether pthreads work with $ax_pthread_try_flag]) - PTHREAD_CFLAGS="$ax_pthread_try_flag" - ;; - pthread-config) - AC_CHECK_PROG([ax_pthread_config], [pthread-config], [yes], [no]) - AS_IF([test "x$ax_pthread_config" = "xno"], [continue]) - PTHREAD_CFLAGS="`pthread-config --cflags`" - PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`" - ;; - - *) - AC_MSG_CHECKING([for the pthreads library -l$ax_pthread_try_flag]) - PTHREAD_LIBS="-l$ax_pthread_try_flag" - ;; - esac - - ax_pthread_save_CFLAGS="$CFLAGS" - ax_pthread_save_LIBS="$LIBS" - CFLAGS="$CFLAGS $PTHREAD_CFLAGS" - LIBS="$PTHREAD_LIBS $LIBS" - - # Check for various functions. We must include pthread.h, - # since some functions may be macros. (On the Sequent, we - # need a special flag -Kthread to make this header compile.) - # We check for pthread_join because it is in -lpthread on IRIX - # while pthread_create is in libc. We check for pthread_attr_init - # due to DEC craziness with -lpthreads. We check for - # pthread_cleanup_push because it is one of the few pthread - # functions on Solaris that doesn't have a non-functional libc stub. - # We try pthread_create on general principles. - - AC_LINK_IFELSE([AC_LANG_PROGRAM([#include <pthread.h> -# if $ax_pthread_check_cond -# error "$ax_pthread_check_macro must be defined" -# endif - static void routine(void *a) { a = 0; } - static void *start_routine(void *a) { return a; }], - [pthread_t th; pthread_attr_t attr; - pthread_create(&th, 0, start_routine, 0); - pthread_join(th, 0); - pthread_attr_init(&attr); - pthread_cleanup_push(routine, 0); - pthread_cleanup_pop(0) /* ; */])], - [ax_pthread_ok=yes], - []) - - CFLAGS="$ax_pthread_save_CFLAGS" - LIBS="$ax_pthread_save_LIBS" - - AC_MSG_RESULT([$ax_pthread_ok]) - AS_IF([test "x$ax_pthread_ok" = "xyes"], [break]) - - PTHREAD_LIBS="" - PTHREAD_CFLAGS="" -done -fi # Various other checks: if test "x$ax_pthread_ok" = "xyes"; then @@ -438,7 +464,8 @@ if test "x$ax_pthread_ok" = "xyes"; then AC_CACHE_CHECK([for PTHREAD_PRIO_INHERIT], [ax_cv_PTHREAD_PRIO_INHERIT], [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <pthread.h>]], - [[int i = PTHREAD_PRIO_INHERIT;]])], + [[int i = PTHREAD_PRIO_INHERIT; + return i;]])], [ax_cv_PTHREAD_PRIO_INHERIT=yes], [ax_cv_PTHREAD_PRIO_INHERIT=no]) ]) @@ -460,18 +487,28 @@ if test "x$ax_pthread_ok" = "xyes"; then [#handle absolute path differently from PATH based program lookup AS_CASE(["x$CC"], [x/*], - [AS_IF([AS_EXECUTABLE_P([${CC}_r])],[PTHREAD_CC="${CC}_r"])], - [AC_CHECK_PROGS([PTHREAD_CC],[${CC}_r],[$CC])])]) + [ + AS_IF([AS_EXECUTABLE_P([${CC}_r])],[PTHREAD_CC="${CC}_r"]) + AS_IF([test "x${CXX}" != "x"], [AS_IF([AS_EXECUTABLE_P([${CXX}_r])],[PTHREAD_CXX="${CXX}_r"])]) + ], + [ + AC_CHECK_PROGS([PTHREAD_CC],[${CC}_r],[$CC]) + AS_IF([test "x${CXX}" != "x"], [AC_CHECK_PROGS([PTHREAD_CXX],[${CXX}_r],[$CXX])]) + ] + ) + ]) ;; esac fi fi test -n "$PTHREAD_CC" || PTHREAD_CC="$CC" +test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX" AC_SUBST([PTHREAD_LIBS]) AC_SUBST([PTHREAD_CFLAGS]) AC_SUBST([PTHREAD_CC]) +AC_SUBST([PTHREAD_CXX]) # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: if test "x$ax_pthread_ok" = "xyes"; then diff --git a/subprojects/libsodium/m4/ax_tls.m4 b/subprojects/libsodium/m4/ax_tls.m4 @@ -44,7 +44,7 @@ # modified version of the Autoconf Macro, you may extend this special # exception to the GPL to apply to your modified version as well. -#serial 14 +#serial 15 AC_DEFUN([AX_TLS], [ AC_MSG_CHECKING([for thread local storage (TLS) class]) @@ -52,23 +52,20 @@ AC_DEFUN([AX_TLS], [ [for ax_tls_keyword in thread_local _Thread_local __thread '__declspec(thread)' none; do AS_CASE([$ax_tls_keyword], [none], [ac_cv_tls=none ; break], - [AC_TRY_COMPILE( - [#include <stdlib.h> - static void - foo(void) { - static ] $ax_tls_keyword [ int bar; - exit(1); - }], - [], - [ac_cv_tls=$ax_tls_keyword ; break], - ac_cv_tls=none - )]) - done - ]) + [AC_COMPILE_IFELSE([AC_LANG_PROGRAM( + [#include <stdlib.h>], + [static $ax_tls_keyword int bar;] + )], + [ac_cv_tls=$ax_tls_keyword ; break], + [ac_cv_tls=none] + )] + ) + done ] + ) AC_MSG_RESULT([$ac_cv_tls]) AS_IF([test "$ac_cv_tls" != "none"], - [AC_DEFINE_UNQUOTED([TLS],[$ac_cv_tls],[If the compiler supports a TLS storage class define it to that here]) - m4_ifnblank([$1],[$1])], - [m4_ifnblank([$2],[$2])]) + [AC_DEFINE_UNQUOTED([TLS],[$ac_cv_tls],[If the compiler supports a TLS storage class, define it to that here]) + m4_ifnblank([$1],[$1],[[:]])], + [m4_ifnblank([$2],[$2],[[:]])]) ]) diff --git a/subprojects/libsodium/m4/ax_valgrind_check.m4 b/subprojects/libsodium/m4/ax_valgrind_check.m4 @@ -36,21 +36,19 @@ # AX_VALGRIND_DFLT([sgcheck], [off]) # AX_VALGRIND_CHECK # -# Makefile.am: +# in each Makefile.am with tests: # # @VALGRIND_CHECK_RULES@ # VALGRIND_SUPPRESSIONS_FILES = my-project.supp # EXTRA_DIST = my-project.supp # -# This results in a "check-valgrind" rule being added to any Makefile.am -# which includes "@VALGRIND_CHECK_RULES@" (assuming the module has been -# configured with --enable-valgrind). Running `make check-valgrind` in -# that directory will run the module's test suite (`make check`) once for -# each of the available Valgrind tools (out of memcheck, helgrind and drd) -# while the sgcheck will be skipped unless enabled again on the -# commandline with --enable-valgrind-sgcheck. The results for each check -# will be output to test-suite-$toolname.log. The target will succeed if -# there are zero errors and fail otherwise. +# This results in a "check-valgrind" rule being added. Running `make +# check-valgrind` in that directory will recursively run the module's test +# suite (`make check`) once for each of the available Valgrind tools (out +# of memcheck, helgrind and drd) while the sgcheck will be skipped unless +# enabled again on the commandline with --enable-valgrind-sgcheck. The +# results for each check will be output to test-suite-$toolname.log. The +# target will succeed if there are zero errors and fail otherwise. # # Alternatively, a "check-valgrind-$TOOL" rule will be added, for $TOOL in # memcheck, helgrind, drd and sgcheck. These are useful because often only @@ -67,7 +65,7 @@ # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 15 +#serial 23 dnl Configured tools m4_define([valgrind_tool_list], [[memcheck], [helgrind], [drd], [sgcheck]]) @@ -80,10 +78,14 @@ AC_DEFUN([AX_VALGRIND_DFLT],[ ])dnl AC_DEFUN([AX_VALGRIND_CHECK],[ + AM_EXTRA_RECURSIVE_TARGETS([check-valgrind]) + m4_foreach([vgtool], [valgrind_tool_list], + [AM_EXTRA_RECURSIVE_TARGETS([check-valgrind-]vgtool)]) + dnl Check for --enable-valgrind AC_ARG_ENABLE([valgrind], - [AS_HELP_STRING([--enable-valgrind], [Whether to enable Valgrind on the unit tests (requires GNU make)])], - [enable_valgrind=$enableval],[enable_valgrind=no]) + [AS_HELP_STRING([--enable-valgrind], [Whether to enable Valgrind on the unit tests])], + [enable_valgrind=$enableval],[enable_valgrind=]) AS_IF([test "$enable_valgrind" != "no"],[ # Check for Valgrind. @@ -175,7 +177,7 @@ valgrind_quiet_ = $(valgrind_quiet_$(AM_DEFAULT_VERBOSITY)) valgrind_quiet_0 = --quiet valgrind_v_use = $(valgrind_v_use_$(V)) valgrind_v_use_ = $(valgrind_v_use_$(AM_DEFAULT_VERBOSITY)) -valgrind_v_use_0 = @echo " USE " $(patsubst check-valgrind-%,%,$''@):; +valgrind_v_use_0 = @echo " USE " $(patsubst check-valgrind-%-local,%,$''@):; # Support running with and without libtool. ifneq ($(LIBTOOL),) @@ -185,12 +187,12 @@ valgrind_lt = endif # Use recursive makes in order to ignore errors during check -check-valgrind: +check-valgrind-local: ifeq ($(VALGRIND_ENABLED),yes) $(A''M_V_at)$(MAKE) $(AM_MAKEFLAGS) -k \ $(foreach tool, $(valgrind_enabled_tools), check-valgrind-$(tool)) else - @echo "Need to use GNU make and reconfigure with --enable-valgrind" + @echo "Need to reconfigure with --enable-valgrind" endif # Valgrind running @@ -204,14 +206,16 @@ VALGRIND_LOG_COMPILER = \ $(valgrind_lt) \ $(VALGRIND) $(VALGRIND_SUPPRESSIONS) --error-exitcode=1 $(VALGRIND_FLAGS) -define valgrind_tool_rule = -check-valgrind-$(1): +define valgrind_tool_rule +check-valgrind-$(1)-local: ifeq ($$(VALGRIND_ENABLED)-$$(ENABLE_VALGRIND_$(1)),yes-yes) +ifneq ($$(TESTS),) $$(valgrind_v_use)$$(MAKE) check-TESTS \ TESTS_ENVIRONMENT="$$(VALGRIND_TESTS_ENVIRONMENT)" \ LOG_COMPILER="$$(VALGRIND_LOG_COMPILER)" \ LOG_FLAGS="$$(valgrind_$(1)_flags)" \ TEST_SUITE_LOG=test-suite-$(1).log +endif else ifeq ($$(VALGRIND_ENABLED),yes) @echo "Need to reconfigure with --enable-valgrind-$(1)" else @@ -227,15 +231,9 @@ A''M_DISTCHECK_CONFIGURE_FLAGS += --disable-valgrind MOSTLYCLEANFILES ?= MOSTLYCLEANFILES += $(valgrind_log_files) -.PHONY: check-valgrind $(add-prefix check-valgrind-,$(valgrind_tools)) +.PHONY: check-valgrind $(addprefix check-valgrind-,$(valgrind_tools)) '] - AS_IF([test "$enable_valgrind" != "yes"], [ - VALGRIND_CHECK_RULES=' -check-valgrind: - @echo "Need to use GNU make and reconfigure with --enable-valgrind"' - ]) - AC_SUBST([VALGRIND_CHECK_RULES]) m4_ifdef([_AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE([VALGRIND_CHECK_RULES])]) ]) diff --git a/subprojects/libsodium/m4/libtool.m4 b/subprojects/libsodium/m4/libtool.m4 @@ -1,6 +1,7 @@ # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # -# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. +# Copyright (C) 1996-2001, 2003-2019, 2021-2024 Free Software +# Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives @@ -8,13 +9,13 @@ # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl -# Copyright (C) 2014 Free Software Foundation, Inc. +# Copyright (C) 2024 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of of the License, or +# the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you @@ -31,7 +32,7 @@ m4_define([_LT_COPYING], [dnl # along with this program. If not, see <http://www.gnu.org/licenses/>. ]) -# serial 58 LT_INIT +# serial 63 LT_INIT # LT_PREREQ(VERSION) @@ -59,7 +60,7 @@ esac # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], -[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK +[AC_PREREQ([2.64])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl @@ -181,6 +182,7 @@ m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl +m4_require([_LT_DECL_FILECMD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl @@ -219,8 +221,8 @@ esac ofile=libtool can_build_shared=yes -# All known linkers require a '.a' archive for static linking (except MSVC, -# which needs '.lib'). +# All known linkers require a '.a' archive for static linking (except MSVC and +# ICC, which need '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld @@ -614,7 +616,7 @@ m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- # This macro allows early generation of the libtool script (before -# AC_OUTPUT is called), incase it is used in configure for compilation +# AC_OUTPUT is called), in case it is used in configure for compilation # tests. AC_DEFUN([LT_OUTPUT], [: ${CONFIG_LT=./config.lt} @@ -649,9 +651,9 @@ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) configured by $[0], generated by m4_PACKAGE_STRING. -Copyright (C) 2011 Free Software Foundation, Inc. +Copyright (C) 2024 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation -gives unlimited permision to copy, distribute and modify it." +gives unlimited permission to copy, distribute and modify it." while test 0 != $[#] do @@ -728,7 +730,6 @@ _LT_CONFIG_SAVE_COMMANDS([ cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. @@ -778,7 +779,7 @@ _LT_EOF # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" \ + $SED '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || @@ -973,6 +974,7 @@ _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ])# _LT_LINKER_BOILERPLATE + # _LT_REQUIRED_DARWIN_CHECKS # ------------------------- m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ @@ -1023,6 +1025,21 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ rm -f conftest.* fi]) + # Feature test to disable chained fixups since it is not + # compatible with '-undefined dynamic_lookup' + AC_CACHE_CHECK([for -no_fixup_chains linker flag], + [lt_cv_support_no_fixup_chains], + [ save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -Wl,-no_fixup_chains" + AC_LINK_IFELSE( + [AC_LANG_PROGRAM([],[])], + lt_cv_support_no_fixup_chains=yes, + lt_cv_support_no_fixup_chains=no + ) + LDFLAGS=$save_LDFLAGS + ] + ) + AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no @@ -1042,12 +1059,12 @@ int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$AR $AR_FLAGS libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR $AR_FLAGS libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF -int main() { return 0;} +int main(void) { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err @@ -1067,23 +1084,37 @@ _LT_EOF _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - darwin*) # darwin 5.x on - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; - 10.[[012]][[,.]]*) - _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + darwin*) + case $MACOSX_DEPLOYMENT_TARGET,$host in + 10.[[012]],*|,*powerpc*-darwin[[5-8]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + *) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' + if test yes = "$lt_cv_support_no_fixup_chains"; then + AS_VAR_APPEND([_lt_dar_allow_undefined], [' $wl-no_fixup_chains']) + fi + ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi + _lt_dar_needs_single_mod=no + case $host_os in + rhapsody* | darwin1.*) + _lt_dar_needs_single_mod=yes ;; + darwin*) + # When targeting Mac OS X 10.4 (darwin 8) or later, + # -single_module is the default and -multi_module is unsupported. + # The toolchain on macOS 10.14 (darwin 18) and later cannot + # target any OS version that needs -single_module. + case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in + 10.0,*-darwin[[567]].*|10.[[0-3]],*-darwin[[5-9]].*|10.[[0-3]],*-darwin1[[0-7]].*) + _lt_dar_needs_single_mod=yes ;; + esac + ;; + esac if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else @@ -1126,12 +1157,12 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" - _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="$SED -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], -[ if test yes != "$lt_cv_apple_cc_single_mod"; then +[ if test yes = "$_lt_dar_needs_single_mod" -a yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="$SED 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else @@ -1245,7 +1276,8 @@ _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], -[AC_MSG_CHECKING([for sysroot]) +[m4_require([_LT_DECL_SED])dnl +AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot @@ -1258,11 +1290,13 @@ lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then - lt_sysroot=`$CC --print-sysroot 2>/dev/null` + # Trim trailing / since we'll always append absolute paths and we want + # to avoid //, if only for less confusing output for the user. + lt_sysroot=`$CC --print-sysroot 2>/dev/null | $SED 's:/\+$::'` fi ;; #( /*) - lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + lt_sysroot=`echo "$with_sysroot" | $SED -e "$sed_quote_subst"` ;; #( no|'') ;; #( @@ -1292,7 +1326,7 @@ ia64-*-hpux*) # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; @@ -1309,7 +1343,7 @@ ia64-*-hpux*) echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; @@ -1321,7 +1355,7 @@ ia64-*-hpux*) ;; esac else - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; @@ -1343,7 +1377,7 @@ mips64*-*linux*) echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; @@ -1351,7 +1385,7 @@ mips64*-*linux*) emul="${emul}64" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; @@ -1359,7 +1393,7 @@ mips64*-*linux*) emul="${emul}ltsmip" ;; esac - case `/usr/bin/file conftest.$ac_objext` in + case `$FILECMD conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; @@ -1370,7 +1404,7 @@ mips64*-*linux*) ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ -s390*-*linux*|s390*-*tpf*|sparc*-*linux*) +s390*-*linux*|s390*-*tpf*|sparc*-*linux*|x86_64-gnu*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when @@ -1379,14 +1413,14 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; - x86_64-*linux*) - case `/usr/bin/file conftest.o` in + x86_64-*linux*|x86_64-gnu*) + case `$FILECMD conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; @@ -1414,7 +1448,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; - x86_64-*linux*) + x86_64-*linux*|x86_64-gnu*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) @@ -1454,7 +1488,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in + case `$FILECMD conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) @@ -1493,9 +1527,22 @@ need_locks=$enable_libtool_lock m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} -: ${AR_FLAGS=cru} _LT_DECL([], [AR], [1], [The archiver]) -_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +# Use ARFLAGS variable as AR's operation code to sync the variable naming with +# Automake. If both AR_FLAGS and ARFLAGS are specified, AR_FLAGS should have +# higher priority because that's what people were doing historically (setting +# ARFLAGS for automake and AR_FLAGS for libtool). FIXME: Make the AR_FLAGS +# variable obsoleted/removed. + +test ${AR_FLAGS+y} || AR_FLAGS=${ARFLAGS-cr} +lt_ar_flags=$AR_FLAGS +_LT_DECL([], [lt_ar_flags], [0], [Flags to create an archive (by configure)]) + +# Make AR_FLAGS overridable by 'make ARFLAGS='. Don't try to run-time override +# by AR_FLAGS because that was never working and AR_FLAGS is about to die. +_LT_DECL([], [AR_FLAGS], [\@S|@{ARFLAGS-"\@S|@lt_ar_flags"}], + [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no @@ -1534,7 +1581,7 @@ AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) -AC_CHECK_TOOL(RANLIB, ranlib, :) +AC_REQUIRE([AC_PROG_RANLIB]) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) @@ -1545,15 +1592,8 @@ old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then - case $host_os in - bitrig* | openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" - ;; - esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" + old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in @@ -1685,14 +1725,14 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. + gnu* | ironclad*) + # Under GNU Hurd and Ironclad, this test is not required because there + # is no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; - cygwin* | mingw* | cegcc*) + cygwin* | mingw* | windows* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, @@ -1714,7 +1754,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=8192; ;; - bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) + darwin* | dragonfly* | freebsd* | midnightbsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` @@ -1757,7 +1797,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` + lt_cv_sys_max_cmd_len=`echo $kargmax | $SED 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi @@ -1874,11 +1914,11 @@ else /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) -int fnord () __attribute__((visibility("default"))); +int fnord (void) __attribute__((visibility("default"))); #endif -int fnord () { return 42; } -int main () +int fnord (void) { return 42; } +int main (void) { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; @@ -1935,7 +1975,7 @@ else lt_cv_dlopen_self=yes ;; - mingw* | pw32* | cegcc*) + mingw* | windows* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; @@ -2207,26 +2247,35 @@ m4_defun([_LT_CMD_STRIPLIB], striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) +if test -z "$STRIP"; then + AC_MSG_RESULT([no]) else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP"; then + if $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) + else + case $host_os in + darwin*) + # FIXME - insert some real tests, host_os isn't really good enough striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) - else + ;; + freebsd*) + if $STRIP -V 2>&1 | $GREP "elftoolchain" >/dev/null; then + old_striplib="$STRIP --strip-debug" + striplib="$STRIP --strip-unneeded" + AC_MSG_RESULT([yes]) + else + AC_MSG_RESULT([no]) + fi + ;; + *) AC_MSG_RESULT([no]) - fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac + ;; + esac + fi fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) @@ -2294,7 +2343,7 @@ if test yes = "$GCC"; then *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in - mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; + mingw* | windows* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` @@ -2352,7 +2401,7 @@ BEGIN {RS = " "; FS = "/|\n";} { # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in - mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + mingw* | windows* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` @@ -2427,7 +2476,7 @@ aix[[4-9]]*) # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl - # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # linker flag in LDFLAGS as well, or --enable-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the @@ -2521,7 +2570,7 @@ bsdi[[45]]*) # libtool to hard-code these into programs ;; -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no @@ -2532,15 +2581,29 @@ cygwin* | mingw* | pw32* | cegcc*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \$file`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname~ - if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then - eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; - fi' + # If user builds GCC with multilib enabled, + # it should just install on $(libdir) + # not on $(libdir)/../bin or 32 bits dlls would override 64 bit ones. + if test xyes = x"$multilib"; then + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + $install_prog $dir/$dlname $destdir/$dlname~ + chmod a+x $destdir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib $destdir/$dlname'\'' || exit \$?; + fi' + else + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + fi postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' @@ -2549,30 +2612,30 @@ cygwin* | mingw* | pw32* | cegcc*) case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + soname_spec='`echo $libname | $SED -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; - mingw* | cegcc*) + mingw* | windows* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='`echo $libname | $SED -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; - *,cl*) - # Native MSVC + *,cl* | *,icl*) + # Native MSVC or ICC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in - mingw*) + mingw* | windows*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' @@ -2585,7 +2648,7 @@ m4_if([$1], [],[ done IFS=$lt_save_ifs # Convert to MSYS style. - sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form @@ -2622,7 +2685,7 @@ m4_if([$1], [],[ ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; @@ -2655,7 +2718,7 @@ dgux*) shlibpath_var=LD_LIBRARY_PATH ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then @@ -2679,7 +2742,21 @@ freebsd* | dragonfly*) need_version=yes ;; esac - shlibpath_var=LD_LIBRARY_PATH + case $host_cpu in + powerpc64) + # On FreeBSD bi-arch platforms, a different variable is used for 32-bit + # binaries. See <https://man.freebsd.org/cgi/man.cgi?query=ld.so>. + AC_COMPILE_IFELSE( + [AC_LANG_SOURCE( + [[int test_pointer_size[sizeof (void *) - 5]; + ]])], + [shlibpath_var=LD_LIBRARY_PATH], + [shlibpath_var=LD_32_LIBRARY_PATH]) + ;; + *) + shlibpath_var=LD_LIBRARY_PATH + ;; + esac case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes @@ -2709,8 +2786,9 @@ haiku*) soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no - sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' - hardcode_into_libs=yes + sys_lib_search_path_spec='/boot/system/non-packaged/develop/lib /boot/system/develop/lib' + sys_lib_dlsearch_path_spec='/boot/home/config/non-packaged/lib /boot/home/config/lib /boot/system/non-packaged/lib /boot/system/lib' + hardcode_into_libs=no ;; hpux9* | hpux10* | hpux11*) @@ -2820,7 +2898,7 @@ linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no - library_names_spec='$libname$release$shared_ext' + library_names_spec='$libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH @@ -2832,8 +2910,9 @@ linux*android*) hardcode_into_libs=yes dynamic_linker='Android linker' - # Don't embed -rpath directories since the linker doesn't support them. - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + # -rpath works at least for libraries that are not overridden by + # libraries installed in system locations. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; # This must be glibc/ELF. @@ -2867,7 +2946,7 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) # before this can be enabled. hardcode_into_libs=yes - # Ideally, we could use ldconfig to report *all* directores which are + # Ideally, we could use ldconfig to report *all* directories which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, @@ -2887,6 +2966,18 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no @@ -2905,6 +2996,18 @@ netbsd*) hardcode_into_libs=yes ;; +*-mlibc) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + dynamic_linker='mlibc ld.so' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + ;; + newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' @@ -2924,7 +3027,7 @@ newsos6) dynamic_linker='ldqnx.so' ;; -openbsd* | bitrig*) +openbsd*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no @@ -2984,6 +3087,17 @@ rdos*) dynamic_linker=no ;; +serenity*) + version_type=linux # correct to gnu/linux during the next big refactor + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + dynamic_linker='SerenityOS LibELF' + ;; + solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no @@ -3081,6 +3195,21 @@ uts4*) shlibpath_var=LD_LIBRARY_PATH ;; +emscripten*) + version_type=none + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + dynamic_linker="Emscripten linker" + _LT_COMPILER_PIC($1)='-fPIC' + _LT_TAGVAR(archive_cmds, $1)='$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -sSIDE_MODULE=2 -shared $libobjs $deplibs $compiler_flags -o $lib -s EXPORTED_FUNCTIONS=@$output_objdir/$soname.expsym' + _LT_TAGVAR(archive_cmds_need_lc, $1)=no + _LT_TAGVAR(no_undefined_flag, $1)= + ;; + *) dynamic_linker=no ;; @@ -3256,7 +3385,7 @@ if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in - *-*-mingw*) + *-*-mingw* | *-*-windows*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) @@ -3365,7 +3494,7 @@ case $reload_flag in esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi @@ -3437,7 +3566,6 @@ lt_cv_deplibs_check_method='unknown' # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure @@ -3454,7 +3582,7 @@ beos*) bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' + lt_cv_file_magic_cmd='$FILECMD -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; @@ -3464,7 +3592,7 @@ cygwin*) lt_cv_file_magic_cmd='func_win32_libid' ;; -mingw* | pw32*) +mingw* | windows* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. @@ -3473,7 +3601,7 @@ mingw* | pw32*) lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. - lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64|pe-aarch64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; @@ -3488,14 +3616,14 @@ darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; -freebsd* | dragonfly*) +freebsd* | dragonfly* | midnightbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac @@ -3509,7 +3637,7 @@ haiku*) ;; hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' @@ -3546,7 +3674,11 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +*-mlibc) + lt_cv_deplibs_check_method=pass_all + ;; + +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else @@ -3556,7 +3688,7 @@ netbsd*) newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_cmd=$FILECMD lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; @@ -3564,7 +3696,7 @@ newos6*) lt_cv_deplibs_check_method=pass_all ;; -openbsd* | bitrig*) +openbsd*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else @@ -3580,6 +3712,10 @@ rdos*) lt_cv_deplibs_check_method=pass_all ;; +serenity*) + lt_cv_deplibs_check_method=pass_all + ;; + solaris*) lt_cv_deplibs_check_method=pass_all ;; @@ -3628,7 +3764,7 @@ file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in - mingw* | pw32*) + mingw* | windows* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else @@ -3680,16 +3816,16 @@ else # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in - mingw*) lt_bad_file=conftest.nm/nofile ;; + mingw* | windows*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac - case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + case `"$tmp_nm" -B $lt_bad_file 2>&1 | $SED '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in + case `"$tmp_nm" -p /dev/null 2>&1 | $SED '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 @@ -3715,7 +3851,7 @@ else # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | $SED '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; @@ -3771,7 +3907,7 @@ lt_cv_sharedlib_from_linklib_cmd, [lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in @@ -3803,16 +3939,16 @@ _LT_DECL([], [sharedlib_from_linklib_cmd], [1], m4_defun([_LT_PATH_MANIFEST_TOOL], [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt -AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], - [lt_cv_path_mainfest_tool=no +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_manifest_tool], + [lt_cv_path_manifest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&AS_MESSAGE_LOG_FD if $GREP 'Manifest Tool' conftest.out > /dev/null; then - lt_cv_path_mainfest_tool=yes + lt_cv_path_manifest_tool=yes fi rm -f conftest*]) -if test yes != "$lt_cv_path_mainfest_tool"; then +if test yes != "$lt_cv_path_manifest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl @@ -3841,7 +3977,7 @@ AC_DEFUN([LT_LIB_M], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in -*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-mingw* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) @@ -3916,7 +4052,7 @@ case $host_os in aix*) symcode='[[BCDT]]' ;; -cygwin* | mingw* | pw32* | cegcc*) +cygwin* | mingw* | windows* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) @@ -3931,7 +4067,7 @@ osf*) symcode='[[BCDEGQRST]]' ;; solaris*) - symcode='[[BDRT]]' + symcode='[[BCDRT]]' ;; sco3.2v5*) symcode='[[DT]]' @@ -3955,7 +4091,7 @@ esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. - lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + lt_cv_sys_global_symbol_to_import="$SED -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" @@ -3973,20 +4109,20 @@ fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +lt_cv_sys_global_symbol_to_cdecl="$SED -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address="$SED -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="$SED -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ @@ -3995,7 +4131,7 @@ $lt_c_name_lib_hook\ # Handle CRLF in mingw tool chain opt_cr= case $build_os in -mingw*) +mingw* | windows*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac @@ -4010,7 +4146,7 @@ for ac_symprfx in "" "_"; do if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. - # Also find C++ and __fastcall symbols from MSVC++, + # Also find C++ and __fastcall symbols from MSVC++ or ICC, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ @@ -4028,9 +4164,9 @@ for ac_symprfx in "" "_"; do " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" + lt_cv_sys_global_symbol_pipe="$SED -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi - lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | $SED '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no @@ -4046,13 +4182,14 @@ void nm_test_func(void){} #ifdef __cplusplus } #endif -int main(){nm_test_var='a';nm_test_func();return(0);} +int main(void){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -4222,7 +4359,7 @@ m4_if([$1], [CXX], [ beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) + mingw* | windows* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style @@ -4298,7 +4435,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - mingw* | cygwin* | os2* | pw32* | cegcc*) + mingw* | windows* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], @@ -4317,7 +4454,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) @@ -4400,7 +4537,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' @@ -4424,7 +4561,9 @@ m4_if([$1], [CXX], [ ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) + ;; + *-mlibc) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -4454,6 +4593,8 @@ m4_if([$1], [CXX], [ ;; psos*) ;; + serenity*) + ;; solaris*) case $cc_basename in CC* | sunCC*) @@ -4546,7 +4687,7 @@ m4_if([$1], [CXX], [ # PIC is the default for these OSes. ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style @@ -4650,7 +4791,7 @@ m4_if([$1], [CXX], [ esac ;; - mingw* | cygwin* | pw32* | os2* | cegcc*) + mingw* | windows* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], @@ -4692,6 +4833,12 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; + *flang* | ftn | f18* | f95*) + # Flang compiler. + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -4736,7 +4883,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' @@ -4774,6 +4921,12 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; + *-mlibc) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; + *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. @@ -4790,6 +4943,9 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; + serenity*) + ;; + solaris*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' @@ -4919,15 +5075,15 @@ m4_if([$1], [CXX], [ if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; - cygwin* | mingw* | cegcc*) + cygwin* | mingw* | windows* | cegcc*) case $cc_basename in - cl*) + cl* | icl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) @@ -4983,21 +5139,18 @@ dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in - cygwin* | mingw* | pw32* | cegcc*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time + cygwin* | mingw* | windows* | pw32* | cegcc*) + # FIXME: the MSVC++ and ICC port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) + # we just hope/assume this is gcc and not c89 (= MSVC++ or ICC) with_gnu_ld=yes ;; - openbsd* | bitrig*) - with_gnu_ld=no - ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes @@ -5044,7 +5197,7 @@ dnl Note also adjust exclude_expsyms for C++ above. _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no - case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in + case `$LD -v | $SED -e 's/([[^)]]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... @@ -5098,7 +5251,7 @@ _LT_EOF fi ;; - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' @@ -5108,6 +5261,7 @@ _LT_EOF _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + _LT_TAGVAR(file_list_spec, $1)='@' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' @@ -5127,7 +5281,7 @@ _LT_EOF haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=no ;; os2*) @@ -5154,8 +5308,9 @@ _LT_EOF cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; interix[[3-9]]*) @@ -5170,7 +5325,7 @@ _LT_EOF # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) @@ -5213,7 +5368,7 @@ _LT_EOF _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes @@ -5225,13 +5380,14 @@ _LT_EOF if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) @@ -5241,7 +5397,7 @@ _LT_EOF _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi @@ -5252,7 +5408,12 @@ _LT_EOF fi ;; - netbsd*) + *-mlibc) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= @@ -5373,7 +5534,7 @@ _LT_EOF if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no @@ -5554,14 +5715,14 @@ _LT_EOF _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. + # Microsoft Visual C++ or Intel C++ Compiler. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in - cl*) - # Native MSVC + cl* | icl*) + # Native MSVC or ICC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes @@ -5571,14 +5732,14 @@ _LT_EOF # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_cmds, $1)='$CC -Fe$output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + $CC -Fe$tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' @@ -5602,7 +5763,7 @@ _LT_EOF fi' ;; *) - # Assume MSVC wrapper + # Assume MSVC and ICC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. @@ -5650,7 +5811,7 @@ _LT_EOF ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes @@ -5790,11 +5951,15 @@ _LT_EOF # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; esac ;; - netbsd*) + *-mlibc) + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -5816,7 +5981,7 @@ _LT_EOF *nto* | *qnx*) ;; - openbsd* | bitrig*) + openbsd*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no @@ -5859,8 +6024,9 @@ _LT_EOF cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; osf3*) @@ -5894,6 +6060,9 @@ _LT_EOF _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; + serenity*) + ;; + solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test yes = "$GCC"; then @@ -6152,7 +6321,7 @@ _LT_TAGDECL([], [hardcode_direct], [0], _LT_TAGDECL([], [hardcode_direct_absolute], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting $shlibpath_var if the + "absolute", i.e. impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR @@ -6210,7 +6379,7 @@ _LT_TAGVAR(objext, $1)=$objext lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' +lt_simple_link_test_code='int main(void){return(0);}' _LT_TAG_COMPILER # Save the default compiler, since it gets overwritten when the other @@ -6399,8 +6568,7 @@ if test yes != "$_lt_caught_CXX_error"; then wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | - $GREP 'no-whole-archive' > /dev/null; then + if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= @@ -6420,7 +6588,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' else GXX=no @@ -6629,10 +6797,10 @@ if test yes != "$_lt_caught_CXX_error"; then esac ;; - cygwin* | mingw* | pw32* | cegcc*) + cygwin* | mingw* | windows* | pw32* | cegcc*) case $GXX,$cc_basename in - ,cl* | no,cl*) - # Native MSVC + ,cl* | no,cl* | ,icl* | no,icl*) + # Native MSVC or ICC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' @@ -6682,6 +6850,7 @@ if test yes != "$_lt_caught_CXX_error"; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' @@ -6728,8 +6897,9 @@ if test yes != "$_lt_caught_CXX_error"; then cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' ;; dgux*) @@ -6760,7 +6930,7 @@ if test yes != "$_lt_caught_CXX_error"; then _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; - freebsd* | dragonfly*) + freebsd* | dragonfly* | midnightbsd*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes @@ -6768,7 +6938,7 @@ if test yes != "$_lt_caught_CXX_error"; then haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - _LT_TAGVAR(link_all_deplibs, $1)=yes + _LT_TAGVAR(link_all_deplibs, $1)=no ;; hpux9*) @@ -6795,7 +6965,7 @@ if test yes != "$_lt_caught_CXX_error"; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "[[-]]L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then @@ -6860,7 +7030,7 @@ if test yes != "$_lt_caught_CXX_error"; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " [[-]]L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then @@ -6897,7 +7067,7 @@ if test yes != "$_lt_caught_CXX_error"; then # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$SED "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in @@ -7037,13 +7207,13 @@ if test yes != "$_lt_caught_CXX_error"; then _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) - case `$CC -V 2>&1 | sed 5q` in + case `$CC -V 2>&1 | $SED 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' @@ -7092,6 +7262,10 @@ if test yes != "$_lt_caught_CXX_error"; then esac ;; + *-mlibc) + _LT_TAGVAR(ld_shlibs, $1)=yes + ;; + netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' @@ -7108,7 +7282,7 @@ if test yes != "$_lt_caught_CXX_error"; then _LT_TAGVAR(ld_shlibs, $1)=yes ;; - openbsd* | bitrig*) + openbsd*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no @@ -7199,7 +7373,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' else # FIXME: insert proper C++ library support @@ -7214,6 +7388,9 @@ if test yes != "$_lt_caught_CXX_error"; then _LT_TAGVAR(ld_shlibs, $1)=no ;; + serenity*) + ;; + sunos4*) case $cc_basename in CC*) @@ -7283,7 +7460,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. @@ -7294,7 +7471,7 @@ if test yes != "$_lt_caught_CXX_error"; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " [[-]]L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' @@ -7532,10 +7709,11 @@ if AC_TRY_EVAL(ac_compile); then case $prev$p in -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. + # Some compilers place space between "-{L,R,l}" and the path. # Remove the space. - if test x-L = "$p" || - test x-R = "$p"; then + if test x-L = x"$p" || + test x-R = x"$p" || + test x-l = x"$p"; then prev=$p continue fi @@ -8189,6 +8367,14 @@ _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) AC_SUBST([DLLTOOL]) ]) +# _LT_DECL_FILECMD +# ---------------- +# Check for a file(cmd) program that can be used to detect file type and magic +m4_defun([_LT_DECL_FILECMD], +[AC_CHECK_PROG([FILECMD], [file], [file], [:]) +_LT_DECL([], [FILECMD], [1], [A file(cmd) program that detects file types]) +])# _LD_DECL_FILECMD + # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates @@ -8201,73 +8387,6 @@ _LT_DECL([], [SED], [1], [A sed program that does not truncate output]) _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], [Sed that helps us avoid accidentally triggering echo(1) options like -n]) ])# _LT_DECL_SED - -m4_ifndef([AC_PROG_SED], [ -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ - -m4_defun([AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f "$lt_ac_sed" && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test 10 -lt "$lt_ac_count" && break - lt_ac_count=`expr $lt_ac_count + 1` - if test "$lt_ac_count" -gt "$lt_ac_max"; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -])#AC_PROG_SED -])#m4_ifndef - -# Old name: -AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_SED], []) @@ -8314,7 +8433,7 @@ AC_CACHE_VAL(lt_cv_to_host_file_cmd, [case $host in *-*-mingw* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) @@ -8327,7 +8446,7 @@ AC_CACHE_VAL(lt_cv_to_host_file_cmd, ;; *-*-cygwin* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) @@ -8353,9 +8472,9 @@ AC_CACHE_VAL(lt_cv_to_tool_file_cmd, [#assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in - *-*-mingw* ) + *-*-mingw* | *-*-windows* ) case $build in - *-*-mingw* ) # actually msys + *-*-mingw* | *-*-windows* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac diff --git a/subprojects/libsodium/m4/ltoptions.m4 b/subprojects/libsodium/m4/ltoptions.m4 @@ -1,14 +1,14 @@ # Helper functions for option handling. -*- Autoconf -*- # -# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software -# Foundation, Inc. +# Copyright (C) 2004-2005, 2007-2009, 2011-2019, 2021-2024 Free +# Software Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. -# serial 8 ltoptions.m4 +# serial 10 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) @@ -128,7 +128,7 @@ LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) +*-*-cygwin* | *-*-mingw* | *-*-windows* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) @@ -323,29 +323,39 @@ dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _LT_WITH_AIX_SONAME([DEFAULT]) # ---------------------------------- -# implement the --with-aix-soname flag, and support the `aix-soname=aix' -# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT -# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. +# implement the --enable-aix-soname configure option, and support the +# `aix-soname=aix' and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. +# DEFAULT is either `aix', `both', or `svr4'. If omitted, it defaults to `aix'. m4_define([_LT_WITH_AIX_SONAME], [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[[5-9]]*,yes) AC_MSG_CHECKING([which variant of shared library versioning to provide]) - AC_ARG_WITH([aix-soname], - [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], + AC_ARG_ENABLE([aix-soname], + [AS_HELP_STRING([--enable-aix-soname=aix|svr4|both], [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], - [case $withval in - aix|svr4|both) - ;; - *) - AC_MSG_ERROR([Unknown argument to --with-aix-soname]) - ;; - esac - lt_cv_with_aix_soname=$with_aix_soname], - [AC_CACHE_VAL([lt_cv_with_aix_soname], - [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) - with_aix_soname=$lt_cv_with_aix_soname]) + [case $enableval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --enable-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$enable_aix_soname], + [_AC_ENABLE_IF([with], [aix-soname], + [case $withval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --with-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname], + [AC_CACHE_VAL([lt_cv_with_aix_soname], + [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)]) + enable_aix_soname=$lt_cv_with_aix_soname]) + with_aix_soname=$enable_aix_soname AC_MSG_RESULT([$with_aix_soname]) if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member @@ -376,30 +386,50 @@ LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) # _LT_WITH_PIC([MODE]) # -------------------- -# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' +# implement the --enable-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], -[AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], +[AC_ARG_ENABLE([pic], + [AS_HELP_STRING([--enable-pic@<:@=PKGS@:>@], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [lt_p=${PACKAGE-default} - case $withval in - yes|no) pic_mode=$withval ;; - *) - pic_mode=default - # Look at the argument we got. We use all the common list separators. - lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, - for lt_pkg in $withval; do - IFS=$lt_save_ifs - if test "X$lt_pkg" = "X$lt_p"; then - pic_mode=yes - fi - done - IFS=$lt_save_ifs - ;; - esac], - [pic_mode=m4_default([$1], [default])]) + case $enableval in + yes|no) pic_mode=$enableval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $enableval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [dnl Continue to support --with-pic and --without-pic, for backward + dnl compatibility. + _AC_ENABLE_IF([with], [pic], + [lt_p=${PACKAGE-default} + case $withval in + yes|no) pic_mode=$withval ;; + *) + pic_mode=default + # Look at the argument we got. We use all the common list separators. + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, + for lt_pkg in $withval; do + IFS=$lt_save_ifs + if test "X$lt_pkg" = "X$lt_p"; then + pic_mode=yes + fi + done + IFS=$lt_save_ifs + ;; + esac], + [pic_mode=m4_default([$1], [default])])] + ) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC diff --git a/subprojects/libsodium/m4/ltversion.m4 b/subprojects/libsodium/m4/ltversion.m4 @@ -1,6 +1,7 @@ # ltversion.m4 -- version numbers -*- Autoconf -*- # -# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. +# Copyright (C) 2004, 2011-2019, 2021-2024 Free Software Foundation, +# Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives @@ -9,15 +10,15 @@ # @configure_input@ -# serial 4179 ltversion.m4 +# serial 4441 ltversion.m4 # This file is part of GNU Libtool -m4_define([LT_PACKAGE_VERSION], [2.4.6]) -m4_define([LT_PACKAGE_REVISION], [2.4.6]) +m4_define([LT_PACKAGE_VERSION], [2.5.4]) +m4_define([LT_PACKAGE_REVISION], [2.5.4]) AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.6' -macro_revision='2.4.6' +[macro_version='2.5.4' +macro_revision='2.5.4' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) diff --git a/subprojects/libsodium/meson.build b/subprojects/libsodium/meson.build @@ -123,15 +123,20 @@ add_project_arguments('-DCONFIGURED', language: 'c') conf_data = configuration_data() -conf_data.set('VERSION', '1.0.18') -conf_data.set('SODIUM_LIBRARY_VERSION_MAJOR', 10) -conf_data.set('SODIUM_LIBRARY_VERSION_MINOR', 3) +conf_data.set('VERSION', '1.0.20') +conf_data.set('SODIUM_LIBRARY_VERSION_MAJOR', 26) +conf_data.set('SODIUM_LIBRARY_VERSION_MINOR', 2) conf_data.set('SODIUM_LIBRARY_MINIMAL_DEF', '') subdir('src/libsodium/include/sodium') libsodium_base_src = [ - 'src/libsodium/crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c', - 'src/libsodium/crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c', + 'src/libsodium/crypto_aead/aegis128l/aead_aegis128l.c', + 'src/libsodium/crypto_aead/aegis128l/aegis128l_soft.c', + 'src/libsodium/crypto_aead/aegis256/aead_aegis256.c', + 'src/libsodium/crypto_aead/aegis256/aegis256_soft.c', + 'src/libsodium/crypto_aead/aes256gcm/aead_aes256gcm.c', + 'src/libsodium/crypto_aead/chacha20poly1305/aead_chacha20poly1305.c', + 'src/libsodium/crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c', 'src/libsodium/crypto_auth/crypto_auth.c', 'src/libsodium/crypto_auth/hmacsha256/auth_hmacsha256.c', 'src/libsodium/crypto_auth/hmacsha512/auth_hmacsha512.c', @@ -145,6 +150,7 @@ libsodium_base_src = [ 'src/libsodium/crypto_core/hsalsa20/ref2/core_hsalsa20_ref2.c', 'src/libsodium/crypto_core/hsalsa20/core_hsalsa20.c', 'src/libsodium/crypto_core/salsa/ref/core_salsa_ref.c', + 'src/libsodium/crypto_core/softaes/softaes.c', 'src/libsodium/crypto_generichash/crypto_generichash.c', 'src/libsodium/crypto_generichash/blake2b/generichash_blake2.c', 'src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ref.c', @@ -157,6 +163,8 @@ libsodium_base_src = [ 'src/libsodium/crypto_hash/sha512/cp/hash_sha512_cp.c', 'src/libsodium/crypto_kdf/blake2b/kdf_blake2b.c', 'src/libsodium/crypto_kdf/crypto_kdf.c', + 'src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha256.c', + 'src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha512.c', 'src/libsodium/crypto_kx/crypto_kx.c', 'src/libsodium/crypto_onetimeauth/crypto_onetimeauth.c', 'src/libsodium/crypto_onetimeauth/poly1305/onetimeauth_poly1305.c', @@ -190,7 +198,7 @@ libsodium_base_src = [ 'src/libsodium/crypto_stream/salsa20/stream_salsa20.c', 'src/libsodium/crypto_stream/salsa20/ref/salsa20_ref.c', 'src/libsodium/crypto_stream/xsalsa20/stream_xsalsa20.c', - 'src/libsodium/crypto_verify/sodium/verify.c', + 'src/libsodium/crypto_verify/verify.c', 'src/libsodium/randombytes/randombytes.c', 'src/libsodium/randombytes/sysrandom/randombytes_sysrandom.c', 'src/libsodium/sodium/codecs.c', @@ -210,8 +218,6 @@ libsodium_avx_src = [ 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_namespace.h', 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c', 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder.h', - 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base.h', - 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h', 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_namespace.h', 'src/libsodium/crypto_scalarmult/curve25519/sandy2x/sandy2x.S', ] diff --git a/subprojects/libsodium/msvc-scripts/Makefile.am b/subprojects/libsodium/msvc-scripts/Makefile.am @@ -1,4 +0,0 @@ -EXTRA_DIST = \ - process.bat \ - rep.vbs \ - sodium.props diff --git a/subprojects/libsodium/msvc-scripts/Makefile.in b/subprojects/libsodium/msvc-scripts/Makefile.in @@ -1,492 +0,0 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994-2018 Free Software Foundation, Inc. - -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ -VPATH = @srcdir@ -am__is_gnu_make = { \ - if test -z '$(MAKELEVEL)'; then \ - false; \ - elif test -n '$(MAKE_HOST)'; then \ - true; \ - elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ - true; \ - else \ - false; \ - fi; \ -} -am__make_running_with_option = \ - case $${target_option-} in \ - ?) ;; \ - *) echo "am__make_running_with_option: internal error: invalid" \ - "target option '$${target_option-}' specified" >&2; \ - exit 1;; \ - esac; \ - has_opt=no; \ - sane_makeflags=$$MAKEFLAGS; \ - if $(am__is_gnu_make); then \ - sane_makeflags=$$MFLAGS; \ - else \ - case $$MAKEFLAGS in \ - *\\[\ \ ]*) \ - bs=\\; \ - sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ - | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ - esac; \ - fi; \ - skip_next=no; \ - strip_trailopt () \ - { \ - flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ - }; \ - for flg in $$sane_makeflags; do \ - test $$skip_next = yes && { skip_next=no; continue; }; \ - case $$flg in \ - *=*|--*) continue;; \ - -*I) strip_trailopt 'I'; skip_next=yes;; \ - -*I?*) strip_trailopt 'I';; \ - -*O) strip_trailopt 'O'; skip_next=yes;; \ - -*O?*) strip_trailopt 'O';; \ - -*l) strip_trailopt 'l'; skip_next=yes;; \ - -*l?*) strip_trailopt 'l';; \ - -[dEDm]) skip_next=yes;; \ - -[JT]) skip_next=yes;; \ - esac; \ - case $$flg in \ - *$$target_option*) has_opt=yes; break;; \ - esac; \ - done; \ - test $$has_opt = yes -am__make_dryrun = (target_option=n; $(am__make_running_with_option)) -am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) -pkgdatadir = $(datadir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkglibexecdir = $(libexecdir)/@PACKAGE@ -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -build_triplet = @build@ -host_triplet = @host@ -subdir = msvc-scripts -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ - $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ - $(top_srcdir)/m4/ax_check_compile_flag.m4 \ - $(top_srcdir)/m4/ax_check_define.m4 \ - $(top_srcdir)/m4/ax_check_link_flag.m4 \ - $(top_srcdir)/m4/ax_pthread.m4 $(top_srcdir)/m4/ax_tls.m4 \ - $(top_srcdir)/m4/ax_valgrind_check.m4 \ - $(top_srcdir)/m4/ld-output-def.m4 $(top_srcdir)/m4/libtool.m4 \ - $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ - $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ - $(top_srcdir)/configure.ac -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) -mkinstalldirs = $(install_sh) -d -CONFIG_CLEAN_FILES = -CONFIG_CLEAN_VPATH_FILES = -AM_V_P = $(am__v_P_@AM_V@) -am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) -am__v_P_0 = false -am__v_P_1 = : -AM_V_GEN = $(am__v_GEN_@AM_V@) -am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) -am__v_GEN_0 = @echo " GEN " $@; -am__v_GEN_1 = -AM_V_at = $(am__v_at_@AM_V@) -am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) -am__v_at_0 = @ -am__v_at_1 = -SOURCES = -DIST_SOURCES = -am__can_run_installinfo = \ - case $$AM_UPDATE_INFO_DIR in \ - n|no|NO) false;; \ - *) (install-info --version) >/dev/null 2>&1;; \ - esac -am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) -am__DIST_COMMON = $(srcdir)/Makefile.in -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -ALLOCA = @ALLOCA@ -AMTAR = @AMTAR@ -AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ -AR = @AR@ -AS = @AS@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -CC = @CC@ -CCAS = @CCAS@ -CCASDEPMODE = @CCASDEPMODE@ -CCASFLAGS = @CCASFLAGS@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CFLAGS_AESNI = @CFLAGS_AESNI@ -CFLAGS_AVX = @CFLAGS_AVX@ -CFLAGS_AVX2 = @CFLAGS_AVX2@ -CFLAGS_AVX512F = @CFLAGS_AVX512F@ -CFLAGS_MMX = @CFLAGS_MMX@ -CFLAGS_PCLMUL = @CFLAGS_PCLMUL@ -CFLAGS_RDRAND = @CFLAGS_RDRAND@ -CFLAGS_SSE2 = @CFLAGS_SSE2@ -CFLAGS_SSE3 = @CFLAGS_SSE3@ -CFLAGS_SSE41 = @CFLAGS_SSE41@ -CFLAGS_SSSE3 = @CFLAGS_SSSE3@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CWFLAGS = @CWFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DLLTOOL = @DLLTOOL@ -DLL_VERSION = @DLL_VERSION@ -DSYMUTIL = @DSYMUTIL@ -DUMPBIN = @DUMPBIN@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ -ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ -ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ -ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ -EXEEXT = @EXEEXT@ -FGREP = @FGREP@ -GREP = @GREP@ -HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ -HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ -HAVE_CPUID_V = @HAVE_CPUID_V@ -HAVE_TI_MODE_V = @HAVE_TI_MODE_V@ -INSTALL = @INSTALL@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LIBTOOL = @LIBTOOL@ -LIBTOOL_DEPS = @LIBTOOL_DEPS@ -LIBTOOL_EXTRA_FLAGS = @LIBTOOL_EXTRA_FLAGS@ -LIPO = @LIPO@ -LN_S = @LN_S@ -LTLIBOBJS = @LTLIBOBJS@ -LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ -MAINT = @MAINT@ -MAKEINFO = @MAKEINFO@ -MANIFEST_TOOL = @MANIFEST_TOOL@ -MKDIR_P = @MKDIR_P@ -NM = @NM@ -NMEDIT = @NMEDIT@ -OBJDUMP = @OBJDUMP@ -OBJEXT = @OBJEXT@ -OTOOL = @OTOOL@ -OTOOL64 = @OTOOL64@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_URL = @PACKAGE_URL@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ -PTHREAD_CC = @PTHREAD_CC@ -PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ -PTHREAD_LIBS = @PTHREAD_LIBS@ -RANLIB = @RANLIB@ -SAFECODE_HOME = @SAFECODE_HOME@ -SED = @SED@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SODIUM_LIBRARY_MINIMAL_DEF = @SODIUM_LIBRARY_MINIMAL_DEF@ -SODIUM_LIBRARY_VERSION = @SODIUM_LIBRARY_VERSION@ -SODIUM_LIBRARY_VERSION_MAJOR = @SODIUM_LIBRARY_VERSION_MAJOR@ -SODIUM_LIBRARY_VERSION_MINOR = @SODIUM_LIBRARY_VERSION_MINOR@ -STRIP = @STRIP@ -TEST_LDFLAGS = @TEST_LDFLAGS@ -VALGRIND = @VALGRIND@ -VALGRIND_ENABLED = @VALGRIND_ENABLED@ -VERSION = @VERSION@ -abs_builddir = @abs_builddir@ -abs_srcdir = @abs_srcdir@ -abs_top_builddir = @abs_top_builddir@ -abs_top_srcdir = @abs_top_srcdir@ -ac_ct_AR = @ac_ct_AR@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -ax_pthread_config = @ax_pthread_config@ -bindir = @bindir@ -build = @build@ -build_alias = @build_alias@ -build_cpu = @build_cpu@ -build_os = @build_os@ -build_vendor = @build_vendor@ -builddir = @builddir@ -datadir = @datadir@ -datarootdir = @datarootdir@ -docdir = @docdir@ -dvidir = @dvidir@ -exec_prefix = @exec_prefix@ -host = @host@ -host_alias = @host_alias@ -host_cpu = @host_cpu@ -host_os = @host_os@ -host_vendor = @host_vendor@ -htmldir = @htmldir@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localedir = @localedir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -pdfdir = @pdfdir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -psdir = @psdir@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -srcdir = @srcdir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -top_build_prefix = @top_build_prefix@ -top_builddir = @top_builddir@ -top_srcdir = @top_srcdir@ -valgrind_enabled_tools = @valgrind_enabled_tools@ -valgrind_tools = @valgrind_tools@ -EXTRA_DIST = \ - process.bat \ - rep.vbs \ - sodium.props - -all: all-am - -.SUFFIXES: -$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ - && { if test -f $@; then exit 0; else break; fi; }; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign msvc-scripts/Makefile'; \ - $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --foreign msvc-scripts/Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(am__aclocal_m4_deps): - -mostlyclean-libtool: - -rm -f *.lo - -clean-libtool: - -rm -rf .libs _libs -tags TAGS: - -ctags CTAGS: - -cscope cscopelist: - - -distdir: $(BUILT_SOURCES) - $(MAKE) $(AM_MAKEFLAGS) distdir-am - -distdir-am: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ - list='$(DISTFILES)'; \ - dist_files=`for file in $$list; do echo $$file; done | \ - sed -e "s|^$$srcdirstrip/||;t" \ - -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ - case $$dist_files in \ - */*) $(MKDIR_P) `echo "$$dist_files" | \ - sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ - sort -u` ;; \ - esac; \ - for file in $$dist_files; do \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - if test -d $$d/$$file; then \ - dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test -d "$(distdir)/$$file"; then \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ - find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ - fi; \ - cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ - else \ - test -f "$(distdir)/$$file" \ - || cp -p $$d/$$file "$(distdir)/$$file" \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - if test -z '$(STRIP)'; then \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - install; \ - else \ - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ - fi -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -clean: clean-am - -clean-am: clean-generic clean-libtool mostlyclean-am - -distclean: distclean-am - -rm -f Makefile -distclean-am: clean-am distclean-generic - -dvi: dvi-am - -dvi-am: - -html: html-am - -html-am: - -info: info-am - -info-am: - -install-data-am: - -install-dvi: install-dvi-am - -install-dvi-am: - -install-exec-am: - -install-html: install-html-am - -install-html-am: - -install-info: install-info-am - -install-info-am: - -install-man: - -install-pdf: install-pdf-am - -install-pdf-am: - -install-ps: install-ps-am - -install-ps-am: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-generic mostlyclean-libtool - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: - -.MAKE: install-am install-strip - -.PHONY: all all-am check check-am clean clean-generic clean-libtool \ - cscopelist-am ctags-am distclean distclean-generic \ - distclean-libtool distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ - install-dvi-am install-exec install-exec-am install-html \ - install-html-am install-info install-info-am install-man \ - install-pdf install-pdf-am install-ps install-ps-am \ - install-strip installcheck installcheck-am installdirs \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ - tags-am uninstall uninstall-am - -.PRECIOUS: Makefile - - -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/subprojects/libsodium/msvc-scripts/process.bat b/subprojects/libsodium/msvc-scripts/process.bat @@ -1,5 +0,0 @@ -cscript msvc-scripts/rep.vbs //Nologo s/@VERSION@/1.0.18/ < src\libsodium\include\sodium\version.h.in > tmp -cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_VERSION_MAJOR@/10/ < tmp > tmp2 -cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_VERSION_MINOR@/3/ < tmp2 > tmp3 -cscript msvc-scripts/rep.vbs //Nologo s/@SODIUM_LIBRARY_MINIMAL_DEF@// < tmp3 > src\libsodium\include\sodium\version.h -del tmp tmp2 tmp3 diff --git a/subprojects/libsodium/msvc-scripts/sodium.props b/subprojects/libsodium/msvc-scripts/sodium.props @@ -1,28 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> - <ImportGroup Label="PropertySheets" /> - <PropertyGroup Label="UserMacros" /> - <PropertyGroup /> - <ItemDefinitionGroup> - <ClCompile> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> - <MultiProcessorCompilation>true</MultiProcessorCompilation> - <PreprocessorDefinitions>UNICODE;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <PreprocessorDefinitions>NATIVE_LITTLE_ENDIAN=1;%(PreprocessorDefinitions)</PreprocessorDefinitions> - <PreprocessorDefinitions>inline=__inline;%(PreprocessorDefinitions)</PreprocessorDefinitions> - </ClCompile> - <PreBuildEvent> - <Command>"$(SolutionDir)/msvc-scripts/process.bat"</Command> - </PreBuildEvent> - <PreBuildEvent> - <Message>Process .in files</Message> - </PreBuildEvent> - <PostBuildEvent> - <Command>"$(SolutionDir)/test/default/wintest.bat" $(Configuration) $(Platform)</Command> - </PostBuildEvent> - <PostBuildEvent> - <Message>Run the test suite</Message> - </PostBuildEvent> - </ItemDefinitionGroup> - <ItemGroup /> -</Project> diff --git a/subprojects/libsodium/packaging/dotnet-core/.gitignore b/subprojects/libsodium/packaging/dotnet-core/.gitignore @@ -1,5 +0,0 @@ -build -cache -temp -Makefile -!recipes/* diff --git a/subprojects/libsodium/packaging/dotnet-core/README.md b/subprojects/libsodium/packaging/dotnet-core/README.md @@ -1,59 +0,0 @@ -This directory contains scripts and files to package libsodium for .NET Core. - -*Note:* The NuGet package is intended for the implementation of language -bindings such as [NSec](https://github.com/ektrah/nsec). It does not provide a -.NET API itself. - -In .NET Core, it is customary to provide pre-compiled binaries for all platforms -as NuGet packages. The purpose of the `prepare.py` script in this directory is -to generate a `Makefile` that downloads and builds libsodium binaries for a -number of platforms and assembles them in a NuGet package that can be uploaded -to [nuget.org](https://nuget.org/). - -* For Windows, binaries are obtained from - [download.libsodium.org](https://download.libsodium.org/libsodium/releases/). -* For macOS, binaries are extracted from the - [Homebrew libsodium bottle](https://bintray.com/homebrew/bottles/libsodium). -* For Linux, libsodium is compiled in Docker containers. - -See `prepare.py` for the complete list of supported platforms. - -The metadata for the NuGet package is located in `libsodium.props`. - - -**Versioning** - -Version numbers for the packages for .NET Core consist of three components: - -* *libsodium version* - The libsodium version is in the format `X.Y.Z`. -* *package revision* - It may be necessary to release more than one package for a libsodium version, - e.g., when adding support for a new platform or if a release contains a broken - binary. In this case, a package revision number is added as a fourth part to - the libsodium version, starting at `1`. For example, `1.0.18` is the initial - release of the package for libsodium 1.0.18 and `1.0.18.5` is the fifth - revision (sixth release) of that package. -* *pre-release label* - If a package is a pre-release, a label is appended to the version number in - `-preview-##` format where `##` is the number of the pre-release, starting at - `01`. For example, `1.0.18-preview-01` is the first pre-release of the package - for libsodium 1.0.18 and `1.0.18.5-preview-02` the second pre-release of the - fifth revision of the package for libsodium 1.0.18. - - -**Making a release** - -1. Update any existing Docker images. -2. Run `python3 prepare.py <version>` to generate the `Makefile`, where - `<version>` is the package version number in the format described above. -3. Take a look at the generated `Makefile`. It uses `sudo` a few times. -4. Run `make` to download and build the binaries and create the NuGet package. - You may need to install `docker`, `make`, `curl`, `tar` and `unzip` first. -5. Grab a cup of coffee. Downloading the Docker images and compiling the Linux - binaries takes a while. When done, the NuGet package is output as a `.nupkg` - file in the `build` directory. -6. Run `make test` to perform a quick test of the NuGet package. Verify that - everything else in the `.nupkg` file is in place. -7. Publish the release by uploading the `.nupkg` file to - [nuget.org](https://nuget.org/). diff --git a/subprojects/libsodium/packaging/dotnet-core/libsodium.pkgproj b/subprojects/libsodium/packaging/dotnet-core/libsodium.pkgproj @@ -0,0 +1,49 @@ +<Project Sdk="Microsoft.NET.Sdk"> + + <PropertyGroup> + <TargetFramework>netstandard2.0</TargetFramework> + <NoBuild>true</NoBuild> + <IncludeBuildOutput>false</IncludeBuildOutput> + <SuppressDependenciesWhenPacking>true</SuppressDependenciesWhenPacking> + </PropertyGroup> + + <PropertyGroup> + <PackageId>libsodium</PackageId> + <Version>1.0.20.1</Version> + <Authors>Frank Denis</Authors> + <Description>Internal implementation package not meant for direct consumption. Please do not reference directly.</Description> + <Copyright>© $([System.DateTime]::UtcNow.ToString(yyyy)) Frank Denis</Copyright> + <PackageLicenseExpression>ISC</PackageLicenseExpression> + <PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance> + <PackageProjectUrl>https://libsodium.org/</PackageProjectUrl> + <RepositoryUrl>https://github.com/jedisct1/libsodium.git</RepositoryUrl> + <RepositoryType>git</RepositoryType> + <MinClientVersion>4.0</MinClientVersion> + </PropertyGroup> + + <ItemGroup> + <Content Include="LICENSE" PackagePath="" /> + <Content Include="AUTHORS" PackagePath="" /> + <Content Include="ChangeLog" PackagePath="" /> + <Content Include="runtimes/win-x64/native/libsodium.dll" PackagePath="runtimes/win-x64/native/" /> + <Content Include="runtimes/win-x86/native/libsodium.dll" PackagePath="runtimes/win-x86/native/" /> + <Content Include="runtimes/win-arm64/native/libsodium.dll" PackagePath="runtimes/win-arm64/native/" /> + <Content Include="runtimes/linux-x64/native/libsodium.so" PackagePath="runtimes/linux-x64/native/" /> + <Content Include="runtimes/linux-arm/native/libsodium.so" PackagePath="runtimes/linux-arm/native/" /> + <Content Include="runtimes/linux-arm64/native/libsodium.so" PackagePath="runtimes/linux-arm64/native/" /> + <Content Include="runtimes/linux-musl-x64/native/libsodium.so" PackagePath="runtimes/linux-musl-x64/native/" /> + <Content Include="runtimes/linux-musl-arm/native/libsodium.so" PackagePath="runtimes/linux-musl-arm/native/" /> + <Content Include="runtimes/linux-musl-arm64/native/libsodium.so" PackagePath="runtimes/linux-musl-arm64/native/" /> + <Content Include="runtimes/osx-x64/native/libsodium.dylib" PackagePath="runtimes/osx-x64/native/" /> + <Content Include="runtimes/osx-arm64/native/libsodium.dylib" PackagePath="runtimes/osx-arm64/native/" /> + <Content Include="runtimes/ios-arm64/native/libsodium.a" PackagePath="runtimes/ios-arm64/native/" /> + <Content Include="runtimes/tvos-arm64/native/libsodium.a" PackagePath="runtimes/tvos-arm64/native/" /> + <Content Include="runtimes/maccatalyst-x64/native/libsodium.a" PackagePath="runtimes/maccatalyst-x64/native/" /> + <Content Include="runtimes/maccatalyst-arm64/native/libsodium.a" PackagePath="runtimes/maccatalyst-arm64/native/" /> + <Content Include="runtimes/android-arm64/native/libsodium.so" PackagePath="runtimes/android-arm64/native/" /> + <Content Include="runtimes/android-arm/native/libsodium.so" PackagePath="runtimes/android-arm/native/" /> + <Content Include="runtimes/android-x64/native/libsodium.so" PackagePath="runtimes/android-x64/native/" /> + <Content Include="runtimes/android-x86/native/libsodium.so" PackagePath="runtimes/android-x86/native/" /> + </ItemGroup> + +</Project> diff --git a/subprojects/libsodium/packaging/dotnet-core/libsodium.props b/subprojects/libsodium/packaging/dotnet-core/libsodium.props @@ -1,36 +0,0 @@ -<?xml version="1.0"?> -<Project> - - <PropertyGroup> - <TargetFramework>netstandard1.1</TargetFramework> - <DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences> - <NoBuild>true</NoBuild> - <IncludeBuildOutput>false</IncludeBuildOutput> - <PackageOutputPath>$(MSBuildProjectDirectory)</PackageOutputPath> - <ProjectFileToPack>$(MSBuildProjectFullPath)</ProjectFileToPack> - </PropertyGroup> - - <PropertyGroup> - <PackageId>libsodium</PackageId> - <Version><!-- set by prepare.py --></Version> - <Authors>Frank Denis</Authors> - <Description>Internal implementation package not meant for direct consumption. Please do not reference directly.</Description> - <Copyright>© 2013-2019 Frank Denis</Copyright> - <PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance> - <PackageLicenseUrl>https://raw.githubusercontent.com/jedisct1/libsodium/master/LICENSE</PackageLicenseUrl> - <PackageProjectUrl>https://libsodium.org/</PackageProjectUrl> - <MinClientVersion>4.0</MinClientVersion> - </PropertyGroup> - - <ItemGroup> - <PackageReference Include="Microsoft.NETCore.Platforms" Version="1.0.1" /> - </ItemGroup> - - <ItemGroup> - <Content Include="LICENSE" PackagePath="" /> - <Content Include="AUTHORS" PackagePath="" /> - <Content Include="ChangeLog" PackagePath="" /> - <Content Include="runtimes\**\*.*" PackagePath="runtimes\" /> - </ItemGroup> - -</Project> diff --git a/subprojects/libsodium/packaging/dotnet-core/prepare.py b/subprojects/libsodium/packaging/dotnet-core/prepare.py @@ -1,302 +0,0 @@ -#!/usr/bin/env python3 - -import os.path -import re -import sys - -WINDOWS = [ - # --------------------- ----------------- # - # Runtime ID Platform # - # --------------------- ----------------- # - ("win-x64", "x64"), - ("win-x86", "Win32"), - # --------------------- ----------------- # -] - -MACOS = [ - # --------------------- ----------------- # - # Runtime ID Codename # - # --------------------- ----------------- # - ("osx-x64", "mojave"), - # --------------------- ----------------- # -] - -LINUX = [ - # --------------------- ----------------- # - # Runtime ID Docker Image # - # --------------------- ----------------- # - ("linux-x64", "debian:stretch"), - # --------------------- ----------------- # -] - -EXTRAS = ["LICENSE", "AUTHORS", "ChangeLog"] - -PROPSFILE = "libsodium.props" -MAKEFILE = "Makefile" -BUILDDIR = "build" -CACHEDIR = "cache" -TEMPDIR = "temp" - -PACKAGE = "libsodium" -LIBRARY = "libsodium" - -DOCKER = "sudo docker" - - -class Version: - def __init__(self, libsodium_version, package_version): - self.libsodium_version = libsodium_version - self.package_version = package_version - - self.builddir = os.path.join(BUILDDIR, libsodium_version) - self.tempdir = os.path.join(TEMPDIR, libsodium_version) - self.projfile = os.path.join( - self.builddir, "{0}.{1}.pkgproj".format(PACKAGE, package_version) - ) - self.propsfile = os.path.join(self.builddir, "{0}.props".format(PACKAGE)) - self.pkgfile = os.path.join( - BUILDDIR, "{0}.{1}.nupkg".format(PACKAGE, package_version) - ) - - -class WindowsItem: - def __init__(self, version, rid, platform): - self.url = "https://download.libsodium.org/libsodium/releases/libsodium-{0}-stable-msvc.zip".format( - version.libsodium_version - ) - self.cachefile = os.path.join(CACHEDIR, re.sub(r"[^A-Za-z0-9.]", "-", self.url)) - self.packfile = os.path.join( - version.builddir, "runtimes", rid, "native", LIBRARY + ".dll" - ) - self.itemfile = "{0}/Release/v140/dynamic/libsodium.dll".format(platform) - self.tempdir = os.path.join(version.tempdir, rid) - self.tempfile = os.path.join(self.tempdir, os.path.normpath(self.itemfile)) - - def make(self, f): - f.write("\n") - f.write("{0}: {1}\n".format(self.packfile, self.tempfile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcp -f $< $@\n") - f.write("\n") - f.write("{0}: {1}\n".format(self.tempfile, self.cachefile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\tcd {0} && unzip -q -DD -o {1} '{2}'\n".format( - self.tempdir, - os.path.relpath(self.cachefile, self.tempdir), - self.itemfile, - ) - ) - - -class MacOSItem: - def __init__(self, version, rid, codename): - self.url = "https://bintray.com/homebrew/bottles/download_file?file_path=libsodium-{0}.{1}.bottle.tar.gz".format( - version.libsodium_version, codename - ) - self.cachefile = os.path.join(CACHEDIR, re.sub(r"[^A-Za-z0-9.]", "-", self.url)) - self.packfile = os.path.join( - version.builddir, "runtimes", rid, "native", LIBRARY + ".dylib" - ) - self.itemfile = "libsodium/{0}/lib/libsodium.dylib".format( - version.libsodium_version - ) - self.tempdir = os.path.join(version.tempdir, rid) - self.tempfile = os.path.join(self.tempdir, os.path.normpath(self.itemfile)) - - def make(self, f): - f.write("\n") - f.write("{0}: {1}\n".format(self.packfile, self.tempfile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcp -f $< $@\n") - f.write("\n") - f.write("{0}: {1}\n".format(self.tempfile, self.cachefile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\tcd {0} && tar xzmf {1} '{2}'\n".format( - self.tempdir, - os.path.relpath(self.cachefile, self.tempdir), - os.path.dirname(self.itemfile), - ) - ) - - -class LinuxItem: - def __init__(self, version, rid, docker_image): - self.url = "https://download.libsodium.org/libsodium/releases/libsodium-{0}.tar.gz".format( - version.libsodium_version - ) - self.cachefile = os.path.join(CACHEDIR, re.sub(r"[^A-Za-z0-9.]", "-", self.url)) - self.packfile = os.path.join( - version.builddir, "runtimes", rid, "native", LIBRARY + ".so" - ) - self.tempdir = os.path.join(version.tempdir, rid) - self.tempfile = os.path.join(self.tempdir, "libsodium.so") - self.docker_image = docker_image - self.recipe = rid - - def make(self, f): - recipe = self.recipe - while not os.path.exists(os.path.join("recipes", recipe)): - m = re.fullmatch(r"([^.-]+)((([.][^.-]+)*)[.][^.-]+)?([-].*)?", recipe) - if m.group(5) is None: - recipe = "build" - break - elif m.group(2) is None: - recipe = m.group(1) - else: - recipe = m.group(1) + m.group(3) + m.group(5) - - f.write("\n") - f.write("{0}: {1}\n".format(self.packfile, self.tempfile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcp -f $< $@\n") - f.write("\n") - f.write("{0}: {1}\n".format(self.tempfile, self.cachefile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\t{0} run --rm ".format(DOCKER) - + "-v $(abspath recipes):/io/recipes " - + "-v $(abspath $<):/io/libsodium.tar.gz " - + "-v $(abspath $(dir $@)):/io/output " - + "{0} sh -x -e /io/recipes/{1}\n".format(self.docker_image, recipe) - ) - - -class ExtraItem: - def __init__(self, version, filename): - self.url = "https://download.libsodium.org/libsodium/releases/libsodium-{0}.tar.gz".format( - version.libsodium_version - ) - self.cachefile = os.path.join(CACHEDIR, re.sub(r"[^A-Za-z0-9.]", "-", self.url)) - self.packfile = os.path.join(version.builddir, filename) - self.itemfile = "libsodium-{0}/{1}".format(version.libsodium_version, filename) - self.tempdir = os.path.join(version.tempdir, "extras") - self.tempfile = os.path.join(self.tempdir, os.path.normpath(self.itemfile)) - - def make(self, f): - f.write("\n") - f.write("{0}: {1}\n".format(self.packfile, self.tempfile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcp -f $< $@\n") - f.write("\n") - f.write("{0}: {1}\n".format(self.tempfile, self.cachefile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\tcd {0} && tar xzmf {1} '{2}'\n".format( - self.tempdir, - os.path.relpath(self.cachefile, self.tempdir), - self.itemfile, - ) - ) - - -def main(args): - m = ( - re.fullmatch(r"((\d+\.\d+\.\d+)(\.\d+)?)(?:-(\w+(?:[_.-]\w+)*))?", args[1]) - if len(args) == 2 - else None - ) - - if m is None: - print("Usage:") - print(" python3 prepare.py <version>") - print() - print("Examples:") - print(" python3 prepare.py 1.0.18-preview-01") - print(" python3 prepare.py 1.0.18-preview-02") - print(" python3 prepare.py 1.0.18-preview-03") - print(" python3 prepare.py 1.0.18") - print(" python3 prepare.py 1.0.18.1-preview-01") - print(" python3 prepare.py 1.0.18.1") - print(" python3 prepare.py 1.0.18.2") - return 1 - - version = Version(m.group(2), m.group(0)) - - items = ( - [WindowsItem(version, rid, platform) for (rid, platform) in WINDOWS] - + [MacOSItem(version, rid, codename) for (rid, codename) in MACOS] - + [LinuxItem(version, rid, docker_image) for (rid, docker_image) in LINUX] - + [ExtraItem(version, filename) for filename in EXTRAS] - ) - - downloads = {item.cachefile: item.url for item in items} - - with open(MAKEFILE, "w") as f: - f.write("all: {0}\n".format(version.pkgfile)) - - for download in sorted(downloads): - f.write("\n") - f.write("{0}:\n".format(download)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcurl -f#Lo $@ '{0}'\n".format(downloads[download])) - - for item in items: - item.make(f) - - f.write("\n") - f.write("{0}: {1}\n".format(version.propsfile, PROPSFILE)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write("\tcp -f $< $@\n") - - f.write("\n") - f.write("{0}: {1}\n".format(version.projfile, version.propsfile)) - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\techo '" - + '<Project Sdk="Microsoft.NET.Sdk">' - + '<Import Project="{0}" />'.format( - os.path.relpath(version.propsfile, os.path.dirname(version.projfile)) - ) - + "<PropertyGroup>" - + "<Version>{0}</Version>".format(version.package_version) - + "</PropertyGroup>" - + "</Project>' > $@\n" - ) - - f.write("\n") - f.write("{0}:".format(version.pkgfile)) - f.write(" \\\n\t\t{0}".format(version.projfile)) - f.write(" \\\n\t\t{0}".format(version.propsfile)) - for item in items: - f.write(" \\\n\t\t{0}".format(item.packfile)) - f.write("\n") - f.write("\t@mkdir -p $(dir $@)\n") - f.write( - "\t{0} run --rm ".format(DOCKER) - + "-v $(abspath recipes):/io/recipes " - + "-v $(abspath $(dir $<)):/io/input " - + "-v $(abspath $(dir $@)):/io/output " - + "{0} sh -x -e /io/recipes/{1} {2}\n".format( - "microsoft/dotnet:2.0-sdk", - "pack", - os.path.relpath(version.projfile, version.builddir), - ) - ) - - f.write("\n") - f.write("test: {0}\n".format(version.pkgfile)) - f.write( - "\t{0} run --rm ".format(DOCKER) - + "-v $(abspath recipes):/io/recipes " - + "-v $(abspath $(dir $<)):/io/packages " - + '{0} sh -x -e /io/recipes/{1} "{2}"\n'.format( - "microsoft/dotnet:2.0-sdk", "test", version.package_version - ) - ) - - print( - "prepared", - MAKEFILE, - "to make", - version.pkgfile, - "for libsodium", - version.libsodium_version, - ) - return 0 - - -if __name__ == "__main__": - sys.exit(main(sys.argv)) - diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/alpine-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/alpine-x64 @@ -1,3 +0,0 @@ -apk add --update alpine-sdk - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/build b/subprojects/libsodium/packaging/dotnet-core/recipes/build @@ -1,9 +0,0 @@ -cd ~ -tar xzf /io/libsodium.tar.gz -cd libsodium-* -./configure -make -make check -make install -strip --strip-all /usr/local/lib/libsodium.so -cp /usr/local/lib/libsodium.so /io/output diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/centos-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/centos-x64 @@ -1,3 +0,0 @@ -yum install -y binutils gcc make tar - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/debian-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/debian-x64 @@ -1,4 +0,0 @@ -apt-get update -apt-get install -y --no-install-recommends build-essential - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/fedora-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/fedora-x64 @@ -1,3 +0,0 @@ -dnf install -y binutils gcc make tar - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/linux-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/linux-x64 @@ -1,4 +0,0 @@ -apt-get update -apt-get install -y --no-install-recommends build-essential - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/opensuse-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/opensuse-x64 @@ -1,3 +0,0 @@ -zypper install -y --no-recommends -n binutils gcc make tar - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/pack b/subprojects/libsodium/packaging/dotnet-core/recipes/pack @@ -1,5 +0,0 @@ -cp -r /io/input ~/build -cd ~/build -dotnet restore $1 -dotnet pack $1 -cp *.nupkg /io/output diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/test b/subprojects/libsodium/packaging/dotnet-core/recipes/test @@ -1,27 +0,0 @@ -TEST_PROGRAM='using System; -using System.Runtime.InteropServices; - -static class Program -{ - [DllImport("libsodium")] - static extern int sodium_init(); - - static int Main() - { - int error = sodium_init(); - Console.WriteLine(error == 0 - ? "ok" - : "error: sodium_init() returned {0}", error); - return error == 0 ? 0 : 1; - } -} -' - -dotnet --info -cd ~ -dotnet new console --name Test -cd Test -echo "$TEST_PROGRAM" > Program.cs -dotnet add package libsodium --version $1 --source /io/packages -dotnet restore -dotnet run diff --git a/subprojects/libsodium/packaging/dotnet-core/recipes/ubuntu-x64 b/subprojects/libsodium/packaging/dotnet-core/recipes/ubuntu-x64 @@ -1,4 +0,0 @@ -apt-get update -apt-get install -y --no-install-recommends build-essential - -. $(dirname $0)/build diff --git a/subprojects/libsodium/packaging/dotnet-core/test.cs b/subprojects/libsodium/packaging/dotnet-core/test.cs @@ -0,0 +1,43 @@ +using System; +using System.Runtime.InteropServices; + +internal static class Program +{ + internal static int Main() + { + Console.WriteLine("sodium_version_string: {0}", Marshal.PtrToStringAnsi(sodium_version_string())); + Console.WriteLine("sodium_library_version_major: {0}", sodium_library_version_major()); + Console.WriteLine("sodium_library_version_minor: {0}", sodium_library_version_minor()); + Console.WriteLine("sodium_library_minimal: {0}", sodium_library_minimal()); + int error = sodium_init(); + Console.WriteLine("sodium_init: {0}", error); + if (error == 0) + { + randombytes_buf(out ulong buf, (UIntPtr)sizeof(ulong)); + Console.WriteLine("randombytes_buf: 0x'{0:X8}'", buf); + Console.WriteLine("crypto_aead_aes256gcm_is_available: {0}", crypto_aead_aes256gcm_is_available()); + } + return error == 0 ? 0 : 1; + } + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern int crypto_aead_aes256gcm_is_available(); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern void randombytes_buf(out ulong buf, UIntPtr size); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern int sodium_init(); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern int sodium_library_version_major(); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern int sodium_library_minimal(); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern int sodium_library_version_minor(); + + [DllImport("libsodium", CallingConvention = CallingConvention.Cdecl)] + private static extern IntPtr sodium_version_string(); +} diff --git a/subprojects/libsodium/packaging/nuget/package.config b/subprojects/libsodium/packaging/nuget/package.config @@ -1,4 +1,4 @@ <?xml version="1.0" encoding="utf-8"?> <!-- These values are populated into the package.gsl templates by package.bat. --> <!-- The target attribute controls path and file name only, id controls package naming. --> -<package id="libsodium_vc120" target="libsodium" version = "1.0.18.0" pathversion="1_0_18_0" platformtoolset="v120" /> +<package id="libsodium_vc120" target="libsodium" version = "1.0.20.1" pathversion="1_0_20_1" platformtoolset="v120" /> diff --git a/subprojects/libsodium/regen-msvc/libsodium.vcxproj.tpl b/subprojects/libsodium/regen-msvc/libsodium.vcxproj.tpl @@ -1,59 +1,13 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup Label="Globals"> <ProjectGuid>{A185B162-6CB6-4502-B03F-B56F7699A8D9}</ProjectGuid> <ProjectName>libsodium</ProjectName> <PlatformToolset>{{platform}}</PlatformToolset> </PropertyGroup> <ItemGroup Label="ProjectConfigurations"> - <ProjectConfiguration Include="DebugDLL|Win32"> - <Configuration>DebugDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|Win32"> - <Configuration>ReleaseDLL</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugDLL|x64"> - <Configuration>DebugDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseDLL|x64"> - <Configuration>ReleaseDLL</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|Win32"> - <Configuration>DebugLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|Win32"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLTCG|x64"> - <Configuration>DebugLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLTCG|x64"> - <Configuration>ReleaseLTCG</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLIB|Win32"> - <Configuration>DebugLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|Win32"> - <Configuration>ReleaseLIB</Configuration> - <Platform>Win32</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="DebugLIB|x64"> - <Configuration>DebugLIB</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> - <ProjectConfiguration Include="ReleaseLIB|x64"> - <Configuration>ReleaseLIB</Configuration> - <Platform>x64</Platform> - </ProjectConfiguration> + {{configurations}} </ItemGroup> <PropertyGroup Label="Configuration"> <ConfigurationType Condition="$(Configuration.IndexOf('DLL')) == -1">StaticLibrary</ConfigurationType> @@ -67,16 +21,6 @@ <Import Project="$(ProjectDir)$(ProjectName).props" /> </ImportGroup> <ItemGroup> - <None Include="..\..\..\..\packaging\nuget\package.bat" /> - <None Include="..\..\..\..\packaging\nuget\package.config" /> - <None Include="..\..\..\..\packaging\nuget\package.gsl" /> - <None Include="..\..\..\..\packaging\nuget\package.nuspec" /> - <None Include="..\..\..\..\packaging\nuget\package.targets" /> - </ItemGroup> - <ItemGroup> - <Xml Include="..\..\..\..\packaging\nuget\package.xml" /> - </ItemGroup> - <ItemGroup> {{v1}} </ItemGroup> <ItemGroup> diff --git a/subprojects/libsodium/regen-msvc/regen-msvc.py b/subprojects/libsodium/regen-msvc/regen-msvc.py @@ -9,24 +9,24 @@ dirs = set() tlv1 = "" for file in glob.iglob("src/libsodium/**/*.c", recursive=True): file = file.replace("/", "\\") - tlv1 = tlv1 + ' <ClCompile Include="{}" />\r\n'.format(file) + tlv1 = tlv1 + ' <ClCompile Include="..\\..\\{}" />\r\n'.format(file) tlv2 = "" for file in glob.iglob("src/libsodium/**/*.h", recursive=True): file = file.replace("/", "\\") - tlv2 = tlv2 + ' <ClInclude Include="{}" />\r\n'.format(file) + tlv2 = tlv2 + ' <ClInclude Include="..\\..\\{}" />\r\n'.format(file) tlf1 = "" for file in glob.iglob("src/libsodium/**/*.c", recursive=True): file = file.replace("/", "\\") - tlf1 = tlf1 + ' <ClCompile Include="{}">\r\n'.format(file) + tlf1 = tlf1 + ' <ClCompile Include="..\\..\\{}">\r\n'.format(file) tlf1 = tlf1 + " <Filter>Source Files</Filter>\r\n" tlf1 = tlf1 + " </ClCompile>\r\n" tlf2 = "" for file in glob.iglob("src/libsodium/**/*.h", recursive=True): file = file.replace("/", "\\") - tlf2 = tlf2 + ' <ClInclude Include="{}">\r\n'.format(file) + tlf2 = tlf2 + ' <ClInclude Include="..\\..\\{}">\r\n'.format(file) tlf2 = tlf2 + " <Filter>Header Files</Filter>\r\n" tlf2 = tlf2 + " </ClInclude>\r\n" @@ -77,6 +77,39 @@ for dir in dirs: fd = fd + " </Filter>\r\n" +def get_project_configurations(vs_version): + projconfig = "" + configs = [ + "DebugDLL", + "ReleaseDLL", + "DebugLIB", + "ReleaseLIB", + "DebugLTCG", + "ReleaseLTCG", + ] + platforms = ["Win32", "x64"] + # add arm64 platform only for v142+ toolchain + if vs_version >= 142: + platforms.append("ARM64") + for config in configs: + for platform in platforms: + projconfig = ( + projconfig + + ' <ProjectConfiguration Include="{}|{}">\r\n'.format( + config, platform + ) + ) + projconfig = ( + projconfig + + " <Configuration>{}</Configuration>\r\n".format(config) + ) + projconfig = projconfig + " <Platform>{}</Platform>\r\n".format( + platform + ) + projconfig = projconfig + " </ProjectConfiguration>\r\n" + return projconfig + + def apply_template(tplfile, outfile, sbox): tpl = "" with open(tplfile, "rb") as fd: @@ -105,14 +138,22 @@ sbox = { sd = os.path.dirname(os.path.realpath(__file__)) apply_template( - sd + "/tl_libsodium.vcxproj.filters.tpl", "libsodium.vcxproj.filters", sbox + sd + "/tl_libsodium.vcxproj.filters.tpl", + "ci/appveyor/libsodium.vcxproj.filters", + sbox, ) sbox.update({"platform": "v140"}) -apply_template(sd + "/tl_libsodium.vcxproj.tpl", "libsodium.vcxproj", sbox) +sbox.update({"configurations": get_project_configurations(140)}) +apply_template(sd + "/tl_libsodium.vcxproj.tpl", "ci/appveyor/libsodium.vcxproj", sbox) apply_template( sd + "/libsodium.vcxproj.filters.tpl", + "builds/msvc/vs2022/libsodium/libsodium.vcxproj.filters", + sbox, +) +apply_template( + sd + "/libsodium.vcxproj.filters.tpl", "builds/msvc/vs2019/libsodium/libsodium.vcxproj.filters", sbox, ) @@ -142,7 +183,16 @@ apply_template( sbox, ) +sbox.update({"platform": "v143"}) +sbox.update({"configurations": get_project_configurations(143)}) +apply_template( + sd + "/libsodium.vcxproj.tpl", + "builds/msvc/vs2022/libsodium/libsodium.vcxproj", + sbox, +) + sbox.update({"platform": "v142"}) +sbox.update({"configurations": get_project_configurations(142)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2019/libsodium/libsodium.vcxproj", @@ -150,6 +200,7 @@ apply_template( ) sbox.update({"platform": "v141"}) +sbox.update({"configurations": get_project_configurations(141)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2017/libsodium/libsodium.vcxproj", @@ -157,6 +208,7 @@ apply_template( ) sbox.update({"platform": "v140"}) +sbox.update({"configurations": get_project_configurations(140)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2015/libsodium/libsodium.vcxproj", @@ -164,6 +216,7 @@ apply_template( ) sbox.update({"platform": "v120"}) +sbox.update({"configurations": get_project_configurations(120)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2013/libsodium/libsodium.vcxproj", @@ -171,6 +224,7 @@ apply_template( ) sbox.update({"platform": "v110"}) +sbox.update({"configurations": get_project_configurations(110)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2012/libsodium/libsodium.vcxproj", @@ -178,6 +232,7 @@ apply_template( ) sbox.update({"platform": "v100"}) +sbox.update({"configurations": get_project_configurations(100)}) apply_template( sd + "/libsodium.vcxproj.tpl", "builds/msvc/vs2010/libsodium/libsodium.vcxproj", diff --git a/subprojects/libsodium/regen-msvc/tl_libsodium.vcxproj.tpl b/subprojects/libsodium/regen-msvc/tl_libsodium.vcxproj.tpl @@ -1,5 +1,6 @@ <?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> +<Project DefaultTargets="Build" ToolsVersion="4.0" + xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <ItemGroup Label="ProjectConfigurations"> <ProjectConfiguration Include="DebugDLL|Win32"> <Configuration>DebugDLL</Configuration> @@ -181,7 +182,7 @@ <PreprocessorDefinitions>SODIUM_STATIC;SODIUM_EXPORT=;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> <RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> </ClCompile> <Link> <SubSystem>Console</SubSystem> @@ -197,7 +198,7 @@ <PreprocessorDefinitions>SODIUM_EXPORT=__declspec(dllexport);SODIUM_DLL_EXPORT;WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> <RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <AdditionalIncludeDirectories>$(SolutionDir)..\..\;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> </ClCompile> <Link> <SubSystem>Console</SubSystem> @@ -246,7 +247,7 @@ <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> </ClCompile> <Link> <SubSystem>Console</SubSystem> @@ -267,7 +268,7 @@ <DisableSpecificWarnings>4244;%(DisableSpecificWarnings)</DisableSpecificWarnings> <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary> <FavorSizeOrSpeed>Speed</FavorSizeOrSpeed> - <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include\sodium;$(SolutionDir)src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> + <AdditionalIncludeDirectories>$(SolutionDir);$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include\sodium;$(SolutionDir)..\..\src\libsodium\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> </ClCompile> <Link> <SubSystem>Console</SubSystem> @@ -319,10 +320,10 @@ </ItemGroup> <ItemGroup> {{tlv2}} - <ClInclude Include="builds\msvc\resource.h" /> + <ClInclude Include="..\..\builds\msvc\resource.h" /> </ItemGroup> <ItemGroup> - <ResourceCompile Include="builds\msvc\resource.rc"> + <ResourceCompile Include="..\..\builds\msvc\resource.rc"> </ResourceCompile> </ItemGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> diff --git a/subprojects/libsodium/src/Makefile.in b/subprojects/libsodium/src/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,9 +89,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = src ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -141,6 +145,10 @@ am__recursive_targets = \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -158,8 +166,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -193,7 +199,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -205,6 +210,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -217,6 +223,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -233,8 +241,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -277,6 +287,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -302,8 +313,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -337,11 +350,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -422,6 +440,11 @@ $(am__recursive_targets): if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -575,12 +598,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-recursive + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-recursive + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-recursive + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-recursive + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-recursive + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am @@ -650,10 +693,15 @@ uninstall-am: .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ + check-am check-valgrind-am check-valgrind-drd-am \ + check-valgrind-drd-local check-valgrind-helgrind-am \ + check-valgrind-helgrind-local check-valgrind-local \ + check-valgrind-memcheck-am check-valgrind-memcheck-local \ + check-valgrind-sgcheck-am check-valgrind-sgcheck-local clean \ + clean-generic clean-libtool cscopelist-am ctags ctags-am \ + distclean distclean-generic distclean-libtool distclean-tags \ + distdir dvi dvi-am html html-am info info-am install \ + install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ @@ -668,3 +716,10 @@ uninstall-am: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/src/libsodium/Makefile.am b/subprojects/libsodium/src/libsodium/Makefile.am @@ -2,8 +2,19 @@ lib_LTLIBRARIES = \ libsodium.la libsodium_la_SOURCES = \ - crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c \ - crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c \ + crypto_aead/aegis128l/aead_aegis128l.c \ + crypto_aead/aegis128l/aegis128l_common.h \ + crypto_aead/aegis128l/aegis128l_soft.c \ + crypto_aead/aegis128l/aegis128l_soft.h \ + crypto_aead/aegis128l/implementations.h \ + crypto_aead/aegis256/aead_aegis256.c \ + crypto_aead/aegis256/aegis256_common.h \ + crypto_aead/aegis256/aegis256_soft.c \ + crypto_aead/aegis256/aegis256_soft.h \ + crypto_aead/aegis256/implementations.h \ + crypto_aead/aes256gcm/aead_aes256gcm.c \ + crypto_aead/chacha20poly1305/aead_chacha20poly1305.c \ + crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c \ crypto_auth/crypto_auth.c \ crypto_auth/hmacsha256/auth_hmacsha256.c \ crypto_auth/hmacsha512/auth_hmacsha512.c \ @@ -17,6 +28,7 @@ libsodium_la_SOURCES = \ crypto_core/hsalsa20/ref2/core_hsalsa20_ref2.c \ crypto_core/hsalsa20/core_hsalsa20.c \ crypto_core/salsa/ref/core_salsa_ref.c \ + crypto_core/softaes/softaes.c \ crypto_generichash/crypto_generichash.c \ crypto_generichash/blake2b/generichash_blake2.c \ crypto_generichash/blake2b/ref/blake2.h \ @@ -33,6 +45,8 @@ libsodium_la_SOURCES = \ crypto_hash/sha512/cp/hash_sha512_cp.c \ crypto_kdf/blake2b/kdf_blake2b.c \ crypto_kdf/crypto_kdf.c \ + crypto_kdf/hkdf/kdf_hkdf_sha256.c \ + crypto_kdf/hkdf/kdf_hkdf_sha512.c \ crypto_kx/crypto_kx.c \ crypto_onetimeauth/crypto_onetimeauth.c \ crypto_onetimeauth/poly1305/onetimeauth_poly1305.c \ @@ -81,13 +95,15 @@ libsodium_la_SOURCES = \ crypto_stream/salsa20/stream_salsa20.c \ crypto_stream/salsa20/stream_salsa20.h \ crypto_stream/xsalsa20/stream_xsalsa20.c \ - crypto_verify/sodium/verify.c \ + crypto_verify/verify.c \ + include/sodium/private/asm_cet.h \ include/sodium/private/chacha20_ietf_ext.h \ include/sodium/private/common.h \ include/sodium/private/ed25519_ref10.h \ include/sodium/private/implementations.h \ include/sodium/private/mutex.h \ include/sodium/private/sse2_64_32.h \ + include/sodium/private/softaes.h \ randombytes/randombytes.c \ sodium/codecs.c \ sodium/core.c \ @@ -127,8 +143,7 @@ noinst_HEADERS = \ crypto_scalarmult/curve25519/sandy2x/fe51_mul.S \ crypto_scalarmult/curve25519/sandy2x/fe51_nsquare.S \ crypto_scalarmult/curve25519/sandy2x/fe51_pack.S \ - crypto_scalarmult/curve25519/sandy2x/ladder.S \ - crypto_scalarmult/curve25519/sandy2x/ladder_base.S + crypto_scalarmult/curve25519/sandy2x/ladder.S if HAVE_AVX_ASM libsodium_la_SOURCES += \ @@ -141,8 +156,6 @@ libsodium_la_SOURCES += \ crypto_scalarmult/curve25519/sandy2x/fe51_namespace.h \ crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c \ crypto_scalarmult/curve25519/sandy2x/ladder.h \ - crypto_scalarmult/curve25519/sandy2x/ladder_base.h \ - crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h \ crypto_scalarmult/curve25519/sandy2x/ladder_namespace.h \ crypto_scalarmult/curve25519/sandy2x/sandy2x.S endif @@ -197,8 +210,8 @@ endif SUBDIRS = \ include -libsodium_la_LIBADD = libaesni.la libsse2.la libssse3.la libsse41.la libavx2.la libavx512f.la -noinst_LTLIBRARIES = libaesni.la libsse2.la libssse3.la libsse41.la libavx2.la libavx512f.la +libsodium_la_LIBADD = libaesni.la libarmcrypto.la libsse2.la libssse3.la libsse41.la libavx2.la libavx512f.la +noinst_LTLIBRARIES = libaesni.la libarmcrypto.la libsse2.la libssse3.la libsse41.la libavx2.la libavx512f.la librdrand_la_LDFLAGS = $(libsodium_la_LDFLAGS) librdrand_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ @@ -214,10 +227,24 @@ libsodium_la_SOURCES += \ randombytes/sysrandom/randombytes_sysrandom.c endif +libarmcrypto_la_LDFLAGS = $(libsodium_la_LDFLAGS) +libarmcrypto_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ + @CFLAGS_ARMCRYPTO@ +libarmcrypto_la_SOURCES = \ + crypto_aead/aegis128l/aegis128l_armcrypto.c \ + crypto_aead/aegis128l/aegis128l_armcrypto.h \ + crypto_aead/aegis256/aegis256_armcrypto.c \ + crypto_aead/aegis256/aegis256_armcrypto.h \ + crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c + libaesni_la_LDFLAGS = $(libsodium_la_LDFLAGS) libaesni_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ - @CFLAGS_SSE2@ @CFLAGS_SSSE3@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@ + @CFLAGS_SSE2@ @CFLAGS_SSSE3@ @CFLAGS_AVX@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@ libaesni_la_SOURCES = \ + crypto_aead/aegis128l/aegis128l_aesni.c \ + crypto_aead/aegis128l/aegis128l_aesni.h \ + crypto_aead/aegis256/aegis256_aesni.c \ + crypto_aead/aegis256/aegis256_aesni.h \ crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c libsse2_la_LDFLAGS = $(libsodium_la_LDFLAGS) diff --git a/subprojects/libsodium/src/libsodium/Makefile.in b/subprojects/libsodium/src/libsodium/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -72,6 +72,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -90,6 +92,7 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ @HAVE_TI_MODE_TRUE@am__append_1 = \ @HAVE_TI_MODE_TRUE@ crypto_core/ed25519/ref10/fe_51/base.h \ @HAVE_TI_MODE_TRUE@ crypto_core/ed25519/ref10/fe_51/base2.h \ @@ -123,8 +126,6 @@ host_triplet = @host@ @HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/fe51_namespace.h \ @HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c \ @HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/ladder.h \ -@HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/ladder_base.h \ -@HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h \ @HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/ladder_namespace.h \ @HAVE_AVX_ASM_TRUE@ crypto_scalarmult/curve25519/sandy2x/sandy2x.S @@ -170,7 +171,8 @@ host_triplet = @host@ subdir = src/libsodium ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -210,16 +212,18 @@ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ + { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \ } am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(defexecdir)" LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) libaesni_la_LIBADD = am__dirstamp = $(am__leading_dot)dirstamp -am_libaesni_la_OBJECTS = crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo +am_libaesni_la_OBJECTS = \ + crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo \ + crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo \ + crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo libaesni_la_OBJECTS = $(am_libaesni_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) @@ -228,6 +232,16 @@ am__v_lt_1 = libaesni_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(libaesni_la_LDFLAGS) $(LDFLAGS) -o $@ +libarmcrypto_la_LIBADD = +am_libarmcrypto_la_OBJECTS = \ + crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo \ + crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo \ + crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo +libarmcrypto_la_OBJECTS = $(am_libarmcrypto_la_OBJECTS) +libarmcrypto_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC \ + $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \ + $(AM_CFLAGS) $(CFLAGS) $(libarmcrypto_la_LDFLAGS) $(LDFLAGS) \ + -o $@ libavx2_la_LIBADD = am_libavx2_la_OBJECTS = crypto_generichash/blake2b/ref/libavx2_la-blake2b-compress-avx2.lo \ crypto_pwhash/argon2/libavx2_la-argon2-fill-block-avx2.lo \ @@ -250,11 +264,23 @@ librdrand_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(librdrand_la_LDFLAGS) $(LDFLAGS) -o $@ @EMSCRIPTEN_FALSE@am_librdrand_la_rpath = -libsodium_la_DEPENDENCIES = libaesni.la libsse2.la libssse3.la \ - libsse41.la libavx2.la libavx512f.la $(am__append_8) +libsodium_la_DEPENDENCIES = libaesni.la libarmcrypto.la libsse2.la \ + libssse3.la libsse41.la libavx2.la libavx512f.la \ + $(am__append_8) am__libsodium_la_SOURCES_DIST = \ - crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c \ - crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c \ + crypto_aead/aegis128l/aead_aegis128l.c \ + crypto_aead/aegis128l/aegis128l_common.h \ + crypto_aead/aegis128l/aegis128l_soft.c \ + crypto_aead/aegis128l/aegis128l_soft.h \ + crypto_aead/aegis128l/implementations.h \ + crypto_aead/aegis256/aead_aegis256.c \ + crypto_aead/aegis256/aegis256_common.h \ + crypto_aead/aegis256/aegis256_soft.c \ + crypto_aead/aegis256/aegis256_soft.h \ + crypto_aead/aegis256/implementations.h \ + crypto_aead/aes256gcm/aead_aes256gcm.c \ + crypto_aead/chacha20poly1305/aead_chacha20poly1305.c \ + crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c \ crypto_auth/crypto_auth.c \ crypto_auth/hmacsha256/auth_hmacsha256.c \ crypto_auth/hmacsha512/auth_hmacsha512.c \ @@ -267,6 +293,7 @@ am__libsodium_la_SOURCES_DIST = \ crypto_core/hsalsa20/ref2/core_hsalsa20_ref2.c \ crypto_core/hsalsa20/core_hsalsa20.c \ crypto_core/salsa/ref/core_salsa_ref.c \ + crypto_core/softaes/softaes.c \ crypto_generichash/crypto_generichash.c \ crypto_generichash/blake2b/generichash_blake2.c \ crypto_generichash/blake2b/ref/blake2.h \ @@ -281,7 +308,9 @@ am__libsodium_la_SOURCES_DIST = \ crypto_hash/sha512/hash_sha512.c \ crypto_hash/sha512/cp/hash_sha512_cp.c \ crypto_kdf/blake2b/kdf_blake2b.c crypto_kdf/crypto_kdf.c \ - crypto_kx/crypto_kx.c crypto_onetimeauth/crypto_onetimeauth.c \ + crypto_kdf/hkdf/kdf_hkdf_sha256.c \ + crypto_kdf/hkdf/kdf_hkdf_sha512.c crypto_kx/crypto_kx.c \ + crypto_onetimeauth/crypto_onetimeauth.c \ crypto_onetimeauth/poly1305/onetimeauth_poly1305.c \ crypto_onetimeauth/poly1305/onetimeauth_poly1305.h \ crypto_onetimeauth/poly1305/donna/poly1305_donna.h \ @@ -326,13 +355,14 @@ am__libsodium_la_SOURCES_DIST = \ crypto_stream/salsa20/stream_salsa20.c \ crypto_stream/salsa20/stream_salsa20.h \ crypto_stream/xsalsa20/stream_xsalsa20.c \ - crypto_verify/sodium/verify.c \ + crypto_verify/verify.c include/sodium/private/asm_cet.h \ include/sodium/private/chacha20_ietf_ext.h \ include/sodium/private/common.h \ include/sodium/private/ed25519_ref10.h \ include/sodium/private/implementations.h \ include/sodium/private/mutex.h \ - include/sodium/private/sse2_64_32.h randombytes/randombytes.c \ + include/sodium/private/sse2_64_32.h \ + include/sodium/private/softaes.h randombytes/randombytes.c \ sodium/codecs.c sodium/core.c sodium/runtime.c sodium/utils.c \ sodium/version.c crypto_core/ed25519/ref10/fe_51/base.h \ crypto_core/ed25519/ref10/fe_51/base2.h \ @@ -358,8 +388,6 @@ am__libsodium_la_SOURCES_DIST = \ crypto_scalarmult/curve25519/sandy2x/fe51_namespace.h \ crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c \ crypto_scalarmult/curve25519/sandy2x/ladder.h \ - crypto_scalarmult/curve25519/sandy2x/ladder_base.h \ - crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h \ crypto_scalarmult/curve25519/sandy2x/ladder_namespace.h \ crypto_scalarmult/curve25519/sandy2x/sandy2x.S \ crypto_box/curve25519xchacha20poly1305/box_curve25519xchacha20poly1305.c \ @@ -414,8 +442,14 @@ am__objects_1 = @MINIMAL_FALSE@ crypto_stream/salsa208/libsodium_la-stream_salsa208.lo \ @MINIMAL_FALSE@ crypto_stream/xchacha20/libsodium_la-stream_xchacha20.lo @EMSCRIPTEN_FALSE@am__objects_6 = randombytes/sysrandom/libsodium_la-randombytes_sysrandom.lo -am_libsodium_la_OBJECTS = crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo \ - crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo \ +am_libsodium_la_OBJECTS = \ + crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo \ + crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo \ + crypto_aead/aegis256/libsodium_la-aead_aegis256.lo \ + crypto_aead/aegis256/libsodium_la-aegis256_soft.lo \ + crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo \ + crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo \ + crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo \ crypto_auth/libsodium_la-crypto_auth.lo \ crypto_auth/hmacsha256/libsodium_la-auth_hmacsha256.lo \ crypto_auth/hmacsha512/libsodium_la-auth_hmacsha512.lo \ @@ -429,6 +463,7 @@ am_libsodium_la_OBJECTS = crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_ crypto_core/hsalsa20/ref2/libsodium_la-core_hsalsa20_ref2.lo \ crypto_core/hsalsa20/libsodium_la-core_hsalsa20.lo \ crypto_core/salsa/ref/libsodium_la-core_salsa_ref.lo \ + crypto_core/softaes/libsodium_la-softaes.lo \ crypto_generichash/libsodium_la-crypto_generichash.lo \ crypto_generichash/blake2b/libsodium_la-generichash_blake2.lo \ crypto_generichash/blake2b/ref/libsodium_la-blake2b-compress-ref.lo \ @@ -441,6 +476,8 @@ am_libsodium_la_OBJECTS = crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_ crypto_hash/sha512/cp/libsodium_la-hash_sha512_cp.lo \ crypto_kdf/blake2b/libsodium_la-kdf_blake2b.lo \ crypto_kdf/libsodium_la-crypto_kdf.lo \ + crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo \ + crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo \ crypto_kx/libsodium_la-crypto_kx.lo \ crypto_onetimeauth/libsodium_la-crypto_onetimeauth.lo \ crypto_onetimeauth/poly1305/libsodium_la-onetimeauth_poly1305.lo \ @@ -473,7 +510,7 @@ am_libsodium_la_OBJECTS = crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_ crypto_stream/libsodium_la-crypto_stream.lo \ crypto_stream/salsa20/libsodium_la-stream_salsa20.lo \ crypto_stream/xsalsa20/libsodium_la-stream_xsalsa20.lo \ - crypto_verify/sodium/libsodium_la-verify.lo \ + crypto_verify/libsodium_la-verify.lo \ randombytes/libsodium_la-randombytes.lo \ sodium/libsodium_la-codecs.lo sodium/libsodium_la-core.lo \ sodium/libsodium_la-runtime.lo sodium/libsodium_la-utils.lo \ @@ -532,9 +569,19 @@ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp am__maybe_remake_depfiles = depfiles -am__depfiles_remade = crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo \ - crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo \ - crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo \ +am__depfiles_remade = crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Plo \ + crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Plo \ + crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Plo \ + crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Plo \ + crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Plo \ + crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Plo \ + crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Plo \ + crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Plo \ + crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Plo \ + crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo \ + crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Plo \ + crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo \ + crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo \ crypto_auth/$(DEPDIR)/libsodium_la-crypto_auth.Plo \ crypto_auth/hmacsha256/$(DEPDIR)/libsodium_la-auth_hmacsha256.Plo \ crypto_auth/hmacsha512/$(DEPDIR)/libsodium_la-auth_hmacsha512.Plo \ @@ -552,6 +599,7 @@ am__depfiles_remade = crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes crypto_core/hsalsa20/$(DEPDIR)/libsodium_la-core_hsalsa20.Plo \ crypto_core/hsalsa20/ref2/$(DEPDIR)/libsodium_la-core_hsalsa20_ref2.Plo \ crypto_core/salsa/ref/$(DEPDIR)/libsodium_la-core_salsa_ref.Plo \ + crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Plo \ crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Plo \ crypto_generichash/blake2b/$(DEPDIR)/libsodium_la-generichash_blake2.Plo \ crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Plo \ @@ -567,6 +615,8 @@ am__depfiles_remade = crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes crypto_hash/sha512/cp/$(DEPDIR)/libsodium_la-hash_sha512_cp.Plo \ crypto_kdf/$(DEPDIR)/libsodium_la-crypto_kdf.Plo \ crypto_kdf/blake2b/$(DEPDIR)/libsodium_la-kdf_blake2b.Plo \ + crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Plo \ + crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Plo \ crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Plo \ crypto_onetimeauth/$(DEPDIR)/libsodium_la-crypto_onetimeauth.Plo \ crypto_onetimeauth/poly1305/$(DEPDIR)/libsodium_la-onetimeauth_poly1305.Plo \ @@ -631,7 +681,7 @@ am__depfiles_remade = crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes crypto_stream/salsa208/ref/$(DEPDIR)/libsodium_la-stream_salsa208_ref.Plo \ crypto_stream/xchacha20/$(DEPDIR)/libsodium_la-stream_xchacha20.Plo \ crypto_stream/xsalsa20/$(DEPDIR)/libsodium_la-stream_xsalsa20.Plo \ - crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Plo \ + crypto_verify/$(DEPDIR)/libsodium_la-verify.Plo \ randombytes/$(DEPDIR)/libsodium_la-randombytes.Plo \ randombytes/internal/$(DEPDIR)/librdrand_la-randombytes_internal_random.Plo \ randombytes/sysrandom/$(DEPDIR)/libsodium_la-randombytes_sysrandom.Plo \ @@ -669,13 +719,14 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = -SOURCES = $(libaesni_la_SOURCES) $(libavx2_la_SOURCES) \ - $(libavx512f_la_SOURCES) $(librdrand_la_SOURCES) \ - $(libsodium_la_SOURCES) $(libsse2_la_SOURCES) \ - $(libsse41_la_SOURCES) $(libssse3_la_SOURCES) -DIST_SOURCES = $(libaesni_la_SOURCES) $(libavx2_la_SOURCES) \ - $(libavx512f_la_SOURCES) $(librdrand_la_SOURCES) \ - $(am__libsodium_la_SOURCES_DIST) \ +SOURCES = $(libaesni_la_SOURCES) $(libarmcrypto_la_SOURCES) \ + $(libavx2_la_SOURCES) $(libavx512f_la_SOURCES) \ + $(librdrand_la_SOURCES) $(libsodium_la_SOURCES) \ + $(libsse2_la_SOURCES) $(libsse41_la_SOURCES) \ + $(libssse3_la_SOURCES) +DIST_SOURCES = $(libaesni_la_SOURCES) $(libarmcrypto_la_SOURCES) \ + $(libavx2_la_SOURCES) $(libavx512f_la_SOURCES) \ + $(librdrand_la_SOURCES) $(am__libsodium_la_SOURCES_DIST) \ $(am__libsse2_la_SOURCES_DIST) $(libsse41_la_SOURCES) \ $(libssse3_la_SOURCES) RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ @@ -701,6 +752,10 @@ am__recursive_targets = \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -718,8 +773,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in \ $(top_srcdir)/build-aux/depcomp @@ -754,7 +807,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -766,6 +818,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -778,6 +831,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -794,8 +849,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -838,6 +895,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -863,8 +921,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -898,11 +958,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -911,9 +976,19 @@ valgrind_tools = @valgrind_tools@ lib_LTLIBRARIES = \ libsodium.la -libsodium_la_SOURCES = \ - crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c \ - crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c \ +libsodium_la_SOURCES = crypto_aead/aegis128l/aead_aegis128l.c \ + crypto_aead/aegis128l/aegis128l_common.h \ + crypto_aead/aegis128l/aegis128l_soft.c \ + crypto_aead/aegis128l/aegis128l_soft.h \ + crypto_aead/aegis128l/implementations.h \ + crypto_aead/aegis256/aead_aegis256.c \ + crypto_aead/aegis256/aegis256_common.h \ + crypto_aead/aegis256/aegis256_soft.c \ + crypto_aead/aegis256/aegis256_soft.h \ + crypto_aead/aegis256/implementations.h \ + crypto_aead/aes256gcm/aead_aes256gcm.c \ + crypto_aead/chacha20poly1305/aead_chacha20poly1305.c \ + crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c \ crypto_auth/crypto_auth.c \ crypto_auth/hmacsha256/auth_hmacsha256.c \ crypto_auth/hmacsha512/auth_hmacsha512.c \ @@ -926,6 +1001,7 @@ libsodium_la_SOURCES = \ crypto_core/hsalsa20/ref2/core_hsalsa20_ref2.c \ crypto_core/hsalsa20/core_hsalsa20.c \ crypto_core/salsa/ref/core_salsa_ref.c \ + crypto_core/softaes/softaes.c \ crypto_generichash/crypto_generichash.c \ crypto_generichash/blake2b/generichash_blake2.c \ crypto_generichash/blake2b/ref/blake2.h \ @@ -940,7 +1016,9 @@ libsodium_la_SOURCES = \ crypto_hash/sha512/hash_sha512.c \ crypto_hash/sha512/cp/hash_sha512_cp.c \ crypto_kdf/blake2b/kdf_blake2b.c crypto_kdf/crypto_kdf.c \ - crypto_kx/crypto_kx.c crypto_onetimeauth/crypto_onetimeauth.c \ + crypto_kdf/hkdf/kdf_hkdf_sha256.c \ + crypto_kdf/hkdf/kdf_hkdf_sha512.c crypto_kx/crypto_kx.c \ + crypto_onetimeauth/crypto_onetimeauth.c \ crypto_onetimeauth/poly1305/onetimeauth_poly1305.c \ crypto_onetimeauth/poly1305/onetimeauth_poly1305.h \ crypto_onetimeauth/poly1305/donna/poly1305_donna.h \ @@ -985,13 +1063,14 @@ libsodium_la_SOURCES = \ crypto_stream/salsa20/stream_salsa20.c \ crypto_stream/salsa20/stream_salsa20.h \ crypto_stream/xsalsa20/stream_xsalsa20.c \ - crypto_verify/sodium/verify.c \ + crypto_verify/verify.c include/sodium/private/asm_cet.h \ include/sodium/private/chacha20_ietf_ext.h \ include/sodium/private/common.h \ include/sodium/private/ed25519_ref10.h \ include/sodium/private/implementations.h \ include/sodium/private/mutex.h \ - include/sodium/private/sse2_64_32.h randombytes/randombytes.c \ + include/sodium/private/sse2_64_32.h \ + include/sodium/private/softaes.h randombytes/randombytes.c \ sodium/codecs.c sodium/core.c sodium/runtime.c sodium/utils.c \ sodium/version.c $(am__append_1) $(am__append_2) \ $(am__append_3) $(am__append_4) $(am__append_5) \ @@ -1001,8 +1080,7 @@ noinst_HEADERS = \ crypto_scalarmult/curve25519/sandy2x/fe51_mul.S \ crypto_scalarmult/curve25519/sandy2x/fe51_nsquare.S \ crypto_scalarmult/curve25519/sandy2x/fe51_pack.S \ - crypto_scalarmult/curve25519/sandy2x/ladder.S \ - crypto_scalarmult/curve25519/sandy2x/ladder_base.S + crypto_scalarmult/curve25519/sandy2x/ladder.S randombytes_internal_randombytes_internal_random_CFLAGS = @CFLAGS_RDRAND@ libsodium_la_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -no-undefined \ @@ -1018,10 +1096,12 @@ libsodium_la_CPPFLAGS = \ SUBDIRS = \ include -libsodium_la_LIBADD = libaesni.la libsse2.la libssse3.la libsse41.la \ - libavx2.la libavx512f.la $(am__append_8) -noinst_LTLIBRARIES = libaesni.la libsse2.la libssse3.la libsse41.la \ - libavx2.la libavx512f.la $(am__append_9) +libsodium_la_LIBADD = libaesni.la libarmcrypto.la libsse2.la \ + libssse3.la libsse41.la libavx2.la libavx512f.la \ + $(am__append_8) +noinst_LTLIBRARIES = libaesni.la libarmcrypto.la libsse2.la \ + libssse3.la libsse41.la libavx2.la libavx512f.la \ + $(am__append_9) librdrand_la_LDFLAGS = $(libsodium_la_LDFLAGS) librdrand_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ @CFLAGS_RDRAND@ @@ -1029,11 +1109,26 @@ librdrand_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ librdrand_la_SOURCES = \ randombytes/internal/randombytes_internal_random.c +libarmcrypto_la_LDFLAGS = $(libsodium_la_LDFLAGS) +libarmcrypto_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ + @CFLAGS_ARMCRYPTO@ + +libarmcrypto_la_SOURCES = \ + crypto_aead/aegis128l/aegis128l_armcrypto.c \ + crypto_aead/aegis128l/aegis128l_armcrypto.h \ + crypto_aead/aegis256/aegis256_armcrypto.c \ + crypto_aead/aegis256/aegis256_armcrypto.h \ + crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c + libaesni_la_LDFLAGS = $(libsodium_la_LDFLAGS) libaesni_la_CPPFLAGS = $(libsodium_la_CPPFLAGS) \ - @CFLAGS_SSE2@ @CFLAGS_SSSE3@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@ + @CFLAGS_SSE2@ @CFLAGS_SSSE3@ @CFLAGS_AVX@ @CFLAGS_AESNI@ @CFLAGS_PCLMUL@ libaesni_la_SOURCES = \ + crypto_aead/aegis128l/aegis128l_aesni.c \ + crypto_aead/aegis128l/aegis128l_aesni.h \ + crypto_aead/aegis256/aegis256_aesni.c \ + crypto_aead/aegis256/aegis256_aesni.h \ crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c libsse2_la_LDFLAGS = $(libsodium_la_LDFLAGS) @@ -1152,71 +1247,103 @@ uninstall-libLTLIBRARIES: done clean-libLTLIBRARIES: - -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) + -$(am__rm_f) $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } + echo rm -f $${locs}; \ + $(am__rm_f) $${locs} clean-noinstLTLIBRARIES: - -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) + -$(am__rm_f) $(noinst_LTLIBRARIES) @list='$(noinst_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ - test -z "$$locs" || { \ - echo rm -f $${locs}; \ - rm -f $${locs}; \ - } + echo rm -f $${locs}; \ + $(am__rm_f) $${locs} +crypto_aead/aegis128l/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aegis128l + @: >>crypto_aead/aegis128l/$(am__dirstamp) +crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aegis128l/$(DEPDIR) + @: >>crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo: \ + crypto_aead/aegis128l/$(am__dirstamp) \ + crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis256/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aegis256 + @: >>crypto_aead/aegis256/$(am__dirstamp) +crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aegis256/$(DEPDIR) + @: >>crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo: \ + crypto_aead/aegis256/$(am__dirstamp) \ + crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) crypto_aead/aes256gcm/aesni/$(am__dirstamp): @$(MKDIR_P) crypto_aead/aes256gcm/aesni - @: > crypto_aead/aes256gcm/aesni/$(am__dirstamp) + @: >>crypto_aead/aes256gcm/aesni/$(am__dirstamp) crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_aead/aes256gcm/aesni/$(DEPDIR) - @: > crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp) crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo: \ crypto_aead/aes256gcm/aesni/$(am__dirstamp) \ crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp) libaesni.la: $(libaesni_la_OBJECTS) $(libaesni_la_DEPENDENCIES) $(EXTRA_libaesni_la_DEPENDENCIES) $(AM_V_CCLD)$(libaesni_la_LINK) $(libaesni_la_OBJECTS) $(libaesni_la_LIBADD) $(LIBS) +crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo: \ + crypto_aead/aegis128l/$(am__dirstamp) \ + crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo: \ + crypto_aead/aegis256/$(am__dirstamp) \ + crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aes256gcm/armcrypto/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aes256gcm/armcrypto + @: >>crypto_aead/aes256gcm/armcrypto/$(am__dirstamp) +crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aes256gcm/armcrypto/$(DEPDIR) + @: >>crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo: \ + crypto_aead/aes256gcm/armcrypto/$(am__dirstamp) \ + crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/$(am__dirstamp) + +libarmcrypto.la: $(libarmcrypto_la_OBJECTS) $(libarmcrypto_la_DEPENDENCIES) $(EXTRA_libarmcrypto_la_DEPENDENCIES) + $(AM_V_CCLD)$(libarmcrypto_la_LINK) $(libarmcrypto_la_OBJECTS) $(libarmcrypto_la_LIBADD) $(LIBS) crypto_generichash/blake2b/ref/$(am__dirstamp): @$(MKDIR_P) crypto_generichash/blake2b/ref - @: > crypto_generichash/blake2b/ref/$(am__dirstamp) + @: >>crypto_generichash/blake2b/ref/$(am__dirstamp) crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_generichash/blake2b/ref/$(DEPDIR) - @: > crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) crypto_generichash/blake2b/ref/libavx2_la-blake2b-compress-avx2.lo: \ crypto_generichash/blake2b/ref/$(am__dirstamp) \ crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/argon2/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/argon2 - @: > crypto_pwhash/argon2/$(am__dirstamp) + @: >>crypto_pwhash/argon2/$(am__dirstamp) crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/argon2/$(DEPDIR) - @: > crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/argon2/libavx2_la-argon2-fill-block-avx2.lo: \ crypto_pwhash/argon2/$(am__dirstamp) \ crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/dolbeau/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20/dolbeau - @: > crypto_stream/chacha20/dolbeau/$(am__dirstamp) + @: >>crypto_stream/chacha20/dolbeau/$(am__dirstamp) crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20/dolbeau/$(DEPDIR) - @: > crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/dolbeau/libavx2_la-chacha20_dolbeau-avx2.lo: \ crypto_stream/chacha20/dolbeau/$(am__dirstamp) \ crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/xmm6int/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/xmm6int - @: > crypto_stream/salsa20/xmm6int/$(am__dirstamp) + @: >>crypto_stream/salsa20/xmm6int/$(am__dirstamp) crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/xmm6int/$(DEPDIR) - @: > crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/xmm6int/libavx2_la-salsa20_xmm6int-avx2.lo: \ crypto_stream/salsa20/xmm6int/$(am__dirstamp) \ crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp) @@ -1231,75 +1358,96 @@ libavx512f.la: $(libavx512f_la_OBJECTS) $(libavx512f_la_DEPENDENCIES) $(EXTRA_li $(AM_V_CCLD)$(libavx512f_la_LINK) $(libavx512f_la_OBJECTS) $(libavx512f_la_LIBADD) $(LIBS) randombytes/internal/$(am__dirstamp): @$(MKDIR_P) randombytes/internal - @: > randombytes/internal/$(am__dirstamp) + @: >>randombytes/internal/$(am__dirstamp) randombytes/internal/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) randombytes/internal/$(DEPDIR) - @: > randombytes/internal/$(DEPDIR)/$(am__dirstamp) + @: >>randombytes/internal/$(DEPDIR)/$(am__dirstamp) randombytes/internal/librdrand_la-randombytes_internal_random.lo: \ randombytes/internal/$(am__dirstamp) \ randombytes/internal/$(DEPDIR)/$(am__dirstamp) librdrand.la: $(librdrand_la_OBJECTS) $(librdrand_la_DEPENDENCIES) $(EXTRA_librdrand_la_DEPENDENCIES) $(AM_V_CCLD)$(librdrand_la_LINK) $(am_librdrand_la_rpath) $(librdrand_la_OBJECTS) $(librdrand_la_LIBADD) $(LIBS) -crypto_aead/chacha20poly1305/sodium/$(am__dirstamp): - @$(MKDIR_P) crypto_aead/chacha20poly1305/sodium - @: > crypto_aead/chacha20poly1305/sodium/$(am__dirstamp) -crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp): - @$(MKDIR_P) crypto_aead/chacha20poly1305/sodium/$(DEPDIR) - @: > crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) -crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo: \ - crypto_aead/chacha20poly1305/sodium/$(am__dirstamp) \ - crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) -crypto_aead/xchacha20poly1305/sodium/$(am__dirstamp): - @$(MKDIR_P) crypto_aead/xchacha20poly1305/sodium - @: > crypto_aead/xchacha20poly1305/sodium/$(am__dirstamp) -crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp): - @$(MKDIR_P) crypto_aead/xchacha20poly1305/sodium/$(DEPDIR) - @: > crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) -crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo: \ - crypto_aead/xchacha20poly1305/sodium/$(am__dirstamp) \ - crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo: \ + crypto_aead/aegis128l/$(am__dirstamp) \ + crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo: \ + crypto_aead/aegis128l/$(am__dirstamp) \ + crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis256/libsodium_la-aead_aegis256.lo: \ + crypto_aead/aegis256/$(am__dirstamp) \ + crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aegis256/libsodium_la-aegis256_soft.lo: \ + crypto_aead/aegis256/$(am__dirstamp) \ + crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aes256gcm/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aes256gcm + @: >>crypto_aead/aes256gcm/$(am__dirstamp) +crypto_aead/aes256gcm/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/aes256gcm/$(DEPDIR) + @: >>crypto_aead/aes256gcm/$(DEPDIR)/$(am__dirstamp) +crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo: \ + crypto_aead/aes256gcm/$(am__dirstamp) \ + crypto_aead/aes256gcm/$(DEPDIR)/$(am__dirstamp) +crypto_aead/chacha20poly1305/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/chacha20poly1305 + @: >>crypto_aead/chacha20poly1305/$(am__dirstamp) +crypto_aead/chacha20poly1305/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/chacha20poly1305/$(DEPDIR) + @: >>crypto_aead/chacha20poly1305/$(DEPDIR)/$(am__dirstamp) +crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo: \ + crypto_aead/chacha20poly1305/$(am__dirstamp) \ + crypto_aead/chacha20poly1305/$(DEPDIR)/$(am__dirstamp) +crypto_aead/xchacha20poly1305/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/xchacha20poly1305 + @: >>crypto_aead/xchacha20poly1305/$(am__dirstamp) +crypto_aead/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_aead/xchacha20poly1305/$(DEPDIR) + @: >>crypto_aead/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) +crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo: \ + crypto_aead/xchacha20poly1305/$(am__dirstamp) \ + crypto_aead/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_auth/$(am__dirstamp): @$(MKDIR_P) crypto_auth - @: > crypto_auth/$(am__dirstamp) + @: >>crypto_auth/$(am__dirstamp) crypto_auth/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_auth/$(DEPDIR) - @: > crypto_auth/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_auth/$(DEPDIR)/$(am__dirstamp) crypto_auth/libsodium_la-crypto_auth.lo: crypto_auth/$(am__dirstamp) \ crypto_auth/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha256/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha256 - @: > crypto_auth/hmacsha256/$(am__dirstamp) + @: >>crypto_auth/hmacsha256/$(am__dirstamp) crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha256/$(DEPDIR) - @: > crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha256/libsodium_la-auth_hmacsha256.lo: \ crypto_auth/hmacsha256/$(am__dirstamp) \ crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha512/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha512 - @: > crypto_auth/hmacsha512/$(am__dirstamp) + @: >>crypto_auth/hmacsha512/$(am__dirstamp) crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha512/$(DEPDIR) - @: > crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha512/libsodium_la-auth_hmacsha512.lo: \ crypto_auth/hmacsha512/$(am__dirstamp) \ crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha512256/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha512256 - @: > crypto_auth/hmacsha512256/$(am__dirstamp) + @: >>crypto_auth/hmacsha512256/$(am__dirstamp) crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_auth/hmacsha512256/$(DEPDIR) - @: > crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp) crypto_auth/hmacsha512256/libsodium_la-auth_hmacsha512256.lo: \ crypto_auth/hmacsha512256/$(am__dirstamp) \ crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp) crypto_box/$(am__dirstamp): @$(MKDIR_P) crypto_box - @: > crypto_box/$(am__dirstamp) + @: >>crypto_box/$(am__dirstamp) crypto_box/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_box/$(DEPDIR) - @: > crypto_box/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_box/$(DEPDIR)/$(am__dirstamp) crypto_box/libsodium_la-crypto_box.lo: crypto_box/$(am__dirstamp) \ crypto_box/$(DEPDIR)/$(am__dirstamp) crypto_box/libsodium_la-crypto_box_easy.lo: \ @@ -1310,73 +1458,82 @@ crypto_box/libsodium_la-crypto_box_seal.lo: \ crypto_box/$(DEPDIR)/$(am__dirstamp) crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_box/curve25519xsalsa20poly1305 - @: > crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp) + @: >>crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp) crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_box/curve25519xsalsa20poly1305/$(DEPDIR) - @: > crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_box/curve25519xsalsa20poly1305/libsodium_la-box_curve25519xsalsa20poly1305.lo: \ crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp) \ crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_core/ed25519/ref10/$(am__dirstamp): @$(MKDIR_P) crypto_core/ed25519/ref10 - @: > crypto_core/ed25519/ref10/$(am__dirstamp) + @: >>crypto_core/ed25519/ref10/$(am__dirstamp) crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/ed25519/ref10/$(DEPDIR) - @: > crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_core/ed25519/ref10/libsodium_la-ed25519_ref10.lo: \ crypto_core/ed25519/ref10/$(am__dirstamp) \ crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_core/hchacha20/$(am__dirstamp): @$(MKDIR_P) crypto_core/hchacha20 - @: > crypto_core/hchacha20/$(am__dirstamp) + @: >>crypto_core/hchacha20/$(am__dirstamp) crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/hchacha20/$(DEPDIR) - @: > crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp) crypto_core/hchacha20/libsodium_la-core_hchacha20.lo: \ crypto_core/hchacha20/$(am__dirstamp) \ crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp) crypto_core/hsalsa20/ref2/$(am__dirstamp): @$(MKDIR_P) crypto_core/hsalsa20/ref2 - @: > crypto_core/hsalsa20/ref2/$(am__dirstamp) + @: >>crypto_core/hsalsa20/ref2/$(am__dirstamp) crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/hsalsa20/ref2/$(DEPDIR) - @: > crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp) crypto_core/hsalsa20/ref2/libsodium_la-core_hsalsa20_ref2.lo: \ crypto_core/hsalsa20/ref2/$(am__dirstamp) \ crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp) crypto_core/hsalsa20/$(am__dirstamp): @$(MKDIR_P) crypto_core/hsalsa20 - @: > crypto_core/hsalsa20/$(am__dirstamp) + @: >>crypto_core/hsalsa20/$(am__dirstamp) crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/hsalsa20/$(DEPDIR) - @: > crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp) crypto_core/hsalsa20/libsodium_la-core_hsalsa20.lo: \ crypto_core/hsalsa20/$(am__dirstamp) \ crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp) crypto_core/salsa/ref/$(am__dirstamp): @$(MKDIR_P) crypto_core/salsa/ref - @: > crypto_core/salsa/ref/$(am__dirstamp) + @: >>crypto_core/salsa/ref/$(am__dirstamp) crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/salsa/ref/$(DEPDIR) - @: > crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp) crypto_core/salsa/ref/libsodium_la-core_salsa_ref.lo: \ crypto_core/salsa/ref/$(am__dirstamp) \ crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp) +crypto_core/softaes/$(am__dirstamp): + @$(MKDIR_P) crypto_core/softaes + @: >>crypto_core/softaes/$(am__dirstamp) +crypto_core/softaes/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_core/softaes/$(DEPDIR) + @: >>crypto_core/softaes/$(DEPDIR)/$(am__dirstamp) +crypto_core/softaes/libsodium_la-softaes.lo: \ + crypto_core/softaes/$(am__dirstamp) \ + crypto_core/softaes/$(DEPDIR)/$(am__dirstamp) crypto_generichash/$(am__dirstamp): @$(MKDIR_P) crypto_generichash - @: > crypto_generichash/$(am__dirstamp) + @: >>crypto_generichash/$(am__dirstamp) crypto_generichash/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_generichash/$(DEPDIR) - @: > crypto_generichash/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_generichash/$(DEPDIR)/$(am__dirstamp) crypto_generichash/libsodium_la-crypto_generichash.lo: \ crypto_generichash/$(am__dirstamp) \ crypto_generichash/$(DEPDIR)/$(am__dirstamp) crypto_generichash/blake2b/$(am__dirstamp): @$(MKDIR_P) crypto_generichash/blake2b - @: > crypto_generichash/blake2b/$(am__dirstamp) + @: >>crypto_generichash/blake2b/$(am__dirstamp) crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_generichash/blake2b/$(DEPDIR) - @: > crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp) crypto_generichash/blake2b/libsodium_la-generichash_blake2.lo: \ crypto_generichash/blake2b/$(am__dirstamp) \ crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp) @@ -1391,97 +1548,109 @@ crypto_generichash/blake2b/ref/libsodium_la-generichash_blake2b.lo: \ crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) crypto_hash/$(am__dirstamp): @$(MKDIR_P) crypto_hash - @: > crypto_hash/$(am__dirstamp) + @: >>crypto_hash/$(am__dirstamp) crypto_hash/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_hash/$(DEPDIR) - @: > crypto_hash/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_hash/$(DEPDIR)/$(am__dirstamp) crypto_hash/libsodium_la-crypto_hash.lo: crypto_hash/$(am__dirstamp) \ crypto_hash/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha256/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha256 - @: > crypto_hash/sha256/$(am__dirstamp) + @: >>crypto_hash/sha256/$(am__dirstamp) crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha256/$(DEPDIR) - @: > crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha256/libsodium_la-hash_sha256.lo: \ crypto_hash/sha256/$(am__dirstamp) \ crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha256/cp/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha256/cp - @: > crypto_hash/sha256/cp/$(am__dirstamp) + @: >>crypto_hash/sha256/cp/$(am__dirstamp) crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha256/cp/$(DEPDIR) - @: > crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha256/cp/libsodium_la-hash_sha256_cp.lo: \ crypto_hash/sha256/cp/$(am__dirstamp) \ crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha512/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha512 - @: > crypto_hash/sha512/$(am__dirstamp) + @: >>crypto_hash/sha512/$(am__dirstamp) crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha512/$(DEPDIR) - @: > crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha512/libsodium_la-hash_sha512.lo: \ crypto_hash/sha512/$(am__dirstamp) \ crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha512/cp/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha512/cp - @: > crypto_hash/sha512/cp/$(am__dirstamp) + @: >>crypto_hash/sha512/cp/$(am__dirstamp) crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_hash/sha512/cp/$(DEPDIR) - @: > crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp) crypto_hash/sha512/cp/libsodium_la-hash_sha512_cp.lo: \ crypto_hash/sha512/cp/$(am__dirstamp) \ crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp) crypto_kdf/blake2b/$(am__dirstamp): @$(MKDIR_P) crypto_kdf/blake2b - @: > crypto_kdf/blake2b/$(am__dirstamp) + @: >>crypto_kdf/blake2b/$(am__dirstamp) crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_kdf/blake2b/$(DEPDIR) - @: > crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp) crypto_kdf/blake2b/libsodium_la-kdf_blake2b.lo: \ crypto_kdf/blake2b/$(am__dirstamp) \ crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp) crypto_kdf/$(am__dirstamp): @$(MKDIR_P) crypto_kdf - @: > crypto_kdf/$(am__dirstamp) + @: >>crypto_kdf/$(am__dirstamp) crypto_kdf/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_kdf/$(DEPDIR) - @: > crypto_kdf/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_kdf/$(DEPDIR)/$(am__dirstamp) crypto_kdf/libsodium_la-crypto_kdf.lo: crypto_kdf/$(am__dirstamp) \ crypto_kdf/$(DEPDIR)/$(am__dirstamp) +crypto_kdf/hkdf/$(am__dirstamp): + @$(MKDIR_P) crypto_kdf/hkdf + @: >>crypto_kdf/hkdf/$(am__dirstamp) +crypto_kdf/hkdf/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_kdf/hkdf/$(DEPDIR) + @: >>crypto_kdf/hkdf/$(DEPDIR)/$(am__dirstamp) +crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo: \ + crypto_kdf/hkdf/$(am__dirstamp) \ + crypto_kdf/hkdf/$(DEPDIR)/$(am__dirstamp) +crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo: \ + crypto_kdf/hkdf/$(am__dirstamp) \ + crypto_kdf/hkdf/$(DEPDIR)/$(am__dirstamp) crypto_kx/$(am__dirstamp): @$(MKDIR_P) crypto_kx - @: > crypto_kx/$(am__dirstamp) + @: >>crypto_kx/$(am__dirstamp) crypto_kx/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_kx/$(DEPDIR) - @: > crypto_kx/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_kx/$(DEPDIR)/$(am__dirstamp) crypto_kx/libsodium_la-crypto_kx.lo: crypto_kx/$(am__dirstamp) \ crypto_kx/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth - @: > crypto_onetimeauth/$(am__dirstamp) + @: >>crypto_onetimeauth/$(am__dirstamp) crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/$(DEPDIR) - @: > crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/libsodium_la-crypto_onetimeauth.lo: \ crypto_onetimeauth/$(am__dirstamp) \ crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305 - @: > crypto_onetimeauth/poly1305/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/$(am__dirstamp) crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305/$(DEPDIR) - @: > crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/poly1305/libsodium_la-onetimeauth_poly1305.lo: \ crypto_onetimeauth/poly1305/$(am__dirstamp) \ crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/poly1305/donna/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305/donna - @: > crypto_onetimeauth/poly1305/donna/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/donna/$(am__dirstamp) crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305/donna/$(DEPDIR) - @: > crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/poly1305/donna/libsodium_la-poly1305_donna.lo: \ crypto_onetimeauth/poly1305/donna/$(am__dirstamp) \ crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp) @@ -1508,46 +1677,46 @@ crypto_pwhash/argon2/libsodium_la-pwhash_argon2id.lo: \ crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash - @: > crypto_pwhash/$(am__dirstamp) + @: >>crypto_pwhash/$(am__dirstamp) crypto_pwhash/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/$(DEPDIR) - @: > crypto_pwhash/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_pwhash/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/libsodium_la-crypto_pwhash.lo: \ crypto_pwhash/$(am__dirstamp) \ crypto_pwhash/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult - @: > crypto_scalarmult/$(am__dirstamp) + @: >>crypto_scalarmult/$(am__dirstamp) crypto_scalarmult/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/$(DEPDIR) - @: > crypto_scalarmult/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/libsodium_la-crypto_scalarmult.lo: \ crypto_scalarmult/$(am__dirstamp) \ crypto_scalarmult/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/ref10/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519/ref10 - @: > crypto_scalarmult/curve25519/ref10/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/ref10/$(am__dirstamp) crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519/ref10/$(DEPDIR) - @: > crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/ref10/libsodium_la-x25519_ref10.lo: \ crypto_scalarmult/curve25519/ref10/$(am__dirstamp) \ crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519 - @: > crypto_scalarmult/curve25519/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/$(am__dirstamp) crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519/$(DEPDIR) - @: > crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/libsodium_la-scalarmult_curve25519.lo: \ crypto_scalarmult/curve25519/$(am__dirstamp) \ crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox - @: > crypto_secretbox/$(am__dirstamp) + @: >>crypto_secretbox/$(am__dirstamp) crypto_secretbox/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox/$(DEPDIR) - @: > crypto_secretbox/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_secretbox/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/libsodium_la-crypto_secretbox.lo: \ crypto_secretbox/$(am__dirstamp) \ crypto_secretbox/$(DEPDIR)/$(am__dirstamp) @@ -1556,72 +1725,72 @@ crypto_secretbox/libsodium_la-crypto_secretbox_easy.lo: \ crypto_secretbox/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/xsalsa20poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox/xsalsa20poly1305 - @: > crypto_secretbox/xsalsa20poly1305/$(am__dirstamp) + @: >>crypto_secretbox/xsalsa20poly1305/$(am__dirstamp) crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox/xsalsa20poly1305/$(DEPDIR) - @: > crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/xsalsa20poly1305/libsodium_la-secretbox_xsalsa20poly1305.lo: \ crypto_secretbox/xsalsa20poly1305/$(am__dirstamp) \ crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_secretstream/xchacha20poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_secretstream/xchacha20poly1305 - @: > crypto_secretstream/xchacha20poly1305/$(am__dirstamp) + @: >>crypto_secretstream/xchacha20poly1305/$(am__dirstamp) crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_secretstream/xchacha20poly1305/$(DEPDIR) - @: > crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_secretstream/xchacha20poly1305/libsodium_la-secretstream_xchacha20poly1305.lo: \ crypto_secretstream/xchacha20poly1305/$(am__dirstamp) \ crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash - @: > crypto_shorthash/$(am__dirstamp) + @: >>crypto_shorthash/$(am__dirstamp) crypto_shorthash/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash/$(DEPDIR) - @: > crypto_shorthash/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_shorthash/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/libsodium_la-crypto_shorthash.lo: \ crypto_shorthash/$(am__dirstamp) \ crypto_shorthash/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/siphash24/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash/siphash24 - @: > crypto_shorthash/siphash24/$(am__dirstamp) + @: >>crypto_shorthash/siphash24/$(am__dirstamp) crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash/siphash24/$(DEPDIR) - @: > crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/siphash24/libsodium_la-shorthash_siphash24.lo: \ crypto_shorthash/siphash24/$(am__dirstamp) \ crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/siphash24/ref/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash/siphash24/ref - @: > crypto_shorthash/siphash24/ref/$(am__dirstamp) + @: >>crypto_shorthash/siphash24/ref/$(am__dirstamp) crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_shorthash/siphash24/ref/$(DEPDIR) - @: > crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp) crypto_shorthash/siphash24/ref/libsodium_la-shorthash_siphash24_ref.lo: \ crypto_shorthash/siphash24/ref/$(am__dirstamp) \ crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp) crypto_sign/$(am__dirstamp): @$(MKDIR_P) crypto_sign - @: > crypto_sign/$(am__dirstamp) + @: >>crypto_sign/$(am__dirstamp) crypto_sign/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_sign/$(DEPDIR) - @: > crypto_sign/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_sign/$(DEPDIR)/$(am__dirstamp) crypto_sign/libsodium_la-crypto_sign.lo: crypto_sign/$(am__dirstamp) \ crypto_sign/$(DEPDIR)/$(am__dirstamp) crypto_sign/ed25519/$(am__dirstamp): @$(MKDIR_P) crypto_sign/ed25519 - @: > crypto_sign/ed25519/$(am__dirstamp) + @: >>crypto_sign/ed25519/$(am__dirstamp) crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_sign/ed25519/$(DEPDIR) - @: > crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp) crypto_sign/ed25519/libsodium_la-sign_ed25519.lo: \ crypto_sign/ed25519/$(am__dirstamp) \ crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp) crypto_sign/ed25519/ref10/$(am__dirstamp): @$(MKDIR_P) crypto_sign/ed25519/ref10 - @: > crypto_sign/ed25519/ref10/$(am__dirstamp) + @: >>crypto_sign/ed25519/ref10/$(am__dirstamp) crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_sign/ed25519/ref10/$(DEPDIR) - @: > crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_sign/ed25519/ref10/libsodium_la-keypair.lo: \ crypto_sign/ed25519/ref10/$(am__dirstamp) \ crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) @@ -1633,72 +1802,71 @@ crypto_sign/ed25519/ref10/libsodium_la-sign.lo: \ crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20 - @: > crypto_stream/chacha20/$(am__dirstamp) + @: >>crypto_stream/chacha20/$(am__dirstamp) crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20/$(DEPDIR) - @: > crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/libsodium_la-stream_chacha20.lo: \ crypto_stream/chacha20/$(am__dirstamp) \ crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/ref/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20/ref - @: > crypto_stream/chacha20/ref/$(am__dirstamp) + @: >>crypto_stream/chacha20/ref/$(am__dirstamp) crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/chacha20/ref/$(DEPDIR) - @: > crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/chacha20/ref/libsodium_la-chacha20_ref.lo: \ crypto_stream/chacha20/ref/$(am__dirstamp) \ crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/$(am__dirstamp): @$(MKDIR_P) crypto_stream - @: > crypto_stream/$(am__dirstamp) + @: >>crypto_stream/$(am__dirstamp) crypto_stream/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/$(DEPDIR) - @: > crypto_stream/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/$(DEPDIR)/$(am__dirstamp) crypto_stream/libsodium_la-crypto_stream.lo: \ crypto_stream/$(am__dirstamp) \ crypto_stream/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20 - @: > crypto_stream/salsa20/$(am__dirstamp) + @: >>crypto_stream/salsa20/$(am__dirstamp) crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/$(DEPDIR) - @: > crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/libsodium_la-stream_salsa20.lo: \ crypto_stream/salsa20/$(am__dirstamp) \ crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp) crypto_stream/xsalsa20/$(am__dirstamp): @$(MKDIR_P) crypto_stream/xsalsa20 - @: > crypto_stream/xsalsa20/$(am__dirstamp) + @: >>crypto_stream/xsalsa20/$(am__dirstamp) crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/xsalsa20/$(DEPDIR) - @: > crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp) crypto_stream/xsalsa20/libsodium_la-stream_xsalsa20.lo: \ crypto_stream/xsalsa20/$(am__dirstamp) \ crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp) -crypto_verify/sodium/$(am__dirstamp): - @$(MKDIR_P) crypto_verify/sodium - @: > crypto_verify/sodium/$(am__dirstamp) -crypto_verify/sodium/$(DEPDIR)/$(am__dirstamp): - @$(MKDIR_P) crypto_verify/sodium/$(DEPDIR) - @: > crypto_verify/sodium/$(DEPDIR)/$(am__dirstamp) -crypto_verify/sodium/libsodium_la-verify.lo: \ - crypto_verify/sodium/$(am__dirstamp) \ - crypto_verify/sodium/$(DEPDIR)/$(am__dirstamp) +crypto_verify/$(am__dirstamp): + @$(MKDIR_P) crypto_verify + @: >>crypto_verify/$(am__dirstamp) +crypto_verify/$(DEPDIR)/$(am__dirstamp): + @$(MKDIR_P) crypto_verify/$(DEPDIR) + @: >>crypto_verify/$(DEPDIR)/$(am__dirstamp) +crypto_verify/libsodium_la-verify.lo: crypto_verify/$(am__dirstamp) \ + crypto_verify/$(DEPDIR)/$(am__dirstamp) randombytes/$(am__dirstamp): @$(MKDIR_P) randombytes - @: > randombytes/$(am__dirstamp) + @: >>randombytes/$(am__dirstamp) randombytes/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) randombytes/$(DEPDIR) - @: > randombytes/$(DEPDIR)/$(am__dirstamp) + @: >>randombytes/$(DEPDIR)/$(am__dirstamp) randombytes/libsodium_la-randombytes.lo: randombytes/$(am__dirstamp) \ randombytes/$(DEPDIR)/$(am__dirstamp) sodium/$(am__dirstamp): @$(MKDIR_P) sodium - @: > sodium/$(am__dirstamp) + @: >>sodium/$(am__dirstamp) sodium/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) sodium/$(DEPDIR) - @: > sodium/$(DEPDIR)/$(am__dirstamp) + @: >>sodium/$(DEPDIR)/$(am__dirstamp) sodium/libsodium_la-codecs.lo: sodium/$(am__dirstamp) \ sodium/$(DEPDIR)/$(am__dirstamp) sodium/libsodium_la-core.lo: sodium/$(am__dirstamp) \ @@ -1711,10 +1879,10 @@ sodium/libsodium_la-version.lo: sodium/$(am__dirstamp) \ sodium/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/xmm6/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/xmm6 - @: > crypto_stream/salsa20/xmm6/$(am__dirstamp) + @: >>crypto_stream/salsa20/xmm6/$(am__dirstamp) crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/xmm6/$(DEPDIR) - @: > crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/xmm6/libsodium_la-salsa20_xmm6-asm.lo: \ crypto_stream/salsa20/xmm6/$(am__dirstamp) \ crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) @@ -1723,19 +1891,19 @@ crypto_stream/salsa20/xmm6/libsodium_la-salsa20_xmm6.lo: \ crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/ref/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/ref - @: > crypto_stream/salsa20/ref/$(am__dirstamp) + @: >>crypto_stream/salsa20/ref/$(am__dirstamp) crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa20/ref/$(DEPDIR) - @: > crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa20/ref/libsodium_la-salsa20_ref.lo: \ crypto_stream/salsa20/ref/$(am__dirstamp) \ crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519/sandy2x - @: > crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp) crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/curve25519/sandy2x/$(DEPDIR) - @: > crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/curve25519/sandy2x/libsodium_la-curve25519_sandy2x.lo: \ crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp) \ crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) @@ -1750,10 +1918,10 @@ crypto_scalarmult/curve25519/sandy2x/libsodium_la-sandy2x.lo: \ crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) crypto_box/curve25519xchacha20poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_box/curve25519xchacha20poly1305 - @: > crypto_box/curve25519xchacha20poly1305/$(am__dirstamp) + @: >>crypto_box/curve25519xchacha20poly1305/$(am__dirstamp) crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_box/curve25519xchacha20poly1305/$(DEPDIR) - @: > crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_box/curve25519xchacha20poly1305/libsodium_la-box_curve25519xchacha20poly1305.lo: \ crypto_box/curve25519xchacha20poly1305/$(am__dirstamp) \ crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) @@ -1762,10 +1930,10 @@ crypto_box/curve25519xchacha20poly1305/libsodium_la-box_seal_curve25519xchacha20 crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_core/ed25519/$(am__dirstamp): @$(MKDIR_P) crypto_core/ed25519 - @: > crypto_core/ed25519/$(am__dirstamp) + @: >>crypto_core/ed25519/$(am__dirstamp) crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_core/ed25519/$(DEPDIR) - @: > crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) crypto_core/ed25519/libsodium_la-core_ed25519.lo: \ crypto_core/ed25519/$(am__dirstamp) \ crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) @@ -1774,10 +1942,10 @@ crypto_core/ed25519/libsodium_la-core_ristretto255.lo: \ crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256 - @: > crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256/$(DEPDIR) - @: > crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/libsodium_la-crypto_scrypt-common.lo: \ crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp) \ crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) @@ -1792,37 +1960,37 @@ crypto_pwhash/scryptsalsa208sha256/libsodium_la-pwhash_scryptsalsa208sha256.lo: crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256/nosse - @: > crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR) - @: > crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/nosse/libsodium_la-pwhash_scryptsalsa208sha256_nosse.lo: \ crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp) \ crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/ed25519/ref10/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/ed25519/ref10 - @: > crypto_scalarmult/ed25519/ref10/$(am__dirstamp) + @: >>crypto_scalarmult/ed25519/ref10/$(am__dirstamp) crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/ed25519/ref10/$(DEPDIR) - @: > crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/ed25519/ref10/libsodium_la-scalarmult_ed25519_ref10.lo: \ crypto_scalarmult/ed25519/ref10/$(am__dirstamp) \ crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/ristretto255/ref10/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/ristretto255/ref10 - @: > crypto_scalarmult/ristretto255/ref10/$(am__dirstamp) + @: >>crypto_scalarmult/ristretto255/ref10/$(am__dirstamp) crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_scalarmult/ristretto255/ref10/$(DEPDIR) - @: > crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp) crypto_scalarmult/ristretto255/ref10/libsodium_la-scalarmult_ristretto255_ref10.lo: \ crypto_scalarmult/ristretto255/ref10/$(am__dirstamp) \ crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/xchacha20poly1305/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox/xchacha20poly1305 - @: > crypto_secretbox/xchacha20poly1305/$(am__dirstamp) + @: >>crypto_secretbox/xchacha20poly1305/$(am__dirstamp) crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_secretbox/xchacha20poly1305/$(DEPDIR) - @: > crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) crypto_secretbox/xchacha20poly1305/libsodium_la-secretbox_xchacha20poly1305.lo: \ crypto_secretbox/xchacha20poly1305/$(am__dirstamp) \ crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) @@ -1837,55 +2005,55 @@ crypto_sign/ed25519/ref10/libsodium_la-obsolete.lo: \ crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa2012/ref/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa2012/ref - @: > crypto_stream/salsa2012/ref/$(am__dirstamp) + @: >>crypto_stream/salsa2012/ref/$(am__dirstamp) crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa2012/ref/$(DEPDIR) - @: > crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa2012/ref/libsodium_la-stream_salsa2012_ref.lo: \ crypto_stream/salsa2012/ref/$(am__dirstamp) \ crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa2012/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa2012 - @: > crypto_stream/salsa2012/$(am__dirstamp) + @: >>crypto_stream/salsa2012/$(am__dirstamp) crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa2012/$(DEPDIR) - @: > crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa2012/libsodium_la-stream_salsa2012.lo: \ crypto_stream/salsa2012/$(am__dirstamp) \ crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa208/ref/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa208/ref - @: > crypto_stream/salsa208/ref/$(am__dirstamp) + @: >>crypto_stream/salsa208/ref/$(am__dirstamp) crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa208/ref/$(DEPDIR) - @: > crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa208/ref/libsodium_la-stream_salsa208_ref.lo: \ crypto_stream/salsa208/ref/$(am__dirstamp) \ crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa208/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa208 - @: > crypto_stream/salsa208/$(am__dirstamp) + @: >>crypto_stream/salsa208/$(am__dirstamp) crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/salsa208/$(DEPDIR) - @: > crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp) crypto_stream/salsa208/libsodium_la-stream_salsa208.lo: \ crypto_stream/salsa208/$(am__dirstamp) \ crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp) crypto_stream/xchacha20/$(am__dirstamp): @$(MKDIR_P) crypto_stream/xchacha20 - @: > crypto_stream/xchacha20/$(am__dirstamp) + @: >>crypto_stream/xchacha20/$(am__dirstamp) crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_stream/xchacha20/$(DEPDIR) - @: > crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp) crypto_stream/xchacha20/libsodium_la-stream_xchacha20.lo: \ crypto_stream/xchacha20/$(am__dirstamp) \ crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp) randombytes/sysrandom/$(am__dirstamp): @$(MKDIR_P) randombytes/sysrandom - @: > randombytes/sysrandom/$(am__dirstamp) + @: >>randombytes/sysrandom/$(am__dirstamp) randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) randombytes/sysrandom/$(DEPDIR) - @: > randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp) + @: >>randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp) randombytes/sysrandom/libsodium_la-randombytes_sysrandom.lo: \ randombytes/sysrandom/$(am__dirstamp) \ randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp) @@ -1894,19 +2062,19 @@ libsodium.la: $(libsodium_la_OBJECTS) $(libsodium_la_DEPENDENCIES) $(EXTRA_libso $(AM_V_CCLD)$(libsodium_la_LINK) -rpath $(libdir) $(libsodium_la_OBJECTS) $(libsodium_la_LIBADD) $(LIBS) crypto_onetimeauth/poly1305/sse2/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305/sse2 - @: > crypto_onetimeauth/poly1305/sse2/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/sse2/$(am__dirstamp) crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_onetimeauth/poly1305/sse2/$(DEPDIR) - @: > crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp) crypto_onetimeauth/poly1305/sse2/libsse2_la-poly1305_sse2.lo: \ crypto_onetimeauth/poly1305/sse2/$(am__dirstamp) \ crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256/sse - @: > crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp): @$(MKDIR_P) crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR) - @: > crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp) + @: >>crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp) crypto_pwhash/scryptsalsa208sha256/sse/libsse2_la-pwhash_scryptsalsa208sha256_sse.lo: \ crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp) \ crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp) @@ -1937,12 +2105,20 @@ libssse3.la: $(libssse3_la_OBJECTS) $(libssse3_la_DEPENDENCIES) $(EXTRA_libssse3 mostlyclean-compile: -rm -f *.$(OBJEXT) + -rm -f crypto_aead/aegis128l/*.$(OBJEXT) + -rm -f crypto_aead/aegis128l/*.lo + -rm -f crypto_aead/aegis256/*.$(OBJEXT) + -rm -f crypto_aead/aegis256/*.lo + -rm -f crypto_aead/aes256gcm/*.$(OBJEXT) + -rm -f crypto_aead/aes256gcm/*.lo -rm -f crypto_aead/aes256gcm/aesni/*.$(OBJEXT) -rm -f crypto_aead/aes256gcm/aesni/*.lo - -rm -f crypto_aead/chacha20poly1305/sodium/*.$(OBJEXT) - -rm -f crypto_aead/chacha20poly1305/sodium/*.lo - -rm -f crypto_aead/xchacha20poly1305/sodium/*.$(OBJEXT) - -rm -f crypto_aead/xchacha20poly1305/sodium/*.lo + -rm -f crypto_aead/aes256gcm/armcrypto/*.$(OBJEXT) + -rm -f crypto_aead/aes256gcm/armcrypto/*.lo + -rm -f crypto_aead/chacha20poly1305/*.$(OBJEXT) + -rm -f crypto_aead/chacha20poly1305/*.lo + -rm -f crypto_aead/xchacha20poly1305/*.$(OBJEXT) + -rm -f crypto_aead/xchacha20poly1305/*.lo -rm -f crypto_auth/*.$(OBJEXT) -rm -f crypto_auth/*.lo -rm -f crypto_auth/hmacsha256/*.$(OBJEXT) @@ -1969,6 +2145,8 @@ mostlyclean-compile: -rm -f crypto_core/hsalsa20/ref2/*.lo -rm -f crypto_core/salsa/ref/*.$(OBJEXT) -rm -f crypto_core/salsa/ref/*.lo + -rm -f crypto_core/softaes/*.$(OBJEXT) + -rm -f crypto_core/softaes/*.lo -rm -f crypto_generichash/*.$(OBJEXT) -rm -f crypto_generichash/*.lo -rm -f crypto_generichash/blake2b/*.$(OBJEXT) @@ -1989,6 +2167,8 @@ mostlyclean-compile: -rm -f crypto_kdf/*.lo -rm -f crypto_kdf/blake2b/*.$(OBJEXT) -rm -f crypto_kdf/blake2b/*.lo + -rm -f crypto_kdf/hkdf/*.$(OBJEXT) + -rm -f crypto_kdf/hkdf/*.lo -rm -f crypto_kx/*.$(OBJEXT) -rm -f crypto_kx/*.lo -rm -f crypto_onetimeauth/*.$(OBJEXT) @@ -2069,8 +2249,8 @@ mostlyclean-compile: -rm -f crypto_stream/xchacha20/*.lo -rm -f crypto_stream/xsalsa20/*.$(OBJEXT) -rm -f crypto_stream/xsalsa20/*.lo - -rm -f crypto_verify/sodium/*.$(OBJEXT) - -rm -f crypto_verify/sodium/*.lo + -rm -f crypto_verify/*.$(OBJEXT) + -rm -f crypto_verify/*.lo -rm -f randombytes/*.$(OBJEXT) -rm -f randombytes/*.lo -rm -f randombytes/internal/*.$(OBJEXT) @@ -2083,9 +2263,19 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_auth/$(DEPDIR)/libsodium_la-crypto_auth.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_auth/hmacsha256/$(DEPDIR)/libsodium_la-auth_hmacsha256.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_auth/hmacsha512/$(DEPDIR)/libsodium_la-auth_hmacsha512.Plo@am__quote@ # am--include-marker @@ -2103,6 +2293,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@crypto_core/hsalsa20/$(DEPDIR)/libsodium_la-core_hsalsa20.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_core/hsalsa20/ref2/$(DEPDIR)/libsodium_la-core_hsalsa20_ref2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_core/salsa/ref/$(DEPDIR)/libsodium_la-core_salsa_ref.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_generichash/blake2b/$(DEPDIR)/libsodium_la-generichash_blake2.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Plo@am__quote@ # am--include-marker @@ -2118,6 +2309,8 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@crypto_hash/sha512/cp/$(DEPDIR)/libsodium_la-hash_sha512_cp.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_kdf/$(DEPDIR)/libsodium_la-crypto_kdf.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_kdf/blake2b/$(DEPDIR)/libsodium_la-kdf_blake2b.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_onetimeauth/$(DEPDIR)/libsodium_la-crypto_onetimeauth.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_onetimeauth/poly1305/$(DEPDIR)/libsodium_la-onetimeauth_poly1305.Plo@am__quote@ # am--include-marker @@ -2182,7 +2375,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@crypto_stream/salsa208/ref/$(DEPDIR)/libsodium_la-stream_salsa208_ref.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_stream/xchacha20/$(DEPDIR)/libsodium_la-stream_xchacha20.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@crypto_stream/xsalsa20/$(DEPDIR)/libsodium_la-stream_xsalsa20.Plo@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Plo@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@crypto_verify/$(DEPDIR)/libsodium_la-verify.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@randombytes/$(DEPDIR)/libsodium_la-randombytes.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@randombytes/internal/$(DEPDIR)/librdrand_la-randombytes_internal_random.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@randombytes/sysrandom/$(DEPDIR)/libsodium_la-randombytes_sysrandom.Plo@am__quote@ # am--include-marker @@ -2194,7 +2387,7 @@ distclean-compile: $(am__depfiles_remade): @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ + @: >>$@ am--depfiles: $(am__depfiles_remade) @@ -2260,6 +2453,20 @@ crypto_scalarmult/curve25519/sandy2x/libsodium_la-sandy2x.lo: crypto_scalarmult/ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< +crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo: crypto_aead/aegis128l/aegis128l_aesni.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo -MD -MP -MF crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Tpo -c -o crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo `test -f 'crypto_aead/aegis128l/aegis128l_aesni.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_aesni.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Tpo crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis128l/aegis128l_aesni.c' object='crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis128l/libaesni_la-aegis128l_aesni.lo `test -f 'crypto_aead/aegis128l/aegis128l_aesni.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_aesni.c + +crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo: crypto_aead/aegis256/aegis256_aesni.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo -MD -MP -MF crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Tpo -c -o crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo `test -f 'crypto_aead/aegis256/aegis256_aesni.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_aesni.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Tpo crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis256/aegis256_aesni.c' object='crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis256/libaesni_la-aegis256_aesni.lo `test -f 'crypto_aead/aegis256/aegis256_aesni.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_aesni.c + crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo: crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo -MD -MP -MF crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Tpo -c -o crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo `test -f 'crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Tpo crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo @@ -2267,6 +2474,27 @@ crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo: crypto_aead/aes @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libaesni_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aes256gcm/aesni/libaesni_la-aead_aes256gcm_aesni.lo `test -f 'crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c +crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo: crypto_aead/aegis128l/aegis128l_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo -MD -MP -MF crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Tpo -c -o crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo `test -f 'crypto_aead/aegis128l/aegis128l_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Tpo crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis128l/aegis128l_armcrypto.c' object='crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis128l/libarmcrypto_la-aegis128l_armcrypto.lo `test -f 'crypto_aead/aegis128l/aegis128l_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_armcrypto.c + +crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo: crypto_aead/aegis256/aegis256_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo -MD -MP -MF crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Tpo -c -o crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo `test -f 'crypto_aead/aegis256/aegis256_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Tpo crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis256/aegis256_armcrypto.c' object='crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis256/libarmcrypto_la-aegis256_armcrypto.lo `test -f 'crypto_aead/aegis256/aegis256_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_armcrypto.c + +crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo: crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo -MD -MP -MF crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Tpo -c -o crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo `test -f 'crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Tpo crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c' object='crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libarmcrypto_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aes256gcm/armcrypto/libarmcrypto_la-aead_aes256gcm_armcrypto.lo `test -f 'crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c + crypto_generichash/blake2b/ref/libavx2_la-blake2b-compress-avx2.lo: crypto_generichash/blake2b/ref/blake2b-compress-avx2.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libavx2_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_generichash/blake2b/ref/libavx2_la-blake2b-compress-avx2.lo -MD -MP -MF crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Tpo -c -o crypto_generichash/blake2b/ref/libavx2_la-blake2b-compress-avx2.lo `test -f 'crypto_generichash/blake2b/ref/blake2b-compress-avx2.c' || echo '$(srcdir)/'`crypto_generichash/blake2b/ref/blake2b-compress-avx2.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Tpo crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Plo @@ -2309,19 +2537,54 @@ randombytes/internal/librdrand_la-randombytes_internal_random.lo: randombytes/in @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(librdrand_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o randombytes/internal/librdrand_la-randombytes_internal_random.lo `test -f 'randombytes/internal/randombytes_internal_random.c' || echo '$(srcdir)/'`randombytes/internal/randombytes_internal_random.c -crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo: crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo -MD -MP -MF crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Tpo -c -o crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo `test -f 'crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Tpo crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c' object='crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo' libtool=yes @AMDEPBACKSLASH@ +crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo: crypto_aead/aegis128l/aead_aegis128l.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo -MD -MP -MF crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Tpo -c -o crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo `test -f 'crypto_aead/aegis128l/aead_aegis128l.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aead_aegis128l.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Tpo crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis128l/aead_aegis128l.c' object='crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis128l/libsodium_la-aead_aegis128l.lo `test -f 'crypto_aead/aegis128l/aead_aegis128l.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aead_aegis128l.c + +crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo: crypto_aead/aegis128l/aegis128l_soft.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo -MD -MP -MF crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Tpo -c -o crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo `test -f 'crypto_aead/aegis128l/aegis128l_soft.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_soft.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Tpo crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis128l/aegis128l_soft.c' object='crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis128l/libsodium_la-aegis128l_soft.lo `test -f 'crypto_aead/aegis128l/aegis128l_soft.c' || echo '$(srcdir)/'`crypto_aead/aegis128l/aegis128l_soft.c + +crypto_aead/aegis256/libsodium_la-aead_aegis256.lo: crypto_aead/aegis256/aead_aegis256.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis256/libsodium_la-aead_aegis256.lo -MD -MP -MF crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Tpo -c -o crypto_aead/aegis256/libsodium_la-aead_aegis256.lo `test -f 'crypto_aead/aegis256/aead_aegis256.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aead_aegis256.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Tpo crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis256/aead_aegis256.c' object='crypto_aead/aegis256/libsodium_la-aead_aegis256.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis256/libsodium_la-aead_aegis256.lo `test -f 'crypto_aead/aegis256/aead_aegis256.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aead_aegis256.c + +crypto_aead/aegis256/libsodium_la-aegis256_soft.lo: crypto_aead/aegis256/aegis256_soft.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aegis256/libsodium_la-aegis256_soft.lo -MD -MP -MF crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Tpo -c -o crypto_aead/aegis256/libsodium_la-aegis256_soft.lo `test -f 'crypto_aead/aegis256/aegis256_soft.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_soft.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Tpo crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aegis256/aegis256_soft.c' object='crypto_aead/aegis256/libsodium_la-aegis256_soft.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/chacha20poly1305/sodium/libsodium_la-aead_chacha20poly1305.lo `test -f 'crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aegis256/libsodium_la-aegis256_soft.lo `test -f 'crypto_aead/aegis256/aegis256_soft.c' || echo '$(srcdir)/'`crypto_aead/aegis256/aegis256_soft.c -crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo: crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo -MD -MP -MF crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Tpo -c -o crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo `test -f 'crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Tpo crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c' object='crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo' libtool=yes @AMDEPBACKSLASH@ +crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo: crypto_aead/aes256gcm/aead_aes256gcm.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo -MD -MP -MF crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Tpo -c -o crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo `test -f 'crypto_aead/aes256gcm/aead_aes256gcm.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/aead_aes256gcm.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Tpo crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/aes256gcm/aead_aes256gcm.c' object='crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/xchacha20poly1305/sodium/libsodium_la-aead_xchacha20poly1305.lo `test -f 'crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/aes256gcm/libsodium_la-aead_aes256gcm.lo `test -f 'crypto_aead/aes256gcm/aead_aes256gcm.c' || echo '$(srcdir)/'`crypto_aead/aes256gcm/aead_aes256gcm.c + +crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo: crypto_aead/chacha20poly1305/aead_chacha20poly1305.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo -MD -MP -MF crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Tpo -c -o crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo `test -f 'crypto_aead/chacha20poly1305/aead_chacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/chacha20poly1305/aead_chacha20poly1305.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Tpo crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/chacha20poly1305/aead_chacha20poly1305.c' object='crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/chacha20poly1305/libsodium_la-aead_chacha20poly1305.lo `test -f 'crypto_aead/chacha20poly1305/aead_chacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/chacha20poly1305/aead_chacha20poly1305.c + +crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo: crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo -MD -MP -MF crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Tpo -c -o crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo `test -f 'crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Tpo crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c' object='crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_aead/xchacha20poly1305/libsodium_la-aead_xchacha20poly1305.lo `test -f 'crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c' || echo '$(srcdir)/'`crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c crypto_auth/libsodium_la-crypto_auth.lo: crypto_auth/crypto_auth.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_auth/libsodium_la-crypto_auth.lo -MD -MP -MF crypto_auth/$(DEPDIR)/libsodium_la-crypto_auth.Tpo -c -o crypto_auth/libsodium_la-crypto_auth.lo `test -f 'crypto_auth/crypto_auth.c' || echo '$(srcdir)/'`crypto_auth/crypto_auth.c @@ -2414,6 +2677,13 @@ crypto_core/salsa/ref/libsodium_la-core_salsa_ref.lo: crypto_core/salsa/ref/core @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_core/salsa/ref/libsodium_la-core_salsa_ref.lo `test -f 'crypto_core/salsa/ref/core_salsa_ref.c' || echo '$(srcdir)/'`crypto_core/salsa/ref/core_salsa_ref.c +crypto_core/softaes/libsodium_la-softaes.lo: crypto_core/softaes/softaes.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_core/softaes/libsodium_la-softaes.lo -MD -MP -MF crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Tpo -c -o crypto_core/softaes/libsodium_la-softaes.lo `test -f 'crypto_core/softaes/softaes.c' || echo '$(srcdir)/'`crypto_core/softaes/softaes.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Tpo crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_core/softaes/softaes.c' object='crypto_core/softaes/libsodium_la-softaes.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_core/softaes/libsodium_la-softaes.lo `test -f 'crypto_core/softaes/softaes.c' || echo '$(srcdir)/'`crypto_core/softaes/softaes.c + crypto_generichash/libsodium_la-crypto_generichash.lo: crypto_generichash/crypto_generichash.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_generichash/libsodium_la-crypto_generichash.lo -MD -MP -MF crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Tpo -c -o crypto_generichash/libsodium_la-crypto_generichash.lo `test -f 'crypto_generichash/crypto_generichash.c' || echo '$(srcdir)/'`crypto_generichash/crypto_generichash.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Tpo crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Plo @@ -2498,6 +2768,20 @@ crypto_kdf/libsodium_la-crypto_kdf.lo: crypto_kdf/crypto_kdf.c @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_kdf/libsodium_la-crypto_kdf.lo `test -f 'crypto_kdf/crypto_kdf.c' || echo '$(srcdir)/'`crypto_kdf/crypto_kdf.c +crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo: crypto_kdf/hkdf/kdf_hkdf_sha256.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo -MD -MP -MF crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Tpo -c -o crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo `test -f 'crypto_kdf/hkdf/kdf_hkdf_sha256.c' || echo '$(srcdir)/'`crypto_kdf/hkdf/kdf_hkdf_sha256.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Tpo crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_kdf/hkdf/kdf_hkdf_sha256.c' object='crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha256.lo `test -f 'crypto_kdf/hkdf/kdf_hkdf_sha256.c' || echo '$(srcdir)/'`crypto_kdf/hkdf/kdf_hkdf_sha256.c + +crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo: crypto_kdf/hkdf/kdf_hkdf_sha512.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo -MD -MP -MF crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Tpo -c -o crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo `test -f 'crypto_kdf/hkdf/kdf_hkdf_sha512.c' || echo '$(srcdir)/'`crypto_kdf/hkdf/kdf_hkdf_sha512.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Tpo crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_kdf/hkdf/kdf_hkdf_sha512.c' object='crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo' libtool=yes @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_kdf/hkdf/libsodium_la-kdf_hkdf_sha512.lo `test -f 'crypto_kdf/hkdf/kdf_hkdf_sha512.c' || echo '$(srcdir)/'`crypto_kdf/hkdf/kdf_hkdf_sha512.c + crypto_kx/libsodium_la-crypto_kx.lo: crypto_kx/crypto_kx.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_kx/libsodium_la-crypto_kx.lo -MD -MP -MF crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Tpo -c -o crypto_kx/libsodium_la-crypto_kx.lo `test -f 'crypto_kx/crypto_kx.c' || echo '$(srcdir)/'`crypto_kx/crypto_kx.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Tpo crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Plo @@ -2722,12 +3006,12 @@ crypto_stream/xsalsa20/libsodium_la-stream_xsalsa20.lo: crypto_stream/xsalsa20/s @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_stream/xsalsa20/libsodium_la-stream_xsalsa20.lo `test -f 'crypto_stream/xsalsa20/stream_xsalsa20.c' || echo '$(srcdir)/'`crypto_stream/xsalsa20/stream_xsalsa20.c -crypto_verify/sodium/libsodium_la-verify.lo: crypto_verify/sodium/verify.c -@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_verify/sodium/libsodium_la-verify.lo -MD -MP -MF crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Tpo -c -o crypto_verify/sodium/libsodium_la-verify.lo `test -f 'crypto_verify/sodium/verify.c' || echo '$(srcdir)/'`crypto_verify/sodium/verify.c -@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Tpo crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Plo -@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_verify/sodium/verify.c' object='crypto_verify/sodium/libsodium_la-verify.lo' libtool=yes @AMDEPBACKSLASH@ +crypto_verify/libsodium_la-verify.lo: crypto_verify/verify.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT crypto_verify/libsodium_la-verify.lo -MD -MP -MF crypto_verify/$(DEPDIR)/libsodium_la-verify.Tpo -c -o crypto_verify/libsodium_la-verify.lo `test -f 'crypto_verify/verify.c' || echo '$(srcdir)/'`crypto_verify/verify.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) crypto_verify/$(DEPDIR)/libsodium_la-verify.Tpo crypto_verify/$(DEPDIR)/libsodium_la-verify.Plo +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='crypto_verify/verify.c' object='crypto_verify/libsodium_la-verify.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_verify/sodium/libsodium_la-verify.lo `test -f 'crypto_verify/sodium/verify.c' || echo '$(srcdir)/'`crypto_verify/sodium/verify.c +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o crypto_verify/libsodium_la-verify.lo `test -f 'crypto_verify/verify.c' || echo '$(srcdir)/'`crypto_verify/verify.c randombytes/libsodium_la-randombytes.lo: randombytes/randombytes.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libsodium_la_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT randombytes/libsodium_la-randombytes.lo -MD -MP -MF randombytes/$(DEPDIR)/libsodium_la-randombytes.Tpo -c -o randombytes/libsodium_la-randombytes.lo `test -f 'randombytes/randombytes.c' || echo '$(srcdir)/'`randombytes/randombytes.c @@ -3007,9 +3291,13 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs + -rm -rf crypto_aead/aegis128l/.libs crypto_aead/aegis128l/_libs + -rm -rf crypto_aead/aegis256/.libs crypto_aead/aegis256/_libs + -rm -rf crypto_aead/aes256gcm/.libs crypto_aead/aes256gcm/_libs -rm -rf crypto_aead/aes256gcm/aesni/.libs crypto_aead/aes256gcm/aesni/_libs - -rm -rf crypto_aead/chacha20poly1305/sodium/.libs crypto_aead/chacha20poly1305/sodium/_libs - -rm -rf crypto_aead/xchacha20poly1305/sodium/.libs crypto_aead/xchacha20poly1305/sodium/_libs + -rm -rf crypto_aead/aes256gcm/armcrypto/.libs crypto_aead/aes256gcm/armcrypto/_libs + -rm -rf crypto_aead/chacha20poly1305/.libs crypto_aead/chacha20poly1305/_libs + -rm -rf crypto_aead/xchacha20poly1305/.libs crypto_aead/xchacha20poly1305/_libs -rm -rf crypto_auth/.libs crypto_auth/_libs -rm -rf crypto_auth/hmacsha256/.libs crypto_auth/hmacsha256/_libs -rm -rf crypto_auth/hmacsha512/.libs crypto_auth/hmacsha512/_libs @@ -3023,6 +3311,7 @@ clean-libtool: -rm -rf crypto_core/hsalsa20/.libs crypto_core/hsalsa20/_libs -rm -rf crypto_core/hsalsa20/ref2/.libs crypto_core/hsalsa20/ref2/_libs -rm -rf crypto_core/salsa/ref/.libs crypto_core/salsa/ref/_libs + -rm -rf crypto_core/softaes/.libs crypto_core/softaes/_libs -rm -rf crypto_generichash/.libs crypto_generichash/_libs -rm -rf crypto_generichash/blake2b/.libs crypto_generichash/blake2b/_libs -rm -rf crypto_generichash/blake2b/ref/.libs crypto_generichash/blake2b/ref/_libs @@ -3033,6 +3322,7 @@ clean-libtool: -rm -rf crypto_hash/sha512/cp/.libs crypto_hash/sha512/cp/_libs -rm -rf crypto_kdf/.libs crypto_kdf/_libs -rm -rf crypto_kdf/blake2b/.libs crypto_kdf/blake2b/_libs + -rm -rf crypto_kdf/hkdf/.libs crypto_kdf/hkdf/_libs -rm -rf crypto_kx/.libs crypto_kx/_libs -rm -rf crypto_onetimeauth/.libs crypto_onetimeauth/_libs -rm -rf crypto_onetimeauth/poly1305/.libs crypto_onetimeauth/poly1305/_libs @@ -3073,7 +3363,7 @@ clean-libtool: -rm -rf crypto_stream/salsa208/ref/.libs crypto_stream/salsa208/ref/_libs -rm -rf crypto_stream/xchacha20/.libs crypto_stream/xchacha20/_libs -rm -rf crypto_stream/xsalsa20/.libs crypto_stream/xsalsa20/_libs - -rm -rf crypto_verify/sodium/.libs crypto_verify/sodium/_libs + -rm -rf crypto_verify/.libs crypto_verify/_libs -rm -rf randombytes/.libs randombytes/_libs -rm -rf randombytes/internal/.libs randombytes/internal/_libs -rm -rf randombytes/sysrandom/.libs randombytes/sysrandom/_libs @@ -3133,6 +3423,11 @@ $(am__recursive_targets): if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -3287,166 +3582,208 @@ install-strip: mostlyclean-generic: clean-generic: - -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) + -$(am__rm_f) $(CLEANFILES) distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -rm -f crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_aead/aes256gcm/aesni/$(am__dirstamp) - -rm -f crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_aead/chacha20poly1305/sodium/$(am__dirstamp) - -rm -f crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_aead/xchacha20poly1305/sodium/$(am__dirstamp) - -rm -f crypto_auth/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_auth/$(am__dirstamp) - -rm -f crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_auth/hmacsha256/$(am__dirstamp) - -rm -f crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_auth/hmacsha512/$(am__dirstamp) - -rm -f crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_auth/hmacsha512256/$(am__dirstamp) - -rm -f crypto_box/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_box/$(am__dirstamp) - -rm -f crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_box/curve25519xchacha20poly1305/$(am__dirstamp) - -rm -f crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp) - -rm -f crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/ed25519/$(am__dirstamp) - -rm -f crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/ed25519/ref10/$(am__dirstamp) - -rm -f crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/hchacha20/$(am__dirstamp) - -rm -f crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/hsalsa20/$(am__dirstamp) - -rm -f crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/hsalsa20/ref2/$(am__dirstamp) - -rm -f crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_core/salsa/ref/$(am__dirstamp) - -rm -f crypto_generichash/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_generichash/$(am__dirstamp) - -rm -f crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_generichash/blake2b/$(am__dirstamp) - -rm -f crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_generichash/blake2b/ref/$(am__dirstamp) - -rm -f crypto_hash/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_hash/$(am__dirstamp) - -rm -f crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_hash/sha256/$(am__dirstamp) - -rm -f crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_hash/sha256/cp/$(am__dirstamp) - -rm -f crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_hash/sha512/$(am__dirstamp) - -rm -f crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_hash/sha512/cp/$(am__dirstamp) - -rm -f crypto_kdf/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_kdf/$(am__dirstamp) - -rm -f crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_kdf/blake2b/$(am__dirstamp) - -rm -f crypto_kx/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_kx/$(am__dirstamp) - -rm -f crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_onetimeauth/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/donna/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_onetimeauth/poly1305/sse2/$(am__dirstamp) - -rm -f crypto_pwhash/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_pwhash/$(am__dirstamp) - -rm -f crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_pwhash/argon2/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp) - -rm -f crypto_scalarmult/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/ref10/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp) - -rm -f crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/ed25519/ref10/$(am__dirstamp) - -rm -f crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_scalarmult/ristretto255/ref10/$(am__dirstamp) - -rm -f crypto_secretbox/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_secretbox/$(am__dirstamp) - -rm -f crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_secretbox/xchacha20poly1305/$(am__dirstamp) - -rm -f crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_secretbox/xsalsa20poly1305/$(am__dirstamp) - -rm -f crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_secretstream/xchacha20poly1305/$(am__dirstamp) - -rm -f crypto_shorthash/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_shorthash/$(am__dirstamp) - -rm -f crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_shorthash/siphash24/$(am__dirstamp) - -rm -f crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_shorthash/siphash24/ref/$(am__dirstamp) - -rm -f crypto_sign/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_sign/$(am__dirstamp) - -rm -f crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_sign/ed25519/$(am__dirstamp) - -rm -f crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_sign/ed25519/ref10/$(am__dirstamp) - -rm -f crypto_stream/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/$(am__dirstamp) - -rm -f crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/chacha20/$(am__dirstamp) - -rm -f crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/chacha20/dolbeau/$(am__dirstamp) - -rm -f crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/chacha20/ref/$(am__dirstamp) - -rm -f crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa20/$(am__dirstamp) - -rm -f crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa20/ref/$(am__dirstamp) - -rm -f crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa20/xmm6/$(am__dirstamp) - -rm -f crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa20/xmm6int/$(am__dirstamp) - -rm -f crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa2012/$(am__dirstamp) - -rm -f crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa2012/ref/$(am__dirstamp) - -rm -f crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa208/$(am__dirstamp) - -rm -f crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/salsa208/ref/$(am__dirstamp) - -rm -f crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/xchacha20/$(am__dirstamp) - -rm -f crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_stream/xsalsa20/$(am__dirstamp) - -rm -f crypto_verify/sodium/$(DEPDIR)/$(am__dirstamp) - -rm -f crypto_verify/sodium/$(am__dirstamp) - -rm -f randombytes/$(DEPDIR)/$(am__dirstamp) - -rm -f randombytes/$(am__dirstamp) - -rm -f randombytes/internal/$(DEPDIR)/$(am__dirstamp) - -rm -f randombytes/internal/$(am__dirstamp) - -rm -f randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp) - -rm -f randombytes/sysrandom/$(am__dirstamp) - -rm -f sodium/$(DEPDIR)/$(am__dirstamp) - -rm -f sodium/$(am__dirstamp) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) crypto_aead/aegis128l/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aegis128l/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aegis256/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aegis256/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/aesni/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/aesni/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/aes256gcm/armcrypto/$(am__dirstamp) + -$(am__rm_f) crypto_aead/chacha20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/chacha20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_aead/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_aead/xchacha20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_auth/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_auth/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha256/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha256/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha512/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha512/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha512256/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_auth/hmacsha512256/$(am__dirstamp) + -$(am__rm_f) crypto_box/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_box/$(am__dirstamp) + -$(am__rm_f) crypto_box/curve25519xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_box/curve25519xchacha20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_box/curve25519xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_box/curve25519xsalsa20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_core/ed25519/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/ed25519/$(am__dirstamp) + -$(am__rm_f) crypto_core/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/ed25519/ref10/$(am__dirstamp) + -$(am__rm_f) crypto_core/hchacha20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/hchacha20/$(am__dirstamp) + -$(am__rm_f) crypto_core/hsalsa20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/hsalsa20/$(am__dirstamp) + -$(am__rm_f) crypto_core/hsalsa20/ref2/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/hsalsa20/ref2/$(am__dirstamp) + -$(am__rm_f) crypto_core/salsa/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/salsa/ref/$(am__dirstamp) + -$(am__rm_f) crypto_core/softaes/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_core/softaes/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/blake2b/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/blake2b/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/blake2b/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_generichash/blake2b/ref/$(am__dirstamp) + -$(am__rm_f) crypto_hash/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_hash/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha256/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha256/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha256/cp/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha256/cp/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha512/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha512/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha512/cp/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_hash/sha512/cp/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/blake2b/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/blake2b/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/hkdf/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_kdf/hkdf/$(am__dirstamp) + -$(am__rm_f) crypto_kx/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_kx/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/donna/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/donna/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/sse2/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_onetimeauth/poly1305/sse2/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/argon2/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/argon2/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/nosse/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/nosse/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/sse/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_pwhash/scryptsalsa208sha256/sse/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/ref10/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/ref10/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/sandy2x/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/curve25519/sandy2x/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/ed25519/ref10/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/ristretto255/ref10/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_scalarmult/ristretto255/ref10/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/xchacha20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/xsalsa20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_secretbox/xsalsa20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_secretstream/xchacha20poly1305/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_secretstream/xchacha20poly1305/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/siphash24/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/siphash24/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/siphash24/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_shorthash/siphash24/ref/$(am__dirstamp) + -$(am__rm_f) crypto_sign/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_sign/$(am__dirstamp) + -$(am__rm_f) crypto_sign/ed25519/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_sign/ed25519/$(am__dirstamp) + -$(am__rm_f) crypto_sign/ed25519/ref10/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_sign/ed25519/ref10/$(am__dirstamp) + -$(am__rm_f) crypto_stream/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/dolbeau/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/dolbeau/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/chacha20/ref/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/ref/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/xmm6/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/xmm6/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/xmm6int/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa20/xmm6int/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa2012/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa2012/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa2012/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa2012/ref/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa208/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa208/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa208/ref/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/salsa208/ref/$(am__dirstamp) + -$(am__rm_f) crypto_stream/xchacha20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/xchacha20/$(am__dirstamp) + -$(am__rm_f) crypto_stream/xsalsa20/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_stream/xsalsa20/$(am__dirstamp) + -$(am__rm_f) crypto_verify/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) crypto_verify/$(am__dirstamp) + -$(am__rm_f) randombytes/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) randombytes/$(am__dirstamp) + -$(am__rm_f) randombytes/internal/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) randombytes/internal/$(am__dirstamp) + -$(am__rm_f) randombytes/sysrandom/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) randombytes/sysrandom/$(am__dirstamp) + -$(am__rm_f) sodium/$(DEPDIR)/$(am__dirstamp) + -$(am__rm_f) sodium/$(am__dirstamp) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-recursive + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-recursive + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-recursive + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-recursive + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-recursive + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-recursive clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ clean-noinstLTLIBRARIES mostlyclean-am distclean: distclean-recursive - -rm -f crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo - -rm -f crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo - -rm -f crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Plo + -rm -f crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Plo + -rm -f crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo + -rm -f crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Plo + -rm -f crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo + -rm -f crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo -rm -f crypto_auth/$(DEPDIR)/libsodium_la-crypto_auth.Plo -rm -f crypto_auth/hmacsha256/$(DEPDIR)/libsodium_la-auth_hmacsha256.Plo -rm -f crypto_auth/hmacsha512/$(DEPDIR)/libsodium_la-auth_hmacsha512.Plo @@ -3464,6 +3801,7 @@ distclean: distclean-recursive -rm -f crypto_core/hsalsa20/$(DEPDIR)/libsodium_la-core_hsalsa20.Plo -rm -f crypto_core/hsalsa20/ref2/$(DEPDIR)/libsodium_la-core_hsalsa20_ref2.Plo -rm -f crypto_core/salsa/ref/$(DEPDIR)/libsodium_la-core_salsa_ref.Plo + -rm -f crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Plo -rm -f crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Plo -rm -f crypto_generichash/blake2b/$(DEPDIR)/libsodium_la-generichash_blake2.Plo -rm -f crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Plo @@ -3479,6 +3817,8 @@ distclean: distclean-recursive -rm -f crypto_hash/sha512/cp/$(DEPDIR)/libsodium_la-hash_sha512_cp.Plo -rm -f crypto_kdf/$(DEPDIR)/libsodium_la-crypto_kdf.Plo -rm -f crypto_kdf/blake2b/$(DEPDIR)/libsodium_la-kdf_blake2b.Plo + -rm -f crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Plo + -rm -f crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Plo -rm -f crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Plo -rm -f crypto_onetimeauth/$(DEPDIR)/libsodium_la-crypto_onetimeauth.Plo -rm -f crypto_onetimeauth/poly1305/$(DEPDIR)/libsodium_la-onetimeauth_poly1305.Plo @@ -3543,7 +3883,7 @@ distclean: distclean-recursive -rm -f crypto_stream/salsa208/ref/$(DEPDIR)/libsodium_la-stream_salsa208_ref.Plo -rm -f crypto_stream/xchacha20/$(DEPDIR)/libsodium_la-stream_xchacha20.Plo -rm -f crypto_stream/xsalsa20/$(DEPDIR)/libsodium_la-stream_xsalsa20.Plo - -rm -f crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Plo + -rm -f crypto_verify/$(DEPDIR)/libsodium_la-verify.Plo -rm -f randombytes/$(DEPDIR)/libsodium_la-randombytes.Plo -rm -f randombytes/internal/$(DEPDIR)/librdrand_la-randombytes_internal_random.Plo -rm -f randombytes/sysrandom/$(DEPDIR)/libsodium_la-randombytes_sysrandom.Plo @@ -3597,9 +3937,19 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive - -rm -f crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo - -rm -f crypto_aead/chacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo - -rm -f crypto_aead/xchacha20poly1305/sodium/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libaesni_la-aegis128l_aesni.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libarmcrypto_la-aegis128l_armcrypto.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aead_aegis128l.Plo + -rm -f crypto_aead/aegis128l/$(DEPDIR)/libsodium_la-aegis128l_soft.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libaesni_la-aegis256_aesni.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libarmcrypto_la-aegis256_armcrypto.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aead_aegis256.Plo + -rm -f crypto_aead/aegis256/$(DEPDIR)/libsodium_la-aegis256_soft.Plo + -rm -f crypto_aead/aes256gcm/$(DEPDIR)/libsodium_la-aead_aes256gcm.Plo + -rm -f crypto_aead/aes256gcm/aesni/$(DEPDIR)/libaesni_la-aead_aes256gcm_aesni.Plo + -rm -f crypto_aead/aes256gcm/armcrypto/$(DEPDIR)/libarmcrypto_la-aead_aes256gcm_armcrypto.Plo + -rm -f crypto_aead/chacha20poly1305/$(DEPDIR)/libsodium_la-aead_chacha20poly1305.Plo + -rm -f crypto_aead/xchacha20poly1305/$(DEPDIR)/libsodium_la-aead_xchacha20poly1305.Plo -rm -f crypto_auth/$(DEPDIR)/libsodium_la-crypto_auth.Plo -rm -f crypto_auth/hmacsha256/$(DEPDIR)/libsodium_la-auth_hmacsha256.Plo -rm -f crypto_auth/hmacsha512/$(DEPDIR)/libsodium_la-auth_hmacsha512.Plo @@ -3617,6 +3967,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f crypto_core/hsalsa20/$(DEPDIR)/libsodium_la-core_hsalsa20.Plo -rm -f crypto_core/hsalsa20/ref2/$(DEPDIR)/libsodium_la-core_hsalsa20_ref2.Plo -rm -f crypto_core/salsa/ref/$(DEPDIR)/libsodium_la-core_salsa_ref.Plo + -rm -f crypto_core/softaes/$(DEPDIR)/libsodium_la-softaes.Plo -rm -f crypto_generichash/$(DEPDIR)/libsodium_la-crypto_generichash.Plo -rm -f crypto_generichash/blake2b/$(DEPDIR)/libsodium_la-generichash_blake2.Plo -rm -f crypto_generichash/blake2b/ref/$(DEPDIR)/libavx2_la-blake2b-compress-avx2.Plo @@ -3632,6 +3983,8 @@ maintainer-clean: maintainer-clean-recursive -rm -f crypto_hash/sha512/cp/$(DEPDIR)/libsodium_la-hash_sha512_cp.Plo -rm -f crypto_kdf/$(DEPDIR)/libsodium_la-crypto_kdf.Plo -rm -f crypto_kdf/blake2b/$(DEPDIR)/libsodium_la-kdf_blake2b.Plo + -rm -f crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha256.Plo + -rm -f crypto_kdf/hkdf/$(DEPDIR)/libsodium_la-kdf_hkdf_sha512.Plo -rm -f crypto_kx/$(DEPDIR)/libsodium_la-crypto_kx.Plo -rm -f crypto_onetimeauth/$(DEPDIR)/libsodium_la-crypto_onetimeauth.Plo -rm -f crypto_onetimeauth/poly1305/$(DEPDIR)/libsodium_la-onetimeauth_poly1305.Plo @@ -3696,7 +4049,7 @@ maintainer-clean: maintainer-clean-recursive -rm -f crypto_stream/salsa208/ref/$(DEPDIR)/libsodium_la-stream_salsa208_ref.Plo -rm -f crypto_stream/xchacha20/$(DEPDIR)/libsodium_la-stream_xchacha20.Plo -rm -f crypto_stream/xsalsa20/$(DEPDIR)/libsodium_la-stream_xsalsa20.Plo - -rm -f crypto_verify/sodium/$(DEPDIR)/libsodium_la-verify.Plo + -rm -f crypto_verify/$(DEPDIR)/libsodium_la-verify.Plo -rm -f randombytes/$(DEPDIR)/libsodium_la-randombytes.Plo -rm -f randombytes/internal/$(DEPDIR)/librdrand_la-randombytes_internal_random.Plo -rm -f randombytes/sysrandom/$(DEPDIR)/libsodium_la-randombytes_sysrandom.Plo @@ -3726,7 +4079,12 @@ uninstall-am: uninstall-defexecDATA uninstall-libLTLIBRARIES .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ - am--depfiles check check-am clean clean-generic \ + am--depfiles check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-generic \ clean-libLTLIBRARIES clean-libtool clean-noinstLTLIBRARIES \ cscopelist-am ctags ctags-am distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ @@ -3749,3 +4107,10 @@ uninstall-am: uninstall-defexecDATA uninstall-libLTLIBRARIES # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aead_aegis128l.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aead_aegis128l.c @@ -0,0 +1,159 @@ + +#include <errno.h> +#include <stdlib.h> + +#include "core.h" +#include "crypto_aead_aegis128l.h" +#include "private/common.h" +#include "private/implementations.h" +#include "randombytes.h" +#include "runtime.h" + +#include "aegis128l_soft.h" + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) +#include "aegis128l_armcrypto.h" +#endif + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) +#include "aegis128l_aesni.h" +#endif + +static const aegis128l_implementation *implementation = &aegis128l_soft_implementation; + +size_t +crypto_aead_aegis128l_keybytes(void) +{ + return crypto_aead_aegis128l_KEYBYTES; +} + +size_t +crypto_aead_aegis128l_nsecbytes(void) +{ + return crypto_aead_aegis128l_NSECBYTES; +} + +size_t +crypto_aead_aegis128l_npubbytes(void) +{ + return crypto_aead_aegis128l_NPUBBYTES; +} + +size_t +crypto_aead_aegis128l_abytes(void) +{ + return crypto_aead_aegis128l_ABYTES; +} + +size_t +crypto_aead_aegis128l_messagebytes_max(void) +{ + return crypto_aead_aegis128l_MESSAGEBYTES_MAX; +} + +void +crypto_aead_aegis128l_keygen(unsigned char k[crypto_aead_aegis128l_KEYBYTES]) +{ + randombytes_buf(k, crypto_aead_aegis128l_KEYBYTES); +} + +int +crypto_aead_aegis128l_encrypt(unsigned char *c, unsigned long long *clen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + unsigned long long clen = 0ULL; + int ret; + + ret = crypto_aead_aegis128l_encrypt_detached(c, c + mlen, NULL, m, mlen, ad, adlen, nsec, npub, + k); + if (clen_p != NULL) { + if (ret == 0) { + clen = mlen + crypto_aead_aegis128l_ABYTES; + } + *clen_p = clen; + } + return ret; +} + +int +crypto_aead_aegis128l_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) +{ + unsigned long long mlen = 0ULL; + int ret = -1; + + if (clen >= crypto_aead_aegis128l_ABYTES) { + ret = crypto_aead_aegis128l_decrypt_detached( + m, nsec, c, clen - crypto_aead_aegis128l_ABYTES, + c + clen - crypto_aead_aegis128l_ABYTES, ad, adlen, npub, k); + } + if (mlen_p != NULL) { + if (ret == 0) { + mlen = clen - crypto_aead_aegis128l_ABYTES; + } + *mlen_p = mlen; + } + return ret; +} + +int +crypto_aead_aegis128l_encrypt_detached(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + const size_t maclen = crypto_aead_aegis128l_ABYTES; + + if (maclen_p != NULL) { + *maclen_p = maclen; + } + if (mlen > crypto_aead_aegis128l_MESSAGEBYTES_MAX || + adlen > crypto_aead_aegis128l_MESSAGEBYTES_MAX) { + sodium_misuse(); + } + return implementation->encrypt_detached(c, mac, maclen, m, (size_t) mlen, ad, (size_t) adlen, + npub, k); +} + +int +crypto_aead_aegis128l_decrypt_detached(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *mac, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const unsigned char *k) +{ + const size_t maclen = crypto_aead_aegis128l_ABYTES; + + if (clen > crypto_aead_aegis128l_MESSAGEBYTES_MAX || + adlen > crypto_aead_aegis128l_MESSAGEBYTES_MAX) { + return -1; + } + return implementation->decrypt_detached(m, c, (size_t) clen, mac, maclen, ad, (size_t) adlen, + npub, k); +} + +int +_crypto_aead_aegis128l_pick_best_implementation(void) +{ + implementation = &aegis128l_soft_implementation; + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) + if (sodium_runtime_has_armcrypto()) { + implementation = &aegis128l_armcrypto_implementation; + return 0; + } +#endif + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) + if (sodium_runtime_has_aesni() & sodium_runtime_has_avx()) { + implementation = &aegis128l_aesni_implementation; + return 0; + } +#endif + return 0; /* LCOV_EXCL_LINE */ +} diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.c @@ -0,0 +1,70 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis128l.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) + +#include "aegis128l_aesni.h" + +#ifdef __clang__ +#pragma clang attribute push(__attribute__((target("aes,avx"))), apply_to = function) +#elif defined(__GNUC__) +#pragma GCC target("aes,avx") +#endif + +#include "private/sse2_64_32.h" +#include <immintrin.h> +#include <wmmintrin.h> + +#define AES_BLOCK_LENGTH 16 + +typedef __m128i aes_block_t; +#define AES_BLOCK_XOR(A, B) _mm_xor_si128((A), (B)) +#define AES_BLOCK_AND(A, B) _mm_and_si128((A), (B)) +#define AES_BLOCK_LOAD(A) _mm_loadu_si128((const aes_block_t *) (const void *) (A)) +#define AES_BLOCK_LOAD_64x2(A, B) _mm_set_epi64x((long long) (A), (long long) (B)) +#define AES_BLOCK_STORE(A, B) _mm_storeu_si128((aes_block_t *) (void *) (A), (B)) +#define AES_ENC(A, B) _mm_aesenc_si128((A), (B)) + +static inline void +aegis128l_update(aes_block_t *const state, const aes_block_t d1, const aes_block_t d2) +{ + aes_block_t tmp; + + tmp = state[7]; + state[7] = AES_ENC(state[6], state[7]); + state[6] = AES_ENC(state[5], state[6]); + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_ENC(state[3], state[4]); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_ENC(tmp, state[0]); + + state[0] = AES_BLOCK_XOR(state[0], d1); + state[4] = AES_BLOCK_XOR(state[4], d2); +} + +#include "aegis128l_common.h" + +struct aegis128l_implementation aegis128l_aesni_implementation = { SODIUM_C99(.encrypt_detached =) + encrypt_detached, + SODIUM_C99(.decrypt_detached =) + decrypt_detached }; + +#ifdef __clang__ +#pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.h @@ -0,0 +1,8 @@ +#ifndef aegis128l_aesni_H +#define aegis128l_aesni_H + +#include "implementations.h" + +extern struct aegis128l_implementation aegis128l_aesni_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.c @@ -0,0 +1,72 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis128l.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) + +#include "aegis128l_armcrypto.h" + +#ifndef __ARM_FEATURE_CRYPTO +#define __ARM_FEATURE_CRYPTO 1 +#endif +#ifndef __ARM_FEATURE_AES +#define __ARM_FEATURE_AES 1 +#endif + +#include <arm_neon.h> + +#ifdef __clang__ +#pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) +#elif defined(__GNUC__) +#pragma GCC target("+simd+crypto") +#endif + +#define AES_BLOCK_LENGTH 16 + +typedef uint8x16_t aes_block_t; +#define AES_BLOCK_XOR(A, B) veorq_u8((A), (B)) +#define AES_BLOCK_AND(A, B) vandq_u8((A), (B)) +#define AES_BLOCK_LOAD(A) vld1q_u8(A) +#define AES_BLOCK_LOAD_64x2(A, B) vreinterpretq_u8_u64(vsetq_lane_u64((A), vmovq_n_u64(B), 1)) +#define AES_BLOCK_STORE(A, B) vst1q_u8((A), (B)) +#define AES_ENC(A, B) veorq_u8(vaesmcq_u8(vaeseq_u8(vmovq_n_u8(0), (A))), (B)) + +static inline void +aegis128l_update(aes_block_t *const state, const aes_block_t d1, const aes_block_t d2) +{ + aes_block_t tmp; + + tmp = state[7]; + state[7] = AES_ENC(state[6], state[7]); + state[6] = AES_ENC(state[5], state[6]); + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_BLOCK_XOR(AES_ENC(state[3], state[4]), d2); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_BLOCK_XOR(AES_ENC(tmp, state[0]), d1); +} + +#include "aegis128l_common.h" + +struct aegis128l_implementation aegis128l_armcrypto_implementation = { + SODIUM_C99(.encrypt_detached =) encrypt_detached, + SODIUM_C99(.decrypt_detached =) decrypt_detached +}; + +#ifdef __clang__ +#pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.h @@ -0,0 +1,8 @@ +#ifndef aegis128l_armcrypto_H +#define aegis128l_armcrypto_H + +#include "implementations.h" + +extern struct aegis128l_implementation aegis128l_armcrypto_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_common.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_common.h @@ -0,0 +1,248 @@ +#define RATE 32 + +static void +aegis128l_init(const uint8_t *key, const uint8_t *nonce, aes_block_t *const state) +{ + static CRYPTO_ALIGN(AES_BLOCK_LENGTH) + const uint8_t c0_[AES_BLOCK_LENGTH] = { 0x00, 0x01, 0x01, 0x02, 0x03, 0x05, 0x08, 0x0d, + 0x15, 0x22, 0x37, 0x59, 0x90, 0xe9, 0x79, 0x62 }; + static CRYPTO_ALIGN(AES_BLOCK_LENGTH) + const uint8_t c1_[AES_BLOCK_LENGTH] = { 0xdb, 0x3d, 0x18, 0x55, 0x6d, 0xc2, 0x2f, 0xf1, + 0x20, 0x11, 0x31, 0x42, 0x73, 0xb5, 0x28, 0xdd }; + + const aes_block_t c0 = AES_BLOCK_LOAD(c0_); + const aes_block_t c1 = AES_BLOCK_LOAD(c1_); + aes_block_t k; + aes_block_t n; + int i; + + k = AES_BLOCK_LOAD(key); + n = AES_BLOCK_LOAD(nonce); + + state[0] = AES_BLOCK_XOR(k, n); + state[1] = c1; + state[2] = c0; + state[3] = c1; + state[4] = AES_BLOCK_XOR(k, n); + state[5] = AES_BLOCK_XOR(k, c0); + state[6] = AES_BLOCK_XOR(k, c1); + state[7] = AES_BLOCK_XOR(k, c0); + for (i = 0; i < 10; i++) { + aegis128l_update(state, n, k); + } +} + +static void +aegis128l_mac(uint8_t *mac, size_t maclen, uint64_t adlen, uint64_t mlen, aes_block_t *const state) +{ + aes_block_t tmp; + int i; + + tmp = AES_BLOCK_LOAD_64x2(mlen << 3, adlen << 3); + tmp = AES_BLOCK_XOR(tmp, state[2]); + + for (i = 0; i < 7; i++) { + aegis128l_update(state, tmp, tmp); + } + + if (maclen == 16) { + tmp = AES_BLOCK_XOR(state[6], AES_BLOCK_XOR(state[5], state[4])); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[3], state[2])); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[1], state[0])); + AES_BLOCK_STORE(mac, tmp); + } else if (maclen == 32) { + tmp = AES_BLOCK_XOR(state[3], state[2]); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[1], state[0])); + AES_BLOCK_STORE(mac, tmp); + tmp = AES_BLOCK_XOR(state[7], state[6]); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[5], state[4])); + AES_BLOCK_STORE(mac + 16, tmp); + } else { + memset(mac, 0, maclen); + } +} + +static inline void +aegis128l_absorb(const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg0, msg1; + + msg0 = AES_BLOCK_LOAD(src); + msg1 = AES_BLOCK_LOAD(src + AES_BLOCK_LENGTH); + aegis128l_update(state, msg0, msg1); +} + +static inline void +aegis128l_absorb2(const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg0, msg1, msg2, msg3; + + msg0 = AES_BLOCK_LOAD(src + 0 * AES_BLOCK_LENGTH); + msg1 = AES_BLOCK_LOAD(src + 1 * AES_BLOCK_LENGTH); + msg2 = AES_BLOCK_LOAD(src + 2 * AES_BLOCK_LENGTH); + msg3 = AES_BLOCK_LOAD(src + 3 * AES_BLOCK_LENGTH); + aegis128l_update(state, msg0, msg1); + aegis128l_update(state, msg2, msg3); +} + +static void +aegis128l_enc(uint8_t *const dst, const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg0, msg1; + aes_block_t tmp0, tmp1; + + msg0 = AES_BLOCK_LOAD(src); + msg1 = AES_BLOCK_LOAD(src + AES_BLOCK_LENGTH); + tmp0 = AES_BLOCK_XOR(msg0, state[6]); + tmp0 = AES_BLOCK_XOR(tmp0, state[1]); + tmp1 = AES_BLOCK_XOR(msg1, state[5]); + tmp1 = AES_BLOCK_XOR(tmp1, state[2]); + tmp0 = AES_BLOCK_XOR(tmp0, AES_BLOCK_AND(state[2], state[3])); + tmp1 = AES_BLOCK_XOR(tmp1, AES_BLOCK_AND(state[6], state[7])); + AES_BLOCK_STORE(dst, tmp0); + AES_BLOCK_STORE(dst + AES_BLOCK_LENGTH, tmp1); + + aegis128l_update(state, msg0, msg1); +} + +static void +aegis128l_dec(uint8_t *const dst, const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg0, msg1; + + msg0 = AES_BLOCK_LOAD(src); + msg1 = AES_BLOCK_LOAD(src + AES_BLOCK_LENGTH); + msg0 = AES_BLOCK_XOR(msg0, state[6]); + msg0 = AES_BLOCK_XOR(msg0, state[1]); + msg1 = AES_BLOCK_XOR(msg1, state[5]); + msg1 = AES_BLOCK_XOR(msg1, state[2]); + msg0 = AES_BLOCK_XOR(msg0, AES_BLOCK_AND(state[2], state[3])); + msg1 = AES_BLOCK_XOR(msg1, AES_BLOCK_AND(state[6], state[7])); + AES_BLOCK_STORE(dst, msg0); + AES_BLOCK_STORE(dst + AES_BLOCK_LENGTH, msg1); + + aegis128l_update(state, msg0, msg1); +} + +static void +aegis128l_declast(uint8_t *const dst, const uint8_t *const src, size_t len, + aes_block_t *const state) +{ + uint8_t pad[RATE]; + aes_block_t msg0, msg1; + + memset(pad, 0, sizeof pad); + memcpy(pad, src, len); + + msg0 = AES_BLOCK_LOAD(pad); + msg1 = AES_BLOCK_LOAD(pad + AES_BLOCK_LENGTH); + msg0 = AES_BLOCK_XOR(msg0, state[6]); + msg0 = AES_BLOCK_XOR(msg0, state[1]); + msg1 = AES_BLOCK_XOR(msg1, state[5]); + msg1 = AES_BLOCK_XOR(msg1, state[2]); + msg0 = AES_BLOCK_XOR(msg0, AES_BLOCK_AND(state[2], state[3])); + msg1 = AES_BLOCK_XOR(msg1, AES_BLOCK_AND(state[6], state[7])); + AES_BLOCK_STORE(pad, msg0); + AES_BLOCK_STORE(pad + AES_BLOCK_LENGTH, msg1); + + memset(pad + len, 0, sizeof pad - len); + memcpy(dst, pad, len); + + msg0 = AES_BLOCK_LOAD(pad); + msg1 = AES_BLOCK_LOAD(pad + AES_BLOCK_LENGTH); + + aegis128l_update(state, msg0, msg1); +} + +static int +encrypt_detached(uint8_t *c, uint8_t *mac, size_t maclen, const uint8_t *m, size_t mlen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k) +{ + aes_block_t state[8]; + CRYPTO_ALIGN(RATE) uint8_t src[RATE]; + CRYPTO_ALIGN(RATE) uint8_t dst[RATE]; + size_t i; + + aegis128l_init(k, npub, state); + + for (i = 0; i + RATE * 2 <= adlen; i += RATE * 2) { + aegis128l_absorb2(ad + i, state); + } + for (; i + RATE <= adlen; i += RATE) { + aegis128l_absorb(ad + i, state); + } + if (adlen % RATE) { + memset(src, 0, RATE); + memcpy(src, ad + i, adlen % RATE); + aegis128l_absorb(src, state); + } + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis128l_enc(c + i, m + i, state); + } + if (mlen % RATE) { + memset(src, 0, RATE); + memcpy(src, m + i, mlen % RATE); + aegis128l_enc(dst, src, state); + memcpy(c + i, dst, mlen % RATE); + } + + aegis128l_mac(mac, maclen, adlen, mlen, state); + + return 0; +} + +static int +decrypt_detached(uint8_t *m, const uint8_t *c, size_t clen, const uint8_t *mac, size_t maclen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k) +{ + aes_block_t state[8]; + CRYPTO_ALIGN(RATE) uint8_t src[RATE]; + CRYPTO_ALIGN(RATE) uint8_t dst[RATE]; + CRYPTO_ALIGN(16) uint8_t computed_mac[32]; + const size_t mlen = clen; + size_t i; + int ret; + + aegis128l_init(k, npub, state); + + for (i = 0; i + RATE * 2 <= adlen; i += RATE * 2) { + aegis128l_absorb2(ad + i, state); + } + for (; i + RATE <= adlen; i += RATE) { + aegis128l_absorb(ad + i, state); + } + if (adlen % RATE) { + memset(src, 0, RATE); + memcpy(src, ad + i, adlen % RATE); + aegis128l_absorb(src, state); + } + if (m != NULL) { + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis128l_dec(m + i, c + i, state); + } + } else { + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis128l_dec(dst, c + i, state); + } + } + if (mlen % RATE) { + if (m != NULL) { + aegis128l_declast(m + i, c + i, mlen % RATE, state); + } else { + aegis128l_declast(dst, c + i, mlen % RATE, state); + } + } + + COMPILER_ASSERT(sizeof computed_mac >= 32); + aegis128l_mac(computed_mac, maclen, adlen, mlen, state); + ret = -1; + if (maclen == 16) { + ret = crypto_verify_16(computed_mac, mac); + } else if (maclen == 32) { + ret = crypto_verify_32(computed_mac, mac); + } + if (ret != 0 && m != NULL) { + memset(m, 0, mlen); + } + return ret; +} diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.c @@ -0,0 +1,59 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis128l.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#include "crypto_aead_aegis128l.h" +#include "private/softaes.h" + +#if 1 + +#include "aegis128l_soft.h" + +#define AES_BLOCK_LENGTH 16 + +typedef SoftAesBlock aes_block_t; +#define AES_BLOCK_XOR(A, B) softaes_block_xor((A), (B)) +#define AES_BLOCK_AND(A, B) softaes_block_and((A), (B)) +#define AES_BLOCK_LOAD(A) softaes_block_load(A) +#define AES_BLOCK_LOAD_64x2(A, B) softaes_block_load64x2((A), (B)) +#define AES_BLOCK_STORE(A, B) softaes_block_store((A), (B)) +#define AES_ENC(A, B) softaes_block_encrypt((A), (B)) + +static inline void +aegis128l_update(aes_block_t *const state, const aes_block_t d1, const aes_block_t d2) +{ + aes_block_t tmp; + + tmp = state[7]; + state[7] = AES_ENC(state[6], state[7]); + state[6] = AES_ENC(state[5], state[6]); + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_ENC(state[3], state[4]); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_ENC(tmp, state[0]); + + state[0] = AES_BLOCK_XOR(state[0], d1); + state[4] = AES_BLOCK_XOR(state[4], d2); +} + +#include "aegis128l_common.h" + +struct aegis128l_implementation aegis128l_soft_implementation = { SODIUM_C99(.encrypt_detached =) + encrypt_detached, + SODIUM_C99(.decrypt_detached =) + decrypt_detached }; + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.h @@ -0,0 +1,8 @@ +#ifndef aegis128l_soft_H +#define aegis128l_soft_H + +#include "implementations.h" + +extern struct aegis128l_implementation aegis128l_soft_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/implementations.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis128l/implementations.h @@ -0,0 +1,17 @@ +#ifndef aegis128l_implementations_H +#define aegis128l_implementations_H + +#include <stddef.h> +#include <stdint.h> + +#include "crypto_aead_aegis128l.h" + +typedef struct aegis128l_implementation { + int (*encrypt_detached)(uint8_t *c, uint8_t *mac, size_t maclen, const uint8_t *m, size_t mlen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k); + int (*decrypt_detached)(uint8_t *m, const uint8_t *c, size_t clen, const uint8_t *mac, + size_t maclen, const uint8_t *ad, size_t adlen, const uint8_t *npub, + const uint8_t *k); +} aegis128l_implementation; + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aead_aegis256.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aead_aegis256.c @@ -0,0 +1,158 @@ + +#include <errno.h> +#include <stdlib.h> + +#include "core.h" +#include "crypto_aead_aegis256.h" +#include "private/common.h" +#include "private/implementations.h" +#include "randombytes.h" +#include "runtime.h" + +#include "aegis256_soft.h" + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) +#include "aegis256_armcrypto.h" +#endif + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) +#include "aegis256_aesni.h" +#endif + +static const aegis256_implementation *implementation = &aegis256_soft_implementation; + +size_t +crypto_aead_aegis256_keybytes(void) +{ + return crypto_aead_aegis256_KEYBYTES; +} + +size_t +crypto_aead_aegis256_nsecbytes(void) +{ + return crypto_aead_aegis256_NSECBYTES; +} + +size_t +crypto_aead_aegis256_npubbytes(void) +{ + return crypto_aead_aegis256_NPUBBYTES; +} + +size_t +crypto_aead_aegis256_abytes(void) +{ + return crypto_aead_aegis256_ABYTES; +} + +size_t +crypto_aead_aegis256_messagebytes_max(void) +{ + return crypto_aead_aegis256_MESSAGEBYTES_MAX; +} + +void +crypto_aead_aegis256_keygen(unsigned char k[crypto_aead_aegis256_KEYBYTES]) +{ + randombytes_buf(k, crypto_aead_aegis256_KEYBYTES); +} + +int +crypto_aead_aegis256_encrypt(unsigned char *c, unsigned long long *clen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + unsigned long long clen = 0ULL; + int ret; + + ret = + crypto_aead_aegis256_encrypt_detached(c, c + mlen, NULL, m, mlen, ad, adlen, nsec, npub, k); + if (clen_p != NULL) { + if (ret == 0) { + clen = mlen + crypto_aead_aegis256_ABYTES; + } + *clen_p = clen; + } + return ret; +} + +int +crypto_aead_aegis256_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) +{ + unsigned long long mlen = 0ULL; + int ret = -1; + + if (clen >= crypto_aead_aegis256_ABYTES) { + ret = crypto_aead_aegis256_decrypt_detached(m, nsec, c, clen - crypto_aead_aegis256_ABYTES, + c + clen - crypto_aead_aegis256_ABYTES, ad, + adlen, npub, k); + } + if (mlen_p != NULL) { + if (ret == 0) { + mlen = clen - crypto_aead_aegis256_ABYTES; + } + *mlen_p = mlen; + } + return ret; +} + +int +crypto_aead_aegis256_encrypt_detached(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + const size_t maclen = crypto_aead_aegis256_ABYTES; + + if (maclen_p != NULL) { + *maclen_p = maclen; + } + if (mlen > crypto_aead_aegis256_MESSAGEBYTES_MAX || + adlen > crypto_aead_aegis256_MESSAGEBYTES_MAX) { + sodium_misuse(); + } + return implementation->encrypt_detached(c, mac, maclen, m, (size_t) mlen, ad, (size_t) adlen, + npub, k); +} + +int +crypto_aead_aegis256_decrypt_detached(unsigned char *m, unsigned char *nsec, const unsigned char *c, + unsigned long long clen, const unsigned char *mac, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) +{ + const size_t maclen = crypto_aead_aegis256_ABYTES; + + if (clen > crypto_aead_aegis256_MESSAGEBYTES_MAX || + adlen > crypto_aead_aegis256_MESSAGEBYTES_MAX) { + return -1; + } + return implementation->decrypt_detached(m, c, (size_t) clen, mac, maclen, ad, (size_t) adlen, + npub, k); +} + +int +_crypto_aead_aegis256_pick_best_implementation(void) +{ + implementation = &aegis256_soft_implementation; + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) + if (sodium_runtime_has_armcrypto()) { + implementation = &aegis256_armcrypto_implementation; + return 0; + } +#endif + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) + if (sodium_runtime_has_aesni() & sodium_runtime_has_avx()) { + implementation = &aegis256_aesni_implementation; + return 0; + } +#endif + return 0; /* LCOV_EXCL_LINE */ +} diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_aesni.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_aesni.c @@ -0,0 +1,65 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis256.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#if defined(HAVE_AVXINTRIN_H) && defined(HAVE_WMMINTRIN_H) + +#include "aegis256_aesni.h" + +#ifdef __clang__ +#pragma clang attribute push(__attribute__((target("aes,avx"))), apply_to = function) +#elif defined(__GNUC__) +#pragma GCC target("aes,avx") +#endif + +#include "private/sse2_64_32.h" +#include <immintrin.h> +#include <wmmintrin.h> + +#define AES_BLOCK_LENGTH 16 + +typedef __m128i aes_block_t; +#define AES_BLOCK_XOR(A, B) _mm_xor_si128((A), (B)) +#define AES_BLOCK_AND(A, B) _mm_and_si128((A), (B)) +#define AES_BLOCK_LOAD(A) _mm_loadu_si128((const aes_block_t *) (const void *) (A)) +#define AES_BLOCK_LOAD_64x2(A, B) _mm_set_epi64x((long long) (A), (long long) (B)) +#define AES_BLOCK_STORE(A, B) _mm_storeu_si128((aes_block_t *) (void *) (A), (B)) +#define AES_ENC(A, B) _mm_aesenc_si128((A), (B)) + +static inline void +aegis256_update(aes_block_t *const state, const aes_block_t d) +{ + aes_block_t tmp; + + tmp = state[5]; + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_ENC(state[3], state[4]); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_BLOCK_XOR(AES_ENC(tmp, state[0]), d); +} + +#include "aegis256_common.h" + +struct aegis256_implementation aegis256_aesni_implementation = { SODIUM_C99(.encrypt_detached =) + encrypt_detached, + SODIUM_C99(.decrypt_detached =) + decrypt_detached }; + +#ifdef __clang__ +#pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_aesni.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_aesni.h @@ -0,0 +1,8 @@ +#ifndef aegis256_aesni_H +#define aegis256_aesni_H + +#include "implementations.h" + +extern struct aegis256_implementation aegis256_aesni_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.c @@ -0,0 +1,70 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis256.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#if defined(HAVE_ARMCRYPTO) && defined(NATIVE_LITTLE_ENDIAN) + +#include "aegis256_armcrypto.h" + +#ifndef __ARM_FEATURE_CRYPTO +#define __ARM_FEATURE_CRYPTO 1 +#endif +#ifndef __ARM_FEATURE_AES +#define __ARM_FEATURE_AES 1 +#endif + +#include <arm_neon.h> + +#ifdef __clang__ +#pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) +#elif defined(__GNUC__) +#pragma GCC target("+simd+crypto") +#endif + +#define AES_BLOCK_LENGTH 16 + +typedef uint8x16_t aes_block_t; +#define AES_BLOCK_XOR(A, B) veorq_u8((A), (B)) +#define AES_BLOCK_AND(A, B) vandq_u8((A), (B)) +#define AES_BLOCK_LOAD(A) vld1q_u8(A) +#define AES_BLOCK_LOAD_64x2(A, B) vreinterpretq_u8_u64(vsetq_lane_u64((A), vmovq_n_u64(B), 1)) +#define AES_BLOCK_STORE(A, B) vst1q_u8((A), (B)) +#define AES_ENC(A, B) veorq_u8(vaesmcq_u8(vaeseq_u8(vmovq_n_u8(0), (A))), (B)) + +static inline void +aegis256_update(aes_block_t *const state, const aes_block_t d) +{ + aes_block_t tmp; + + tmp = state[5]; + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_ENC(state[3], state[4]); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_BLOCK_XOR(AES_ENC(tmp, state[0]), d); +} + +#include "aegis256_common.h" + +struct aegis256_implementation aegis256_armcrypto_implementation = { SODIUM_C99(.encrypt_detached =) + encrypt_detached, + SODIUM_C99(.decrypt_detached =) + decrypt_detached }; + +#ifdef __clang__ +#pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.h @@ -0,0 +1,8 @@ +#ifndef aegis256_armcrypto_H +#define aegis256_armcrypto_H + +#include "implementations.h" + +extern struct aegis256_implementation aegis256_armcrypto_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_common.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_common.h @@ -0,0 +1,231 @@ +#define RATE 16 + +static void +aegis256_init(const uint8_t *key, const uint8_t *nonce, aes_block_t *const state) +{ + static CRYPTO_ALIGN(AES_BLOCK_LENGTH) + const uint8_t c0_[AES_BLOCK_LENGTH] = { 0x00, 0x01, 0x01, 0x02, 0x03, 0x05, 0x08, 0x0d, + 0x15, 0x22, 0x37, 0x59, 0x90, 0xe9, 0x79, 0x62 }; + static CRYPTO_ALIGN(AES_BLOCK_LENGTH) + const uint8_t c1_[AES_BLOCK_LENGTH] = { 0xdb, 0x3d, 0x18, 0x55, 0x6d, 0xc2, 0x2f, 0xf1, + 0x20, 0x11, 0x31, 0x42, 0x73, 0xb5, 0x28, 0xdd }; + + const aes_block_t c0 = AES_BLOCK_LOAD(c0_); + const aes_block_t c1 = AES_BLOCK_LOAD(c1_); + const aes_block_t k0 = AES_BLOCK_LOAD(key); + const aes_block_t k1 = AES_BLOCK_LOAD(key + AES_BLOCK_LENGTH); + const aes_block_t n0 = AES_BLOCK_LOAD(nonce); + const aes_block_t n1 = AES_BLOCK_LOAD(nonce + AES_BLOCK_LENGTH); + const aes_block_t k0_n0 = AES_BLOCK_XOR(k0, n0); + const aes_block_t k1_n1 = AES_BLOCK_XOR(k1, n1); + int i; + + state[0] = k0_n0; + state[1] = k1_n1; + state[2] = c1; + state[3] = c0; + state[4] = AES_BLOCK_XOR(k0, c0); + state[5] = AES_BLOCK_XOR(k1, c1); + for (i = 0; i < 4; i++) { + aegis256_update(state, k0); + aegis256_update(state, k1); + aegis256_update(state, k0_n0); + aegis256_update(state, k1_n1); + } +} + +static void +aegis256_mac(uint8_t *mac, size_t maclen, uint64_t adlen, uint64_t mlen, aes_block_t *const state) +{ + aes_block_t tmp; + int i; + + tmp = AES_BLOCK_LOAD_64x2(mlen << 3, adlen << 3); + tmp = AES_BLOCK_XOR(tmp, state[3]); + + for (i = 0; i < 7; i++) { + aegis256_update(state, tmp); + } + + if (maclen == 16) { + tmp = AES_BLOCK_XOR(state[5], state[4]); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[3], state[2])); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_XOR(state[1], state[0])); + AES_BLOCK_STORE(mac, tmp); + } else if (maclen == 32) { + tmp = AES_BLOCK_XOR(AES_BLOCK_XOR(state[2], state[1]), state[0]); + AES_BLOCK_STORE(mac, tmp); + tmp = AES_BLOCK_XOR(AES_BLOCK_XOR(state[5], state[4]), state[3]); + AES_BLOCK_STORE(mac + 16, tmp); + } else { + memset(mac, 0, maclen); + } +} + +static inline void +aegis256_absorb(const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg; + + msg = AES_BLOCK_LOAD(src); + aegis256_update(state, msg); +} + +static inline void +aegis256_absorb2(const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg, msg2; + + msg = AES_BLOCK_LOAD(src + 0 * AES_BLOCK_LENGTH); + msg2 = AES_BLOCK_LOAD(src + 1 * AES_BLOCK_LENGTH); + aegis256_update(state, msg); + aegis256_update(state, msg2); +} + +static void +aegis256_enc(uint8_t *const dst, const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg; + aes_block_t tmp; + + msg = AES_BLOCK_LOAD(src); + tmp = AES_BLOCK_XOR(msg, state[5]); + tmp = AES_BLOCK_XOR(tmp, state[4]); + tmp = AES_BLOCK_XOR(tmp, state[1]); + tmp = AES_BLOCK_XOR(tmp, AES_BLOCK_AND(state[2], state[3])); + AES_BLOCK_STORE(dst, tmp); + + aegis256_update(state, msg); +} + +static void +aegis256_dec(uint8_t *const dst, const uint8_t *const src, aes_block_t *const state) +{ + aes_block_t msg; + + msg = AES_BLOCK_LOAD(src); + msg = AES_BLOCK_XOR(msg, state[5]); + msg = AES_BLOCK_XOR(msg, state[4]); + msg = AES_BLOCK_XOR(msg, state[1]); + msg = AES_BLOCK_XOR(msg, AES_BLOCK_AND(state[2], state[3])); + AES_BLOCK_STORE(dst, msg); + + aegis256_update(state, msg); +} + +static void +aegis256_declast(uint8_t *const dst, const uint8_t *const src, size_t len, aes_block_t *const state) +{ + uint8_t pad[RATE]; + aes_block_t msg; + + memset(pad, 0, sizeof pad); + memcpy(pad, src, len); + + msg = AES_BLOCK_LOAD(pad); + msg = AES_BLOCK_XOR(msg, state[5]); + msg = AES_BLOCK_XOR(msg, state[4]); + msg = AES_BLOCK_XOR(msg, state[1]); + msg = AES_BLOCK_XOR(msg, AES_BLOCK_AND(state[2], state[3])); + AES_BLOCK_STORE(pad, msg); + + memset(pad + len, 0, sizeof pad - len); + memcpy(dst, pad, len); + + msg = AES_BLOCK_LOAD(pad); + + aegis256_update(state, msg); +} + +static int +encrypt_detached(uint8_t *c, uint8_t *mac, size_t maclen, const uint8_t *m, size_t mlen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k) +{ + aes_block_t state[6]; + CRYPTO_ALIGN(RATE) uint8_t src[RATE]; + CRYPTO_ALIGN(RATE) uint8_t dst[RATE]; + size_t i; + + aegis256_init(k, npub, state); + + for (i = 0; i + 2 * RATE <= adlen; i += 2 * RATE) { + aegis256_absorb2(ad + i, state); + } + for (; i + RATE <= adlen; i += RATE) { + aegis256_absorb(ad + i, state); + } + if (adlen % RATE) { + memset(src, 0, RATE); + memcpy(src, ad + i, adlen % RATE); + aegis256_absorb(src, state); + } + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis256_enc(c + i, m + i, state); + } + if (mlen % RATE) { + memset(src, 0, RATE); + memcpy(src, m + i, mlen % RATE); + aegis256_enc(dst, src, state); + memcpy(c + i, dst, mlen % RATE); + } + + aegis256_mac(mac, maclen, adlen, mlen, state); + + return 0; +} + +static int +decrypt_detached(uint8_t *m, const uint8_t *c, size_t clen, const uint8_t *mac, size_t maclen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k) +{ + aes_block_t state[6]; + CRYPTO_ALIGN(RATE) uint8_t src[RATE]; + CRYPTO_ALIGN(RATE) uint8_t dst[RATE]; + CRYPTO_ALIGN(16) uint8_t computed_mac[32]; + const size_t mlen = clen; + size_t i; + int ret; + + aegis256_init(k, npub, state); + + for (i = 0; i + 2 * RATE <= adlen; i += 2 * RATE) { + aegis256_absorb2(ad + i, state); + } + for (; i + RATE <= adlen; i += RATE) { + aegis256_absorb(ad + i, state); + } + if (adlen % RATE) { + memset(src, 0, RATE); + memcpy(src, ad + i, adlen % RATE); + aegis256_absorb(src, state); + } + if (m != NULL) { + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis256_dec(m + i, c + i, state); + } + } else { + for (i = 0; i + RATE <= mlen; i += RATE) { + aegis256_dec(dst, c + i, state); + } + } + if (mlen % RATE) { + if (m != NULL) { + aegis256_declast(m + i, c + i, mlen % RATE, state); + } else { + aegis256_declast(dst, c + i, mlen % RATE, state); + } + } + + COMPILER_ASSERT(sizeof computed_mac >= 32); + aegis256_mac(computed_mac, maclen, adlen, mlen, state); + ret = -1; + if (maclen == 16) { + ret = crypto_verify_16(computed_mac, mac); + } else if (maclen == 32) { + ret = crypto_verify_32(computed_mac, mac); + } + if (ret != 0 && m != NULL) { + memset(m, 0, mlen); + } + return ret; +} diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_soft.c b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_soft.c @@ -0,0 +1,54 @@ +#include <errno.h> +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aegis256.h" +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "export.h" +#include "utils.h" + +#include "private/common.h" + +#include "crypto_aead_aegis256.h" +#include "private/softaes.h" + +#if 1 + +#include "aegis256_soft.h" + +#define AES_BLOCK_LENGTH 16 + +typedef SoftAesBlock aes_block_t; +#define AES_BLOCK_XOR(A, B) softaes_block_xor((A), (B)) +#define AES_BLOCK_AND(A, B) softaes_block_and((A), (B)) +#define AES_BLOCK_LOAD(A) softaes_block_load(A) +#define AES_BLOCK_LOAD_64x2(A, B) softaes_block_load64x2((A), (B)) +#define AES_BLOCK_STORE(A, B) softaes_block_store((A), (B)) +#define AES_ENC(A, B) softaes_block_encrypt((A), (B)) + +static inline void +aegis256_update(aes_block_t *const state, const aes_block_t d) +{ + aes_block_t tmp; + + tmp = state[5]; + state[5] = AES_ENC(state[4], state[5]); + state[4] = AES_ENC(state[3], state[4]); + state[3] = AES_ENC(state[2], state[3]); + state[2] = AES_ENC(state[1], state[2]); + state[1] = AES_ENC(state[0], state[1]); + state[0] = AES_BLOCK_XOR(AES_ENC(tmp, state[0]), d); +} + +#include "aegis256_common.h" + +struct aegis256_implementation aegis256_soft_implementation = { SODIUM_C99(.encrypt_detached =) + encrypt_detached, + SODIUM_C99(.decrypt_detached =) + decrypt_detached }; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_soft.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/aegis256_soft.h @@ -0,0 +1,8 @@ +#ifndef aegis256_soft_H +#define aegis256_soft_H + +#include "implementations.h" + +extern struct aegis256_implementation aegis256_soft_implementation; + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/implementations.h b/subprojects/libsodium/src/libsodium/crypto_aead/aegis256/implementations.h @@ -0,0 +1,17 @@ +#ifndef aegis256_implementations_H +#define aegis256_implementations_H + +#include <stddef.h> +#include <stdint.h> + +#include "crypto_aead_aegis256.h" + +typedef struct aegis256_implementation { + int (*encrypt_detached)(uint8_t *c, uint8_t *mac, size_t maclen, const uint8_t *m, size_t mlen, + const uint8_t *ad, size_t adlen, const uint8_t *npub, const uint8_t *k); + int (*decrypt_detached)(uint8_t *m, const uint8_t *c, size_t clen, const uint8_t *mac, + size_t maclen, const uint8_t *ad, size_t adlen, const uint8_t *npub, + const uint8_t *k); +} aegis256_implementation; + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/aead_aes256gcm.c b/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/aead_aes256gcm.c @@ -0,0 +1,157 @@ +#include <errno.h> +#include <stdlib.h> + +#include "crypto_aead_aes256gcm.h" +#include "private/common.h" +#include "randombytes.h" + +size_t +crypto_aead_aes256gcm_keybytes(void) +{ + return crypto_aead_aes256gcm_KEYBYTES; +} + +size_t +crypto_aead_aes256gcm_nsecbytes(void) +{ + return crypto_aead_aes256gcm_NSECBYTES; +} + +size_t +crypto_aead_aes256gcm_npubbytes(void) +{ + return crypto_aead_aes256gcm_NPUBBYTES; +} + +size_t +crypto_aead_aes256gcm_abytes(void) +{ + return crypto_aead_aes256gcm_ABYTES; +} + +size_t +crypto_aead_aes256gcm_statebytes(void) +{ + return (sizeof(crypto_aead_aes256gcm_state) + (size_t) 15U) & ~(size_t) 15U; +} + +size_t +crypto_aead_aes256gcm_messagebytes_max(void) +{ + return crypto_aead_aes256gcm_MESSAGEBYTES_MAX; +} + +void +crypto_aead_aes256gcm_keygen(unsigned char k[crypto_aead_aes256gcm_KEYBYTES]) +{ + randombytes_buf(k, crypto_aead_aes256gcm_KEYBYTES); +} + +#if !((defined(HAVE_ARMCRYPTO) && defined(__clang__) && defined(NATIVE_LITTLE_ENDIAN)) || \ + (defined(HAVE_TMMINTRIN_H) && defined(HAVE_WMMINTRIN_H))) + +#ifndef ENOSYS +#define ENOSYS ENXIO +#endif + +int +crypto_aead_aes256gcm_encrypt_detached(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_encrypt(unsigned char *c, unsigned long long *clen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_decrypt_detached(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *mac, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const unsigned char *k) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_beforenm(crypto_aead_aes256gcm_state *st_, const unsigned char *k) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_encrypt_detached_afternm(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long mlen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *nsec, + const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_encrypt_afternm(unsigned char *c, unsigned long long *clen_p, + const unsigned char *m, unsigned long long mlen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *nsec, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_decrypt_detached_afternm(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *mac, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_decrypt_afternm(unsigned char *m, unsigned long long *mlen_p, + unsigned char *nsec, const unsigned char *c, + unsigned long long clen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + errno = ENOSYS; + return -1; +} + +int +crypto_aead_aes256gcm_is_available(void) +{ + return 0; +} + +#endif +\ No newline at end of file diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c b/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c @@ -1,17 +1,12 @@ - -/* - * AES256-GCM, based on the "Intel Carry-Less Multiplication Instruction and its Usage for Computing - * the GCM Mode" paper and reference code, using the aggregated reduction method. - * Originally adapted by Romain Dolbeau. - */ - #include <errno.h> +#include <limits.h> #include <stdint.h> #include <stdlib.h> #include <string.h> #include "core.h" #include "crypto_aead_aes256gcm.h" +#include "crypto_verify_16.h" #include "export.h" #include "private/common.h" #include "private/sse2_64_32.h" @@ -21,976 +16,803 @@ #if defined(HAVE_TMMINTRIN_H) && defined(HAVE_WMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("ssse3") -# pragma GCC target("aes") -# pragma GCC target("pclmul") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("aes,avx,pclmul"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("aes,avx,pclmul") # endif +#if !defined(_MSC_VER) || _MSC_VER < 1800 +#define __vectorcall +#endif + #include <tmmintrin.h> #include <wmmintrin.h> -#ifndef ENOSYS -# define ENOSYS ENXIO -#endif - -#if defined(__INTEL_COMPILER) || defined(_bswap64) -#elif defined(_MSC_VER) -# define _bswap64(a) _byteswap_uint64(a) -#elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 2)) -# define _bswap64(a) __builtin_bswap64(a) -#else -static inline uint64_t -_bswap64(const uint64_t x) -{ - return - ((x << 56) & 0xFF00000000000000UL) | ((x << 40) & 0x00FF000000000000UL) | - ((x << 24) & 0x0000FF0000000000UL) | ((x << 8) & 0x000000FF00000000UL) | - ((x >> 8) & 0x00000000FF000000UL) | ((x >> 24) & 0x0000000000FF0000UL) | - ((x >> 40) & 0x000000000000FF00UL) | ((x >> 56) & 0x00000000000000FFUL); +#define ABYTES crypto_aead_aes256gcm_ABYTES +#define NPUBBYTES crypto_aead_aes256gcm_NPUBBYTES +#define KEYBYTES crypto_aead_aes256gcm_KEYBYTES + +#define PARALLEL_BLOCKS 7 +#undef USE_KARATSUBA_MULTIPLICATION + +typedef __m128i BlockVec; + +#define LOAD128(a) _mm_loadu_si128((const BlockVec *) (a)) +#define STORE128(a, b) _mm_storeu_si128((BlockVec *) (a), (b)) +#define AES_ENCRYPT(block_vec, rkey) _mm_aesenc_si128((block_vec), (rkey)) +#define AES_ENCRYPTLAST(block_vec, rkey) _mm_aesenclast_si128((block_vec), (rkey)) +#define AES_KEYGEN(block_vec, rc) _mm_aeskeygenassist_si128((block_vec), (rc)) +#define XOR128(a, b) _mm_xor_si128((a), (b)) +#define AND128(a, b) _mm_and_si128((a), (b)) +#define OR128(a, b) _mm_or_si128((a), (b)) +#define SET64x2(a, b) _mm_set_epi64x((uint64_t) (a), (uint64_t) (b)) +#define ZERO128 _mm_setzero_si128() +#define ONE128 SET64x2(0, 1) +#define ADD64x2(a, b) _mm_add_epi64((a), (b)) +#define SUB64x2(a, b) _mm_sub_epi64((a), (b)) +#define SHL64x2(a, b) _mm_slli_epi64((a), (b)) +#define SHR64x2(a, b) _mm_srli_epi64((a), (b)) +#define REV128(x) \ + _mm_shuffle_epi8((x), _mm_set_epi8(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15)) +#define SHUFFLE32x4(x, a, b, c, d) _mm_shuffle_epi32((x), _MM_SHUFFLE((d), (c), (b), (a))) +#define BYTESHL128(a, b) _mm_slli_si128(a, b) +#define BYTESHR128(a, b) _mm_srli_si128(a, b) +#define SHL128(a, b) OR128(SHL64x2((a), (b)), SHR64x2(BYTESHL128((a), 8), 64 - (b))) +#define CLMULLO128(a, b) _mm_clmulepi64_si128((a), (b), 0x00) +#define CLMULHI128(a, b) _mm_clmulepi64_si128((a), (b), 0x11) +#define CLMULLOHI128(a, b) _mm_clmulepi64_si128((a), (b), 0x10) +#define CLMULHILO128(a, b) _mm_clmulepi64_si128((a), (b), 0x01) +#define PREFETCH_READ(x) _mm_prefetch((x), _MM_HINT_T1) +#define PREFETCH_WRITE(x) _mm_prefetch((x), _MM_HINT_T1) + +#define ROUNDS 14 + +#define PC_COUNT (2 * PARALLEL_BLOCKS) + +typedef struct I256 { + BlockVec hi; + BlockVec lo; + BlockVec mid; +} I256; + +typedef BlockVec Precomp; + +typedef struct GHash { + BlockVec acc; +} GHash; + +typedef struct State { + BlockVec rkeys[ROUNDS + 1]; + Precomp hx[PC_COUNT]; +} State; + +static void __vectorcall expand256(const unsigned char key[KEYBYTES], BlockVec rkeys[1 + ROUNDS]) +{ + BlockVec t1, t2, s; + size_t i = 0; + +#define EXPAND_KEY_1(RC) \ + rkeys[i++] = t2; \ + s = AES_KEYGEN(t2, RC); \ + t1 = XOR128(t1, BYTESHL128(t1, 4)); \ + t1 = XOR128(t1, BYTESHL128(t1, 8)); \ + t1 = XOR128(t1, SHUFFLE32x4(s, 3, 3, 3, 3)); + +#define EXPAND_KEY_2(RC) \ + rkeys[i++] = t1; \ + s = AES_KEYGEN(t1, RC); \ + t2 = XOR128(t2, BYTESHL128(t2, 4)); \ + t2 = XOR128(t2, BYTESHL128(t2, 8)); \ + t2 = XOR128(t2, SHUFFLE32x4(s, 2, 2, 2, 2)); + + t1 = LOAD128(&key[0]); + t2 = LOAD128(&key[16]); + + rkeys[i++] = t1; + EXPAND_KEY_1(0x01); + EXPAND_KEY_2(0x01); + EXPAND_KEY_1(0x02); + EXPAND_KEY_2(0x02); + EXPAND_KEY_1(0x04); + EXPAND_KEY_2(0x04); + EXPAND_KEY_1(0x08); + EXPAND_KEY_2(0x08); + EXPAND_KEY_1(0x10); + EXPAND_KEY_2(0x10); + EXPAND_KEY_1(0x20); + EXPAND_KEY_2(0x20); + EXPAND_KEY_1(0x40); + rkeys[i++] = t1; } -#endif -typedef struct aes256gcm_state { - __m128i rkeys[16]; - unsigned char H[16]; -} aes256gcm_state; +/* Encrypt a single AES block */ static inline void -aesni_key256_expand(const unsigned char *key, __m128i * const rkeys) +encrypt(const State *st, unsigned char dst[16], const unsigned char src[16]) { - __m128i X0, X1, X2, X3; - int i = 0; - - X0 = _mm_loadu_si128((const __m128i *) &key[0]); - rkeys[i++] = X0; - - X2 = _mm_loadu_si128((const __m128i *) &key[16]); - rkeys[i++] = X2; - -#define EXPAND_KEY_1(S) do { \ - X1 = _mm_shuffle_epi32(_mm_aeskeygenassist_si128(X2, (S)), 0xff); \ - X3 = _mm_castps_si128(_mm_shuffle_ps(_mm_castsi128_ps(X3), _mm_castsi128_ps(X0), 0x10)); \ - X0 = _mm_xor_si128(X0, X3); \ - X3 = _mm_castps_si128(_mm_shuffle_ps(_mm_castsi128_ps(X3), _mm_castsi128_ps(X0), 0x8c)); \ - X0 = _mm_xor_si128(_mm_xor_si128(X0, X3), X1); \ - rkeys[i++] = X0; \ -} while (0) - -#define EXPAND_KEY_2(S) do { \ - X1 = _mm_shuffle_epi32(_mm_aeskeygenassist_si128(X0, (S)), 0xaa); \ - X3 = _mm_castps_si128(_mm_shuffle_ps(_mm_castsi128_ps(X3), _mm_castsi128_ps(X2), 0x10)); \ - X2 = _mm_xor_si128(X2, X3); \ - X3 = _mm_castps_si128(_mm_shuffle_ps(_mm_castsi128_ps(X3), _mm_castsi128_ps(X2), 0x8c)); \ - X2 = _mm_xor_si128(_mm_xor_si128(X2, X3), X1); \ - rkeys[i++] = X2; \ -} while (0) - - X3 = _mm_setzero_si128(); - EXPAND_KEY_1(0x01); EXPAND_KEY_2(0x01); - EXPAND_KEY_1(0x02); EXPAND_KEY_2(0x02); - EXPAND_KEY_1(0x04); EXPAND_KEY_2(0x04); - EXPAND_KEY_1(0x08); EXPAND_KEY_2(0x08); - EXPAND_KEY_1(0x10); EXPAND_KEY_2(0x10); - EXPAND_KEY_1(0x20); EXPAND_KEY_2(0x20); - EXPAND_KEY_1(0x40); + BlockVec t; + + size_t i; + + t = XOR128(LOAD128(src), st->rkeys[0]); + for (i = 1; i < ROUNDS; i++) { + t = AES_ENCRYPT(t, st->rkeys[i]); + } + t = AES_ENCRYPTLAST(t, st->rkeys[ROUNDS]); + STORE128(dst, t); } -/** single, by-the-book AES encryption with AES-NI */ -static inline void -aesni_encrypt1(unsigned char *out, __m128i nv, const __m128i *rkeys) +/* Encrypt and add a single AES block */ + +static inline void __vectorcall encrypt_xor_block(const State *st, unsigned char dst[16], + const unsigned char src[16], + const BlockVec counter) { - __m128i temp = _mm_xor_si128(nv, rkeys[0]); - - temp = _mm_aesenc_si128(temp, rkeys[1]); - temp = _mm_aesenc_si128(temp, rkeys[2]); - temp = _mm_aesenc_si128(temp, rkeys[3]); - temp = _mm_aesenc_si128(temp, rkeys[4]); - temp = _mm_aesenc_si128(temp, rkeys[5]); - temp = _mm_aesenc_si128(temp, rkeys[6]); - temp = _mm_aesenc_si128(temp, rkeys[7]); - temp = _mm_aesenc_si128(temp, rkeys[8]); - temp = _mm_aesenc_si128(temp, rkeys[9]); - temp = _mm_aesenc_si128(temp, rkeys[10]); - temp = _mm_aesenc_si128(temp, rkeys[11]); - temp = _mm_aesenc_si128(temp, rkeys[12]); - temp = _mm_aesenc_si128(temp, rkeys[13]); - - temp = _mm_aesenclast_si128(temp, rkeys[14]); - _mm_storeu_si128((__m128i *) out, temp); -} + BlockVec ts; + size_t i; -/** multiple-blocks-at-once AES encryption with AES-NI ; - on Haswell, aesenc has a latency of 7 and a throughput of 1 - so the sequence of aesenc should be bubble-free if you - have at least 8 blocks. Let's build an arbitratry-sized - function */ -/* Step 1 : loading the nonce */ -/* load & increment the n vector (non-vectorized, unused for now) */ -#define NVDECLx(a) \ - __m128i nv##a - -#define NVx(a) \ - nv##a = _mm_shuffle_epi8(_mm_load_si128((const __m128i *) n), pt); \ - n[3]++ - -/* Step 2 : define value in round one (xor with subkey #0, aka key) */ -#define TEMPDECLx(a) \ - __m128i temp##a - -#define TEMPx(a) \ - temp##a = _mm_xor_si128(nv##a, rkeys[0]) - -/* Step 3: one round of AES */ -#define AESENCx(a) \ - temp##a = _mm_aesenc_si128(temp##a, rkeys[roundctr]) - -/* Step 4: last round of AES */ -#define AESENCLASTx(a) \ - temp##a = _mm_aesenclast_si128(temp##a, rkeys[14]) - -/* Step 5: store result */ -#define STOREx(a) \ - _mm_storeu_si128((__m128i *) (out + (a * 16)), temp##a) - -/* all the MAKE* macros are for automatic explicit unrolling */ -#define MAKE4(X) \ - X(0); \ - X(1); \ - X(2); \ - X(3) - -#define MAKE8(X) \ - X(0); \ - X(1); \ - X(2); \ - X(3); \ - X(4); \ - X(5); \ - X(6); \ - X(7) - -#define COUNTER_INC2(N) (N)[3] += 2 - -/* create a function of unrolling N ; the MAKEN is the unrolling - macro, defined above. The N in MAKEN must match N, obviously. */ -#define FUNC(N, MAKEN) \ - static inline void aesni_encrypt##N(unsigned char *out, uint32_t *n, const __m128i *rkeys) \ - { \ - const __m128i pt = _mm_set_epi8(12, 13, 14, 15, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0); \ - int roundctr; \ - MAKEN(NVDECLx); \ - MAKEN(TEMPDECLx); \ - \ - MAKEN(NVx); \ - MAKEN(TEMPx); \ - for (roundctr = 1; roundctr < 14; roundctr++) { \ - MAKEN(AESENCx); \ - } \ - MAKEN(AESENCLASTx); \ - MAKEN(STOREx); \ + ts = XOR128(counter, st->rkeys[0]); + for (i = 1; i < ROUNDS; i++) { + ts = AES_ENCRYPT(ts, st->rkeys[i]); } + ts = AES_ENCRYPTLAST(ts, st->rkeys[i]); + ts = XOR128(ts, LOAD128(src)); + STORE128(dst, ts); +} -FUNC(8, MAKE8) - -/* all GF(2^128) fnctions are by the book, meaning this one: - <https://software.intel.com/sites/default/files/managed/72/cc/clmul-wp-rev-2.02-2014-04-20.pdf> -*/ +/* Encrypt and add PARALLEL_BLOCKS AES blocks */ -static inline void -addmul(unsigned char *c, const unsigned char *a, unsigned int xlen, const unsigned char *b) +static inline void __vectorcall encrypt_xor_wide(const State *st, + unsigned char dst[16 * PARALLEL_BLOCKS], + const unsigned char src[16 * PARALLEL_BLOCKS], + const BlockVec counters[PARALLEL_BLOCKS]) { - const __m128i rev = _mm_set_epi8(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15); - __m128i A, B, C; - __m128i tmp2, tmp3, tmp4, tmp5, tmp6, tmp7, tmp8, tmp9; - __m128i tmp10, tmp11, tmp12, tmp13, tmp14, tmp15, tmp16, tmp17, tmp18; - __m128i tmp19, tmp20, tmp21, tmp22, tmp23, tmp24, tmp25, tmp26, tmp27; - __m128i tmp28, tmp29, tmp30, tmp31, tmp32, tmp33, tmp34, tmp35, tmp36; - - if (xlen >= 16) { - A = _mm_loadu_si128((const __m128i *) a); - } else { - CRYPTO_ALIGN(16) unsigned char padded[16]; - unsigned int i; + BlockVec ts[PARALLEL_BLOCKS]; + size_t i, j; - memset(padded, 0, 16); - for (i = 0; i < xlen; i++) { - padded[i] = a[i]; + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = XOR128(counters[j], st->rkeys[0]); + } + for (i = 1; i < ROUNDS; i++) { + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = AES_ENCRYPT(ts[j], st->rkeys[i]); } - A = _mm_load_si128((const __m128i *) padded); } - A = _mm_shuffle_epi8(A, rev); - B = _mm_loadu_si128((const __m128i *) b); - C = _mm_loadu_si128((const __m128i *) c); - A = _mm_xor_si128(A, C); - tmp3 = _mm_clmulepi64_si128(A, B, 0x00); - tmp4 = _mm_clmulepi64_si128(A, B, 0x10); - tmp5 = _mm_clmulepi64_si128(A, B, 0x01); - tmp6 = _mm_clmulepi64_si128(A, B, 0x11); - tmp10 = _mm_xor_si128(tmp4, tmp5); - tmp13 = _mm_slli_si128(tmp10, 8); - tmp11 = _mm_srli_si128(tmp10, 8); - tmp15 = _mm_xor_si128(tmp3, tmp13); - tmp17 = _mm_xor_si128(tmp6, tmp11); - tmp7 = _mm_srli_epi32(tmp15, 31); - tmp8 = _mm_srli_epi32(tmp17, 31); - tmp16 = _mm_slli_epi32(tmp15, 1); - tmp18 = _mm_slli_epi32(tmp17, 1); - tmp9 = _mm_srli_si128(tmp7, 12); - tmp22 = _mm_slli_si128(tmp8, 4); - tmp25 = _mm_slli_si128(tmp7, 4); - tmp29 = _mm_or_si128(tmp16, tmp25); - tmp19 = _mm_or_si128(tmp18, tmp22); - tmp20 = _mm_or_si128(tmp19, tmp9); - tmp26 = _mm_slli_epi32(tmp29, 31); - tmp23 = _mm_slli_epi32(tmp29, 30); - tmp32 = _mm_slli_epi32(tmp29, 25); - tmp27 = _mm_xor_si128(tmp26, tmp23); - tmp28 = _mm_xor_si128(tmp27, tmp32); - tmp24 = _mm_srli_si128(tmp28, 4); - tmp33 = _mm_slli_si128(tmp28, 12); - tmp30 = _mm_xor_si128(tmp29, tmp33); - tmp2 = _mm_srli_epi32(tmp30, 1); - tmp12 = _mm_srli_epi32(tmp30, 2); - tmp14 = _mm_srli_epi32(tmp30, 7); - tmp34 = _mm_xor_si128(tmp2, tmp12); - tmp35 = _mm_xor_si128(tmp34, tmp14); - tmp36 = _mm_xor_si128(tmp35, tmp24); - tmp31 = _mm_xor_si128(tmp30, tmp36); - tmp21 = _mm_xor_si128(tmp20, tmp31); - _mm_storeu_si128((__m128i *) c, tmp21); + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = AES_ENCRYPTLAST(ts[j], st->rkeys[i]); + ts[j] = XOR128(ts[j], LOAD128(&src[16 * j])); + } + for (j = 0; j < PARALLEL_BLOCKS; j++) { + STORE128(&dst[16 * j], ts[j]); + } } -/* pure multiplication, for pre-computing powers of H */ -static inline __m128i -mulv(__m128i A, __m128i B) +/* Square a field element */ + +static inline I256 __vectorcall clsq128(const BlockVec x) { - __m128i tmp3 = _mm_clmulepi64_si128(A, B, 0x00); - __m128i tmp4 = _mm_clmulepi64_si128(A, B, 0x10); - __m128i tmp5 = _mm_clmulepi64_si128(A, B, 0x01); - __m128i tmp6 = _mm_clmulepi64_si128(A, B, 0x11); - __m128i tmp10 = _mm_xor_si128(tmp4, tmp5); - __m128i tmp13 = _mm_slli_si128(tmp10, 8); - __m128i tmp11 = _mm_srli_si128(tmp10, 8); - __m128i tmp15 = _mm_xor_si128(tmp3, tmp13); - __m128i tmp17 = _mm_xor_si128(tmp6, tmp11); - __m128i tmp7 = _mm_srli_epi32(tmp15, 31); - __m128i tmp8 = _mm_srli_epi32(tmp17, 31); - __m128i tmp16 = _mm_slli_epi32(tmp15, 1); - __m128i tmp18 = _mm_slli_epi32(tmp17, 1); - __m128i tmp9 = _mm_srli_si128(tmp7, 12); - __m128i tmp22 = _mm_slli_si128(tmp8, 4); - __m128i tmp25 = _mm_slli_si128(tmp7, 4); - __m128i tmp29 = _mm_or_si128(tmp16, tmp25); - __m128i tmp19 = _mm_or_si128(tmp18, tmp22); - __m128i tmp20 = _mm_or_si128(tmp19, tmp9); - __m128i tmp26 = _mm_slli_epi32(tmp29, 31); - __m128i tmp23 = _mm_slli_epi32(tmp29, 30); - __m128i tmp32 = _mm_slli_epi32(tmp29, 25); - __m128i tmp27 = _mm_xor_si128(tmp26, tmp23); - __m128i tmp28 = _mm_xor_si128(tmp27, tmp32); - __m128i tmp24 = _mm_srli_si128(tmp28, 4); - __m128i tmp33 = _mm_slli_si128(tmp28, 12); - __m128i tmp30 = _mm_xor_si128(tmp29, tmp33); - __m128i tmp2 = _mm_srli_epi32(tmp30, 1); - __m128i tmp12 = _mm_srli_epi32(tmp30, 2); - __m128i tmp14 = _mm_srli_epi32(tmp30, 7); - __m128i tmp34 = _mm_xor_si128(tmp2, tmp12); - __m128i tmp35 = _mm_xor_si128(tmp34, tmp14); - __m128i tmp36 = _mm_xor_si128(tmp35, tmp24); - __m128i tmp31 = _mm_xor_si128(tmp30, tmp36); - __m128i C = _mm_xor_si128(tmp20, tmp31); - - return C; + const BlockVec r_lo = CLMULLO128(x, x); + const BlockVec r_hi = CLMULHI128(x, x); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) ZERO128, + }; } -/* 4 multiply-accumulate at once; again - <https://software.intel.com/sites/default/files/managed/72/cc/clmul-wp-rev-2.02-2014-04-20.pdf> - for the Aggregated Reduction Method & sample code. - Algorithm by Krzysztof Jankowski, Pierre Laurent - Intel */ - -#define RED_DECL(a) __m128i H##a##_X##a##_lo, H##a##_X##a##_hi, tmp##a, tmp##a##B -#define RED_SHUFFLE(a) X##a = _mm_shuffle_epi8(X##a, rev) -#define RED_MUL_LOW(a) H##a##_X##a##_lo = _mm_clmulepi64_si128(H##a, X##a, 0x00) -#define RED_MUL_HIGH(a) H##a##_X##a##_hi = _mm_clmulepi64_si128(H##a, X##a, 0x11) -#define RED_MUL_MID(a) \ - tmp##a = _mm_shuffle_epi32(H##a, 0x4e); \ - tmp##a##B = _mm_shuffle_epi32(X##a, 0x4e); \ - tmp##a = _mm_xor_si128(tmp##a, H##a); \ - tmp##a##B = _mm_xor_si128(tmp##a##B, X##a); \ - tmp##a = _mm_clmulepi64_si128(tmp##a, tmp##a##B, 0x00) - -#define MULREDUCE4(rev, H0_, H1_, H2_, H3_, X0_, X1_, X2_, X3_, accv) \ -do { \ - MAKE4(RED_DECL); \ - __m128i lo, hi; \ - __m128i tmp8, tmp9; \ - __m128i H0 = H0_; \ - __m128i H1 = H1_; \ - __m128i H2 = H2_; \ - __m128i H3 = H3_; \ - __m128i X0 = X0_; \ - __m128i X1 = X1_; \ - __m128i X2 = X2_; \ - __m128i X3 = X3_; \ -\ -/* byte-revert the inputs & xor the first one into the accumulator */ \ -\ - MAKE4(RED_SHUFFLE); \ - X3 = _mm_xor_si128(X3, accv); \ -\ -/* 4 low H*X (x0*h0) */ \ -\ - MAKE4(RED_MUL_LOW); \ - lo = _mm_xor_si128(H0_X0_lo, H1_X1_lo); \ - lo = _mm_xor_si128(lo, H2_X2_lo); \ - lo = _mm_xor_si128(lo, H3_X3_lo); \ -\ -/* 4 high H*X (x1*h1) */ \ -\ - MAKE4(RED_MUL_HIGH); \ - hi = _mm_xor_si128(H0_X0_hi, H1_X1_hi); \ - hi = _mm_xor_si128(hi, H2_X2_hi); \ - hi = _mm_xor_si128(hi, H3_X3_hi); \ -\ -/* 4 middle H*X, using Karatsuba, i.e. \ - x1*h0+x0*h1 =(x1+x0)*(h1+h0)-x1*h1-x0*h0 \ - we already have all x1y1 & x0y0 (accumulated in hi & lo) \ - (0 is low half and 1 is high half) \ - */ \ -/* permute the high and low 64 bits in H1 & X1, \ - so create (h0,h1) from (h1,h0) and (x0,x1) from (x1,x0), \ - then compute (h0+h1,h1+h0) and (x0+x1,x1+x0), \ - and finally multiply \ - */ \ - MAKE4(RED_MUL_MID); \ -\ -/* substracts x1*h1 and x0*h0 */ \ - tmp0 = _mm_xor_si128(tmp0, lo); \ - tmp0 = _mm_xor_si128(tmp0, hi); \ - tmp0 = _mm_xor_si128(tmp1, tmp0); \ - tmp0 = _mm_xor_si128(tmp2, tmp0); \ - tmp0 = _mm_xor_si128(tmp3, tmp0);\ -\ - /* reduction */ \ - tmp0B = _mm_slli_si128(tmp0, 8); \ - tmp0 = _mm_srli_si128(tmp0, 8); \ - lo = _mm_xor_si128(tmp0B, lo); \ - hi = _mm_xor_si128(tmp0, hi); \ - tmp3 = lo; \ - tmp2B = hi; \ - tmp3B = _mm_srli_epi32(tmp3, 31); \ - tmp8 = _mm_srli_epi32(tmp2B, 31); \ - tmp3 = _mm_slli_epi32(tmp3, 1); \ - tmp2B = _mm_slli_epi32(tmp2B, 1); \ - tmp9 = _mm_srli_si128(tmp3B, 12); \ - tmp8 = _mm_slli_si128(tmp8, 4); \ - tmp3B = _mm_slli_si128(tmp3B, 4); \ - tmp3 = _mm_or_si128(tmp3, tmp3B); \ - tmp2B = _mm_or_si128(tmp2B, tmp8); \ - tmp2B = _mm_or_si128(tmp2B, tmp9); \ - tmp3B = _mm_slli_epi32(tmp3, 31); \ - tmp8 = _mm_slli_epi32(tmp3, 30); \ - tmp9 = _mm_slli_epi32(tmp3, 25); \ - tmp3B = _mm_xor_si128(tmp3B, tmp8); \ - tmp3B = _mm_xor_si128(tmp3B, tmp9); \ - tmp8 = _mm_srli_si128(tmp3B, 4); \ - tmp3B = _mm_slli_si128(tmp3B, 12); \ - tmp3 = _mm_xor_si128(tmp3, tmp3B); \ - tmp2 = _mm_srli_epi32(tmp3, 1); \ - tmp0B = _mm_srli_epi32(tmp3, 2); \ - tmp1B = _mm_srli_epi32(tmp3, 7); \ - tmp2 = _mm_xor_si128(tmp2, tmp0B); \ - tmp2 = _mm_xor_si128(tmp2, tmp1B); \ - tmp2 = _mm_xor_si128(tmp2, tmp8); \ - tmp3 = _mm_xor_si128(tmp3, tmp2); \ - tmp2B = _mm_xor_si128(tmp2B, tmp3); \ -\ - accv = tmp2B; \ -} while(0) - -#define XORx(a) \ - temp##a = _mm_xor_si128(temp##a, \ - _mm_loadu_si128((const __m128i *) (in + a * 16))) - -#define LOADx(a) \ - __m128i in##a = _mm_loadu_si128((const __m128i *) (in + a * 16)) - -/* full encrypt & checksum 8 blocks at once */ -#define aesni_encrypt8full(out_, n_, rkeys, in_, accum, hv_, h2v_, h3v_, h4v_, rev) \ -do { \ - unsigned char *out = out_; \ - uint32_t *n = n_; \ - const unsigned char *in = in_; \ - const __m128i hv = hv_; \ - const __m128i h2v = h2v_; \ - const __m128i h3v = h3v_; \ - const __m128i h4v = h4v_; \ - const __m128i pt = _mm_set_epi8(12, 13, 14, 15, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0); \ - __m128i accv_; \ - int roundctr; \ - \ - MAKE8(NVDECLx); \ - MAKE8(TEMPDECLx); \ - MAKE8(NVx); \ - MAKE8(TEMPx); \ - for (roundctr = 1; roundctr < 14; roundctr++) { \ - MAKE8(AESENCx); \ - } \ - MAKE8(AESENCLASTx); \ - MAKE8(XORx); \ - MAKE8(STOREx); \ - accv_ = _mm_load_si128((const __m128i *) accum); \ - MULREDUCE4(rev, hv, h2v, h3v, h4v, temp3, temp2, temp1, temp0, accv_); \ - MULREDUCE4(rev, hv, h2v, h3v, h4v, temp7, temp6, temp5, temp4, accv_); \ - _mm_store_si128((__m128i *) accum, accv_); \ -} while(0) - -/* checksum 8 blocks at once */ -#define aesni_addmul8full(in_, accum, hv_, h2v_, h3v_, h4v_, rev) \ -do { \ - const unsigned char *in = in_; \ - const __m128i hv = hv_; \ - const __m128i h2v = h2v_; \ - const __m128i h3v = h3v_; \ - const __m128i h4v = h4v_; \ - __m128i accv_; \ - \ - MAKE8(LOADx); \ - accv_ = _mm_load_si128((const __m128i *) accum); \ - MULREDUCE4(rev, hv, h2v, h3v, h4v, in3, in2, in1, in0, accv_); \ - MULREDUCE4(rev, hv, h2v, h3v, h4v, in7, in6, in5, in4, accv_); \ - _mm_store_si128((__m128i *) accum, accv_); \ -} while(0) - -/* decrypt 8 blocks at once */ -#define aesni_decrypt8full(out_, n_, rkeys, in_) \ -do { \ - unsigned char *out = out_; \ - uint32_t *n = n_; \ - const unsigned char *in = in_; \ - const __m128i pt = _mm_set_epi8(12, 13, 14, 15, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0); \ - int roundctr; \ -\ - MAKE8(NVDECLx); \ - MAKE8(TEMPDECLx); \ - MAKE8(NVx); \ - MAKE8(TEMPx); \ - for (roundctr = 1; roundctr < 14; roundctr++) { \ - MAKE8(AESENCx); \ - } \ - MAKE8(AESENCLASTx); \ - MAKE8(XORx); \ - MAKE8(STOREx); \ -} while(0) +/* Multiply two field elements -- Textbook multiplication is faster than Karatsuba on some recent + * CPUs */ -int -crypto_aead_aes256gcm_beforenm(crypto_aead_aes256gcm_state *ctx_, - const unsigned char *k) +static inline I256 __vectorcall clmul128(const BlockVec x, const BlockVec y) +{ +#ifdef USE_KARATSUBA_MULTIPLICATION + const BlockVec x_hi = BYTESHR128(x, 8); + const BlockVec y_hi = BYTESHR128(y, 8); + const BlockVec r_lo = CLMULLO128(x, y); + const BlockVec r_hi = CLMULHI128(x, y); + const BlockVec r_mid = XOR128(CLMULLO128(XOR128(x, x_hi), XOR128(y, y_hi)), XOR128(r_lo, r_hi)); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) r_mid, + }; +#else + const BlockVec r_hi = CLMULHI128(x, y); + const BlockVec r_lo = CLMULLO128(x, y); + const BlockVec r_mid = XOR128(CLMULHILO128(x, y), CLMULLOHI128(x, y)); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) r_mid, + }; +#endif +} + +/* Merge the middle word and reduce a field element */ + +static inline BlockVec __vectorcall gcm_reduce(const I256 x) { - aes256gcm_state *ctx = (aes256gcm_state *) (void *) ctx_; - unsigned char *H = ctx->H; - __m128i *rkeys = ctx->rkeys; - __m128i zero = _mm_setzero_si128(); + const BlockVec hi = XOR128(x.hi, BYTESHR128(x.mid, 8)); + const BlockVec lo = XOR128(x.lo, BYTESHL128(x.mid, 8)); - COMPILER_ASSERT((sizeof *ctx_) >= (sizeof *ctx)); - aesni_key256_expand(k, rkeys); - aesni_encrypt1(H, zero, rkeys); + const BlockVec p64 = SET64x2(0, 0xc200000000000000); + const BlockVec a = CLMULLO128(lo, p64); + const BlockVec b = XOR128(SHUFFLE32x4(lo, 2, 3, 0, 1), a); + const BlockVec c = CLMULLO128(b, p64); + const BlockVec d = XOR128(SHUFFLE32x4(b, 2, 3, 0, 1), c); - return 0; + return XOR128(d, hi); } -int -crypto_aead_aes256gcm_encrypt_detached_afternm(unsigned char *c, - unsigned char *mac, unsigned long long *maclen_p, - const unsigned char *m, unsigned long long mlen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) +/* Precompute powers of H from `from` to `to` */ + +static inline void __vectorcall precomp(Precomp hx[PC_COUNT], const size_t from, const size_t to) { - const __m128i rev = _mm_set_epi8(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15); - const aes256gcm_state *ctx = (const aes256gcm_state *) (const void *) ctx_; - const __m128i *rkeys = ctx->rkeys; - __m128i Hv, H2v, H3v, H4v, accv; - unsigned long long i, j; - unsigned long long adlen_rnd64 = adlen & ~63ULL; - unsigned long long mlen_rnd128 = mlen & ~127ULL; - CRYPTO_ALIGN(16) uint32_t n2[4]; - CRYPTO_ALIGN(16) unsigned char H[16]; - CRYPTO_ALIGN(16) unsigned char T[16]; - CRYPTO_ALIGN(16) unsigned char accum[16]; - CRYPTO_ALIGN(16) unsigned char fb[16]; + const Precomp h = hx[0]; + size_t i; - (void) nsec; - memcpy(H, ctx->H, sizeof H); - if (mlen > crypto_aead_aes256gcm_MESSAGEBYTES_MAX) { - sodium_misuse(); /* LCOV_EXCL_LINE */ + for (i = from & ~1U; i < to; i += 2) { + hx[i] = gcm_reduce(clmul128(hx[i - 1], h)); + hx[i + 1] = gcm_reduce(clsq128(hx[i / 2])); } - memcpy(&n2[0], npub, 3 * 4); - n2[3] = 0x01000000; - aesni_encrypt1(T, _mm_load_si128((const __m128i *) n2), rkeys); - { - uint64_t x; - x = _bswap64((uint64_t) (8 * adlen)); - memcpy(&fb[0], &x, sizeof x); - x = _bswap64((uint64_t) (8 * mlen)); - memcpy(&fb[8], &x, sizeof x); +} + +/* Precompute powers of H given a key and a block count */ + +static void __vectorcall precomp_for_block_count(Precomp hx[PC_COUNT], + const unsigned char gh_key[16], + const size_t block_count) +{ + const BlockVec h0 = REV128(LOAD128(gh_key)); + BlockVec carry = SET64x2(0xc200000000000000, 1); + BlockVec mask = SUB64x2(ZERO128, SHR64x2(h0, 63)); + BlockVec h0_shifted; + BlockVec h; + + mask = SHUFFLE32x4(mask, 3, 3, 3, 3); + carry = AND128(carry, mask); + h0_shifted = SHL128(h0, 1); + h = XOR128(h0_shifted, carry); + + hx[0] = h; + hx[1] = gcm_reduce(clsq128(hx[0])); + + if (block_count >= PC_COUNT) { + precomp(hx, 2, PC_COUNT); + } else { + precomp(hx, 2, block_count); } - /* we store H (and it's power) byte-reverted once and for all */ - Hv = _mm_shuffle_epi8(_mm_load_si128((const __m128i *) H), rev); - _mm_store_si128((__m128i *) H, Hv); - H2v = mulv(Hv, Hv); - H3v = mulv(H2v, Hv); - H4v = mulv(H3v, Hv); - - accv = _mm_setzero_si128(); - /* unrolled by 4 GCM (by 8 doesn't improve using MULREDUCE4) */ - for (i = 0; i < adlen_rnd64; i += 64) { - __m128i X4_ = _mm_loadu_si128((const __m128i *) (ad + i + 0)); - __m128i X3_ = _mm_loadu_si128((const __m128i *) (ad + i + 16)); - __m128i X2_ = _mm_loadu_si128((const __m128i *) (ad + i + 32)); - __m128i X1_ = _mm_loadu_si128((const __m128i *) (ad + i + 48)); - MULREDUCE4(rev, Hv, H2v, H3v, H4v, X1_, X2_, X3_, X4_, accv); +} + +/* Initialize a GHash */ + +static inline void +gh_init(GHash *sth) +{ + sth->acc = ZERO128; +} + +static inline I256 __vectorcall gh_update0(const GHash *const sth, const unsigned char *const p, + const Precomp hn) +{ + const BlockVec m = REV128(LOAD128(p)); + return clmul128(XOR128(sth->acc, m), hn); +} + +static inline void __vectorcall gh_update(I256 *const u, const unsigned char *p, const Precomp hn) +{ + const BlockVec m = REV128(LOAD128(p)); + const I256 t = clmul128(m, hn); + *u = (I256) { SODIUM_C99(.hi =) XOR128(u->hi, t.hi), SODIUM_C99(.lo =) XOR128(u->lo, t.lo), + SODIUM_C99(.mid =) XOR128(u->mid, t.mid) }; +} + +/* Absorb ad_len bytes of associated data. There has to be no partial block. */ + +static inline void +gh_ad_blocks(const State *st, GHash *sth, const unsigned char *ad, size_t ad_len) +{ + size_t i; + + i = (size_t) 0U; + for (; i + PC_COUNT * 16 <= ad_len; i += PC_COUNT * 16) { + I256 u = gh_update0(sth, ad + i, st->hx[PC_COUNT - 1 - 0]); + size_t j; + + for (j = 1; j < PC_COUNT; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[PC_COUNT - 1 - j]); + } + sth->acc = gcm_reduce(u); } - _mm_store_si128((__m128i *) accum, accv); + for (; i + PC_COUNT * 16 / 2 <= ad_len; i += PC_COUNT * 16 / 2) { + I256 u = gh_update0(sth, ad + i, st->hx[PC_COUNT / 2 - 1 - 0]); + size_t j; - /* GCM remainder loop */ - for (i = adlen_rnd64; i < adlen; i += 16) { - unsigned int blocklen = 16; + for (j = 1; j < PC_COUNT / 2; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[PC_COUNT / 2 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + for (; i + 4 * 16 <= ad_len; i += 4 * 16) { + size_t j; + I256 u = gh_update0(sth, ad + i, st->hx[4 - 1 - 0]); - if (i + (unsigned long long) blocklen > adlen) { - blocklen = (unsigned int) (adlen - i); + for (j = 1; j < 4; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[4 - 1 - j]); } - addmul(accum, ad + i, blocklen, H); + sth->acc = gcm_reduce(u); } + for (; i + 2 * 16 <= ad_len; i += 2 * 16) { + size_t j; + I256 u = gh_update0(sth, ad + i, st->hx[2 - 1 - 0]); -/* this only does 8 full blocks, so no fancy bounds checking is necessary*/ -#define LOOPRND128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - \ - for (i = 0; i < mlen_rnd128; i += lb) { \ - aesni_encrypt8full(c + i, n2, rkeys, m + i, accum, Hv, H2v, H3v, H4v, rev); \ - } \ - } while(0) - -/* remainder loop, with the slower GCM update to accommodate partial blocks */ -#define LOOPRMD128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - \ - for (i = mlen_rnd128; i < mlen; i += lb) { \ - CRYPTO_ALIGN(16) unsigned char outni[8 * 16]; \ - unsigned long long mj = lb; \ - \ - aesni_encrypt8(outni, n2, rkeys); \ - if ((i + mj) >= mlen) { \ - mj = mlen - i; \ - } \ - for (j = 0; j < mj; j++) { \ - c[i + j] = m[i + j] ^ outni[j]; \ - } \ - for (j = 0; j < mj; j += 16) { \ - unsigned int bl = 16; \ - \ - if (j + (unsigned long long) bl >= mj) { \ - bl = (unsigned int) (mj - j); \ - } \ - addmul(accum, c + i + j, bl, H); \ - } \ - } \ - } while(0) - - n2[3] &= 0x00ffffff; - COUNTER_INC2(n2); - LOOPRND128; - LOOPRMD128; - - addmul(accum, fb, 16, H); - - for (i = 0; i < 16; ++i) { - mac[i] = T[i] ^ accum[15 - i]; + for (j = 1; j < 2; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[2 - 1 - j]); + } + sth->acc = gcm_reduce(u); } - if (maclen_p != NULL) { - *maclen_p = 16; + if (i < ad_len) { + I256 u = gh_update0(sth, ad + i, st->hx[0]); + sth->acc = gcm_reduce(u); } - return 0; } -int -crypto_aead_aes256gcm_encrypt_afternm(unsigned char *c, unsigned long long *clen_p, - const unsigned char *m, unsigned long long mlen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) +/* Increment counters */ + +static inline BlockVec __vectorcall incr_counters(BlockVec rev_counters[], BlockVec counter, + const size_t n) { - int ret = crypto_aead_aes256gcm_encrypt_detached_afternm(c, - c + mlen, NULL, - m, mlen, - ad, adlen, - nsec, npub, ctx_); - if (clen_p != NULL) { - *clen_p = mlen + crypto_aead_aes256gcm_ABYTES; + size_t i; + + const BlockVec one = ONE128; + for (i = 0; i < n; i++) { + rev_counters[i] = REV128(counter); + counter = ADD64x2(counter, one); } - return ret; + return counter; } -int -crypto_aead_aes256gcm_decrypt_detached_afternm(unsigned char *m, unsigned char *nsec, - const unsigned char *c, unsigned long long clen, - const unsigned char *mac, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) +/* Compute the number of required blocks to encrypt and authenticate `ad_len` of associated data, + * and `m_len` of encrypted bytes. Return `0` if limits would be exceeded.*/ + +static inline size_t +required_blocks(const size_t ad_len, const size_t m_len) { - const __m128i rev = _mm_set_epi8(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15); - const aes256gcm_state *ctx = (const aes256gcm_state *) (const void *) ctx_; - const __m128i *rkeys = ctx->rkeys; - __m128i Hv, H2v, H3v, H4v, accv; - unsigned long long i, j; - unsigned long long adlen_rnd64 = adlen & ~63ULL; - unsigned long long mlen; - unsigned long long mlen_rnd128; - CRYPTO_ALIGN(16) uint32_t n2[4]; - CRYPTO_ALIGN(16) unsigned char H[16]; - CRYPTO_ALIGN(16) unsigned char T[16]; - CRYPTO_ALIGN(16) unsigned char accum[16]; - CRYPTO_ALIGN(16) unsigned char fb[16]; + const size_t ad_blocks = (ad_len + 15) / 16; + const size_t m_blocks = (m_len + 15) / 16; - (void) nsec; - if (clen > crypto_aead_aes256gcm_MESSAGEBYTES_MAX) { - sodium_misuse(); /* LCOV_EXCL_LINE */ + if (ad_len > SIZE_MAX - 2 * PARALLEL_BLOCKS * 16 || + m_len > SIZE_MAX - 2 * PARALLEL_BLOCKS * 16 || ad_len < ad_blocks || m_len < m_blocks || + m_blocks >= (1ULL << 32) - 2) { + return 0; } - mlen = clen; - - memcpy(&n2[0], npub, 3 * 4); - n2[3] = 0x01000000; - aesni_encrypt1(T, _mm_load_si128((const __m128i *) n2), rkeys); - - { - uint64_t x; - x = _bswap64((uint64_t)(8 * adlen)); - memcpy(&fb[0], &x, sizeof x); - x = _bswap64((uint64_t)(8 * mlen)); - memcpy(&fb[8], &x, sizeof x); + return ad_blocks + m_blocks + 1; +} + +/* Generic AES-GCM encryption. "Generic" as it can handle arbitrary input sizes, +unlike a length-limited version that would precompute all the required powers of H */ + +static void +aes_gcm_encrypt_generic(const State *st, GHash *sth, unsigned char mac[ABYTES], unsigned char *dst, + const unsigned char *src, size_t src_len, const unsigned char *ad, + size_t ad_len, unsigned char counter_[16]) +{ + CRYPTO_ALIGN(32) I256 u; + CRYPTO_ALIGN(16) unsigned char last_blocks[2 * 16]; + const BlockVec one = ONE128; + BlockVec final_block; + BlockVec rev_counters[PARALLEL_BLOCKS]; + BlockVec counter; + size_t i; + size_t j; + size_t left; + size_t pi; + + COMPILER_ASSERT(PC_COUNT % PARALLEL_BLOCKS == 0); + + /* Associated data */ + + if (ad != NULL && ad_len != 0) { + gh_ad_blocks(st, sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, sth, pad, sizeof pad); + } } - memcpy(H, ctx->H, sizeof H); - Hv = _mm_shuffle_epi8(_mm_load_si128((const __m128i *) H), rev); - _mm_store_si128((__m128i *) H, Hv); - H2v = mulv(Hv, Hv); - H3v = mulv(H2v, Hv); - H4v = mulv(H3v, Hv); - - accv = _mm_setzero_si128(); - for (i = 0; i < adlen_rnd64; i += 64) { - __m128i X4_ = _mm_loadu_si128((const __m128i *) (ad + i + 0)); - __m128i X3_ = _mm_loadu_si128((const __m128i *) (ad + i + 16)); - __m128i X2_ = _mm_loadu_si128((const __m128i *) (ad + i + 32)); - __m128i X1_ = _mm_loadu_si128((const __m128i *) (ad + i + 48)); - MULREDUCE4(rev, Hv, H2v, H3v, H4v, X1_, X2_, X3_, X4_, accv); + /* Encrypted data */ + + counter = REV128(LOAD128(counter_)); + i = 0; + + /* 2*PARALLEL_BLOCKS aggregation */ + + if (src_len - i >= 2 * PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; + + for (; i + 2 * PARALLEL_BLOCKS * 16 <= src_len; i += 2 * PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + PREFETCH_READ(src + i + PARALLEL_BLOCKS * 16); +#if PARALLEL_BLOCKS >= 64 / 16 + PREFETCH_READ(src + i + PARALLEL_BLOCKS * 16 + 64); +#endif + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[2 * PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[2 * PARALLEL_BLOCKS - 1 - j]); + } + + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i + PARALLEL_BLOCKS * 16, src + i + PARALLEL_BLOCKS * 16, + rev_counters); + + PREFETCH_READ(src + i + 2 * PARALLEL_BLOCKS * 16); +#if PARALLEL_BLOCKS >= 64 / 16 + PREFETCH_READ(src + i + 2 * PARALLEL_BLOCKS * 16 + 64); +#endif + pi = i; + for (j = 0; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); } - _mm_store_si128((__m128i *) accum, accv); - for (i = adlen_rnd64; i < adlen; i += 16) { - unsigned int blocklen = 16; - if (i + (unsigned long long) blocklen > adlen) { - blocklen = (unsigned int) (adlen - i); + /* PARALLEL_BLOCKS aggregation */ + + if (src_len - i >= PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; + + for (; i + PARALLEL_BLOCKS * 16 <= src_len; i += PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); } - addmul(accum, ad + i, blocklen, H); + sth->acc = gcm_reduce(u); } - mlen_rnd128 = mlen & ~127ULL; - -#define LOOPACCUMDRND128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - for (i = 0; i < mlen_rnd128; i += lb) { \ - aesni_addmul8full(c + i, accum, Hv, H2v, H3v, H4v, rev); \ - } \ - } while(0) - -#define LOOPDRND128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - \ - for (i = 0; i < mlen_rnd128; i += lb) { \ - aesni_decrypt8full(m + i, n2, rkeys, c + i); \ - } \ - } while(0) - -#define LOOPACCUMDRMD128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - \ - for (i = mlen_rnd128; i < mlen; i += lb) { \ - unsigned long long mj = lb; \ - \ - if ((i + mj) >= mlen) { \ - mj = mlen - i; \ - } \ - for (j = 0; j < mj; j += 16) { \ - unsigned int bl = 16; \ - \ - if (j + (unsigned long long) bl >= mj) { \ - bl = (unsigned int) (mj - j); \ - } \ - addmul(accum, c + i + j, bl, H); \ - } \ - } \ - } while(0) - -#define LOOPDRMD128 \ - do { \ - const int iter = 8; \ - const int lb = iter * 16; \ - \ - for (i = mlen_rnd128; i < mlen; i += lb) { \ - CRYPTO_ALIGN(16) unsigned char outni[8 * 16]; \ - unsigned long long mj = lb; \ - \ - if ((i + mj) >= mlen) { \ - mj = mlen - i; \ - } \ - aesni_encrypt8(outni, n2, rkeys); \ - for (j = 0; j < mj; j++) { \ - m[i + j] = c[i + j] ^ outni[j]; \ - } \ - } \ - } while(0) - - n2[3] &= 0x00ffffff; - - COUNTER_INC2(n2); - LOOPACCUMDRND128; - LOOPACCUMDRMD128; - addmul(accum, fb, 16, H); - { - unsigned char d = 0; - - for (i = 0; i < 16; i++) { - d |= (mac[i] ^ (T[i] ^ accum[15 - i])); + /* 4-blocks aggregation */ + + for (; i + 4 * 16 <= src_len; i += 4 * 16) { + counter = incr_counters(rev_counters, counter, 4); + for (j = 0; j < 4; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); } - if (d != 0) { - if (m != NULL) { - memset(m, 0, mlen); - } - return -1; + + u = gh_update0(sth, dst + i, st->hx[4 - 1 - 0]); + for (j = 1; j < 4; j += 1) { + gh_update(&u, dst + i + j * 16, st->hx[4 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + /* 2-blocks aggregation */ + + for (; i + 2 * 16 <= src_len; i += 2 * 16) { + counter = incr_counters(rev_counters, counter, 2); + for (j = 0; j < 2; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); } - if (m == NULL) { - return 0; + + u = gh_update0(sth, dst + i, st->hx[2 - 1 - 0]); + for (j = 1; j < 2; j += 1) { + gh_update(&u, dst + i + j * 16, st->hx[2 - 1 - j]); } + sth->acc = gcm_reduce(u); } - n2[3] = 0U; - COUNTER_INC2(n2); - LOOPDRND128; - LOOPDRMD128; - return 0; + /* Remaining *partial* blocks; if we have 16 bytes left, we want to keep the + full block authenticated along with the final block, hence < and not <= */ + + for (; i + 16 < src_len; i += 16) { + encrypt_xor_block(st, dst + i, src + i, REV128(counter)); + u = gh_update0(sth, dst + i, st->hx[1 - 1 - 0]); + sth->acc = gcm_reduce(u); + counter = ADD64x2(counter, one); + } + + /* Authenticate both the last block of the message and the final block */ + + final_block = REV128(SET64x2(ad_len * 8, src_len * 8)); + STORE32_BE(counter_ + NPUBBYTES, 1); + encrypt(st, mac, counter_); + left = src_len - i; + if (left != 0) { + for (j = 0; j < left; j++) { + last_blocks[j] = src[i + j]; + } + STORE128(last_blocks + 16, final_block); + encrypt_xor_block(st, last_blocks, last_blocks, REV128(counter)); + for (; j < 16; j++) { + last_blocks[j] = 0; + } + for (j = 0; j < left; j++) { + dst[i + j] = last_blocks[j]; + } + gh_ad_blocks(st, sth, last_blocks, 32); + } else { + STORE128(last_blocks, final_block); + gh_ad_blocks(st, sth, last_blocks, 16); + } + STORE128(mac, XOR128(LOAD128(mac), REV128(sth->acc))); } -int -crypto_aead_aes256gcm_decrypt_afternm(unsigned char *m, unsigned long long *mlen_p, - unsigned char *nsec, - const unsigned char *c, unsigned long long clen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) +/* Generic AES-GCM decryption. "Generic" as it can handle arbitrary input sizes, +unlike a length-limited version that would precompute all the required powers of H */ + +static void +aes_gcm_decrypt_generic(const State *st, GHash *sth, unsigned char mac[ABYTES], unsigned char *dst, + const unsigned char *src, size_t src_len, const unsigned char *ad, + size_t ad_len, unsigned char counter_[16]) { - unsigned long long mlen = 0ULL; - int ret = -1; + CRYPTO_ALIGN(32) I256 u; + CRYPTO_ALIGN(16) unsigned char last_blocks[2 * 16]; + const BlockVec one = ONE128; + BlockVec final_block; + BlockVec rev_counters[PARALLEL_BLOCKS]; + BlockVec counter; + size_t i; + size_t j; + size_t left; + + COMPILER_ASSERT(PC_COUNT % PARALLEL_BLOCKS == 0); - if (clen >= crypto_aead_aes256gcm_ABYTES) { - ret = crypto_aead_aes256gcm_decrypt_detached_afternm - (m, nsec, c, clen - crypto_aead_aes256gcm_ABYTES, - c + clen - crypto_aead_aes256gcm_ABYTES, - ad, adlen, npub, ctx_); + /* Associated data */ + + if (ad != NULL && ad_len != 0) { + gh_ad_blocks(st, sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, sth, pad, sizeof pad); + } } - if (mlen_p != NULL) { - if (ret == 0) { - mlen = clen - crypto_aead_aes256gcm_ABYTES; + + /* Encrypted data */ + + counter = REV128(LOAD128(counter_)); + i = 0; + + /* 2*PARALLEL_BLOCKS aggregation */ + + while (i + 2 * PARALLEL_BLOCKS * 16 <= src_len) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + + u = gh_update0(sth, src + i, st->hx[2 * PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[2 * PARALLEL_BLOCKS - 1 - j]); } - *mlen_p = mlen; + + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + + i += PARALLEL_BLOCKS * 16; + for (j = 0; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; } - return ret; -} -int -crypto_aead_aes256gcm_encrypt_detached(unsigned char *c, - unsigned char *mac, - unsigned long long *maclen_p, - const unsigned char *m, - unsigned long long mlen, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const unsigned char *k) -{ - CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state ctx; + /* PARALLEL_BLOCKS aggregation */ - crypto_aead_aes256gcm_beforenm(&ctx, k); + for (; i + PARALLEL_BLOCKS * 16 <= src_len; i += PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); - return crypto_aead_aes256gcm_encrypt_detached_afternm - (c, mac, maclen_p, m, mlen, ad, adlen, nsec, npub, - (const crypto_aead_aes256gcm_state *) &ctx); -} + u = gh_update0(sth, src + i, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); -int -crypto_aead_aes256gcm_encrypt(unsigned char *c, - unsigned long long *clen_p, - const unsigned char *m, - unsigned long long mlen, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const unsigned char *k) -{ - CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state ctx; - int ret; + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + } - crypto_aead_aes256gcm_beforenm(&ctx, k); + /* 4-blocks aggregation */ - ret = crypto_aead_aes256gcm_encrypt_afternm - (c, clen_p, m, mlen, ad, adlen, nsec, npub, - (const crypto_aead_aes256gcm_state *) &ctx); - sodium_memzero(&ctx, sizeof ctx); + for (; i + 4 * 16 <= src_len; i += 4 * 16) { + counter = incr_counters(rev_counters, counter, 4); - return ret; -} + u = gh_update0(sth, src + i, st->hx[4 - 1 - 0]); + for (j = 1; j < 4; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[4 - 1 - j]); + } + sth->acc = gcm_reduce(u); -int -crypto_aead_aes256gcm_decrypt_detached(unsigned char *m, - unsigned char *nsec, - const unsigned char *c, - unsigned long long clen, - const unsigned char *mac, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *npub, - const unsigned char *k) -{ - CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state ctx; + for (j = 0; j < 4; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + } - crypto_aead_aes256gcm_beforenm(&ctx, k); + /* 2-blocks aggregation */ - return crypto_aead_aes256gcm_decrypt_detached_afternm - (m, nsec, c, clen, mac, ad, adlen, npub, - (const crypto_aead_aes256gcm_state *) &ctx); -} + for (; i + 2 * 16 <= src_len; i += 2 * 16) { + counter = incr_counters(rev_counters, counter, 2); -int -crypto_aead_aes256gcm_decrypt(unsigned char *m, - unsigned long long *mlen_p, - unsigned char *nsec, - const unsigned char *c, - unsigned long long clen, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *npub, - const unsigned char *k) -{ - CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state ctx; - int ret; + u = gh_update0(sth, src + i, st->hx[2 - 1 - 0]); + for (j = 1; j < 2; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[2 - 1 - j]); + } + sth->acc = gcm_reduce(u); - crypto_aead_aes256gcm_beforenm(&ctx, k); + for (j = 0; j < 2; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + } - ret = crypto_aead_aes256gcm_decrypt_afternm - (m, mlen_p, nsec, c, clen, ad, adlen, npub, - (const crypto_aead_aes256gcm_state *) &ctx); - sodium_memzero(&ctx, sizeof ctx); + /* Remaining *partial* blocks; if we have 16 bytes left, we want to keep the + full block authenticated along with the final block, hence < and not <= */ - return ret; + for (; i + 16 < src_len; i += 16) { + u = gh_update0(sth, src + i, st->hx[1 - 1 - 0]); + sth->acc = gcm_reduce(u); + encrypt_xor_block(st, dst + i, src + i, REV128(counter)); + counter = ADD64x2(counter, one); + } + + /* Authenticate both the last block of the message and the final block */ + + final_block = REV128(SET64x2(ad_len * 8, src_len * 8)); + STORE32_BE(counter_ + NPUBBYTES, 1); + encrypt(st, mac, counter_); + left = src_len - i; + if (left != 0) { + for (j = 0; j < left; j++) { + last_blocks[j] = src[i + j]; + } + for (; j < 16; j++) { + last_blocks[j] = 0; + } + STORE128(last_blocks + 16, final_block); + gh_ad_blocks(st, sth, last_blocks, 32); + encrypt_xor_block(st, last_blocks, last_blocks, REV128(counter)); + for (j = 0; j < left; j++) { + dst[i + j] = last_blocks[j]; + } + } else { + STORE128(last_blocks, final_block); + gh_ad_blocks(st, sth, last_blocks, 16); + } + STORE128(mac, XOR128(LOAD128(mac), REV128(sth->acc))); } int -crypto_aead_aes256gcm_is_available(void) +crypto_aead_aes256gcm_beforenm(crypto_aead_aes256gcm_state *st_, const unsigned char *k) { - return sodium_runtime_has_pclmul() & sodium_runtime_has_aesni(); -} + State *st = (State *) (void *) st_; + CRYPTO_ALIGN(16) unsigned char h[16]; -#else + COMPILER_ASSERT(sizeof *st_ >= sizeof *st); -int -crypto_aead_aes256gcm_encrypt_detached(unsigned char *c, - unsigned char *mac, - unsigned long long *maclen_p, - const unsigned char *m, - unsigned long long mlen, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const unsigned char *k) -{ - errno = ENOSYS; - return -1; -} + expand256(k, st->rkeys); + memset(h, 0, sizeof h); + encrypt(st, h, h); -int -crypto_aead_aes256gcm_encrypt(unsigned char *c, unsigned long long *clen_p, - const unsigned char *m, unsigned long long mlen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *nsec, const unsigned char *npub, - const unsigned char *k) -{ - errno = ENOSYS; - return -1; -} + precomp_for_block_count(st->hx, h, PC_COUNT); -int -crypto_aead_aes256gcm_decrypt_detached(unsigned char *m, - unsigned char *nsec, - const unsigned char *c, - unsigned long long clen, - const unsigned char *mac, - const unsigned char *ad, - unsigned long long adlen, - const unsigned char *npub, - const unsigned char *k) -{ - errno = ENOSYS; - return -1; + return 0; } int -crypto_aead_aes256gcm_decrypt(unsigned char *m, unsigned long long *mlen_p, - unsigned char *nsec, const unsigned char *c, - unsigned long long clen, const unsigned char *ad, - unsigned long long adlen, const unsigned char *npub, - const unsigned char *k) -{ - errno = ENOSYS; - return -1; +crypto_aead_aes256gcm_encrypt_detached_afternm(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long m_len_, const unsigned char *ad, + unsigned long long ad_len_, + const unsigned char *nsec, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + CRYPTO_ALIGN(16) unsigned char j[16]; + size_t gh_required_blocks; + const size_t ad_len = (size_t) ad_len_; + const size_t m_len = (size_t) m_len_; + + (void) nsec; + if (maclen_p != NULL) { + *maclen_p = 0; + } + if (ad_len_ > SODIUM_SIZE_MAX || m_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + gh_required_blocks = required_blocks(ad_len, m_len); + if (gh_required_blocks == 0) { + memset(mac, 0xd0, ABYTES); + memset(c, 0, m_len); + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + aes_gcm_encrypt_generic(st, &sth, mac, c, m, m_len, ad, ad_len, j); + + if (maclen_p != NULL) { + *maclen_p = ABYTES; + } + return 0; } int -crypto_aead_aes256gcm_beforenm(crypto_aead_aes256gcm_state *ctx_, - const unsigned char *k) +crypto_aead_aes256gcm_encrypt(unsigned char *c, unsigned long long *clen_p, const unsigned char *m, + unsigned long long m_len, const unsigned char *ad, + unsigned long long ad_len, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) { - errno = ENOSYS; - return -1; + const int ret = crypto_aead_aes256gcm_encrypt_detached(c, c + m_len, NULL, m, m_len, ad, ad_len, + nsec, npub, k); + if (clen_p != NULL) { + if (ret == 0) { + *clen_p = m_len + crypto_aead_aes256gcm_ABYTES; + } else { + *clen_p = 0; + } + } + return ret; } int -crypto_aead_aes256gcm_encrypt_detached_afternm(unsigned char *c, - unsigned char *mac, unsigned long long *maclen_p, - const unsigned char *m, unsigned long long mlen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *nsec, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) +crypto_aead_aes256gcm_encrypt_detached(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long m_len, const unsigned char *ad, + unsigned long long ad_len, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) { - errno = ENOSYS; - return -1; + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; + int ret; + + PREFETCH_WRITE(c); + PREFETCH_READ(m); + PREFETCH_READ(ad); + + crypto_aead_aes256gcm_beforenm(&st, k); + ret = crypto_aead_aes256gcm_encrypt_detached_afternm(c, mac, maclen_p, m, m_len, ad, ad_len, + nsec, npub, &st); + sodium_memzero(&st, sizeof st); + + return ret; } int @@ -998,82 +820,196 @@ crypto_aead_aes256gcm_encrypt_afternm(unsigned char *c, unsigned long long *clen const unsigned char *m, unsigned long long mlen, const unsigned char *ad, unsigned long long adlen, const unsigned char *nsec, const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) + const crypto_aead_aes256gcm_state *st_) { - errno = ENOSYS; - return -1; + int ret = crypto_aead_aes256gcm_encrypt_detached_afternm(c, c + mlen, NULL, m, mlen, ad, adlen, + nsec, npub, st_); + if (clen_p != NULL) { + *clen_p = mlen + crypto_aead_aes256gcm_ABYTES; + } + return ret; +} + +static int +crypto_aead_aes256gcm_verify_mac(unsigned char *nsec, const unsigned char *c, + unsigned long long c_len_, const unsigned char *mac, + const unsigned char *ad, unsigned long long ad_len_, + const unsigned char *npub, const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + BlockVec final_block; + CRYPTO_ALIGN(16) unsigned char j[16]; + CRYPTO_ALIGN(16) unsigned char computed_mac[16]; + CRYPTO_ALIGN(16) unsigned char last_block[16]; + size_t gh_required_blocks; + size_t left; + const size_t ad_len = (size_t) ad_len_; + const size_t c_len = (size_t) c_len_; + int ret; + + (void) nsec; + if (ad_len_ > SODIUM_SIZE_MAX || c_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + gh_required_blocks = required_blocks(ad_len, c_len); + if (gh_required_blocks == 0) { + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + gh_ad_blocks(st, &sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, &sth, pad, sizeof pad); + } + + gh_ad_blocks(st, &sth, c, c_len & ~15); + left = c_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, c + c_len - left, left); + gh_ad_blocks(st, &sth, pad, sizeof pad); + } + final_block = REV128(SET64x2(ad_len * 8, c_len * 8)); + STORE32_BE(j + NPUBBYTES, 1); + encrypt(st, computed_mac, j); + STORE128(last_block, final_block); + gh_ad_blocks(st, &sth, last_block, 16); + STORE128(computed_mac, XOR128(LOAD128(computed_mac), REV128(sth.acc))); + + ret = crypto_verify_16(mac, computed_mac); + sodium_memzero(computed_mac, sizeof computed_mac); + + return ret; } int crypto_aead_aes256gcm_decrypt_detached_afternm(unsigned char *m, unsigned char *nsec, - const unsigned char *c, unsigned long long clen, - const unsigned char *mac, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) -{ - errno = ENOSYS; - return -1; + const unsigned char *c, unsigned long long c_len_, + const unsigned char *mac, const unsigned char *ad, + unsigned long long ad_len_, + const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + CRYPTO_ALIGN(16) unsigned char j[16]; + unsigned char computed_mac[16]; + size_t gh_required_blocks; + const size_t ad_len = (size_t) ad_len_; + const size_t c_len = (size_t) c_len_; + const size_t m_len = c_len; + + (void) nsec; + if (ad_len_ > SODIUM_SIZE_MAX || c_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + if (m == NULL) { + return crypto_aead_aes256gcm_verify_mac(nsec, c, c_len, mac, ad, ad_len, npub, st_); + } + gh_required_blocks = required_blocks(ad_len, m_len); + if (gh_required_blocks == 0) { + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + aes_gcm_decrypt_generic(st, &sth, computed_mac, m, c, m_len, ad, ad_len, j); + + if (crypto_verify_16(mac, computed_mac) != 0) { + sodium_memzero(computed_mac, sizeof computed_mac); + memset(m, 0xd0, m_len); + return -1; + } + return 0; } int crypto_aead_aes256gcm_decrypt_afternm(unsigned char *m, unsigned long long *mlen_p, - unsigned char *nsec, - const unsigned char *c, unsigned long long clen, - const unsigned char *ad, unsigned long long adlen, - const unsigned char *npub, - const crypto_aead_aes256gcm_state *ctx_) + unsigned char *nsec, const unsigned char *c, + unsigned long long clen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) { - errno = ENOSYS; - return -1; + unsigned long long mlen = 0ULL; + int ret = -1; + + if (clen >= ABYTES) { + ret = crypto_aead_aes256gcm_decrypt_detached_afternm( + m, nsec, c, clen - ABYTES, c + clen - ABYTES, ad, adlen, npub, st_); + } + if (mlen_p != NULL) { + if (ret == 0) { + mlen = clen - ABYTES; + } + *mlen_p = mlen; + } + return ret; } int -crypto_aead_aes256gcm_is_available(void) +crypto_aead_aes256gcm_decrypt_detached(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *mac, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const unsigned char *k) { - return 0; -} + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; -#endif + PREFETCH_WRITE(m); + PREFETCH_READ(c); + PREFETCH_READ(ad); -size_t -crypto_aead_aes256gcm_keybytes(void) -{ - return crypto_aead_aes256gcm_KEYBYTES; -} + crypto_aead_aes256gcm_beforenm(&st, k); -size_t -crypto_aead_aes256gcm_nsecbytes(void) -{ - return crypto_aead_aes256gcm_NSECBYTES; + return crypto_aead_aes256gcm_decrypt_detached_afternm( + m, nsec, c, clen, mac, ad, adlen, npub, (const crypto_aead_aes256gcm_state *) &st); } -size_t -crypto_aead_aes256gcm_npubbytes(void) +int +crypto_aead_aes256gcm_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) { - return crypto_aead_aes256gcm_NPUBBYTES; -} + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; + int ret; -size_t -crypto_aead_aes256gcm_abytes(void) -{ - return crypto_aead_aes256gcm_ABYTES; -} + PREFETCH_WRITE(m); + PREFETCH_READ(c); + PREFETCH_READ(ad); -size_t -crypto_aead_aes256gcm_statebytes(void) -{ - return (sizeof(crypto_aead_aes256gcm_state) + (size_t) 15U) & ~(size_t) 15U; -} + crypto_aead_aes256gcm_beforenm(&st, k); -size_t -crypto_aead_aes256gcm_messagebytes_max(void) -{ - return crypto_aead_aes256gcm_MESSAGEBYTES_MAX; + ret = crypto_aead_aes256gcm_decrypt_afternm(m, mlen_p, nsec, c, clen, ad, adlen, npub, + (const crypto_aead_aes256gcm_state *) &st); + sodium_memzero(&st, sizeof st); + + return ret; } -void -crypto_aead_aes256gcm_keygen(unsigned char k[crypto_aead_aes256gcm_KEYBYTES]) +int +crypto_aead_aes256gcm_is_available(void) { - randombytes_buf(k, crypto_aead_aes256gcm_KEYBYTES); + return sodium_runtime_has_pclmul() & sodium_runtime_has_aesni() & sodium_runtime_has_avx(); } + +#ifdef __clang__ +# pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c b/subprojects/libsodium/src/libsodium/crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c @@ -0,0 +1,1033 @@ +#include <errno.h> +#include <limits.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "core.h" +#include "crypto_aead_aes256gcm.h" +#include "crypto_verify_16.h" +#include "export.h" +#include "private/common.h" +#include "randombytes.h" +#include "runtime.h" +#include "utils.h" + +#if defined(HAVE_ARMCRYPTO) && defined(__clang__) && defined(NATIVE_LITTLE_ENDIAN) + +#if !defined(_MSC_VER) || _MSC_VER < 1800 +#define __vectorcall +#endif + +#ifndef __ARM_FEATURE_CRYPTO +#define __ARM_FEATURE_CRYPTO 1 +#endif +#ifndef __ARM_FEATURE_AES +#define __ARM_FEATURE_AES 1 +#endif + +#include <arm_neon.h> + +#ifdef __clang__ +#pragma clang attribute push(__attribute__((target("neon,crypto,aes"))), apply_to = function) +#elif defined(__GNUC__) +#pragma GCC target("+simd+crypto") +#endif + +#define ABYTES crypto_aead_aes256gcm_ABYTES +#define NPUBBYTES crypto_aead_aes256gcm_NPUBBYTES +#define KEYBYTES crypto_aead_aes256gcm_KEYBYTES + +#define PARALLEL_BLOCKS 6 +#undef USE_KARATSUBA_MULTIPLICATION + +typedef uint64x2_t BlockVec; + +#define LOAD128(a) vld1q_u64((const uint64_t *) (const void *) (a)) +#define STORE128(a, b) vst1q_u64((uint64_t *) (void *) (a), (b)) +#define AES_XENCRYPT(block_vec, rkey) \ + vreinterpretq_u64_u8( \ + vaesmcq_u8(vaeseq_u8(rkey, vreinterpretq_u8_u64(block_vec)))) +#define AES_XENCRYPTLAST(block_vec, rkey) \ + vreinterpretq_u64_u8(vaeseq_u8(rkey, vreinterpretq_u8_u64(block_vec))) +#define XOR128(a, b) veorq_u64((a), (b)) +#define AND128(a, b) vandq_u64((a), (b)) +#define OR128(a, b) vorrq_u64((a), (b)) +#define SET64x2(a, b) vsetq_lane_u64((uint64_t) (a), vmovq_n_u64((uint64_t) (b)), 1) +#define ZERO128 vmovq_n_u8(0) +#define ONE128 SET64x2(0, 1) +#define ADD64x2(a, b) vaddq_u64((a), (b)) +#define SUB64x2(a, b) vsubq_u64((a), (b)) +#define SHL64x2(a, b) vshlq_n_u64((a), (b)) +#define SHR64x2(a, b) vshrq_n_u64((a), (b)) +#define REV128(x) \ + vreinterpretq_u64_u8(__builtin_shufflevector(vreinterpretq_u8_u64(x), vreinterpretq_u8_u64(x), \ + 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, \ + 1, 0)) +#define SHUFFLE32x4(x, a, b, c, d) \ + vreinterpretq_u64_u32(__builtin_shufflevector(vreinterpretq_u32_u64(x), \ + vreinterpretq_u32_u64(x), (a), (b), (c), (d))) +#define BYTESHL128(a, b) vreinterpretq_u64_u8(vextq_s8(vdupq_n_s8(0), (int8x16_t) a, 16 - (b))) +#define BYTESHR128(a, b) vreinterpretq_u64_u8(vextq_s8((int8x16_t) a, vdupq_n_s8(0), (b))) + +#define SHL128(a, b) OR128(SHL64x2((a), (b)), SHR64x2(BYTESHL128((a), 8), 64 - (b))) +#define CLMULLO128(a, b) \ + vreinterpretq_u64_p128(vmull_p64((poly64_t) vget_low_u64(a), (poly64_t) vget_low_u64(b))) +#define CLMULHI128(a, b) \ + vreinterpretq_u64_p128(vmull_high_p64(vreinterpretq_p64_s64(a), vreinterpretq_p64_s64(b))) +#define CLMULLOHI128(a, b) \ + vreinterpretq_u64_p128(vmull_p64((poly64_t) vget_low_u64(a), (poly64_t) vget_high_u64(b))) +#define CLMULHILO128(a, b) \ + vreinterpretq_u64_p128(vmull_p64((poly64_t) vget_high_u64(a), (poly64_t) vget_low_u64(b))) +#define PREFETCH_READ(x) __builtin_prefetch((x), 0, 2) +#define PREFETCH_WRITE(x) __builtin_prefetch((x), 1, 2); + +static inline BlockVec +AES_KEYGEN(BlockVec block_vec, const int rc) +{ + uint8x16_t a = vaeseq_u8(vreinterpretq_u8_u64(block_vec), vmovq_n_u8(0)); + const uint8x16_t b = + __builtin_shufflevector(a, a, 4, 1, 14, 11, 1, 14, 11, 4, 12, 9, 6, 3, 9, 6, 3, 12); + const uint64x2_t c = SET64x2((uint64_t) rc << 32, (uint64_t) rc << 32); + return XOR128(b, c); +} + +#define ROUNDS 14 + +#define PC_COUNT (2 * PARALLEL_BLOCKS) + +typedef struct I256 { + BlockVec hi; + BlockVec lo; + BlockVec mid; +} I256; + +typedef BlockVec Precomp; + +typedef struct GHash { + BlockVec acc; +} GHash; + +typedef struct State { + BlockVec rkeys[ROUNDS + 1]; + Precomp hx[PC_COUNT]; +} State; + +static void __vectorcall expand256(const unsigned char key[KEYBYTES], BlockVec rkeys[1 + ROUNDS]) +{ + BlockVec t1, t2, s; + size_t i = 0; + +#define EXPAND_KEY_1(RC) \ + rkeys[i++] = t2; \ + s = AES_KEYGEN(t2, RC); \ + t1 = XOR128(t1, BYTESHL128(t1, 4)); \ + t1 = XOR128(t1, BYTESHL128(t1, 8)); \ + t1 = XOR128(t1, SHUFFLE32x4(s, 3, 3, 3, 3)); + +#define EXPAND_KEY_2(RC) \ + rkeys[i++] = t1; \ + s = AES_KEYGEN(t1, RC); \ + t2 = XOR128(t2, BYTESHL128(t2, 4)); \ + t2 = XOR128(t2, BYTESHL128(t2, 8)); \ + t2 = XOR128(t2, SHUFFLE32x4(s, 2, 2, 2, 2)); + + t1 = LOAD128(&key[0]); + t2 = LOAD128(&key[16]); + + rkeys[i++] = t1; + EXPAND_KEY_1(0x01); + EXPAND_KEY_2(0x01); + EXPAND_KEY_1(0x02); + EXPAND_KEY_2(0x02); + EXPAND_KEY_1(0x04); + EXPAND_KEY_2(0x04); + EXPAND_KEY_1(0x08); + EXPAND_KEY_2(0x08); + EXPAND_KEY_1(0x10); + EXPAND_KEY_2(0x10); + EXPAND_KEY_1(0x20); + EXPAND_KEY_2(0x20); + EXPAND_KEY_1(0x40); + rkeys[i++] = t1; +} + +/* Encrypt a single AES block */ + +static inline void +encrypt(const State *st, unsigned char dst[16], const unsigned char src[16]) +{ + BlockVec t; + + size_t i; + + t = AES_XENCRYPT(LOAD128(src), st->rkeys[0]); + for (i = 1; i < ROUNDS - 1; i++) { + t = AES_XENCRYPT(t, st->rkeys[i]); + } + t = AES_XENCRYPTLAST(t, st->rkeys[i]); + t = XOR128(t, st->rkeys[ROUNDS]); + STORE128(dst, t); +} + +/* Encrypt and add a single AES block */ + +static inline void __vectorcall encrypt_xor_block(const State *st, unsigned char dst[16], + const unsigned char src[16], + const BlockVec counter) +{ + BlockVec ts; + size_t i; + + ts = AES_XENCRYPT(counter, st->rkeys[0]); + for (i = 1; i < ROUNDS - 1; i++) { + ts = AES_XENCRYPT(ts, st->rkeys[i]); + } + ts = AES_XENCRYPTLAST(ts, st->rkeys[i]); + ts = XOR128(ts, XOR128(st->rkeys[ROUNDS], LOAD128(src))); + STORE128(dst, ts); +} + +/* Encrypt and add PARALLEL_BLOCKS AES blocks */ + +static inline void __vectorcall encrypt_xor_wide(const State *st, + unsigned char dst[16 * PARALLEL_BLOCKS], + const unsigned char src[16 * PARALLEL_BLOCKS], + const BlockVec counters[PARALLEL_BLOCKS]) +{ + BlockVec ts[PARALLEL_BLOCKS]; + size_t i, j; + + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = AES_XENCRYPT(counters[j], st->rkeys[0]); + } + for (i = 1; i < ROUNDS - 1; i++) { + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = AES_XENCRYPT(ts[j], st->rkeys[i]); + } + } + for (j = 0; j < PARALLEL_BLOCKS; j++) { + ts[j] = AES_XENCRYPTLAST(ts[j], st->rkeys[i]); + ts[j] = XOR128(ts[j], XOR128(st->rkeys[ROUNDS], LOAD128(&src[16 * j]))); + } + for (j = 0; j < PARALLEL_BLOCKS; j++) { + STORE128(&dst[16 * j], ts[j]); + } +} + +/* Square a field element */ + +static inline I256 __vectorcall clsq128(const BlockVec x) +{ + const BlockVec r_lo = CLMULLO128(x, x); + const BlockVec r_hi = CLMULHI128(x, x); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) ZERO128, + }; +} + +/* Multiply two field elements -- Textbook multiplication is faster than Karatsuba on some recent + * CPUs */ + +static inline I256 __vectorcall clmul128(const BlockVec x, const BlockVec y) +{ +#ifdef USE_KARATSUBA_MULTIPLICATION + const BlockVec x_hi = BYTESHR128(x, 8); + const BlockVec y_hi = BYTESHR128(y, 8); + const BlockVec r_lo = CLMULLO128(x, y); + const BlockVec r_hi = CLMULHI128(x, y); + const BlockVec r_mid = XOR128(CLMULLO128(XOR128(x, x_hi), XOR128(y, y_hi)), XOR128(r_lo, r_hi)); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) r_mid, + }; +#else + const BlockVec r_hi = CLMULHI128(x, y); + const BlockVec r_lo = CLMULLO128(x, y); + const BlockVec r_mid = XOR128(CLMULHILO128(x, y), CLMULLOHI128(x, y)); + + return (I256) { + SODIUM_C99(.hi =) r_hi, + SODIUM_C99(.lo =) r_lo, + SODIUM_C99(.mid =) r_mid, + }; +#endif +} + +/* Merge the middle word and reduce a field element */ + +static inline BlockVec __vectorcall gcm_reduce(const I256 x) +{ + const BlockVec hi = XOR128(x.hi, BYTESHR128(x.mid, 8)); + const BlockVec lo = XOR128(x.lo, BYTESHL128(x.mid, 8)); + + const BlockVec p64 = SET64x2(0, 0xc200000000000000); + const BlockVec a = CLMULLO128(lo, p64); + const BlockVec b = XOR128(SHUFFLE32x4(lo, 2, 3, 0, 1), a); + const BlockVec c = CLMULLO128(b, p64); + const BlockVec d = XOR128(SHUFFLE32x4(b, 2, 3, 0, 1), c); + + return XOR128(d, hi); +} + +/* Precompute powers of H from `from` to `to` */ + +static inline void __vectorcall precomp(Precomp hx[PC_COUNT], const size_t from, const size_t to) +{ + const Precomp h = hx[0]; + size_t i; + + for (i = from & ~1U; i < to; i += 2) { + hx[i] = gcm_reduce(clmul128(hx[i - 1], h)); + hx[i + 1] = gcm_reduce(clsq128(hx[i / 2])); + } +} + +/* Precompute powers of H given a key and a block count */ + +static void __vectorcall precomp_for_block_count(Precomp hx[PC_COUNT], + const unsigned char gh_key[16], + const size_t block_count) +{ + const BlockVec h0 = REV128(LOAD128(gh_key)); + BlockVec carry = SET64x2(0xc200000000000000, 1); + BlockVec mask = SUB64x2(ZERO128, SHR64x2(h0, 63)); + BlockVec h0_shifted; + BlockVec h; + + mask = SHUFFLE32x4(mask, 3, 3, 3, 3); + carry = AND128(carry, mask); + h0_shifted = SHL128(h0, 1); + h = XOR128(h0_shifted, carry); + + hx[0] = h; + hx[1] = gcm_reduce(clsq128(hx[0])); + + if (block_count >= PC_COUNT) { + precomp(hx, 2, PC_COUNT); + } else { + precomp(hx, 2, block_count); + } +} + +/* Initialize a GHash */ + +static inline void +gh_init(GHash *sth) +{ + sth->acc = ZERO128; +} + +static inline I256 __vectorcall gh_update0(const GHash *const sth, const unsigned char *const p, + const Precomp hn) +{ + const BlockVec m = REV128(LOAD128(p)); + return clmul128(XOR128(sth->acc, m), hn); +} + +static inline void __vectorcall gh_update(I256 *const u, const unsigned char *p, const Precomp hn) +{ + const BlockVec m = REV128(LOAD128(p)); + const I256 t = clmul128(m, hn); + *u = (I256) { SODIUM_C99(.hi =) XOR128(u->hi, t.hi), SODIUM_C99(.lo =) XOR128(u->lo, t.lo), + SODIUM_C99(.mid =) XOR128(u->mid, t.mid) }; +} + +/* Absorb ad_len bytes of associated data. There has to be no partial block. */ + +static inline void +gh_ad_blocks(const State *st, GHash *sth, const unsigned char *ad, size_t ad_len) +{ + size_t i; + + i = (size_t) 0U; + for (; i + PC_COUNT * 16 <= ad_len; i += PC_COUNT * 16) { + I256 u = gh_update0(sth, ad + i, st->hx[PC_COUNT - 1 - 0]); + size_t j; + + for (j = 1; j < PC_COUNT; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[PC_COUNT - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + for (; i + PC_COUNT * 16 / 2 <= ad_len; i += PC_COUNT * 16 / 2) { + I256 u = gh_update0(sth, ad + i, st->hx[PC_COUNT / 2 - 1 - 0]); + size_t j; + + for (j = 1; j < PC_COUNT / 2; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[PC_COUNT / 2 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + for (; i + 4 * 16 <= ad_len; i += 4 * 16) { + size_t j; + I256 u = gh_update0(sth, ad + i, st->hx[4 - 1 - 0]); + + for (j = 1; j < 4; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[4 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + for (; i + 2 * 16 <= ad_len; i += 2 * 16) { + size_t j; + I256 u = gh_update0(sth, ad + i, st->hx[2 - 1 - 0]); + + for (j = 1; j < 2; j += 1) { + gh_update(&u, ad + i + j * 16, st->hx[2 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + if (i < ad_len) { + I256 u = gh_update0(sth, ad + i, st->hx[0]); + sth->acc = gcm_reduce(u); + } +} + +/* Increment counters */ + +static inline BlockVec __vectorcall incr_counters(BlockVec rev_counters[], BlockVec counter, + const size_t n) +{ + size_t i; + + const BlockVec one = ONE128; + for (i = 0; i < n; i++) { + rev_counters[i] = REV128(counter); + counter = ADD64x2(counter, one); + } + return counter; +} + +/* Compute the number of required blocks to encrypt and authenticate `ad_len` of associated data, + * and `m_len` of encrypted bytes. Return `0` if limits would be exceeded.*/ + +static inline size_t +required_blocks(const size_t ad_len, const size_t m_len) +{ + const size_t ad_blocks = (ad_len + 15) / 16; + const size_t m_blocks = (m_len + 15) / 16; + + if (ad_len > SIZE_MAX - 2 * PARALLEL_BLOCKS * 16 || + m_len > SIZE_MAX - 2 * PARALLEL_BLOCKS * 16 || ad_len < ad_blocks || m_len < m_blocks || + m_blocks >= (1ULL << 32) - 2) { + return 0; + } + return ad_blocks + m_blocks + 1; +} + +/* Generic AES-GCM encryption. "Generic" as it can handle arbitrary input sizes, +unlike a length-limited version that would precompute all the required powers of H */ + +static void +aes_gcm_encrypt_generic(const State *st, GHash *sth, unsigned char mac[ABYTES], unsigned char *dst, + const unsigned char *src, size_t src_len, const unsigned char *ad, + size_t ad_len, unsigned char counter_[16]) +{ + CRYPTO_ALIGN(32) I256 u; + CRYPTO_ALIGN(16) unsigned char last_blocks[2 * 16]; + const BlockVec one = ONE128; + BlockVec final_block; + BlockVec rev_counters[PARALLEL_BLOCKS]; + BlockVec counter; + size_t i; + size_t j; + size_t left; + size_t pi; + + COMPILER_ASSERT(PC_COUNT % PARALLEL_BLOCKS == 0); + + /* Associated data */ + + if (ad != NULL && ad_len != 0) { + gh_ad_blocks(st, sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, sth, pad, sizeof pad); + } + } + + /* Encrypted data */ + + counter = REV128(LOAD128(counter_)); + i = 0; + + /* 2*PARALLEL_BLOCKS aggregation */ + + if (src_len - i >= 2 * PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; + + for (; i + 2 * PARALLEL_BLOCKS * 16 <= src_len; i += 2 * PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[2 * PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[2 * PARALLEL_BLOCKS - 1 - j]); + } + + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i + PARALLEL_BLOCKS * 16, src + i + PARALLEL_BLOCKS * 16, + rev_counters); + + pi = i; + for (j = 0; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + /* PARALLEL_BLOCKS aggregation */ + + if (src_len - i >= PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; + + for (; i + PARALLEL_BLOCKS * 16 <= src_len; i += PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + pi = i - PARALLEL_BLOCKS * 16; + u = gh_update0(sth, dst + pi, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, dst + pi + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + /* 4-blocks aggregation */ + + for (; i + 4 * 16 <= src_len; i += 4 * 16) { + counter = incr_counters(rev_counters, counter, 4); + for (j = 0; j < 4; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + + u = gh_update0(sth, dst + i, st->hx[4 - 1 - 0]); + for (j = 1; j < 4; j += 1) { + gh_update(&u, dst + i + j * 16, st->hx[4 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + /* 2-blocks aggregation */ + + for (; i + 2 * 16 <= src_len; i += 2 * 16) { + counter = incr_counters(rev_counters, counter, 2); + for (j = 0; j < 2; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + + u = gh_update0(sth, dst + i, st->hx[2 - 1 - 0]); + for (j = 1; j < 2; j += 1) { + gh_update(&u, dst + i + j * 16, st->hx[2 - 1 - j]); + } + sth->acc = gcm_reduce(u); + } + + /* Remaining *partial* blocks; if we have 16 bytes left, we want to keep the + full block authenticated along with the final block, hence < and not <= */ + + for (; i + 16 < src_len; i += 16) { + encrypt_xor_block(st, dst + i, src + i, REV128(counter)); + u = gh_update0(sth, dst + i, st->hx[1 - 1 - 0]); + sth->acc = gcm_reduce(u); + counter = ADD64x2(counter, one); + } + + /* Authenticate both the last block of the message and the final block */ + + final_block = REV128(SET64x2(ad_len * 8, src_len * 8)); + STORE32_BE(counter_ + NPUBBYTES, 1); + encrypt(st, mac, counter_); + left = src_len - i; + if (left != 0) { + for (j = 0; j < left; j++) { + last_blocks[j] = src[i + j]; + } + STORE128(last_blocks + 16, final_block); + encrypt_xor_block(st, last_blocks, last_blocks, REV128(counter)); + for (; j < 16; j++) { + last_blocks[j] = 0; + } + for (j = 0; j < left; j++) { + dst[i + j] = last_blocks[j]; + } + gh_ad_blocks(st, sth, last_blocks, 32); + } else { + STORE128(last_blocks, final_block); + gh_ad_blocks(st, sth, last_blocks, 16); + } + STORE128(mac, XOR128(LOAD128(mac), REV128(sth->acc))); +} + +/* Generic AES-GCM decryption. "Generic" as it can handle arbitrary input sizes, +unlike a length-limited version that would precompute all the required powers of H */ + +static void +aes_gcm_decrypt_generic(const State *st, GHash *sth, unsigned char mac[ABYTES], unsigned char *dst, + const unsigned char *src, size_t src_len, const unsigned char *ad, + size_t ad_len, unsigned char counter_[16]) +{ + CRYPTO_ALIGN(32) I256 u; + CRYPTO_ALIGN(16) unsigned char last_blocks[2 * 16]; + const BlockVec one = ONE128; + BlockVec final_block; + BlockVec rev_counters[PARALLEL_BLOCKS]; + BlockVec counter; + size_t i; + size_t j; + size_t left; + + COMPILER_ASSERT(PC_COUNT % PARALLEL_BLOCKS == 0); + + /* Associated data */ + + if (ad != NULL && ad_len != 0) { + gh_ad_blocks(st, sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, sth, pad, sizeof pad); + } + } + + /* Encrypted data */ + + counter = REV128(LOAD128(counter_)); + i = 0; + + /* 2*PARALLEL_BLOCKS aggregation */ + + while (i + 2 * PARALLEL_BLOCKS * 16 <= src_len) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + + u = gh_update0(sth, src + i, st->hx[2 * PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[2 * PARALLEL_BLOCKS - 1 - j]); + } + + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + + i += PARALLEL_BLOCKS * 16; + for (j = 0; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + i += PARALLEL_BLOCKS * 16; + } + + /* PARALLEL_BLOCKS aggregation */ + + for (; i + PARALLEL_BLOCKS * 16 <= src_len; i += PARALLEL_BLOCKS * 16) { + counter = incr_counters(rev_counters, counter, PARALLEL_BLOCKS); + + u = gh_update0(sth, src + i, st->hx[PARALLEL_BLOCKS - 1 - 0]); + for (j = 1; j < PARALLEL_BLOCKS; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[PARALLEL_BLOCKS - 1 - j]); + } + sth->acc = gcm_reduce(u); + + encrypt_xor_wide(st, dst + i, src + i, rev_counters); + } + + /* 4-blocks aggregation */ + + for (; i + 4 * 16 <= src_len; i += 4 * 16) { + counter = incr_counters(rev_counters, counter, 4); + + u = gh_update0(sth, src + i, st->hx[4 - 1 - 0]); + for (j = 1; j < 4; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[4 - 1 - j]); + } + sth->acc = gcm_reduce(u); + + for (j = 0; j < 4; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + } + + /* 2-blocks aggregation */ + + for (; i + 2 * 16 <= src_len; i += 2 * 16) { + counter = incr_counters(rev_counters, counter, 2); + + u = gh_update0(sth, src + i, st->hx[2 - 1 - 0]); + for (j = 1; j < 2; j += 1) { + gh_update(&u, src + i + j * 16, st->hx[2 - 1 - j]); + } + sth->acc = gcm_reduce(u); + + for (j = 0; j < 2; j++) { + encrypt_xor_block(st, dst + i + j * 16, src + i + j * 16, rev_counters[j]); + } + } + + /* Remaining *partial* blocks; if we have 16 bytes left, we want to keep the + full block authenticated along with the final block, hence < and not <= */ + + for (; i + 16 < src_len; i += 16) { + u = gh_update0(sth, src + i, st->hx[1 - 1 - 0]); + sth->acc = gcm_reduce(u); + encrypt_xor_block(st, dst + i, src + i, REV128(counter)); + counter = ADD64x2(counter, one); + } + + /* Authenticate both the last block of the message and the final block */ + + final_block = REV128(SET64x2(ad_len * 8, src_len * 8)); + STORE32_BE(counter_ + NPUBBYTES, 1); + encrypt(st, mac, counter_); + left = src_len - i; + if (left != 0) { + for (j = 0; j < left; j++) { + last_blocks[j] = src[i + j]; + } + for (; j < 16; j++) { + last_blocks[j] = 0; + } + STORE128(last_blocks + 16, final_block); + gh_ad_blocks(st, sth, last_blocks, 32); + encrypt_xor_block(st, last_blocks, last_blocks, REV128(counter)); + for (j = 0; j < left; j++) { + dst[i + j] = last_blocks[j]; + } + } else { + STORE128(last_blocks, final_block); + gh_ad_blocks(st, sth, last_blocks, 16); + } + STORE128(mac, XOR128(LOAD128(mac), REV128(sth->acc))); +} + +int +crypto_aead_aes256gcm_beforenm(crypto_aead_aes256gcm_state *st_, const unsigned char *k) +{ + State *st = (State *) (void *) st_; + CRYPTO_ALIGN(16) unsigned char h[16]; + + COMPILER_ASSERT(sizeof *st_ >= sizeof *st); + + expand256(k, st->rkeys); + memset(h, 0, sizeof h); + encrypt(st, h, h); + + precomp_for_block_count(st->hx, h, PC_COUNT); + + return 0; +} + +int +crypto_aead_aes256gcm_encrypt_detached_afternm(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long m_len_, const unsigned char *ad, + unsigned long long ad_len_, + const unsigned char *nsec, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + CRYPTO_ALIGN(16) unsigned char j[16]; + size_t gh_required_blocks; + const size_t ad_len = (size_t) ad_len_; + const size_t m_len = (size_t) m_len_; + + (void) nsec; + if (maclen_p != NULL) { + *maclen_p = 0; + } + if (ad_len_ > SODIUM_SIZE_MAX || m_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + gh_required_blocks = required_blocks(ad_len, m_len); + if (gh_required_blocks == 0) { + memset(mac, 0xd0, ABYTES); + memset(c, 0, m_len); + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + aes_gcm_encrypt_generic(st, &sth, mac, c, m, m_len, ad, ad_len, j); + + if (maclen_p != NULL) { + *maclen_p = ABYTES; + } + return 0; +} + +int +crypto_aead_aes256gcm_encrypt(unsigned char *c, unsigned long long *clen_p, const unsigned char *m, + unsigned long long m_len, const unsigned char *ad, + unsigned long long ad_len, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + const int ret = crypto_aead_aes256gcm_encrypt_detached(c, c + m_len, NULL, m, m_len, ad, ad_len, + nsec, npub, k); + if (clen_p != NULL) { + if (ret == 0) { + *clen_p = m_len + crypto_aead_aes256gcm_ABYTES; + } else { + *clen_p = 0; + } + } + return ret; +} + +int +crypto_aead_aes256gcm_encrypt_detached(unsigned char *c, unsigned char *mac, + unsigned long long *maclen_p, const unsigned char *m, + unsigned long long m_len, const unsigned char *ad, + unsigned long long ad_len, const unsigned char *nsec, + const unsigned char *npub, const unsigned char *k) +{ + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; + int ret; + + PREFETCH_WRITE(c); + PREFETCH_READ(m); + PREFETCH_READ(ad); + + crypto_aead_aes256gcm_beforenm(&st, k); + ret = crypto_aead_aes256gcm_encrypt_detached_afternm(c, mac, maclen_p, m, m_len, ad, ad_len, + nsec, npub, &st); + sodium_memzero(&st, sizeof st); + + return ret; +} + +int +crypto_aead_aes256gcm_encrypt_afternm(unsigned char *c, unsigned long long *clen_p, + const unsigned char *m, unsigned long long mlen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *nsec, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + int ret = crypto_aead_aes256gcm_encrypt_detached_afternm(c, c + mlen, NULL, m, mlen, ad, adlen, + nsec, npub, st_); + if (clen_p != NULL) { + *clen_p = mlen + crypto_aead_aes256gcm_ABYTES; + } + return ret; +} + +static int +crypto_aead_aes256gcm_verify_mac(unsigned char *nsec, const unsigned char *c, + unsigned long long c_len_, const unsigned char *mac, + const unsigned char *ad, unsigned long long ad_len_, + const unsigned char *npub, const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + BlockVec final_block; + CRYPTO_ALIGN(16) unsigned char j[16]; + CRYPTO_ALIGN(16) unsigned char computed_mac[16]; + CRYPTO_ALIGN(16) unsigned char last_block[16]; + size_t gh_required_blocks; + size_t left; + const size_t ad_len = (size_t) ad_len_; + const size_t c_len = (size_t) c_len_; + int ret; + + (void) nsec; + if (ad_len_ > SODIUM_SIZE_MAX || c_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + gh_required_blocks = required_blocks(ad_len, c_len); + if (gh_required_blocks == 0) { + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + gh_ad_blocks(st, &sth, ad, ad_len & ~15); + left = ad_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, ad + ad_len - left, left); + gh_ad_blocks(st, &sth, pad, sizeof pad); + } + + gh_ad_blocks(st, &sth, c, c_len & ~15); + left = c_len & 15; + if (left != 0) { + unsigned char pad[16]; + + memset(pad, 0, sizeof pad); + memcpy(pad, c + c_len - left, left); + gh_ad_blocks(st, &sth, pad, sizeof pad); + } + final_block = REV128(SET64x2(ad_len * 8, c_len * 8)); + STORE32_BE(j + NPUBBYTES, 1); + encrypt(st, computed_mac, j); + STORE128(last_block, final_block); + gh_ad_blocks(st, &sth, last_block, 16); + STORE128(computed_mac, XOR128(LOAD128(computed_mac), REV128(sth.acc))); + + ret = crypto_verify_16(mac, computed_mac); + sodium_memzero(computed_mac, sizeof computed_mac); + + return ret; +} + +int +crypto_aead_aes256gcm_decrypt_detached_afternm(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long c_len_, + const unsigned char *mac, const unsigned char *ad, + unsigned long long ad_len_, + const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + const State *st = (const State *) (const void *) st_; + GHash sth; + CRYPTO_ALIGN(16) unsigned char j[16]; + unsigned char computed_mac[16]; + size_t gh_required_blocks; + const size_t ad_len = (size_t) ad_len_; + const size_t c_len = (size_t) c_len_; + const size_t m_len = c_len; + + (void) nsec; + if (ad_len_ > SODIUM_SIZE_MAX || c_len_ > SODIUM_SIZE_MAX) { + sodium_misuse(); + } + if (m == NULL) { + return crypto_aead_aes256gcm_verify_mac(nsec, c, c_len, mac, ad, ad_len, npub, st_); + } + gh_required_blocks = required_blocks(ad_len, m_len); + if (gh_required_blocks == 0) { + return -1; + } + + gh_init(&sth); + + memcpy(j, npub, NPUBBYTES); + STORE32_BE(j + NPUBBYTES, 2); + + aes_gcm_decrypt_generic(st, &sth, computed_mac, m, c, m_len, ad, ad_len, j); + + if (crypto_verify_16(mac, computed_mac) != 0) { + sodium_memzero(computed_mac, sizeof computed_mac); + memset(m, 0xd0, m_len); + return -1; + } + return 0; +} + +int +crypto_aead_aes256gcm_decrypt_afternm(unsigned char *m, unsigned long long *mlen_p, + unsigned char *nsec, const unsigned char *c, + unsigned long long clen, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const crypto_aead_aes256gcm_state *st_) +{ + unsigned long long mlen = 0ULL; + int ret = -1; + + if (clen >= ABYTES) { + ret = crypto_aead_aes256gcm_decrypt_detached_afternm( + m, nsec, c, clen - ABYTES, c + clen - ABYTES, ad, adlen, npub, st_); + } + if (mlen_p != NULL) { + if (ret == 0) { + mlen = clen - ABYTES; + } + *mlen_p = mlen; + } + return ret; +} + +int +crypto_aead_aes256gcm_decrypt_detached(unsigned char *m, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *mac, const unsigned char *ad, + unsigned long long adlen, const unsigned char *npub, + const unsigned char *k) +{ + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; + + PREFETCH_WRITE(m); + PREFETCH_READ(c); + PREFETCH_READ(ad); + + crypto_aead_aes256gcm_beforenm(&st, k); + + return crypto_aead_aes256gcm_decrypt_detached_afternm( + m, nsec, c, clen, mac, ad, adlen, npub, (const crypto_aead_aes256gcm_state *) &st); +} + +int +crypto_aead_aes256gcm_decrypt(unsigned char *m, unsigned long long *mlen_p, unsigned char *nsec, + const unsigned char *c, unsigned long long clen, + const unsigned char *ad, unsigned long long adlen, + const unsigned char *npub, const unsigned char *k) +{ + CRYPTO_ALIGN(16) crypto_aead_aes256gcm_state st; + int ret; + + PREFETCH_WRITE(m); + PREFETCH_READ(c); + PREFETCH_READ(ad); + + crypto_aead_aes256gcm_beforenm(&st, k); + + ret = crypto_aead_aes256gcm_decrypt_afternm(m, mlen_p, nsec, c, clen, ad, adlen, npub, + (const crypto_aead_aes256gcm_state *) &st); + sodium_memzero(&st, sizeof st); + + return ret; +} + +int +crypto_aead_aes256gcm_is_available(void) +{ + return sodium_runtime_has_armcrypto(); +} + +#ifdef __clang__ +#pragma clang attribute pop +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/chacha20poly1305/sodium/aead_chacha20poly1305.c b/subprojects/libsodium/src/libsodium/crypto_aead/chacha20poly1305/aead_chacha20poly1305.c diff --git a/subprojects/libsodium/src/libsodium/crypto_aead/xchacha20poly1305/sodium/aead_xchacha20poly1305.c b/subprojects/libsodium/src/libsodium/crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c diff --git a/subprojects/libsodium/src/libsodium/crypto_box/crypto_box_seal.c b/subprojects/libsodium/src/libsodium/crypto_box/crypto_box_seal.c @@ -32,10 +32,10 @@ crypto_box_seal(unsigned char *c, const unsigned char *m, if (crypto_box_keypair(epk, esk) != 0) { return -1; /* LCOV_EXCL_LINE */ } - memcpy(c, epk, crypto_box_PUBLICKEYBYTES); _crypto_box_seal_nonce(nonce, epk, pk); ret = crypto_box_easy(c + crypto_box_PUBLICKEYBYTES, m, mlen, nonce, pk, esk); + memcpy(c, epk, crypto_box_PUBLICKEYBYTES); sodium_memzero(esk, sizeof esk); sodium_memzero(epk, sizeof epk); sodium_memzero(nonce, sizeof nonce); diff --git a/subprojects/libsodium/src/libsodium/crypto_box/curve25519xchacha20poly1305/box_seal_curve25519xchacha20poly1305.c b/subprojects/libsodium/src/libsodium/crypto_box/curve25519xchacha20poly1305/box_seal_curve25519xchacha20poly1305.c @@ -38,11 +38,11 @@ crypto_box_curve25519xchacha20poly1305_seal(unsigned char *c, const unsigned cha if (crypto_box_curve25519xchacha20poly1305_keypair(epk, esk) != 0) { return -1; /* LCOV_EXCL_LINE */ } - memcpy(c, epk, crypto_box_curve25519xchacha20poly1305_PUBLICKEYBYTES); _crypto_box_curve25519xchacha20poly1305_seal_nonce(nonce, epk, pk); ret = crypto_box_curve25519xchacha20poly1305_easy( c + crypto_box_curve25519xchacha20poly1305_PUBLICKEYBYTES, m, mlen, nonce, pk, esk); + memcpy(c, epk, crypto_box_curve25519xchacha20poly1305_PUBLICKEYBYTES); sodium_memzero(esk, sizeof esk); sodium_memzero(epk, sizeof epk); sodium_memzero(nonce, sizeof nonce); diff --git a/subprojects/libsodium/src/libsodium/crypto_core/ed25519/core_ed25519.c b/subprojects/libsodium/src/libsodium/crypto_core/ed25519/core_ed25519.c @@ -81,10 +81,10 @@ crypto_core_ed25519_from_hash(unsigned char *p, const unsigned char *h) void crypto_core_ed25519_random(unsigned char *p) { - unsigned char h[crypto_core_ed25519_HASHBYTES]; + unsigned char h[crypto_core_ed25519_UNIFORMBYTES]; randombytes_buf(h, sizeof h); - (void) crypto_core_ed25519_from_hash(p, h); + (void) crypto_core_ed25519_from_uniform(p, h); } void diff --git a/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/ed25519_ref10.c b/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/ed25519_ref10.c @@ -81,8 +81,7 @@ fe25519_invert(fe25519 out, const fe25519 z) fe25519_sq(t3, t3); } fe25519_mul(t2, t3, t2); - fe25519_sq(t2, t2); - for (i = 1; i < 10; ++i) { + for (i = 1; i < 11; ++i) { fe25519_sq(t2, t2); } fe25519_mul(t1, t2, t1); @@ -96,13 +95,11 @@ fe25519_invert(fe25519 out, const fe25519 z) fe25519_sq(t3, t3); } fe25519_mul(t2, t3, t2); - fe25519_sq(t2, t2); - for (i = 1; i < 50; ++i) { + for (i = 1; i < 51; ++i) { fe25519_sq(t2, t2); } fe25519_mul(t1, t2, t1); - fe25519_sq(t1, t1); - for (i = 1; i < 5; ++i) { + for (i = 1; i < 6; ++i) { fe25519_sq(t1, t1); } fe25519_mul(out, t1, t0); @@ -138,8 +135,7 @@ fe25519_pow22523(fe25519 out, const fe25519 z) fe25519_sq(t2, t2); } fe25519_mul(t1, t2, t1); - fe25519_sq(t1, t1); - for (i = 1; i < 10; ++i) { + for (i = 1; i < 11; ++i) { fe25519_sq(t1, t1); } fe25519_mul(t0, t1, t0); @@ -153,8 +149,7 @@ fe25519_pow22523(fe25519 out, const fe25519 z) fe25519_sq(t2, t2); } fe25519_mul(t1, t2, t1); - fe25519_sq(t1, t1); - for (i = 1; i < 50; ++i) { + for (i = 1; i < 51; ++i) { fe25519_sq(t1, t1); } fe25519_mul(t0, t1, t0); @@ -179,6 +174,55 @@ fe25519_abs(fe25519 h, const fe25519 f) fe25519_cneg(h, f, fe25519_isnegative(f)); } +static inline void +fe25519_sqmul(fe25519 s, const int n, const fe25519 a) +{ + int i; + + for (i = 0; i < n; i++) { + fe25519_sq(s, s); + } + fe25519_mul(s, s, a); +} + +static unsigned int +fe25519_notsquare(const fe25519 x) +{ + fe25519 _10, _11, _1100, _1111, _11110000, _11111111; + fe25519 t, u, v; + unsigned char s[32]; + + /* Jacobi symbol - x^((p-1)/2) */ + fe25519_mul(_10, x, x); + fe25519_mul(_11, x, _10); + fe25519_sq(_1100, _11); + fe25519_sq(_1100, _1100); + fe25519_mul(_1111, _11, _1100); + fe25519_sq(_11110000, _1111); + fe25519_sq(_11110000, _11110000); + fe25519_sq(_11110000, _11110000); + fe25519_sq(_11110000, _11110000); + fe25519_mul(_11111111, _1111, _11110000); + fe25519_copy(t, _11111111); + fe25519_sqmul(t, 2, _11); + fe25519_copy(u, t); + fe25519_sqmul(t, 10, u); + fe25519_sqmul(t, 10, u); + fe25519_copy(v, t); + fe25519_sqmul(t, 30, v); + fe25519_copy(v, t); + fe25519_sqmul(t, 60, v); + fe25519_copy(v, t); + fe25519_sqmul(t, 120, v); + fe25519_sqmul(t, 10, u); + fe25519_sqmul(t, 3, _11); + fe25519_sq(t, t); + + fe25519_tobytes(s, t); + + return s[1] & 1; +} + /* r = p + q */ @@ -244,12 +288,13 @@ slide_vartime(signed char *r, const unsigned char *a) } } +static volatile unsigned char optblocker_u8; + int ge25519_frombytes(ge25519_p3 *h, const unsigned char *s) { fe25519 u; fe25519 v; - fe25519 v3; fe25519 vxx; fe25519 m_root_check, p_root_check; fe25519 negx; @@ -263,15 +308,9 @@ ge25519_frombytes(ge25519_p3 *h, const unsigned char *s) fe25519_sub(u, u, h->Z); /* u = y^2-1 */ fe25519_add(v, v, h->Z); /* v = dy^2+1 */ - fe25519_sq(v3, v); - fe25519_mul(v3, v3, v); /* v3 = v^3 */ - fe25519_sq(h->X, v3); - fe25519_mul(h->X, h->X, v); - fe25519_mul(h->X, h->X, u); /* x = uv^7 */ - - fe25519_pow22523(h->X, h->X); /* x = (uv^7)^((q-5)/8) */ - fe25519_mul(h->X, h->X, v3); - fe25519_mul(h->X, h->X, u); /* x = uv^3(uv^7)^((q-5)/8) */ + fe25519_mul(h->X, u, v); + fe25519_pow22523(h->X, h->X); + fe25519_mul(h->X, u, h->X); /* u((uv)^((q-5)/8)) */ fe25519_sq(vxx, h->X); fe25519_mul(vxx, vxx, v); @@ -283,7 +322,7 @@ ge25519_frombytes(ge25519_p3 *h, const unsigned char *s) fe25519_cmov(h->X, x_sqrtm1, 1 - has_m_root); fe25519_neg(negx, h->X); - fe25519_cmov(h->X, negx, fe25519_isnegative(h->X) ^ (s[31] >> 7)); + fe25519_cmov(h->X, negx, fe25519_isnegative(h->X) ^ (((s[31] >> 5) ^ optblocker_u8) >> 2)); fe25519_mul(h->T, h->X, h->Y); return (has_m_root | has_p_root) - 1; @@ -526,26 +565,39 @@ ge25519_precomp_0(ge25519_precomp *h) static unsigned char equal(signed char b, signed char c) { - unsigned char ub = b; - unsigned char uc = c; - unsigned char x = ub ^ uc; /* 0: yes; 1..255: no */ - uint32_t y = (uint32_t) x; /* 0: yes; 1..255: no */ - - y -= 1; /* 4294967295: yes; 0..254: no */ - y >>= 31; /* 1: yes; 0: no */ +#if defined(HAVE_INLINE_ASM) && defined(__x86_64__) + int32_t b32 = (int32_t) b, c32 = (int32_t) c, q32, z32; + __asm__ ("xorl %0,%0\n movl $1,%1\n cmpb %b3,%b2\n cmovel %1,%0" : + "=&r"(z32), "=&r"(q32) : "q"(b32), "q"(c32) : "cc"); + return (unsigned char) z32; +#elif defined(HAVE_INLINE_ASM) && defined(__aarch64__) + unsigned char z; + __asm__ ("and %w0,%w1,255\n cmp %w0,%w2,uxtb\n cset %w0,eq" : + "=&r"(z) : "r"(b), "r"(c) : "cc"); + return z; +#else + const unsigned char x = (unsigned char) b ^ (unsigned char) c; /* 0: yes; 1..255: no */ + uint32_t y = (uint32_t) x; /* 0: yes; 1..255: no */ - return y; + y--; + return ((y >> 29) ^ optblocker_u8) >> 2; /* 1: yes; 0: no */ +#endif } static unsigned char negative(signed char b) { - /* 18446744073709551361..18446744073709551615: yes; 0..255: no */ - uint64_t x = b; - - x >>= 63; /* 1: yes; 0: no */ - +#if defined(HAVE_INLINE_ASM) && defined(__x86_64__) + __asm__ ("shrb $7,%0" : "+r"(b) : : "cc"); + return b; +#elif defined(HAVE_INLINE_ASM) && defined(__aarch64__) + uint8_t x; + __asm__ ("ubfx %w0,%w1,7,1" : "=r"(x) : "r"(b) : ); return x; +#else + const uint8_t x = (uint8_t) b; /* 0..127: no 128..255: yes */ + return ((x >> 5) ^ optblocker_u8) >> 2; /* 1: yes; 0: no */ +#endif } static void @@ -2071,46 +2123,52 @@ sc25519_sqmul(unsigned char s[32], const int n, const unsigned char a[32]) void sc25519_invert(unsigned char recip[32], const unsigned char s[32]) { - unsigned char _10[32], _100[32], _11[32], _101[32], _111[32], - _1001[32], _1011[32], _1111[32]; + unsigned char _10[32], _100[32], _1000[32], _10000[32], _100000[32], + _1000000[32], _10010011[32], _10010111[32], _100110[32], _1010[32], + _1010000[32], _1010011[32], _1011[32], _10110[32], _10111101[32], + _11[32], _1100011[32], _1100111[32], _11010011[32], _1101011[32], + _11100111[32], _11101011[32], _11110101[32]; sc25519_sq(_10, s); - sc25519_sq(_100, _10); - sc25519_mul(_11, _10, s); - sc25519_mul(_101, _10, _11); - sc25519_mul(_111, _10, _101); - sc25519_mul(_1001, _10, _111); - sc25519_mul(_1011, _10, _1001); - sc25519_mul(_1111, _100, _1011); - sc25519_mul(recip, _1111, s); - - sc25519_sqmul(recip, 123 + 3, _101); - sc25519_sqmul(recip, 2 + 2, _11); - sc25519_sqmul(recip, 1 + 4, _1111); - sc25519_sqmul(recip, 1 + 4, _1111); - sc25519_sqmul(recip, 4, _1001); - sc25519_sqmul(recip, 2, _11); - sc25519_sqmul(recip, 1 + 4, _1111); - sc25519_sqmul(recip, 1 + 3, _101); - sc25519_sqmul(recip, 3 + 3, _101); - sc25519_sqmul(recip, 3, _111); - sc25519_sqmul(recip, 1 + 4, _1111); - sc25519_sqmul(recip, 2 + 3, _111); - sc25519_sqmul(recip, 2 + 2, _11); - sc25519_sqmul(recip, 1 + 4, _1011); - sc25519_sqmul(recip, 2 + 4, _1011); - sc25519_sqmul(recip, 6 + 4, _1001); - sc25519_sqmul(recip, 2 + 2, _11); - sc25519_sqmul(recip, 3 + 2, _11); - sc25519_sqmul(recip, 3 + 2, _11); - sc25519_sqmul(recip, 1 + 4, _1001); - sc25519_sqmul(recip, 1 + 3, _111); - sc25519_sqmul(recip, 2 + 4, _1111); - sc25519_sqmul(recip, 1 + 4, _1011); - sc25519_sqmul(recip, 3, _101); - sc25519_sqmul(recip, 2 + 4, _1111); - sc25519_sqmul(recip, 3, _101); - sc25519_sqmul(recip, 1 + 2, _11); + sc25519_mul(_11, s, _10); + sc25519_mul(_100, s, _11); + sc25519_sq(_1000, _100); + sc25519_mul(_1010, _10, _1000); + sc25519_mul(_1011, s, _1010); + sc25519_sq(_10000, _1000); + sc25519_sq(_10110, _1011); + sc25519_mul(_100000, _1010, _10110); + sc25519_mul(_100110, _10000, _10110); + sc25519_sq(_1000000, _100000); + sc25519_mul(_1010000, _10000, _1000000); + sc25519_mul(_1010011, _11, _1010000); + sc25519_mul(_1100011, _10000, _1010011); + sc25519_mul(_1100111, _100, _1100011); + sc25519_mul(_1101011, _100, _1100111); + sc25519_mul(_10010011, _1000000, _1010011); + sc25519_mul(_10010111, _100, _10010011); + sc25519_mul(_10111101, _100110, _10010111); + sc25519_mul(_11010011, _10110, _10111101); + sc25519_mul(_11100111, _1010000, _10010111); + sc25519_mul(_11101011, _100, _11100111); + sc25519_mul(_11110101, _1010, _11101011); + + sc25519_mul(recip, _1011, _11110101); + sc25519_sqmul(recip, 126, _1010011); + sc25519_sqmul(recip, 9, _10); + sc25519_mul(recip, recip, _11110101); + sc25519_sqmul(recip, 7, _1100111); + sc25519_sqmul(recip, 9, _11110101); + sc25519_sqmul(recip, 11, _10111101); + sc25519_sqmul(recip, 8, _11100111); + sc25519_sqmul(recip, 9, _1101011); + sc25519_sqmul(recip, 6, _1011); + sc25519_sqmul(recip, 14, _10010011); + sc25519_sqmul(recip, 10, _1100011); + sc25519_sqmul(recip, 9, _10010111); + sc25519_sqmul(recip, 10, _11110101); + sc25519_sqmul(recip, 8, _11010011); + sc25519_sqmul(recip, 8, _11101011); } /* @@ -2469,94 +2527,48 @@ sc25519_is_canonical(const unsigned char s[32]) return (c != 0); } +/* multiply by the cofactor */ static void -chi25519(fe25519 out, const fe25519 z) +ge25519_clear_cofactor(ge25519_p3 *p3) { - fe25519 t0, t1, t2, t3; - int i; - - fe25519_sq(t0, z); - fe25519_mul(t1, t0, z); - fe25519_sq(t0, t1); - fe25519_sq(t2, t0); - fe25519_sq(t2, t2); - fe25519_mul(t2, t2, t0); - fe25519_mul(t1, t2, z); - fe25519_sq(t2, t1); + ge25519_p1p1 p1; + ge25519_p2 p2; - for (i = 1; i < 5; i++) { - fe25519_sq(t2, t2); - } - fe25519_mul(t1, t2, t1); - fe25519_sq(t2, t1); - for (i = 1; i < 10; i++) { - fe25519_sq(t2, t2); - } - fe25519_mul(t2, t2, t1); - fe25519_sq(t3, t2); - for (i = 1; i < 20; i++) { - fe25519_sq(t3, t3); - } - fe25519_mul(t2, t3, t2); - fe25519_sq(t2, t2); - for (i = 1; i < 10; i++) { - fe25519_sq(t2, t2); - } - fe25519_mul(t1, t2, t1); - fe25519_sq(t2, t1); - for (i = 1; i < 50; i++) { - fe25519_sq(t2, t2); - } - fe25519_mul(t2, t2, t1); - fe25519_sq(t3, t2); - for (i = 1; i < 100; i++) { - fe25519_sq(t3, t3); - } - fe25519_mul(t2, t3, t2); - fe25519_sq(t2, t2); - for (i = 1; i < 50; i++) { - fe25519_sq(t2, t2); - } - fe25519_mul(t1, t2, t1); - fe25519_sq(t1, t1); - for (i = 1; i < 4; i++) { - fe25519_sq(t1, t1); - } - fe25519_mul(out, t1, t0); + ge25519_p3_dbl(&p1, p3); + ge25519_p1p1_to_p2(&p2, &p1); + ge25519_p2_dbl(&p1, &p2); + ge25519_p1p1_to_p2(&p2, &p1); + ge25519_p2_dbl(&p1, &p2); + ge25519_p1p1_to_p3(p3, &p1); } static void ge25519_elligator2(unsigned char s[32], const fe25519 r, const unsigned char x_sign) { - fe25519 e; + fe25519 gx; fe25519 negx; fe25519 rr2; fe25519 x, x2, x3; ge25519_p3 p3; - ge25519_p1p1 p1; - ge25519_p2 p2; - unsigned int e_is_minus_1; + unsigned int notsquare; fe25519_sq2(rr2, r); rr2[0]++; fe25519_invert(rr2, rr2); - fe25519_mul(x, curve25519_A, rr2); + fe25519_mul32(x, rr2, curve25519_A[0]); fe25519_neg(x, x); fe25519_sq(x2, x); fe25519_mul(x3, x, x2); - fe25519_add(e, x3, x); - fe25519_mul(x2, x2, curve25519_A); - fe25519_add(e, x2, e); - - chi25519(e, e); + fe25519_add(gx, x3, x); + fe25519_mul32(x2, x2, curve25519_A[0]); + fe25519_add(gx, x2, gx); - fe25519_tobytes(s, e); - e_is_minus_1 = s[1] & 1; + notsquare = fe25519_notsquare(gx); fe25519_neg(negx, x); - fe25519_cmov(x, negx, e_is_minus_1); + fe25519_cmov(x, negx, notsquare); fe25519_0(x2); - fe25519_cmov(x2, curve25519_A, e_is_minus_1); + fe25519_cmov(x2, curve25519_A, notsquare); fe25519_sub(x, x, x2); /* yed = (x-1)/(x+1) */ @@ -2581,14 +2593,7 @@ ge25519_elligator2(unsigned char s[32], const fe25519 r, const unsigned char x_s abort(); /* LCOV_EXCL_LINE */ } - /* multiply by the cofactor */ - ge25519_p3_dbl(&p1, &p3); - ge25519_p1p1_to_p2(&p2, &p1); - ge25519_p2_dbl(&p1, &p2); - ge25519_p1p1_to_p2(&p2, &p1); - ge25519_p2_dbl(&p1, &p2); - ge25519_p1p1_to_p3(&p3, &p1); - + ge25519_clear_cofactor(&p3); ge25519_p3_tobytes(s, &p3); } @@ -2675,6 +2680,7 @@ ristretto255_is_canonical(const unsigned char *s) { unsigned char c; unsigned char d; + unsigned char e; unsigned int i; c = (s[31] & 0x7f) ^ 0x7f; @@ -2683,8 +2689,9 @@ ristretto255_is_canonical(const unsigned char *s) } c = (((unsigned int) c) - 1U) >> 8; d = (0xed - 1U - (unsigned int) s[0]) >> 8; + e = s[31] >> 7; - return 1 - (((c & d) | s[0]) & 1); + return 1 - (((c & d) | e | s[0]) & 1); } int @@ -2773,7 +2780,7 @@ ristretto255_p3_tobytes(unsigned char *s, const ge25519_p3 *h) fe25519_mul(ix, h->X, sqrtm1); /* ix = X*sqrt(-1) */ fe25519_mul(iy, h->Y, sqrtm1); /* iy = Y*sqrt(-1) */ - fe25519_mul(eden, den1, invsqrtamd); /* eden = den1*sqrt(a-d) */ + fe25519_mul(eden, den1, invsqrtamd); /* eden = den1/sqrt(a-d) */ fe25519_mul(t_z_inv, h->T, z_inv); /* t_z_inv = T*z_inv */ rotate = fe25519_isnegative(t_z_inv); @@ -2816,7 +2823,7 @@ ristretto255_elligator(ge25519_p3 *p, const fe25519 t) fe25519_mul(u, u, onemsqd); /* u = (r+1)*(1-d^2) */ fe25519_1(c); fe25519_neg(c, c); /* c = -1 */ - fe25519_add(rpd, r, d); /* rpd = r*d */ + fe25519_add(rpd, r, d); /* rpd = r+d */ fe25519_mul(v, r, d); /* v = r*d */ fe25519_sub(v, c, v); /* v = c-r*d */ fe25519_mul(v, v, rpd); /* v = (c-r*d)*(r+d) */ diff --git a/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/fe.h b/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/fe.h @@ -1,5 +1,5 @@ /* - Ignores top bit of h. + Ignores top bit of s. */ void diff --git a/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/fe_51/fe.h b/subprojects/libsodium/src/libsodium/crypto_core/ed25519/ref10/fe_51/fe.h @@ -1,5 +1,5 @@ /* - Ignores top bit of h. + Ignores top bit of s. */ void diff --git a/subprojects/libsodium/src/libsodium/crypto_core/softaes/softaes.c b/subprojects/libsodium/src/libsodium/crypto_core/softaes/softaes.c @@ -0,0 +1,340 @@ +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> +#include <string.h> + +#include "private/common.h" +#include "private/softaes.h" + +#if defined(__wasm__) && !defined(FAVOR_PERFORMANCE) +# define FAVOR_PERFORMANCE +#endif + +#ifndef SOFTAES_STRIDE +# define SOFTAES_STRIDE 16 +#endif + +#ifdef FAVOR_PERFORMANCE +static const uint32_t _aes_lut[1024] = { + 0xa56363c6, 0x847c7cf8, 0x997777ee, 0x8d7b7bf6, 0x0df2f2ff, 0xbd6b6bd6, 0xb16f6fde, 0x54c5c591, + 0x50303060, 0x03010102, 0xa96767ce, 0x7d2b2b56, 0x19fefee7, 0x62d7d7b5, 0xe6abab4d, 0x9a7676ec, + 0x45caca8f, 0x9d82821f, 0x40c9c989, 0x877d7dfa, 0x15fafaef, 0xeb5959b2, 0xc947478e, 0x0bf0f0fb, + 0xecadad41, 0x67d4d4b3, 0xfda2a25f, 0xeaafaf45, 0xbf9c9c23, 0xf7a4a453, 0x967272e4, 0x5bc0c09b, + 0xc2b7b775, 0x1cfdfde1, 0xae93933d, 0x6a26264c, 0x5a36366c, 0x413f3f7e, 0x02f7f7f5, 0x4fcccc83, + 0x5c343468, 0xf4a5a551, 0x34e5e5d1, 0x08f1f1f9, 0x937171e2, 0x73d8d8ab, 0x53313162, 0x3f15152a, + 0x0c040408, 0x52c7c795, 0x65232346, 0x5ec3c39d, 0x28181830, 0xa1969637, 0x0f05050a, 0xb59a9a2f, + 0x0907070e, 0x36121224, 0x9b80801b, 0x3de2e2df, 0x26ebebcd, 0x6927274e, 0xcdb2b27f, 0x9f7575ea, + 0x1b090912, 0x9e83831d, 0x742c2c58, 0x2e1a1a34, 0x2d1b1b36, 0xb26e6edc, 0xee5a5ab4, 0xfba0a05b, + 0xf65252a4, 0x4d3b3b76, 0x61d6d6b7, 0xceb3b37d, 0x7b292952, 0x3ee3e3dd, 0x712f2f5e, 0x97848413, + 0xf55353a6, 0x68d1d1b9, 0x00000000, 0x2cededc1, 0x60202040, 0x1ffcfce3, 0xc8b1b179, 0xed5b5bb6, + 0xbe6a6ad4, 0x46cbcb8d, 0xd9bebe67, 0x4b393972, 0xde4a4a94, 0xd44c4c98, 0xe85858b0, 0x4acfcf85, + 0x6bd0d0bb, 0x2aefefc5, 0xe5aaaa4f, 0x16fbfbed, 0xc5434386, 0xd74d4d9a, 0x55333366, 0x94858511, + 0xcf45458a, 0x10f9f9e9, 0x06020204, 0x817f7ffe, 0xf05050a0, 0x443c3c78, 0xba9f9f25, 0xe3a8a84b, + 0xf35151a2, 0xfea3a35d, 0xc0404080, 0x8a8f8f05, 0xad92923f, 0xbc9d9d21, 0x48383870, 0x04f5f5f1, + 0xdfbcbc63, 0xc1b6b677, 0x75dadaaf, 0x63212142, 0x30101020, 0x1affffe5, 0x0ef3f3fd, 0x6dd2d2bf, + 0x4ccdcd81, 0x140c0c18, 0x35131326, 0x2fececc3, 0xe15f5fbe, 0xa2979735, 0xcc444488, 0x3917172e, + 0x57c4c493, 0xf2a7a755, 0x827e7efc, 0x473d3d7a, 0xac6464c8, 0xe75d5dba, 0x2b191932, 0x957373e6, + 0xa06060c0, 0x98818119, 0xd14f4f9e, 0x7fdcdca3, 0x66222244, 0x7e2a2a54, 0xab90903b, 0x8388880b, + 0xca46468c, 0x29eeeec7, 0xd3b8b86b, 0x3c141428, 0x79dedea7, 0xe25e5ebc, 0x1d0b0b16, 0x76dbdbad, + 0x3be0e0db, 0x56323264, 0x4e3a3a74, 0x1e0a0a14, 0xdb494992, 0x0a06060c, 0x6c242448, 0xe45c5cb8, + 0x5dc2c29f, 0x6ed3d3bd, 0xefacac43, 0xa66262c4, 0xa8919139, 0xa4959531, 0x37e4e4d3, 0x8b7979f2, + 0x32e7e7d5, 0x43c8c88b, 0x5937376e, 0xb76d6dda, 0x8c8d8d01, 0x64d5d5b1, 0xd24e4e9c, 0xe0a9a949, + 0xb46c6cd8, 0xfa5656ac, 0x07f4f4f3, 0x25eaeacf, 0xaf6565ca, 0x8e7a7af4, 0xe9aeae47, 0x18080810, + 0xd5baba6f, 0x887878f0, 0x6f25254a, 0x722e2e5c, 0x241c1c38, 0xf1a6a657, 0xc7b4b473, 0x51c6c697, + 0x23e8e8cb, 0x7cdddda1, 0x9c7474e8, 0x211f1f3e, 0xdd4b4b96, 0xdcbdbd61, 0x868b8b0d, 0x858a8a0f, + 0x907070e0, 0x423e3e7c, 0xc4b5b571, 0xaa6666cc, 0xd8484890, 0x05030306, 0x01f6f6f7, 0x120e0e1c, + 0xa36161c2, 0x5f35356a, 0xf95757ae, 0xd0b9b969, 0x91868617, 0x58c1c199, 0x271d1d3a, 0xb99e9e27, + 0x38e1e1d9, 0x13f8f8eb, 0xb398982b, 0x33111122, 0xbb6969d2, 0x70d9d9a9, 0x898e8e07, 0xa7949433, + 0xb69b9b2d, 0x221e1e3c, 0x92878715, 0x20e9e9c9, 0x49cece87, 0xff5555aa, 0x78282850, 0x7adfdfa5, + 0x8f8c8c03, 0xf8a1a159, 0x80898909, 0x170d0d1a, 0xdabfbf65, 0x31e6e6d7, 0xc6424284, 0xb86868d0, + 0xc3414182, 0xb0999929, 0x772d2d5a, 0x110f0f1e, 0xcbb0b07b, 0xfc5454a8, 0xd6bbbb6d, 0x3a16162c, + 0x6363c6a5, 0x7c7cf884, 0x7777ee99, 0x7b7bf68d, 0xf2f2ff0d, 0x6b6bd6bd, 0x6f6fdeb1, 0xc5c59154, + 0x30306050, 0x01010203, 0x6767cea9, 0x2b2b567d, 0xfefee719, 0xd7d7b562, 0xabab4de6, 0x7676ec9a, + 0xcaca8f45, 0x82821f9d, 0xc9c98940, 0x7d7dfa87, 0xfafaef15, 0x5959b2eb, 0x47478ec9, 0xf0f0fb0b, + 0xadad41ec, 0xd4d4b367, 0xa2a25ffd, 0xafaf45ea, 0x9c9c23bf, 0xa4a453f7, 0x7272e496, 0xc0c09b5b, + 0xb7b775c2, 0xfdfde11c, 0x93933dae, 0x26264c6a, 0x36366c5a, 0x3f3f7e41, 0xf7f7f502, 0xcccc834f, + 0x3434685c, 0xa5a551f4, 0xe5e5d134, 0xf1f1f908, 0x7171e293, 0xd8d8ab73, 0x31316253, 0x15152a3f, + 0x0404080c, 0xc7c79552, 0x23234665, 0xc3c39d5e, 0x18183028, 0x969637a1, 0x05050a0f, 0x9a9a2fb5, + 0x07070e09, 0x12122436, 0x80801b9b, 0xe2e2df3d, 0xebebcd26, 0x27274e69, 0xb2b27fcd, 0x7575ea9f, + 0x0909121b, 0x83831d9e, 0x2c2c5874, 0x1a1a342e, 0x1b1b362d, 0x6e6edcb2, 0x5a5ab4ee, 0xa0a05bfb, + 0x5252a4f6, 0x3b3b764d, 0xd6d6b761, 0xb3b37dce, 0x2929527b, 0xe3e3dd3e, 0x2f2f5e71, 0x84841397, + 0x5353a6f5, 0xd1d1b968, 0x00000000, 0xededc12c, 0x20204060, 0xfcfce31f, 0xb1b179c8, 0x5b5bb6ed, + 0x6a6ad4be, 0xcbcb8d46, 0xbebe67d9, 0x3939724b, 0x4a4a94de, 0x4c4c98d4, 0x5858b0e8, 0xcfcf854a, + 0xd0d0bb6b, 0xefefc52a, 0xaaaa4fe5, 0xfbfbed16, 0x434386c5, 0x4d4d9ad7, 0x33336655, 0x85851194, + 0x45458acf, 0xf9f9e910, 0x02020406, 0x7f7ffe81, 0x5050a0f0, 0x3c3c7844, 0x9f9f25ba, 0xa8a84be3, + 0x5151a2f3, 0xa3a35dfe, 0x404080c0, 0x8f8f058a, 0x92923fad, 0x9d9d21bc, 0x38387048, 0xf5f5f104, + 0xbcbc63df, 0xb6b677c1, 0xdadaaf75, 0x21214263, 0x10102030, 0xffffe51a, 0xf3f3fd0e, 0xd2d2bf6d, + 0xcdcd814c, 0x0c0c1814, 0x13132635, 0xececc32f, 0x5f5fbee1, 0x979735a2, 0x444488cc, 0x17172e39, + 0xc4c49357, 0xa7a755f2, 0x7e7efc82, 0x3d3d7a47, 0x6464c8ac, 0x5d5dbae7, 0x1919322b, 0x7373e695, + 0x6060c0a0, 0x81811998, 0x4f4f9ed1, 0xdcdca37f, 0x22224466, 0x2a2a547e, 0x90903bab, 0x88880b83, + 0x46468cca, 0xeeeec729, 0xb8b86bd3, 0x1414283c, 0xdedea779, 0x5e5ebce2, 0x0b0b161d, 0xdbdbad76, + 0xe0e0db3b, 0x32326456, 0x3a3a744e, 0x0a0a141e, 0x494992db, 0x06060c0a, 0x2424486c, 0x5c5cb8e4, + 0xc2c29f5d, 0xd3d3bd6e, 0xacac43ef, 0x6262c4a6, 0x919139a8, 0x959531a4, 0xe4e4d337, 0x7979f28b, + 0xe7e7d532, 0xc8c88b43, 0x37376e59, 0x6d6ddab7, 0x8d8d018c, 0xd5d5b164, 0x4e4e9cd2, 0xa9a949e0, + 0x6c6cd8b4, 0x5656acfa, 0xf4f4f307, 0xeaeacf25, 0x6565caaf, 0x7a7af48e, 0xaeae47e9, 0x08081018, + 0xbaba6fd5, 0x7878f088, 0x25254a6f, 0x2e2e5c72, 0x1c1c3824, 0xa6a657f1, 0xb4b473c7, 0xc6c69751, + 0xe8e8cb23, 0xdddda17c, 0x7474e89c, 0x1f1f3e21, 0x4b4b96dd, 0xbdbd61dc, 0x8b8b0d86, 0x8a8a0f85, + 0x7070e090, 0x3e3e7c42, 0xb5b571c4, 0x6666ccaa, 0x484890d8, 0x03030605, 0xf6f6f701, 0x0e0e1c12, + 0x6161c2a3, 0x35356a5f, 0x5757aef9, 0xb9b969d0, 0x86861791, 0xc1c19958, 0x1d1d3a27, 0x9e9e27b9, + 0xe1e1d938, 0xf8f8eb13, 0x98982bb3, 0x11112233, 0x6969d2bb, 0xd9d9a970, 0x8e8e0789, 0x949433a7, + 0x9b9b2db6, 0x1e1e3c22, 0x87871592, 0xe9e9c920, 0xcece8749, 0x5555aaff, 0x28285078, 0xdfdfa57a, + 0x8c8c038f, 0xa1a159f8, 0x89890980, 0x0d0d1a17, 0xbfbf65da, 0xe6e6d731, 0x424284c6, 0x6868d0b8, + 0x414182c3, 0x999929b0, 0x2d2d5a77, 0x0f0f1e11, 0xb0b07bcb, 0x5454a8fc, 0xbbbb6dd6, 0x16162c3a, + 0x63c6a563, 0x7cf8847c, 0x77ee9977, 0x7bf68d7b, 0xf2ff0df2, 0x6bd6bd6b, 0x6fdeb16f, 0xc59154c5, + 0x30605030, 0x01020301, 0x67cea967, 0x2b567d2b, 0xfee719fe, 0xd7b562d7, 0xab4de6ab, 0x76ec9a76, + 0xca8f45ca, 0x821f9d82, 0xc98940c9, 0x7dfa877d, 0xfaef15fa, 0x59b2eb59, 0x478ec947, 0xf0fb0bf0, + 0xad41ecad, 0xd4b367d4, 0xa25ffda2, 0xaf45eaaf, 0x9c23bf9c, 0xa453f7a4, 0x72e49672, 0xc09b5bc0, + 0xb775c2b7, 0xfde11cfd, 0x933dae93, 0x264c6a26, 0x366c5a36, 0x3f7e413f, 0xf7f502f7, 0xcc834fcc, + 0x34685c34, 0xa551f4a5, 0xe5d134e5, 0xf1f908f1, 0x71e29371, 0xd8ab73d8, 0x31625331, 0x152a3f15, + 0x04080c04, 0xc79552c7, 0x23466523, 0xc39d5ec3, 0x18302818, 0x9637a196, 0x050a0f05, 0x9a2fb59a, + 0x070e0907, 0x12243612, 0x801b9b80, 0xe2df3de2, 0xebcd26eb, 0x274e6927, 0xb27fcdb2, 0x75ea9f75, + 0x09121b09, 0x831d9e83, 0x2c58742c, 0x1a342e1a, 0x1b362d1b, 0x6edcb26e, 0x5ab4ee5a, 0xa05bfba0, + 0x52a4f652, 0x3b764d3b, 0xd6b761d6, 0xb37dceb3, 0x29527b29, 0xe3dd3ee3, 0x2f5e712f, 0x84139784, + 0x53a6f553, 0xd1b968d1, 0x00000000, 0xedc12ced, 0x20406020, 0xfce31ffc, 0xb179c8b1, 0x5bb6ed5b, + 0x6ad4be6a, 0xcb8d46cb, 0xbe67d9be, 0x39724b39, 0x4a94de4a, 0x4c98d44c, 0x58b0e858, 0xcf854acf, + 0xd0bb6bd0, 0xefc52aef, 0xaa4fe5aa, 0xfbed16fb, 0x4386c543, 0x4d9ad74d, 0x33665533, 0x85119485, + 0x458acf45, 0xf9e910f9, 0x02040602, 0x7ffe817f, 0x50a0f050, 0x3c78443c, 0x9f25ba9f, 0xa84be3a8, + 0x51a2f351, 0xa35dfea3, 0x4080c040, 0x8f058a8f, 0x923fad92, 0x9d21bc9d, 0x38704838, 0xf5f104f5, + 0xbc63dfbc, 0xb677c1b6, 0xdaaf75da, 0x21426321, 0x10203010, 0xffe51aff, 0xf3fd0ef3, 0xd2bf6dd2, + 0xcd814ccd, 0x0c18140c, 0x13263513, 0xecc32fec, 0x5fbee15f, 0x9735a297, 0x4488cc44, 0x172e3917, + 0xc49357c4, 0xa755f2a7, 0x7efc827e, 0x3d7a473d, 0x64c8ac64, 0x5dbae75d, 0x19322b19, 0x73e69573, + 0x60c0a060, 0x81199881, 0x4f9ed14f, 0xdca37fdc, 0x22446622, 0x2a547e2a, 0x903bab90, 0x880b8388, + 0x468cca46, 0xeec729ee, 0xb86bd3b8, 0x14283c14, 0xdea779de, 0x5ebce25e, 0x0b161d0b, 0xdbad76db, + 0xe0db3be0, 0x32645632, 0x3a744e3a, 0x0a141e0a, 0x4992db49, 0x060c0a06, 0x24486c24, 0x5cb8e45c, + 0xc29f5dc2, 0xd3bd6ed3, 0xac43efac, 0x62c4a662, 0x9139a891, 0x9531a495, 0xe4d337e4, 0x79f28b79, + 0xe7d532e7, 0xc88b43c8, 0x376e5937, 0x6ddab76d, 0x8d018c8d, 0xd5b164d5, 0x4e9cd24e, 0xa949e0a9, + 0x6cd8b46c, 0x56acfa56, 0xf4f307f4, 0xeacf25ea, 0x65caaf65, 0x7af48e7a, 0xae47e9ae, 0x08101808, + 0xba6fd5ba, 0x78f08878, 0x254a6f25, 0x2e5c722e, 0x1c38241c, 0xa657f1a6, 0xb473c7b4, 0xc69751c6, + 0xe8cb23e8, 0xdda17cdd, 0x74e89c74, 0x1f3e211f, 0x4b96dd4b, 0xbd61dcbd, 0x8b0d868b, 0x8a0f858a, + 0x70e09070, 0x3e7c423e, 0xb571c4b5, 0x66ccaa66, 0x4890d848, 0x03060503, 0xf6f701f6, 0x0e1c120e, + 0x61c2a361, 0x356a5f35, 0x57aef957, 0xb969d0b9, 0x86179186, 0xc19958c1, 0x1d3a271d, 0x9e27b99e, + 0xe1d938e1, 0xf8eb13f8, 0x982bb398, 0x11223311, 0x69d2bb69, 0xd9a970d9, 0x8e07898e, 0x9433a794, + 0x9b2db69b, 0x1e3c221e, 0x87159287, 0xe9c920e9, 0xce8749ce, 0x55aaff55, 0x28507828, 0xdfa57adf, + 0x8c038f8c, 0xa159f8a1, 0x89098089, 0x0d1a170d, 0xbf65dabf, 0xe6d731e6, 0x4284c642, 0x68d0b868, + 0x4182c341, 0x9929b099, 0x2d5a772d, 0x0f1e110f, 0xb07bcbb0, 0x54a8fc54, 0xbb6dd6bb, 0x162c3a16, + 0xc6a56363, 0xf8847c7c, 0xee997777, 0xf68d7b7b, 0xff0df2f2, 0xd6bd6b6b, 0xdeb16f6f, 0x9154c5c5, + 0x60503030, 0x02030101, 0xcea96767, 0x567d2b2b, 0xe719fefe, 0xb562d7d7, 0x4de6abab, 0xec9a7676, + 0x8f45caca, 0x1f9d8282, 0x8940c9c9, 0xfa877d7d, 0xef15fafa, 0xb2eb5959, 0x8ec94747, 0xfb0bf0f0, + 0x41ecadad, 0xb367d4d4, 0x5ffda2a2, 0x45eaafaf, 0x23bf9c9c, 0x53f7a4a4, 0xe4967272, 0x9b5bc0c0, + 0x75c2b7b7, 0xe11cfdfd, 0x3dae9393, 0x4c6a2626, 0x6c5a3636, 0x7e413f3f, 0xf502f7f7, 0x834fcccc, + 0x685c3434, 0x51f4a5a5, 0xd134e5e5, 0xf908f1f1, 0xe2937171, 0xab73d8d8, 0x62533131, 0x2a3f1515, + 0x080c0404, 0x9552c7c7, 0x46652323, 0x9d5ec3c3, 0x30281818, 0x37a19696, 0x0a0f0505, 0x2fb59a9a, + 0x0e090707, 0x24361212, 0x1b9b8080, 0xdf3de2e2, 0xcd26ebeb, 0x4e692727, 0x7fcdb2b2, 0xea9f7575, + 0x121b0909, 0x1d9e8383, 0x58742c2c, 0x342e1a1a, 0x362d1b1b, 0xdcb26e6e, 0xb4ee5a5a, 0x5bfba0a0, + 0xa4f65252, 0x764d3b3b, 0xb761d6d6, 0x7dceb3b3, 0x527b2929, 0xdd3ee3e3, 0x5e712f2f, 0x13978484, + 0xa6f55353, 0xb968d1d1, 0x00000000, 0xc12ceded, 0x40602020, 0xe31ffcfc, 0x79c8b1b1, 0xb6ed5b5b, + 0xd4be6a6a, 0x8d46cbcb, 0x67d9bebe, 0x724b3939, 0x94de4a4a, 0x98d44c4c, 0xb0e85858, 0x854acfcf, + 0xbb6bd0d0, 0xc52aefef, 0x4fe5aaaa, 0xed16fbfb, 0x86c54343, 0x9ad74d4d, 0x66553333, 0x11948585, + 0x8acf4545, 0xe910f9f9, 0x04060202, 0xfe817f7f, 0xa0f05050, 0x78443c3c, 0x25ba9f9f, 0x4be3a8a8, + 0xa2f35151, 0x5dfea3a3, 0x80c04040, 0x058a8f8f, 0x3fad9292, 0x21bc9d9d, 0x70483838, 0xf104f5f5, + 0x63dfbcbc, 0x77c1b6b6, 0xaf75dada, 0x42632121, 0x20301010, 0xe51affff, 0xfd0ef3f3, 0xbf6dd2d2, + 0x814ccdcd, 0x18140c0c, 0x26351313, 0xc32fecec, 0xbee15f5f, 0x35a29797, 0x88cc4444, 0x2e391717, + 0x9357c4c4, 0x55f2a7a7, 0xfc827e7e, 0x7a473d3d, 0xc8ac6464, 0xbae75d5d, 0x322b1919, 0xe6957373, + 0xc0a06060, 0x19988181, 0x9ed14f4f, 0xa37fdcdc, 0x44662222, 0x547e2a2a, 0x3bab9090, 0x0b838888, + 0x8cca4646, 0xc729eeee, 0x6bd3b8b8, 0x283c1414, 0xa779dede, 0xbce25e5e, 0x161d0b0b, 0xad76dbdb, + 0xdb3be0e0, 0x64563232, 0x744e3a3a, 0x141e0a0a, 0x92db4949, 0x0c0a0606, 0x486c2424, 0xb8e45c5c, + 0x9f5dc2c2, 0xbd6ed3d3, 0x43efacac, 0xc4a66262, 0x39a89191, 0x31a49595, 0xd337e4e4, 0xf28b7979, + 0xd532e7e7, 0x8b43c8c8, 0x6e593737, 0xdab76d6d, 0x018c8d8d, 0xb164d5d5, 0x9cd24e4e, 0x49e0a9a9, + 0xd8b46c6c, 0xacfa5656, 0xf307f4f4, 0xcf25eaea, 0xcaaf6565, 0xf48e7a7a, 0x47e9aeae, 0x10180808, + 0x6fd5baba, 0xf0887878, 0x4a6f2525, 0x5c722e2e, 0x38241c1c, 0x57f1a6a6, 0x73c7b4b4, 0x9751c6c6, + 0xcb23e8e8, 0xa17cdddd, 0xe89c7474, 0x3e211f1f, 0x96dd4b4b, 0x61dcbdbd, 0x0d868b8b, 0x0f858a8a, + 0xe0907070, 0x7c423e3e, 0x71c4b5b5, 0xccaa6666, 0x90d84848, 0x06050303, 0xf701f6f6, 0x1c120e0e, + 0xc2a36161, 0x6a5f3535, 0xaef95757, 0x69d0b9b9, 0x17918686, 0x9958c1c1, 0x3a271d1d, 0x27b99e9e, + 0xd938e1e1, 0xeb13f8f8, 0x2bb39898, 0x22331111, 0xd2bb6969, 0xa970d9d9, 0x07898e8e, 0x33a79494, + 0x2db69b9b, 0x3c221e1e, 0x15928787, 0xc920e9e9, 0x8749cece, 0xaaff5555, 0x50782828, 0xa57adfdf, + 0x038f8c8c, 0x59f8a1a1, 0x09808989, 0x1a170d0d, 0x65dabfbf, 0xd731e6e6, 0x84c64242, 0xd0b86868, + 0x82c34141, 0x29b09999, 0x5a772d2d, 0x1e110f0f, 0x7bcbb0b0, 0xa8fc5454, 0x6dd6bbbb, 0x2c3a1616 +}; + +static const uint32_t* const LUT0 = _aes_lut + 0 * 256; +static const uint32_t* const LUT1 = _aes_lut + 1 * 256; +static const uint32_t* const LUT2 = _aes_lut + 2 * 256; +static const uint32_t* const LUT3 = _aes_lut + 3 * 256; + +SoftAesBlock +softaes_block_encrypt(const SoftAesBlock block, const SoftAesBlock rk) +{ + SoftAesBlock out; + uint8_t ix0[4], ix1[4], ix2[4], ix3[4]; + const uint32_t s0 = block.w0; + const uint32_t s1 = block.w1; + const uint32_t s2 = block.w2; + const uint32_t s3 = block.w3; + + ix0[0] = (uint8_t) s0; + ix0[1] = (uint8_t) s1; + ix0[2] = (uint8_t) s2; + ix0[3] = (uint8_t) s3; + + ix1[0] = (uint8_t) (s1 >> 8); + ix1[1] = (uint8_t) (s2 >> 8); + ix1[2] = (uint8_t) (s3 >> 8); + ix1[3] = (uint8_t) (s0 >> 8); + + ix2[0] = (uint8_t) (s2 >> 16); + ix2[1] = (uint8_t) (s3 >> 16); + ix2[2] = (uint8_t) (s0 >> 16); + ix2[3] = (uint8_t) (s1 >> 16); + + ix3[0] = (uint8_t) (s3 >> 24); + ix3[1] = (uint8_t) (s0 >> 24); + ix3[2] = (uint8_t) (s1 >> 24); + ix3[3] = (uint8_t) (s2 >> 24); + + out.w0 = LUT0[ix0[0]]; + out.w1 = LUT0[ix0[1]]; + out.w2 = LUT0[ix0[2]]; + out.w3 = LUT0[ix0[3]]; + + out.w0 ^= LUT1[ix1[0]]; + out.w1 ^= LUT1[ix1[1]]; + out.w2 ^= LUT1[ix1[2]]; + out.w3 ^= LUT1[ix1[3]]; + + out.w0 ^= LUT2[ix2[0]]; + out.w1 ^= LUT2[ix2[1]]; + out.w2 ^= LUT2[ix2[2]]; + out.w3 ^= LUT2[ix2[3]]; + + out.w0 ^= LUT3[ix3[0]]; + out.w1 ^= LUT3[ix3[1]]; + out.w2 ^= LUT3[ix3[2]]; + out.w3 ^= LUT3[ix3[3]]; + + out.w0 ^= rk.w0; + out.w1 ^= rk.w1; + out.w2 ^= rk.w2; + out.w3 ^= rk.w3; + + return out; +} +#else + +uint32_t _aes_lut[256] __attribute__((visibility("hidden"))) = { + 0xa56363c6, 0x847c7cf8, 0x997777ee, 0x8d7b7bf6, 0x0df2f2ff, 0xbd6b6bd6, 0xb16f6fde, 0x54c5c591, + 0x50303060, 0x03010102, 0xa96767ce, 0x7d2b2b56, 0x19fefee7, 0x62d7d7b5, 0xe6abab4d, 0x9a7676ec, + 0x45caca8f, 0x9d82821f, 0x40c9c989, 0x877d7dfa, 0x15fafaef, 0xeb5959b2, 0xc947478e, 0x0bf0f0fb, + 0xecadad41, 0x67d4d4b3, 0xfda2a25f, 0xeaafaf45, 0xbf9c9c23, 0xf7a4a453, 0x967272e4, 0x5bc0c09b, + 0xc2b7b775, 0x1cfdfde1, 0xae93933d, 0x6a26264c, 0x5a36366c, 0x413f3f7e, 0x02f7f7f5, 0x4fcccc83, + 0x5c343468, 0xf4a5a551, 0x34e5e5d1, 0x08f1f1f9, 0x937171e2, 0x73d8d8ab, 0x53313162, 0x3f15152a, + 0x0c040408, 0x52c7c795, 0x65232346, 0x5ec3c39d, 0x28181830, 0xa1969637, 0x0f05050a, 0xb59a9a2f, + 0x0907070e, 0x36121224, 0x9b80801b, 0x3de2e2df, 0x26ebebcd, 0x6927274e, 0xcdb2b27f, 0x9f7575ea, + 0x1b090912, 0x9e83831d, 0x742c2c58, 0x2e1a1a34, 0x2d1b1b36, 0xb26e6edc, 0xee5a5ab4, 0xfba0a05b, + 0xf65252a4, 0x4d3b3b76, 0x61d6d6b7, 0xceb3b37d, 0x7b292952, 0x3ee3e3dd, 0x712f2f5e, 0x97848413, + 0xf55353a6, 0x68d1d1b9, 0x00000000, 0x2cededc1, 0x60202040, 0x1ffcfce3, 0xc8b1b179, 0xed5b5bb6, + 0xbe6a6ad4, 0x46cbcb8d, 0xd9bebe67, 0x4b393972, 0xde4a4a94, 0xd44c4c98, 0xe85858b0, 0x4acfcf85, + 0x6bd0d0bb, 0x2aefefc5, 0xe5aaaa4f, 0x16fbfbed, 0xc5434386, 0xd74d4d9a, 0x55333366, 0x94858511, + 0xcf45458a, 0x10f9f9e9, 0x06020204, 0x817f7ffe, 0xf05050a0, 0x443c3c78, 0xba9f9f25, 0xe3a8a84b, + 0xf35151a2, 0xfea3a35d, 0xc0404080, 0x8a8f8f05, 0xad92923f, 0xbc9d9d21, 0x48383870, 0x04f5f5f1, + 0xdfbcbc63, 0xc1b6b677, 0x75dadaaf, 0x63212142, 0x30101020, 0x1affffe5, 0x0ef3f3fd, 0x6dd2d2bf, + 0x4ccdcd81, 0x140c0c18, 0x35131326, 0x2fececc3, 0xe15f5fbe, 0xa2979735, 0xcc444488, 0x3917172e, + 0x57c4c493, 0xf2a7a755, 0x827e7efc, 0x473d3d7a, 0xac6464c8, 0xe75d5dba, 0x2b191932, 0x957373e6, + 0xa06060c0, 0x98818119, 0xd14f4f9e, 0x7fdcdca3, 0x66222244, 0x7e2a2a54, 0xab90903b, 0x8388880b, + 0xca46468c, 0x29eeeec7, 0xd3b8b86b, 0x3c141428, 0x79dedea7, 0xe25e5ebc, 0x1d0b0b16, 0x76dbdbad, + 0x3be0e0db, 0x56323264, 0x4e3a3a74, 0x1e0a0a14, 0xdb494992, 0x0a06060c, 0x6c242448, 0xe45c5cb8, + 0x5dc2c29f, 0x6ed3d3bd, 0xefacac43, 0xa66262c4, 0xa8919139, 0xa4959531, 0x37e4e4d3, 0x8b7979f2, + 0x32e7e7d5, 0x43c8c88b, 0x5937376e, 0xb76d6dda, 0x8c8d8d01, 0x64d5d5b1, 0xd24e4e9c, 0xe0a9a949, + 0xb46c6cd8, 0xfa5656ac, 0x07f4f4f3, 0x25eaeacf, 0xaf6565ca, 0x8e7a7af4, 0xe9aeae47, 0x18080810, + 0xd5baba6f, 0x887878f0, 0x6f25254a, 0x722e2e5c, 0x241c1c38, 0xf1a6a657, 0xc7b4b473, 0x51c6c697, + 0x23e8e8cb, 0x7cdddda1, 0x9c7474e8, 0x211f1f3e, 0xdd4b4b96, 0xdcbdbd61, 0x868b8b0d, 0x858a8a0f, + 0x907070e0, 0x423e3e7c, 0xc4b5b571, 0xaa6666cc, 0xd8484890, 0x05030306, 0x01f6f6f7, 0x120e0e1c, + 0xa36161c2, 0x5f35356a, 0xf95757ae, 0xd0b9b969, 0x91868617, 0x58c1c199, 0x271d1d3a, 0xb99e9e27, + 0x38e1e1d9, 0x13f8f8eb, 0xb398982b, 0x33111122, 0xbb6969d2, 0x70d9d9a9, 0x898e8e07, 0xa7949433, + 0xb69b9b2d, 0x221e1e3c, 0x92878715, 0x20e9e9c9, 0x49cece87, 0xff5555aa, 0x78282850, 0x7adfdfa5, + 0x8f8c8c03, 0xf8a1a159, 0x80898909, 0x170d0d1a, 0xdabfbf65, 0x31e6e6d7, 0xc6424284, 0xb86868d0, + 0xc3414182, 0xb0999929, 0x772d2d5a, 0x110f0f1e, 0xcbb0b07b, 0xfc5454a8, 0xd6bbbb6d, 0x3a16162c +}; + +static const uint32_t* const LUT = _aes_lut; + +static SoftAesBlock +_encrypt(const uint8_t ix0[4], const uint8_t ix1[4], const uint8_t ix2[4], const uint8_t ix3[4]) +{ + CRYPTO_ALIGN(64) uint32_t t[4][4][256 / SOFTAES_STRIDE]; + CRYPTO_ALIGN(64) uint8_t of[4][4]; + CRYPTO_ALIGN(64) SoftAesBlock out; + size_t i; + size_t j; + + for (j = 0; j < 4; j++) { + of[j][0] = ix0[j] % SOFTAES_STRIDE; + of[j][1] = ix1[j] % SOFTAES_STRIDE; + of[j][2] = ix2[j] % SOFTAES_STRIDE; + of[j][3] = ix3[j] % SOFTAES_STRIDE; + } + for (i = 0; i < 256 / SOFTAES_STRIDE; i++) { + for (j = 0; j < 4; j++) { + t[j][0][i] = LUT[(i * SOFTAES_STRIDE) | of[j][0]]; + t[j][1][i] = LUT[(i * SOFTAES_STRIDE) | of[j][1]]; + t[j][2][i] = LUT[(i * SOFTAES_STRIDE) | of[j][2]]; + t[j][3][i] = LUT[(i * SOFTAES_STRIDE) | of[j][3]]; + } + } + +#ifdef HAVE_INLINE_ASM + __asm__ __volatile__("" : : "r"(t) : "memory"); +#endif + + out.w0 = t[0][0][ix0[0] / SOFTAES_STRIDE]; + out.w0 ^= ROTL32(t[0][1][ix1[0] / SOFTAES_STRIDE], 8); + out.w0 ^= ROTL32(t[0][2][ix2[0] / SOFTAES_STRIDE], 16); + out.w0 ^= ROTL32(t[0][3][ix3[0] / SOFTAES_STRIDE], 24); + + out.w1 = t[1][0][ix0[1] / SOFTAES_STRIDE]; + out.w1 ^= ROTL32(t[1][1][ix1[1] / SOFTAES_STRIDE], 8); + out.w1 ^= ROTL32(t[1][2][ix2[1] / SOFTAES_STRIDE], 16); + out.w1 ^= ROTL32(t[1][3][ix3[1] / SOFTAES_STRIDE], 24); + + out.w2 = t[2][0][ix0[2] / SOFTAES_STRIDE]; + out.w2 ^= ROTL32(t[2][1][ix1[2] / SOFTAES_STRIDE], 8); + out.w2 ^= ROTL32(t[2][2][ix2[2] / SOFTAES_STRIDE], 16); + out.w2 ^= ROTL32(t[2][3][ix3[2] / SOFTAES_STRIDE], 24); + + out.w3 = t[3][0][ix0[3] / SOFTAES_STRIDE]; + out.w3 ^= ROTL32(t[3][1][ix1[3] / SOFTAES_STRIDE], 8); + out.w3 ^= ROTL32(t[3][2][ix2[3] / SOFTAES_STRIDE], 16); + out.w3 ^= ROTL32(t[3][3][ix3[3] / SOFTAES_STRIDE], 24); + + return out; +} + +SoftAesBlock +softaes_block_encrypt(const SoftAesBlock block, const SoftAesBlock rk) +{ + CRYPTO_ALIGN(64) SoftAesBlock out; + CRYPTO_ALIGN(64) uint8_t ix0[4], ix1[4], ix2[4], ix3[4]; + const uint32_t s0 = block.w0; + const uint32_t s1 = block.w1; + const uint32_t s2 = block.w2; + const uint32_t s3 = block.w3; + + ix0[0] = (uint8_t) s0; + ix0[1] = (uint8_t) s1; + ix0[2] = (uint8_t) s2; + ix0[3] = (uint8_t) s3; + + ix1[0] = (uint8_t) (s1 >> 8); + ix1[1] = (uint8_t) (s2 >> 8); + ix1[2] = (uint8_t) (s3 >> 8); + ix1[3] = (uint8_t) (s0 >> 8); + + ix2[0] = (uint8_t) (s2 >> 16); + ix2[1] = (uint8_t) (s3 >> 16); + ix2[2] = (uint8_t) (s0 >> 16); + ix2[3] = (uint8_t) (s1 >> 16); + + ix3[0] = (uint8_t) (s3 >> 24); + ix3[1] = (uint8_t) (s0 >> 24); + ix3[2] = (uint8_t) (s1 >> 24); + ix3[3] = (uint8_t) (s2 >> 24); + + out = _encrypt(ix0, ix1, ix2, ix3); + + out.w0 ^= rk.w0; + out.w1 ^= rk.w1; + out.w2 ^= rk.w2; + out.w3 ^= rk.w3; + + return out; +} +#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2.h b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2.h @@ -23,20 +23,6 @@ #include "crypto_generichash_blake2b.h" #include "export.h" -#define blake2b_init_param crypto_generichash_blake2b__init_param -#define blake2b_init crypto_generichash_blake2b__init -#define blake2b_init_salt_personal \ - crypto_generichash_blake2b__init_salt_personal -#define blake2b_init_key crypto_generichash_blake2b__init_key -#define blake2b_init_key_salt_personal \ - crypto_generichash_blake2b__init_key_salt_personal -#define blake2b_update crypto_generichash_blake2b__update -#define blake2b_final crypto_generichash_blake2b__final -#define blake2b crypto_generichash_blake2b__blake2b -#define blake2b_salt_personal crypto_generichash_blake2b__blake2b_salt_personal -#define blake2b_pick_best_implementation \ - crypto_generichash_blake2b__pick_best_implementation - enum blake2b_constant { BLAKE2B_BLOCKBYTES = 128, BLAKE2B_OUTBYTES = 64, @@ -45,10 +31,12 @@ enum blake2b_constant { BLAKE2B_PERSONALBYTES = 16 }; -#if defined(__IBMC__) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) -#pragma pack(1) +#ifdef __IBMC__ +# pragma pack(1) +#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC) +# pragma pack(1) #else -#pragma pack(push, 1) +# pragma pack(push, 1) #endif typedef struct blake2b_param_ { @@ -74,10 +62,12 @@ typedef struct blake2b_state { uint8_t last_node; } blake2b_state; -#if defined(__IBMC__) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) -#pragma pack() +#ifdef __IBMC__ +# pragma pack(pop) +#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC) +# pragma pack() #else -#pragma pack(pop) +# pragma pack(pop) #endif /* Streaming API */ diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-avx2.c b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-avx2.c @@ -8,22 +8,21 @@ #include "blake2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_AVX2INTRIN_H) && defined(HAVE_EMMINTRIN_H) && \ defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") -# pragma GCC target("avx2") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1,avx2") # endif # include <emmintrin.h> # include <immintrin.h> # include <smmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blake2b-compress-avx2.h" @@ -46,4 +45,8 @@ blake2b_compress_avx2(blake2b_state *S, const uint8_t block[BLAKE2B_BLOCKBYTES]) return 0; } +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.c b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.c @@ -7,20 +7,20 @@ #include "blake2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) && \ defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1") # endif # include <emmintrin.h> # include <smmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blake2b-compress-sse41.h" @@ -84,4 +84,8 @@ blake2b_compress_sse41(blake2b_state *S, return 0; } +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.h b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.h @@ -5,6 +5,8 @@ #define LOADU(p) _mm_loadu_si128((const __m128i *) (const void *) (p)) #define STOREU(p, r) _mm_storeu_si128((__m128i *) (void *) (p), r) +#if !(defined(_mm_roti_epi64) && defined(__XOP__)) +#undef _mm_roti_epi64 #define _mm_roti_epi64(x, c) \ (-(c) == 32) \ ? _mm_shuffle_epi32((x), _MM_SHUFFLE(2, 3, 0, 1)) \ @@ -17,6 +19,7 @@ _mm_add_epi64((x), (x))) \ : _mm_xor_si128(_mm_srli_epi64((x), -(c)), \ _mm_slli_epi64((x), 64 - (-(c)))) +#endif #define G1(row1l, row2l, row3l, row4l, row1h, row2h, row3h, row4h, b0, b1) \ row1l = _mm_add_epi64(_mm_add_epi64(row1l, b0), row2l); \ diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.c b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.c @@ -4,17 +4,18 @@ #include "blake2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3") # endif # include <emmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blake2b-compress-ssse3.h" @@ -87,4 +88,8 @@ blake2b_compress_ssse3(blake2b_state *S, return 0; } +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.h b/subprojects/libsodium/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.h @@ -5,6 +5,8 @@ #define LOADU(p) _mm_loadu_si128((const __m128i *) (const void *) (p)) #define STOREU(p, r) _mm_storeu_si128((__m128i *) (void *) (p), r) +#if !(defined(_mm_roti_epi64) && defined(__XOP__)) +#undef _mm_roti_epi64 #define _mm_roti_epi64(x, c) \ (-(c) == 32) \ ? _mm_shuffle_epi32((x), _MM_SHUFFLE(2, 3, 0, 1)) \ @@ -17,6 +19,7 @@ _mm_add_epi64((x), (x))) \ : _mm_xor_si128(_mm_srli_epi64((x), -(c)), \ _mm_slli_epi64((x), 64 - (-(c)))) +#endif #define G1(row1l, row2l, row3l, row4l, row1h, row2h, row3h, row4h, b0, b1) \ row1l = _mm_add_epi64(_mm_add_epi64(row1l, b0), row2l); \ diff --git a/subprojects/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c b/subprojects/libsodium/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c @@ -156,6 +156,7 @@ SHA256_Pad(crypto_hash_sha256_state *state, uint32_t tmp32[64 + 8]) unsigned int r; unsigned int i; + ACQUIRE_FENCE; r = (unsigned int) ((state->count >> 3) & 0x3f); if (r < 56) { for (i = 0; i < 56 - r; i++) { @@ -197,6 +198,7 @@ crypto_hash_sha256_update(crypto_hash_sha256_state *state, if (inlen <= 0U) { return 0; } + ACQUIRE_FENCE; r = (unsigned long long) ((state->count >> 3) & 0x3f); state->count += ((uint64_t) inlen) << 3; diff --git a/subprojects/libsodium/src/libsodium/crypto_hash/sha512/cp/hash_sha512_cp.c b/subprojects/libsodium/src/libsodium/crypto_hash/sha512/cp/hash_sha512_cp.c @@ -175,6 +175,7 @@ SHA512_Pad(crypto_hash_sha512_state *state, uint64_t tmp64[80 + 8]) unsigned int r; unsigned int i; + ACQUIRE_FENCE; r = (unsigned int) ((state->count[1] >> 3) & 0x7f); if (r < 112) { for (i = 0; i < 112 - r; i++) { @@ -218,6 +219,7 @@ crypto_hash_sha512_update(crypto_hash_sha512_state *state, if (inlen <= 0U) { return 0; } + ACQUIRE_FENCE; r = (unsigned long long) ((state->count[1] >> 3) & 0x7f); bitlen[1] = ((uint64_t) inlen) << 3; diff --git a/subprojects/libsodium/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha256.c b/subprojects/libsodium/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha256.c @@ -0,0 +1,123 @@ +#include <errno.h> +#include <string.h> + +#include "crypto_auth_hmacsha256.h" +#include "crypto_kdf.h" +#include "crypto_kdf_hkdf_sha256.h" +#include "randombytes.h" +#include "utils.h" + +int +crypto_kdf_hkdf_sha256_extract_init(crypto_kdf_hkdf_sha256_state *state, + const unsigned char *salt, size_t salt_len) +{ + return crypto_auth_hmacsha256_init(&state->st, salt, salt_len); +} + +int +crypto_kdf_hkdf_sha256_extract_update(crypto_kdf_hkdf_sha256_state *state, + const unsigned char *ikm, size_t ikm_len) +{ + return crypto_auth_hmacsha256_update(&state->st, ikm, ikm_len); +} + +int +crypto_kdf_hkdf_sha256_extract_final(crypto_kdf_hkdf_sha256_state *state, + unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]) +{ + crypto_auth_hmacsha256_final(&state->st, prk); + sodium_memzero(state, sizeof state); + + return 0; +} + +int +crypto_kdf_hkdf_sha256_extract( + unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES], + const unsigned char *salt, size_t salt_len, const unsigned char *ikm, + size_t ikm_len) +{ + crypto_kdf_hkdf_sha256_state state; + + crypto_kdf_hkdf_sha256_extract_init(&state, salt, salt_len); + crypto_kdf_hkdf_sha256_extract_update(&state, ikm, ikm_len); + + return crypto_kdf_hkdf_sha256_extract_final(&state, prk); +} + +void +crypto_kdf_hkdf_sha256_keygen(unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]) +{ + randombytes_buf(prk, crypto_kdf_hkdf_sha256_KEYBYTES); +} + +int +crypto_kdf_hkdf_sha256_expand(unsigned char *out, size_t out_len, + const char *ctx, size_t ctx_len, + const unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]) +{ + crypto_auth_hmacsha256_state st; + unsigned char tmp[crypto_auth_hmacsha256_BYTES]; + size_t i; + size_t left; + unsigned char counter = 1U; + + if (out_len > crypto_kdf_hkdf_sha256_BYTES_MAX) { + errno = EINVAL; + return -1; + } + for (i = (size_t) 0U; i + crypto_auth_hmacsha256_BYTES <= out_len; + i += crypto_auth_hmacsha256_BYTES) { + crypto_auth_hmacsha256_init(&st, prk, crypto_kdf_hkdf_sha256_KEYBYTES); + if (i != (size_t) 0U) { + crypto_auth_hmacsha256_update(&st, + &out[i - crypto_auth_hmacsha256_BYTES], + crypto_auth_hmacsha256_BYTES); + } + crypto_auth_hmacsha256_update(&st, + (const unsigned char *) ctx, ctx_len); + crypto_auth_hmacsha256_update(&st, &counter, (size_t) 1U); + crypto_auth_hmacsha256_final(&st, &out[i]); + counter++; + } + if ((left = out_len & (crypto_auth_hmacsha256_BYTES - 1U)) != (size_t) 0U) { + crypto_auth_hmacsha256_init(&st, prk, crypto_kdf_hkdf_sha256_KEYBYTES); + if (i != (size_t) 0U) { + crypto_auth_hmacsha256_update(&st, + &out[i - crypto_auth_hmacsha256_BYTES], + crypto_auth_hmacsha256_BYTES); + } + crypto_auth_hmacsha256_update(&st, + (const unsigned char *) ctx, ctx_len); + crypto_auth_hmacsha256_update(&st, &counter, (size_t) 1U); + crypto_auth_hmacsha256_final(&st, tmp); + memcpy(&out[i], tmp, left); + sodium_memzero(tmp, sizeof tmp); + } + sodium_memzero(&st, sizeof st); + + return 0; +} + +size_t +crypto_kdf_hkdf_sha256_keybytes(void) +{ + return crypto_kdf_hkdf_sha256_KEYBYTES; +} + +size_t +crypto_kdf_hkdf_sha256_bytes_min(void) +{ + return crypto_kdf_hkdf_sha256_BYTES_MIN; +} + +size_t +crypto_kdf_hkdf_sha256_bytes_max(void) +{ + return crypto_kdf_hkdf_sha256_BYTES_MAX; +} + +size_t crypto_kdf_hkdf_sha256_statebytes(void) +{ + return sizeof(crypto_kdf_hkdf_sha256_state); +} diff --git a/subprojects/libsodium/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha512.c b/subprojects/libsodium/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha512.c @@ -0,0 +1,123 @@ +#include <errno.h> +#include <string.h> + +#include "crypto_auth_hmacsha512.h" +#include "crypto_kdf.h" +#include "crypto_kdf_hkdf_sha512.h" +#include "randombytes.h" +#include "utils.h" + +int +crypto_kdf_hkdf_sha512_extract_init(crypto_kdf_hkdf_sha512_state *state, + const unsigned char *salt, size_t salt_len) +{ + return crypto_auth_hmacsha512_init(&state->st, salt, salt_len); +} + +int +crypto_kdf_hkdf_sha512_extract_update(crypto_kdf_hkdf_sha512_state *state, + const unsigned char *ikm, size_t ikm_len) +{ + return crypto_auth_hmacsha512_update(&state->st, ikm, ikm_len); +} + +int +crypto_kdf_hkdf_sha512_extract_final(crypto_kdf_hkdf_sha512_state *state, + unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) +{ + crypto_auth_hmacsha512_final(&state->st, prk); + sodium_memzero(state, sizeof state); + + return 0; +} + +int +crypto_kdf_hkdf_sha512_extract( + unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES], + const unsigned char *salt, size_t salt_len, const unsigned char *ikm, + size_t ikm_len) +{ + crypto_kdf_hkdf_sha512_state state; + + crypto_kdf_hkdf_sha512_extract_init(&state, salt, salt_len); + crypto_kdf_hkdf_sha512_extract_update(&state, ikm, ikm_len); + + return crypto_kdf_hkdf_sha512_extract_final(&state, prk); +} + +void +crypto_kdf_hkdf_sha512_keygen(unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) +{ + randombytes_buf(prk, crypto_kdf_hkdf_sha512_KEYBYTES); +} + +int +crypto_kdf_hkdf_sha512_expand(unsigned char *out, size_t out_len, + const char *ctx, size_t ctx_len, + const unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) +{ + crypto_auth_hmacsha512_state st; + unsigned char tmp[crypto_auth_hmacsha512_BYTES]; + size_t i; + size_t left; + unsigned char counter = 1U; + + if (out_len > crypto_kdf_hkdf_sha512_BYTES_MAX) { + errno = EINVAL; + return -1; + } + for (i = (size_t) 0U; i + crypto_auth_hmacsha512_BYTES <= out_len; + i += crypto_auth_hmacsha512_BYTES) { + crypto_auth_hmacsha512_init(&st, prk, crypto_kdf_hkdf_sha512_KEYBYTES); + if (i != (size_t) 0U) { + crypto_auth_hmacsha512_update(&st, + &out[i - crypto_auth_hmacsha512_BYTES], + crypto_auth_hmacsha512_BYTES); + } + crypto_auth_hmacsha512_update(&st, + (const unsigned char *) ctx, ctx_len); + crypto_auth_hmacsha512_update(&st, &counter, (size_t) 1U); + crypto_auth_hmacsha512_final(&st, &out[i]); + counter++; + } + if ((left = out_len & (crypto_auth_hmacsha512_BYTES - 1U)) != (size_t) 0U) { + crypto_auth_hmacsha512_init(&st, prk, crypto_kdf_hkdf_sha512_KEYBYTES); + if (i != (size_t) 0U) { + crypto_auth_hmacsha512_update(&st, + &out[i - crypto_auth_hmacsha512_BYTES], + crypto_auth_hmacsha512_BYTES); + } + crypto_auth_hmacsha512_update(&st, + (const unsigned char *) ctx, ctx_len); + crypto_auth_hmacsha512_update(&st, &counter, (size_t) 1U); + crypto_auth_hmacsha512_final(&st, tmp); + memcpy(&out[i], tmp, left); + sodium_memzero(tmp, sizeof tmp); + } + sodium_memzero(&st, sizeof st); + + return 0; +} + +size_t +crypto_kdf_hkdf_sha512_keybytes(void) +{ + return crypto_kdf_hkdf_sha512_KEYBYTES; +} + +size_t +crypto_kdf_hkdf_sha512_bytes_min(void) +{ + return crypto_kdf_hkdf_sha512_BYTES_MIN; +} + +size_t +crypto_kdf_hkdf_sha512_bytes_max(void) +{ + return crypto_kdf_hkdf_sha512_BYTES_MAX; +} + +size_t crypto_kdf_hkdf_sha512_statebytes(void) +{ + return sizeof(crypto_kdf_hkdf_sha512_state); +} diff --git a/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna32.h b/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna32.h @@ -122,7 +122,7 @@ poly1305_blocks(poly1305_state_internal_t *st, const unsigned char *m, h4 = (unsigned long) d4 & 0x3ffffff; h0 += c * 5; c = (h0 >> 26); - h0 = h0 & 0x3ffffff; + h0 &= 0x3ffffff; h1 += c; m += poly1305_block_size; diff --git a/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna64.h b/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna64.h @@ -120,7 +120,7 @@ poly1305_blocks(poly1305_state_internal_t *st, const unsigned char *m, h2 = LO(d2) & 0x3ffffffffff; h0 += c * 5; c = (h0 >> 44); - h0 = h0 & 0xfffffffffff; + h0 &= 0xfffffffffff; h1 += c; m += poly1305_block_size; diff --git a/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/sse2/poly1305_sse2.c b/subprojects/libsodium/src/libsodium/crypto_onetimeauth/poly1305/sse2/poly1305_sse2.c @@ -6,16 +6,18 @@ #include "crypto_verify_16.h" #include "poly1305_sse2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #include "utils.h" #if defined(HAVE_TI_MODE) && defined(HAVE_EMMINTRIN_H) -# ifdef __GNUC__ +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2"))), apply_to = function) +# elif defined(__GNUC__) # pragma GCC target("sse2") # endif # include <emmintrin.h> +# include "private/sse2_64_32.h" typedef __m128i xmmi; @@ -41,14 +43,14 @@ typedef struct poly1305_state_internal_t { union { uint64_t h[3]; uint32_t hh[10]; - } H; /* 40 bytes */ - uint32_t R[5]; /* 20 bytes */ - uint32_t R2[5]; /* 20 bytes */ - uint32_t R4[5]; /* 20 bytes */ - uint64_t pad[2]; /* 16 bytes */ - uint64_t flags; /* 8 bytes */ - unsigned long long leftover; /* 8 bytes */ - unsigned char buffer[poly1305_block_size]; /* 32 bytes */ + } H; /* 40 bytes */ + uint32_t R[5]; /* 20 bytes */ + uint32_t R2[5]; /* 20 bytes */ + uint32_t R4[5]; /* 20 bytes */ + uint64_t pad[2]; /* 16 bytes */ + uint64_t flags; /* 8 bytes */ + unsigned long long leftover; /* 8 bytes */ + unsigned char buffer[poly1305_block_size]; /* 32 bytes */ } poly1305_state_internal_t; /* 164 bytes total */ /* @@ -192,6 +194,8 @@ poly1305_init_ext(poly1305_state_internal_t *st, const unsigned char key[32], st->leftover = 0U; } +static volatile uint64_t optblocker_u64; + static POLY1305_NOINLINE void poly1305_blocks(poly1305_state_internal_t *st, const unsigned char *m, unsigned long long bytes) @@ -743,7 +747,7 @@ poly1305_blocks(poly1305_state_internal_t *st, const unsigned char *m, g1 &= 0xfffffffffff; g2 = h2 + c - ((uint64_t) 1 << 42); - c = (g2 >> 63) - 1; + c = (((g2 >> 61) ^ optblocker_u64) >> 2) - 1; nc = ~c; h0 = (h0 & nc) | (g0 & c); h1 = (h1 & nc) | (g1 & c); @@ -946,4 +950,8 @@ struct crypto_onetimeauth_poly1305_implementation SODIUM_C99(.onetimeauth_final =) crypto_onetimeauth_poly1305_sse2_final }; +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-core.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-core.c @@ -35,13 +35,17 @@ # define MAP_ANON MAP_ANONYMOUS #endif #ifndef MAP_NOCORE -# define MAP_NOCORE 0 +# ifdef MAP_CONCEAL +# define MAP_NOCORE MAP_CONCEAL +# else +# define MAP_NOCORE 0 +# endif #endif #ifndef MAP_POPULATE # define MAP_POPULATE 0 #endif -static fill_segment_fn fill_segment = fill_segment_ref; +static fill_segment_fn fill_segment = argon2_fill_segment_ref; static void load_block(block *dst, const void *input) @@ -72,7 +76,7 @@ static int allocate_memory(block_region **region, uint32_t m_cost); static int allocate_memory(block_region **region, uint32_t m_cost) { - void * base; + void *base; block *memory; size_t memory_size; @@ -95,12 +99,12 @@ allocate_memory(block_region **region, uint32_t m_cost) -1, 0)) == MAP_FAILED) { base = NULL; /* LCOV_EXCL_LINE */ } /* LCOV_EXCL_LINE */ - memcpy(&memory, &base, sizeof memory); + memory = (block *) base; #elif defined(HAVE_POSIX_MEMALIGN) if ((errno = posix_memalign((void **) &base, 64, memory_size)) != 0) { base = NULL; } - memcpy(&memory, &base, sizeof memory); + memory = (block *) base; #else memory = NULL; if (memory_size + 63 < memory_size) { @@ -109,7 +113,7 @@ allocate_memory(block_region **region, uint32_t m_cost) } else if ((base = malloc(memory_size + 63)) != NULL) { uint8_t *aligned = ((uint8_t *) base) + 63; aligned -= (uintptr_t) aligned & 63; - memcpy(&memory, &aligned, sizeof memory); + memory = (block *) aligned; } #endif if (base == NULL) { @@ -171,8 +175,8 @@ free_memory(block_region *region) free(region); } -void -free_instance(argon2_instance_t *instance, int flags) +static void +argon2_free_instance(argon2_instance_t *instance, int flags) { /* Clear memory */ clear_memory(instance, flags & ARGON2_FLAG_CLEAR_MEMORY); @@ -185,7 +189,7 @@ free_instance(argon2_instance_t *instance, int flags) } void -finalize(const argon2_context *context, argon2_instance_t *instance) +argon2_finalize(const argon2_context *context, argon2_instance_t *instance) { if (context != NULL && instance != NULL) { block blockhash; @@ -214,12 +218,12 @@ finalize(const argon2_context *context, argon2_instance_t *instance) ARGON2_BLOCK_SIZE); /* clear blockhash_bytes */ } - free_instance(instance, context->flags); + argon2_free_instance(instance, context->flags); } } void -fill_memory_blocks(argon2_instance_t *instance, uint32_t pass) +argon2_fill_memory_blocks(argon2_instance_t *instance, uint32_t pass) { argon2_position_t position; uint32_t l; @@ -241,7 +245,7 @@ fill_memory_blocks(argon2_instance_t *instance, uint32_t pass) } int -validate_inputs(const argon2_context *context) +argon2_validate_inputs(const argon2_context *context) { /* LCOV_EXCL_START */ if (NULL == context) { @@ -321,6 +325,15 @@ validate_inputs(const argon2_context *context) } } + /* Validate lanes */ + if (ARGON2_MIN_LANES > context->lanes) { + return ARGON2_LANES_TOO_FEW; + } + + if (ARGON2_MAX_LANES < context->lanes) { + return ARGON2_LANES_TOO_MANY; + } + /* Validate memory cost */ if (ARGON2_MIN_MEMORY > context->m_cost) { return ARGON2_MEMORY_TOO_LITTLE; @@ -343,15 +356,6 @@ validate_inputs(const argon2_context *context) return ARGON2_TIME_TOO_LARGE; } - /* Validate lanes */ - if (ARGON2_MIN_LANES > context->lanes) { - return ARGON2_LANES_TOO_FEW; - } - - if (ARGON2_MAX_LANES < context->lanes) { - return ARGON2_LANES_TOO_MANY; - } - /* Validate threads */ if (ARGON2_MIN_THREADS > context->threads) { return ARGON2_THREADS_TOO_FEW; @@ -365,8 +369,8 @@ validate_inputs(const argon2_context *context) return ARGON2_OK; } -void -fill_first_blocks(uint8_t *blockhash, const argon2_instance_t *instance) +static void +argon2_fill_first_blocks(uint8_t *blockhash, const argon2_instance_t *instance) { uint32_t l; /* Make the first and second block in each lane as G(H0||i||0) or @@ -389,8 +393,9 @@ fill_first_blocks(uint8_t *blockhash, const argon2_instance_t *instance) sodium_memzero(blockhash_bytes, ARGON2_BLOCK_SIZE); } -void -initial_hash(uint8_t *blockhash, argon2_context *context, argon2_type type) +static void +argon2_initial_hash(uint8_t *blockhash, argon2_context *context, + argon2_type type) { crypto_generichash_blake2b_state BlakeHash; uint8_t value[4U /* sizeof(uint32_t) */]; @@ -473,7 +478,7 @@ initial_hash(uint8_t *blockhash, argon2_context *context, argon2_type type) } int -initialize(argon2_instance_t *instance, argon2_context *context) +argon2_initialize(argon2_instance_t *instance, argon2_context *context) { uint8_t blockhash[ARGON2_PREHASH_SEED_LENGTH]; int result = ARGON2_OK; @@ -491,7 +496,7 @@ initialize(argon2_instance_t *instance, argon2_context *context) result = allocate_memory(&(instance->region), instance->memory_blocks); if (ARGON2_OK != result) { - free_instance(instance, context->flags); + argon2_free_instance(instance, context->flags); return result; } @@ -499,45 +504,46 @@ initialize(argon2_instance_t *instance, argon2_context *context) /* H_0 + 8 extra bytes to produce the first blocks */ /* uint8_t blockhash[ARGON2_PREHASH_SEED_LENGTH]; */ /* Hashing all inputs */ - initial_hash(blockhash, context, instance->type); + argon2_initial_hash(blockhash, context, instance->type); /* Zeroing 8 extra bytes */ sodium_memzero(blockhash + ARGON2_PREHASH_DIGEST_LENGTH, ARGON2_PREHASH_SEED_LENGTH - ARGON2_PREHASH_DIGEST_LENGTH); /* 3. Creating first blocks, we always have at least two blocks in a slice */ - fill_first_blocks(blockhash, instance); + argon2_fill_first_blocks(blockhash, instance); /* Clearing the hash */ sodium_memzero(blockhash, ARGON2_PREHASH_SEED_LENGTH); return ARGON2_OK; } -int +static int argon2_pick_best_implementation(void) { /* LCOV_EXCL_START */ #if defined(HAVE_AVX512FINTRIN_H) && defined(HAVE_AVX2INTRIN_H) && \ - defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) + defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) && \ + !defined(__APPLE__) if (sodium_runtime_has_avx512f()) { - fill_segment = fill_segment_avx512f; + fill_segment = argon2_fill_segment_avx512f; return 0; } #endif #if defined(HAVE_AVX2INTRIN_H) && defined(HAVE_TMMINTRIN_H) && \ defined(HAVE_SMMINTRIN_H) if (sodium_runtime_has_avx2()) { - fill_segment = fill_segment_avx2; + fill_segment = argon2_fill_segment_avx2; return 0; } #endif #if defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) if (sodium_runtime_has_ssse3()) { - fill_segment = fill_segment_ssse3; + fill_segment = argon2_fill_segment_ssse3; return 0; } #endif - fill_segment = fill_segment_ref; + fill_segment = argon2_fill_segment_ref; return 0; /* LCOV_EXCL_STOP */ diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-core.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-core.h @@ -214,28 +214,7 @@ static uint32_t index_alpha(const argon2_instance_t *instance, * @return ARGON2_OK if everything is all right, otherwise one of error codes * (all defined in <argon2.h> */ -int validate_inputs(const argon2_context *context); - -/* - * Hashes all the inputs into @a blockhash[PREHASH_DIGEST_LENGTH], clears - * password and secret if needed - * @param context Pointer to the Argon2 internal structure containing memory - * pointer, and parameters for time and space requirements. - * @param blockhash Buffer for pre-hashing digest - * @param type Argon2 type - * @pre @a blockhash must have at least @a PREHASH_DIGEST_LENGTH bytes - * allocated - */ -void initial_hash(uint8_t *blockhash, argon2_context *context, - argon2_type type); - -/* - * Function creates first 2 blocks per lane - * @param instance Pointer to the current instance - * @param blockhash Pointer to the pre-hashing digest - * @pre blockhash must point to @a PREHASH_SEED_LENGTH allocated values - */ -void fill_first_blocks(uint8_t *blockhash, const argon2_instance_t *instance); +int argon2_validate_inputs(const argon2_context *context); /* * Function allocates memory, hashes the inputs with Blake, and creates first @@ -247,12 +226,7 @@ void fill_first_blocks(uint8_t *blockhash, const argon2_instance_t *instance); * @return Zero if successful, -1 if memory failed to allocate. @context->state * will be modified if successful. */ -int initialize(argon2_instance_t *instance, argon2_context *context); - -/* - * Deallocates memory. Used on error path. - */ -void free_instance(argon2_instance_t *instance, int flags); +int argon2_initialize(argon2_instance_t *instance, argon2_context *context); /* * XORing the last block of each lane, hashing it, making the tag. Deallocates @@ -265,7 +239,8 @@ void free_instance(argon2_instance_t *instance, int flags); * @pre if context->free_cbk is not NULL, it should point to a function that * deallocates memory */ -void finalize(const argon2_context *context, argon2_instance_t *instance); +void argon2_finalize(const argon2_context *context, + argon2_instance_t *instance); /* * Function that fills the segment using previous segments also from other @@ -276,15 +251,14 @@ void finalize(const argon2_context *context, argon2_instance_t *instance); */ typedef void (*fill_segment_fn)(const argon2_instance_t *instance, argon2_position_t position); -int argon2_pick_best_implementation(void); -void fill_segment_avx512f(const argon2_instance_t *instance, - argon2_position_t position); -void fill_segment_avx2(const argon2_instance_t *instance, - argon2_position_t position); -void fill_segment_ssse3(const argon2_instance_t *instance, - argon2_position_t position); -void fill_segment_ref(const argon2_instance_t *instance, - argon2_position_t position); +void argon2_fill_segment_avx512f(const argon2_instance_t *instance, + argon2_position_t position); +void argon2_fill_segment_avx2(const argon2_instance_t *instance, + argon2_position_t position); +void argon2_fill_segment_ssse3(const argon2_instance_t *instance, + argon2_position_t position); +void argon2_fill_segment_ref(const argon2_instance_t *instance, + argon2_position_t position); /* * Function that fills the entire memory t_cost times based on the first two @@ -292,6 +266,6 @@ void fill_segment_ref(const argon2_instance_t *instance, * @param instance Pointer to the current instance * @return Zero if successful, -1 if memory failed to allocate */ -void fill_memory_blocks(argon2_instance_t *instance, uint32_t pass); +void argon2_fill_memory_blocks(argon2_instance_t *instance, uint32_t pass); #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-encoding.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-encoding.c @@ -83,7 +83,7 @@ decode_decimal(const char *str, unsigned long *v) * output length must be in the allowed ranges defined in argon2.h. * * The ctx struct must contain buffers large enough to hold the salt and pwd - * when it is fed into decode_string. + * when it is fed into argon2_decode_string. */ /* @@ -91,7 +91,7 @@ decode_decimal(const char *str, unsigned long *v) * Returned value is ARGON2_OK on success. */ int -decode_string(argon2_context *ctx, const char *str, argon2_type type) +argon2_decode_string(argon2_context *ctx, const char *str, argon2_type type) { /* Prefix checking */ #define CC(prefix) \ @@ -193,7 +193,7 @@ decode_string(argon2_context *ctx, const char *str, argon2_type type) BIN(ctx->salt, maxsaltlen, ctx->saltlen); CC("$"); BIN(ctx->out, maxoutlen, ctx->outlen); - validation_result = validate_inputs(ctx); + validation_result = argon2_validate_inputs(ctx); if (validation_result != ARGON2_OK) { return validation_result; } @@ -238,7 +238,8 @@ u32_to_string(char *str, uint32_t x) * On success, ARGON2_OK is returned. */ int -encode_string(char *dst, size_t dst_len, argon2_context *ctx, argon2_type type) +argon2_encode_string(char *dst, size_t dst_len, argon2_context *ctx, + argon2_type type) { #define SS(str) \ do { \ @@ -280,7 +281,7 @@ encode_string(char *dst, size_t dst_len, argon2_context *ctx, argon2_type type) default: return ARGON2_ENCODING_FAIL; } - validation_result = validate_inputs(ctx); + validation_result = argon2_validate_inputs(ctx); if (validation_result != ARGON2_OK) { return validation_result; } diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-encoding.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-encoding.h @@ -17,8 +17,8 @@ * * No other parameters are checked */ -int encode_string(char *dst, size_t dst_len, argon2_context *ctx, - argon2_type type); +int argon2_encode_string(char *dst, size_t dst_len, argon2_context *ctx, + argon2_type type); /* * Decodes an Argon2 hash string into the provided structure 'ctx'. @@ -28,6 +28,7 @@ int encode_string(char *dst, size_t dst_len, argon2_context *ctx, * * Returned value is ARGON2_OK on success. */ -int decode_string(argon2_context *ctx, const char *str, argon2_type type); +int argon2_decode_string(argon2_context *ctx, const char *str, + argon2_type type); #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx2.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx2.c @@ -18,25 +18,24 @@ #include "argon2-core.h" #include "argon2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_AVX2INTRIN_H) && defined(HAVE_EMMINTRIN_H) && \ defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") -# pragma GCC target("avx2") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1,avx2") # endif # ifdef _MSC_VER # include <intrin.h> /* for _mm_set_epi64x */ # endif -#include <emmintrin.h> -#include <immintrin.h> -#include <smmintrin.h> -#include <tmmintrin.h> +# include <emmintrin.h> +# include <immintrin.h> +# include <smmintrin.h> +# include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blamka-round-avx2.h" @@ -141,8 +140,8 @@ generate_addresses(const argon2_instance_t *instance, } void -fill_segment_avx2(const argon2_instance_t *instance, - argon2_position_t position) +argon2_fill_segment_avx2(const argon2_instance_t *instance, + argon2_position_t position) { block *ref_block = NULL, *curr_block = NULL; uint64_t pseudo_rand, ref_index, ref_lane; @@ -236,4 +235,9 @@ fill_segment_avx2(const argon2_instance_t *instance, } } } + +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c @@ -18,26 +18,28 @@ #include "argon2-core.h" #include "argon2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_AVX512FINTRIN_H) && defined(HAVE_AVX2INTRIN_H) && \ defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") -# pragma GCC target("avx2") -# pragma GCC target("avx512f") +# ifdef __clang__ +# if __clang_major__ >= 18 +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2,avx512f,evex512"))), apply_to = function) +# else +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2,avx512f"))), apply_to = function) +# endif +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1,avx2,avx512f") # endif # ifdef _MSC_VER # include <intrin.h> /* for _mm_set_epi64x */ # endif -#include <emmintrin.h> -#include <immintrin.h> -#include <smmintrin.h> -#include <tmmintrin.h> +# include <emmintrin.h> +# include <immintrin.h> +# include <smmintrin.h> +# include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blamka-round-avx512f.h" @@ -146,8 +148,8 @@ generate_addresses(const argon2_instance_t *instance, } void -fill_segment_avx512f(const argon2_instance_t *instance, - argon2_position_t position) +argon2_fill_segment_avx512f(const argon2_instance_t *instance, + argon2_position_t position) { block *ref_block = NULL, *curr_block = NULL; uint64_t pseudo_rand, ref_index, ref_lane; @@ -241,4 +243,9 @@ fill_segment_avx512f(const argon2_instance_t *instance, } } } + +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ref.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ref.c @@ -141,7 +141,8 @@ generate_addresses(const argon2_instance_t *instance, } void -fill_segment_ref(const argon2_instance_t *instance, argon2_position_t position) +argon2_fill_segment_ref(const argon2_instance_t *instance, + argon2_position_t position) { block *ref_block = NULL, *curr_block = NULL; /* Pseudo-random values that determine the reference block position */ diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ssse3.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ssse3.c @@ -18,13 +18,13 @@ #include "argon2-core.h" #include "argon2.h" #include "private/common.h" -#include "private/sse2_64_32.h" #if defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3") # endif # ifdef _MSC_VER @@ -32,6 +32,7 @@ # endif # include <emmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "blamka-round-ssse3.h" @@ -140,8 +141,8 @@ generate_addresses(const argon2_instance_t *instance, } void -fill_segment_ssse3(const argon2_instance_t *instance, - argon2_position_t position) +argon2_fill_segment_ssse3(const argon2_instance_t *instance, + argon2_position_t position) { block *ref_block = NULL, *curr_block = NULL; uint64_t pseudo_rand, ref_index, ref_lane; @@ -235,4 +236,9 @@ fill_segment_ssse3(const argon2_instance_t *instance, } } } + +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2.c @@ -17,6 +17,7 @@ #include <stdlib.h> #include <string.h> +#include "randombytes.h" #include "utils.h" #include "argon2-core.h" @@ -27,7 +28,7 @@ int argon2_ctx(argon2_context *context, argon2_type type) { /* 1. Validate all inputs */ - int result = validate_inputs(context); + int result = argon2_validate_inputs(context); uint32_t memory_blocks, segment_length; uint32_t pass; argon2_instance_t instance; @@ -65,7 +66,7 @@ argon2_ctx(argon2_context *context, argon2_type type) /* 3. Initialization: Hashing inputs, allocating memory, filling first * blocks */ - result = initialize(&instance, context); + result = argon2_initialize(&instance, context); if (ARGON2_OK != result) { return result; @@ -73,11 +74,11 @@ argon2_ctx(argon2_context *context, argon2_type type) /* 4. Filling memory */ for (pass = 0; pass < instance.passes; pass++) { - fill_memory_blocks(&instance, pass); + argon2_fill_memory_blocks(&instance, pass); } /* 5. Finalization */ - finalize(context, &instance); + argon2_finalize(context, &instance); return ARGON2_OK; } @@ -93,6 +94,10 @@ argon2_hash(const uint32_t t_cost, const uint32_t m_cost, int result; uint8_t *out; + if (hash != NULL) { + randombytes_buf(hash, hashlen); + } + if (pwdlen > ARGON2_MAX_PWD_LENGTH) { return ARGON2_PWD_TOO_LONG; } @@ -134,14 +139,10 @@ argon2_hash(const uint32_t t_cost, const uint32_t m_cost, return result; } - /* if raw hash requested, write it */ - if (hash) { - memcpy(hash, out, hashlen); - } - /* if encoding requested, write it */ if (encoded && encodedlen) { - if (encode_string(encoded, encodedlen, &context, type) != ARGON2_OK) { + if (argon2_encode_string(encoded, encodedlen, + &context, type) != ARGON2_OK) { sodium_memzero(out, hashlen); sodium_memzero(encoded, encodedlen); free(out); @@ -149,6 +150,11 @@ argon2_hash(const uint32_t t_cost, const uint32_t m_cost, } } + /* if raw hash requested, write it */ + if (hash) { + memcpy(hash, out, hashlen); + } + sodium_memzero(out, hashlen); free(out); @@ -214,7 +220,7 @@ argon2_verify(const char *encoded, const void *pwd, const size_t pwdlen, ctx.secret = NULL; ctx.secretlen = 0; - /* max values, to be updated in decode_string */ + /* max values, to be updated in argon2_decode_string */ encoded_len = strlen(encoded); if (encoded_len > UINT32_MAX) { return ARGON2_DECODING_LENGTH_FAIL; @@ -240,7 +246,7 @@ argon2_verify(const char *encoded, const void *pwd, const size_t pwdlen, return ARGON2_MEMORY_ALLOCATION_ERROR; } - decode_result = decode_string(&ctx, encoded, type); + decode_result = argon2_decode_string(&ctx, encoded, type); if (decode_result != ARGON2_OK) { free(ctx.ad); free(ctx.salt); @@ -255,7 +261,7 @@ argon2_verify(const char *encoded, const void *pwd, const size_t pwdlen, free(ctx.ad); free(ctx.salt); - if (ret != ARGON2_OK || sodium_memcmp(out, ctx.out, ctx.outlen) != 0) { + if (ret == ARGON2_OK && sodium_memcmp(out, ctx.out, ctx.outlen) != 0) { ret = ARGON2_VERIFY_MISMATCH; } free(out); diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/argon2.h @@ -283,7 +283,7 @@ int argon2_hash(const uint32_t t_cost, const uint32_t m_cost, /** * Verifies a password against an encoded string - * Encoded string is restricted as in validate_inputs() + * Encoded string is restricted as in argon2_validate_inputs() * @param encoded String encoding parameters, salt, hash * @param pwd Pointer to password * @pre Returns ARGON2_OK if successful @@ -292,7 +292,7 @@ int argon2i_verify(const char *encoded, const void *pwd, const size_t pwdlen); /** * Verifies a password against an encoded string - * Encoded string is restricted as in validate_inputs() + * Encoded string is restricted as in argon2_validate_inputs() * @param encoded String encoding parameters, salt, hash * @param pwd Pointer to password * @pre Returns ARGON2_OK if successful diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/blamka-round-ssse3.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/blamka-round-ssse3.h @@ -8,6 +8,9 @@ (_mm_setr_epi8(2, 3, 4, 5, 6, 7, 0, 1, 10, 11, 12, 13, 14, 15, 8, 9)) #define r24 \ (_mm_setr_epi8(3, 4, 5, 6, 7, 0, 1, 2, 11, 12, 13, 14, 15, 8, 9, 10)) + +#if !(defined(_mm_roti_epi64) && defined(__XOP__)) +#undef _mm_roti_epi64 #define _mm_roti_epi64(x, c) \ (-(c) == 32) \ ? _mm_shuffle_epi32((x), _MM_SHUFFLE(2, 3, 0, 1)) \ @@ -20,6 +23,7 @@ _mm_add_epi64((x), (x))) \ : _mm_xor_si128(_mm_srli_epi64((x), -(c)), \ _mm_slli_epi64((x), 64 - (-(c)))) +#endif static inline __m128i fBlaMka(__m128i x, __m128i y) diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/pwhash_argon2i.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/pwhash_argon2i.c @@ -163,6 +163,10 @@ crypto_pwhash_argon2i(unsigned char *const out, unsigned long long outlen, errno = EINVAL; return -1; } + if ((const void *) out == (const void *) passwd) { + errno = EINVAL; + return -1; + } switch (alg) { case crypto_pwhash_argon2i_ALG_ARGON2I13: if (argon2i_hash_raw((uint32_t) opslimit, (uint32_t) (memlimit / 1024U), @@ -210,8 +214,8 @@ crypto_pwhash_argon2i_str(char out[crypto_pwhash_argon2i_STRBYTES], } int -crypto_pwhash_argon2i_str_verify(const char str[crypto_pwhash_argon2i_STRBYTES], - const char *const passwd, +crypto_pwhash_argon2i_str_verify(const char * str, + const char * const passwd, unsigned long long passwdlen) { int verify_ret; @@ -261,7 +265,7 @@ _needs_rehash(const char *str, unsigned long long opslimit, size_t memlimit, ctx.outlen = ctx.pwdlen = ctx.saltlen = (uint32_t) fodder_len; ctx.ad = ctx.secret = NULL; ctx.adlen = ctx.secretlen = 0U; - if (decode_string(&ctx, str, type) != 0) { + if (argon2_decode_string(&ctx, str, type) != 0) { errno = EINVAL; ret = -1; } else if (ctx.t_cost != (uint32_t) opslimit || @@ -276,14 +280,14 @@ _needs_rehash(const char *str, unsigned long long opslimit, size_t memlimit, } int -crypto_pwhash_argon2i_str_needs_rehash(const char str[crypto_pwhash_argon2i_STRBYTES], +crypto_pwhash_argon2i_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) { return _needs_rehash(str, opslimit, memlimit, Argon2_i); } int -crypto_pwhash_argon2id_str_needs_rehash(const char str[crypto_pwhash_argon2id_STRBYTES], +crypto_pwhash_argon2id_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) { return _needs_rehash(str, opslimit, memlimit, Argon2_id); diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/pwhash_argon2id.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/argon2/pwhash_argon2id.c @@ -159,6 +159,10 @@ crypto_pwhash_argon2id(unsigned char *const out, unsigned long long outlen, errno = EINVAL; return -1; } + if ((const void *) out == (const void *) passwd) { + errno = EINVAL; + return -1; + } switch (alg) { case crypto_pwhash_argon2id_ALG_ARGON2ID13: if (argon2id_hash_raw((uint32_t) opslimit, (uint32_t) (memlimit / 1024U), @@ -206,8 +210,8 @@ crypto_pwhash_argon2id_str(char out[crypto_pwhash_argon2id_STRBYTES], } int -crypto_pwhash_argon2id_str_verify(const char str[crypto_pwhash_argon2id_STRBYTES], - const char *const passwd, +crypto_pwhash_argon2id_str_verify(const char * str, + const char * const passwd, unsigned long long passwdlen) { int verify_ret; diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/crypto_pwhash.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/crypto_pwhash.c @@ -172,7 +172,7 @@ crypto_pwhash_str_alg(char out[crypto_pwhash_STRBYTES], } int -crypto_pwhash_str_verify(const char str[crypto_pwhash_STRBYTES], +crypto_pwhash_str_verify(const char * str, const char * const passwd, unsigned long long passwdlen) { @@ -190,7 +190,7 @@ crypto_pwhash_str_verify(const char str[crypto_pwhash_STRBYTES], } int -crypto_pwhash_str_needs_rehash(const char str[crypto_pwhash_STRBYTES], +crypto_pwhash_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) { if (strncmp(str, crypto_pwhash_argon2id_STRPREFIX, diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt-common.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt-common.c @@ -24,6 +24,7 @@ #include "crypto_pwhash_scryptsalsa208sha256.h" #include "crypto_scrypt.h" #include "private/common.h" +#include "randombytes.h" #include "runtime.h" #include "utils.h" @@ -150,6 +151,10 @@ escrypt_r(escrypt_local_t *local, const uint8_t *passwd, size_t passwdlen, uint32_t r; uint32_t p; + if (buf != NULL) { + randombytes_buf(buf, buflen); + } + src = escrypt_parse_setting(setting, &N_log2, &r, &p); if (!src) { return NULL; diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt.h @@ -34,12 +34,6 @@ #include <stddef.h> #include <stdint.h> -#if SIZE_MAX > 0xffffffffULL -#define ARCH_BITS 64 -#else -#define ARCH_BITS 32 -#endif - #define crypto_pwhash_scryptsalsa208sha256_STRPREFIXBYTES 14 #define crypto_pwhash_scryptsalsa208sha256_STRSETTINGBYTES 57 #define crypto_pwhash_scryptsalsa208sha256_STRSALTBYTES 32 @@ -61,38 +55,38 @@ typedef union { typedef escrypt_region_t escrypt_local_t; -extern int escrypt_init_local(escrypt_local_t *__local); +int escrypt_init_local(escrypt_local_t *__local); -extern int escrypt_free_local(escrypt_local_t *__local); +int escrypt_free_local(escrypt_local_t *__local); -extern void *alloc_region(escrypt_region_t *region, size_t size); -extern int free_region(escrypt_region_t *region); +void *escrypt_alloc_region(escrypt_region_t *region, size_t size); +int escrypt_free_region(escrypt_region_t *region); typedef int (*escrypt_kdf_t)(escrypt_local_t *__local, const uint8_t *__passwd, size_t __passwdlen, const uint8_t *__salt, size_t __saltlen, uint64_t __N, uint32_t __r, uint32_t __p, uint8_t *__buf, size_t __buflen); -extern int escrypt_kdf_nosse(escrypt_local_t *__local, const uint8_t *__passwd, - size_t __passwdlen, const uint8_t *__salt, - size_t __saltlen, uint64_t __N, uint32_t __r, - uint32_t __p, uint8_t *__buf, size_t __buflen); +int escrypt_kdf_nosse(escrypt_local_t *__local, const uint8_t *__passwd, + size_t __passwdlen, const uint8_t *__salt, + size_t __saltlen, uint64_t __N, uint32_t __r, + uint32_t __p, uint8_t *__buf, size_t __buflen); -extern int escrypt_kdf_sse(escrypt_local_t *__local, const uint8_t *__passwd, - size_t __passwdlen, const uint8_t *__salt, - size_t __saltlen, uint64_t __N, uint32_t __r, - uint32_t __p, uint8_t *__buf, size_t __buflen); +int escrypt_kdf_sse(escrypt_local_t *__local, const uint8_t *__passwd, + size_t __passwdlen, const uint8_t *__salt, + size_t __saltlen, uint64_t __N, uint32_t __r, + uint32_t __p, uint8_t *__buf, size_t __buflen); -extern uint8_t *escrypt_r(escrypt_local_t *__local, const uint8_t *__passwd, - size_t __passwdlen, const uint8_t *__setting, - uint8_t *__buf, size_t __buflen); +uint8_t *escrypt_r(escrypt_local_t *__local, const uint8_t *__passwd, + size_t __passwdlen, const uint8_t *__setting, + uint8_t *__buf, size_t __buflen); -extern uint8_t *escrypt_gensalt_r(uint32_t __N_log2, uint32_t __r, uint32_t __p, - const uint8_t *__src, size_t __srclen, - uint8_t *__buf, size_t __buflen); +uint8_t *escrypt_gensalt_r(uint32_t __N_log2, uint32_t __r, uint32_t __p, + const uint8_t *__src, size_t __srclen, + uint8_t *__buf, size_t __buflen); -extern const uint8_t *escrypt_parse_setting(const uint8_t *setting, - uint32_t *N_log2_p, uint32_t *r_p, - uint32_t *p_p); +const uint8_t *escrypt_parse_setting(const uint8_t *setting, + uint32_t *N_log2_p, uint32_t *r_p, + uint32_t *p_p); #endif /* !_CRYPTO_SCRYPT_H_ */ diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/nosse/pwhash_scryptsalsa208sha256_nosse.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/nosse/pwhash_scryptsalsa208sha256_nosse.c @@ -39,85 +39,32 @@ #include "private/common.h" static inline void -blkcpy_64(escrypt_block_t *dest, const escrypt_block_t *src) +blkcpy(uint32_t *dest, const uint32_t *src, size_t len) { - int i; - -#if (ARCH_BITS == 32) - for (i = 0; i < 16; ++i) { - dest->w[i] = src->w[i]; - } -#else - for (i = 0; i < 8; ++i) { - dest->d[i] = src->d[i]; - } -#endif -} - -static inline void -blkxor_64(escrypt_block_t *dest, const escrypt_block_t *src) -{ - int i; - -#if (ARCH_BITS == 32) - for (i = 0; i < 16; ++i) { - dest->w[i] ^= src->w[i]; - } -#else - for (i = 0; i < 8; ++i) { - dest->d[i] ^= src->d[i]; - } -#endif + memcpy(dest, src, len * 64); } static inline void -blkcpy(escrypt_block_t *dest, const escrypt_block_t *src, size_t len) +blkxor(uint32_t *dest, const uint32_t *src, size_t len) { - size_t i, L; - -#if (ARCH_BITS == 32) - L = (len >> 2); - for (i = 0; i < L; ++i) { - dest->w[i] = src->w[i]; - } -#else - L = (len >> 3); - for (i = 0; i < L; ++i) { - dest->d[i] = src->d[i]; - } -#endif -} - -static inline void -blkxor(escrypt_block_t *dest, const escrypt_block_t *src, size_t len) -{ - size_t i, L; + size_t i; -#if (ARCH_BITS == 32) - L = (len >> 2); - for (i = 0; i < L; ++i) { - dest->w[i] ^= src->w[i]; + for (i = 0; i < len * 16; i++) { + dest[i] ^= src[i]; } -#else - L = (len >> 3); - for (i = 0; i < L; ++i) { - dest->d[i] ^= src->d[i]; - } -#endif } -/** +/* * salsa20_8(B): * Apply the salsa20/8 core to the provided block. */ static void salsa20_8(uint32_t B[16]) { - escrypt_block_t X; - uint32_t *x = X.w; - size_t i; + uint32_t x[16]; + size_t i; - blkcpy_64(&X, (escrypt_block_t *) B); + blkcpy(x, B, 1); for (i = 0; i < 8; i += 2) { #define R(a, b) (((a) << (b)) | ((a) >> (32 - (b)))) /* Operate on columns. */ @@ -168,11 +115,12 @@ salsa20_8(uint32_t B[16]) } } -/** +/* * blockmix_salsa8(Bin, Bout, X, r): - * Compute Bout = BlockMix_{salsa20/8, r}(Bin). The input Bin must be 128r - * bytes in length; the output Bout must also be the same size. The - * temporary space X must be 64 bytes. + * Compute Bout = BlockMix_{salsa20/8, r}(Bin). + * The input Bin must be 128r bytes in length; + * The output Bout must also be the same size. + * The temporary space X must be 64 bytes. */ static void blockmix_salsa8(const uint32_t *Bin, uint32_t *Bout, uint32_t *X, size_t r) @@ -180,46 +128,41 @@ blockmix_salsa8(const uint32_t *Bin, uint32_t *Bout, uint32_t *X, size_t r) size_t i; /* 1: X <-- B_{2r - 1} */ - blkcpy_64((escrypt_block_t *) X, - (const escrypt_block_t *) &Bin[(2 * r - 1) * 16]); + blkcpy(X, &Bin[(2 * r - 1) * 16], 1); /* 2: for i = 0 to 2r - 1 do */ for (i = 0; i < 2 * r; i += 2) { /* 3: X <-- H(X \xor B_i) */ - blkxor_64((escrypt_block_t *) X, - (const escrypt_block_t *) &Bin[i * 16]); + blkxor(X, &Bin[i * 16], 1); salsa20_8(X); /* 4: Y_i <-- X */ /* 6: B' <-- (Y_0, Y_2 ... Y_{2r-2}, Y_1, Y_3 ... Y_{2r-1}) */ - blkcpy_64((escrypt_block_t *) &Bout[i * 8], - (const escrypt_block_t *) X); + blkcpy(&Bout[i * 8], X, 1); /* 3: X <-- H(X \xor B_i) */ - blkxor_64((escrypt_block_t *) X, - (const escrypt_block_t *) &Bin[i * 16 + 16]); + blkxor(X, &Bin[i * 16 + 16], 1); salsa20_8(X); /* 4: Y_i <-- X */ /* 6: B' <-- (Y_0, Y_2 ... Y_{2r-2}, Y_1, Y_3 ... Y_{2r-1}) */ - blkcpy_64((escrypt_block_t *) &Bout[i * 8 + r * 16], - (escrypt_block_t *) X); + blkcpy(&Bout[i * 8 + r * 16], X, 1); } } -/** +/* * integerify(B, r): * Return the result of parsing B_{2r-1} as a little-endian integer. */ static inline uint64_t -integerify(const void *B, size_t r) +integerify(const uint32_t *B, size_t r) { - const uint32_t *X = (const uint32_t *) ((uintptr_t)(B) + (2 * r - 1) * 64); + const uint32_t *X = B + (2 * r - 1) * 16; - return (((uint64_t)(X[1]) << 32) + X[0]); + return ((uint64_t) (X[1]) << 32) + X[0]; } -/** +/* * smix(B, r, N, V, XY): * Compute B = SMix_r(B, N). The input B must be 128r bytes in length; * the temporary storage V must be 128rN bytes in length; the temporary @@ -244,15 +187,13 @@ smix(uint8_t *B, size_t r, uint64_t N, uint32_t *V, uint32_t *XY) /* 2: for i = 0 to N - 1 do */ for (i = 0; i < N; i += 2) { /* 3: V_i <-- X */ - blkcpy((escrypt_block_t *) &V[i * (32 * r)], (escrypt_block_t *) X, - 128 * r); + blkcpy(&V[i * (32 * r)], X, 2 * r); /* 4: X <-- H(X) */ blockmix_salsa8(X, Y, Z, r); /* 3: V_i <-- X */ - blkcpy((escrypt_block_t *) &V[(i + 1) * (32 * r)], - (escrypt_block_t *) Y, 128 * r); + blkcpy(&V[(i + 1) * (32 * r)], Y, 2 * r); /* 4: X <-- H(X) */ blockmix_salsa8(Y, X, Z, r); @@ -264,16 +205,14 @@ smix(uint8_t *B, size_t r, uint64_t N, uint32_t *V, uint32_t *XY) j = integerify(X, r) & (N - 1); /* 8: X <-- H(X \xor V_j) */ - blkxor((escrypt_block_t *) X, (escrypt_block_t *) &V[j * (32 * r)], - 128 * r); + blkxor(X, &V[j * (32 * r)], 2 * r); blockmix_salsa8(X, Y, Z, r); /* 7: j <-- Integerify(X) mod N */ j = integerify(Y, r) & (N - 1); /* 8: X <-- H(X \xor V_j) */ - blkxor((escrypt_block_t *) Y, (escrypt_block_t *) &V[j * (32 * r)], - 128 * r); + blkxor(Y, &V[j * (32 * r)], 2 * r); blockmix_salsa8(Y, X, Z, r); } /* 10: B' <-- X */ @@ -282,7 +221,7 @@ smix(uint8_t *B, size_t r, uint64_t N, uint32_t *V, uint32_t *XY) } } -/** +/* * escrypt_kdf(local, passwd, passwdlen, salt, saltlen, * N, r, p, buf, buflen): * Compute scrypt(passwd[0 .. passwdlen - 1], salt[0 .. saltlen - 1], N, r, @@ -305,10 +244,6 @@ escrypt_kdf_nosse(escrypt_local_t *local, const uint8_t *passwd, uint32_t i; /* Sanity-check parameters. */ - if (r == 0 || p == 0) { - errno = EINVAL; - return -1; - } #if SIZE_MAX > UINT32_MAX if (buflen > (((uint64_t)(1) << 32) - 1) * 32) { errno = EFBIG; @@ -355,10 +290,10 @@ escrypt_kdf_nosse(escrypt_local_t *local, const uint8_t *passwd, return -1; } if (local->size < need) { - if (free_region(local)) { + if (escrypt_free_region(local)) { return -1; } - if (!alloc_region(local, need)) { + if (!escrypt_alloc_region(local, need)) { return -1; } } @@ -367,7 +302,7 @@ escrypt_kdf_nosse(escrypt_local_t *local, const uint8_t *passwd, XY = (uint32_t *) ((uint8_t *) V + V_size); /* 1: (B_0 ... B_{p-1}) <-- PBKDF2(P, S, 1, p * MFLen) */ - PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, 1, B, B_size); + escrypt_PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, 1, B, B_size); /* 2: for i = 0 to p - 1 do */ for (i = 0; i < p; i++) { @@ -376,7 +311,7 @@ escrypt_kdf_nosse(escrypt_local_t *local, const uint8_t *passwd, } /* 5: DK <-- PBKDF2(P, B, 1, dkLen) */ - PBKDF2_SHA256(passwd, passwdlen, B, B_size, 1, buf, buflen); + escrypt_PBKDF2_SHA256(passwd, passwdlen, B, B_size, 1, buf, buflen); /* Success! */ return 0; diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.c @@ -39,13 +39,14 @@ #include "utils.h" /** - * PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, c, buf, dkLen): + * escrypt_PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, c, buf, dkLen): * Compute PBKDF2(passwd, salt, c, dkLen) using HMAC-SHA256 as the PRF, and * write the output to buf. The value dkLen must be at most 32 * (2^32 - 1). */ void -PBKDF2_SHA256(const uint8_t *passwd, size_t passwdlen, const uint8_t *salt, - size_t saltlen, uint64_t c, uint8_t *buf, size_t dkLen) +escrypt_PBKDF2_SHA256(const uint8_t *passwd, size_t passwdlen, + const uint8_t *salt, size_t saltlen, uint64_t c, + uint8_t *buf, size_t dkLen) { crypto_auth_hmacsha256_state PShctx, hctx; size_t i; diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.h b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.h @@ -35,11 +35,11 @@ #include "crypto_auth_hmacsha256.h" /** - * PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, c, buf, dkLen): + * escrypt_PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, c, buf, dkLen): * Compute PBKDF2(passwd, salt, c, dkLen) using HMAC-SHA256 as the PRF, and * write the output to buf. The value dkLen must be at most 32 * (2^32 - 1). */ -void PBKDF2_SHA256(const uint8_t *, size_t, const uint8_t *, size_t, uint64_t, - uint8_t *, size_t); +void escrypt_PBKDF2_SHA256(const uint8_t *, size_t, const uint8_t *, size_t, + uint64_t, uint8_t *, size_t); #endif /* !_SHA256_H_ */ diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pwhash_scryptsalsa208sha256.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pwhash_scryptsalsa208sha256.c @@ -57,6 +57,7 @@ sodium_strnlen(const char *str, size_t maxlen) { size_t i = 0U; + ACQUIRE_FENCE; while (i < maxlen && str[i] != 0) { i++; } @@ -176,6 +177,10 @@ crypto_pwhash_scryptsalsa208sha256(unsigned char *const out, errno = EINVAL; /* LCOV_EXCL_LINE */ return -1; /* LCOV_EXCL_LINE */ } + if ((const void *) out == (const void *) passwd) { + errno = EINVAL; + return -1; + } return crypto_pwhash_scryptsalsa208sha256_ll( (const uint8_t *) passwd, (size_t) passwdlen, (const uint8_t *) salt, crypto_pwhash_scryptsalsa208sha256_SALTBYTES, (uint64_t)(1) << N_log2, @@ -238,7 +243,7 @@ crypto_pwhash_scryptsalsa208sha256_str( int crypto_pwhash_scryptsalsa208sha256_str_verify( - const char str[crypto_pwhash_scryptsalsa208sha256_STRBYTES], + const char *str, const char *const passwd, unsigned long long passwdlen) { char wanted[crypto_pwhash_scryptsalsa208sha256_STRBYTES]; @@ -268,7 +273,7 @@ crypto_pwhash_scryptsalsa208sha256_str_verify( int crypto_pwhash_scryptsalsa208sha256_str_needs_rehash( - const char str[crypto_pwhash_scryptsalsa208sha256_STRBYTES], + const char * str, unsigned long long opslimit, size_t memlimit) { uint32_t N_log2, N_log2_; diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/scrypt_platform.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/scrypt_platform.c @@ -31,14 +31,18 @@ # define MAP_ANON MAP_ANONYMOUS #endif #ifndef MAP_NOCORE -# define MAP_NOCORE 0 +# ifdef MAP_CONCEAL +# define MAP_NOCORE MAP_CONCEAL +# else +# define MAP_NOCORE 0 +# endif #endif #ifndef MAP_POPULATE # define MAP_POPULATE 0 #endif void * -alloc_region(escrypt_region_t *region, size_t size) +escrypt_alloc_region(escrypt_region_t *region, size_t size) { uint8_t *base, *aligned; #if defined(MAP_ANON) && defined(HAVE_MMAP) @@ -77,7 +81,7 @@ init_region(escrypt_region_t *region) } int -free_region(escrypt_region_t *region) +escrypt_free_region(escrypt_region_t *region) { if (region->base) { #if defined(MAP_ANON) && defined(HAVE_MMAP) @@ -104,5 +108,5 @@ escrypt_init_local(escrypt_local_t *local) int escrypt_free_local(escrypt_local_t *local) { - return free_region(local); + return escrypt_free_region(local); } diff --git a/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/sse/pwhash_scryptsalsa208sha256_sse.c b/subprojects/libsodium/src/libsodium/crypto_pwhash/scryptsalsa208sha256/sse/pwhash_scryptsalsa208sha256_sse.c @@ -35,32 +35,28 @@ #include <string.h> #include "private/common.h" -#include "private/sse2_64_32.h" #ifdef HAVE_EMMINTRIN_H -# ifdef __GNUC__ +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2"))), apply_to = function) +# elif defined(__GNUC__) # pragma GCC target("sse2") # endif + # include <emmintrin.h> -# if defined(__XOP__) && defined(DISABLED) -# include <x86intrin.h> -# endif + +# include "private/sse2_64_32.h" # include "../crypto_scrypt.h" # include "../pbkdf2-sha256.h" -# if defined(__XOP__) && defined(DISABLED) -# define ARX(out, in1, in2, s) \ - out = _mm_xor_si128(out, _mm_roti_epi32(_mm_add_epi32(in1, in2), s)); -# else -# define ARX(out, in1, in2, s) \ +# define ARX(out, in1, in2, s) \ { \ __m128i T = _mm_add_epi32(in1, in2); \ out = _mm_xor_si128(out, _mm_slli_epi32(T, s)); \ out = _mm_xor_si128(out, _mm_srli_epi32(T, 32 - s)); \ } -# endif # define SALSA20_2ROUNDS \ /* Operate on "columns". */ \ @@ -85,7 +81,7 @@ X2 = _mm_shuffle_epi32(X2, 0x4E); \ X3 = _mm_shuffle_epi32(X3, 0x93); -/** +/* * Apply the salsa20/8 core to the block provided in (X0 ... X3) ^ (Z0 ... Z3). */ # define SALSA20_8_XOR(in, out) \ @@ -103,10 +99,11 @@ (out)[3] = X3 = _mm_add_epi32(X3, Y3); \ } -/** +/* * blockmix_salsa8(Bin, Bout, r): - * Compute Bout = BlockMix_{salsa20/8, r}(Bin). The input Bin must be 128r - * bytes in length; the output Bout must also be the same size. + * Compute Bout = BlockMix_{salsa20/8, r}(Bin). + * The input Bin must be 128r bytes in length; + * the output Bout must also be the same size. */ static inline void blockmix_salsa8(const __m128i *Bin, __m128i *Bout, size_t r) @@ -208,18 +205,22 @@ blockmix_salsa8_xor(const __m128i *Bin1, const __m128i *Bin2, __m128i *Bout, # undef XOR4 # undef XOR4_2 -/** +/* * integerify(B, r): * Return the result of parsing B_{2r-1} as a little-endian integer. * Note that B's layout is permuted compared to the generic implementation. */ -static inline uint32_t -integerify(const void *B, size_t r) +static inline uint64_t +integerify(const __m128i *B, size_t r) { - return *(const uint32_t *) ((uintptr_t)(B) + (2 * r - 1) * 64); + const __m128i * X = B + (2*r - 1) * 4; + const uint32_t X0 = (uint32_t) _mm_cvtsi128_si32(X[0]); + const uint32_t X13 = (uint32_t) _mm_cvtsi128_si32(_mm_srli_si128(X[3], 4)); + + return (((uint64_t)(X13) << 32) + X0); } -/** +/* * smix(B, r, N, V, XY): * Compute B = SMix_r(B, N). The input B must be 128r bytes in length; * the temporary storage V must be 128rN bytes in length; the temporary @@ -228,12 +229,12 @@ integerify(const void *B, size_t r) * multiple of 64 bytes. */ static void -smix(uint8_t *B, size_t r, uint32_t N, void *V, void *XY) +smix(uint8_t *B, size_t r, uint64_t N, void *V, void *XY) { size_t s = 128 * r; - __m128i * X = (__m128i *) V, *Y; + __m128i *X = (__m128i *) V, *Y; uint32_t *X32 = (uint32_t *) V; - uint32_t i, j; + uint64_t i, j; size_t k; /* 1: X <-- B */ @@ -295,7 +296,7 @@ smix(uint8_t *B, size_t r, uint32_t N, void *V, void *XY) } } -/** +/* * escrypt_kdf(local, passwd, passwdlen, salt, saltlen, * N, r, p, buf, buflen): * Compute scrypt(passwd[0 .. passwdlen - 1], salt[0 .. saltlen - 1], N, r, @@ -317,10 +318,6 @@ escrypt_kdf_sse(escrypt_local_t *local, const uint8_t *passwd, size_t passwdlen, uint32_t i; /* Sanity-check parameters. */ - if (r == 0 || p == 0) { - errno = EINVAL; - return -1; - } # if SIZE_MAX > UINT32_MAX /* LCOV_EXCL_START */ if (buflen > (((uint64_t)(1) << 32) - 1) * 32) { @@ -375,10 +372,10 @@ escrypt_kdf_sse(escrypt_local_t *local, const uint8_t *passwd, size_t passwdlen, } /* LCOV_EXCL_END */ if (local->size < need) { - if (free_region(local)) { + if (escrypt_free_region(local)) { return -1; /* LCOV_EXCL_LINE */ } - if (!alloc_region(local, need)) { + if (!escrypt_alloc_region(local, need)) { return -1; /* LCOV_EXCL_LINE */ } } @@ -387,18 +384,23 @@ escrypt_kdf_sse(escrypt_local_t *local, const uint8_t *passwd, size_t passwdlen, XY = (uint32_t *) ((uint8_t *) V + V_size); /* 1: (B_0 ... B_{p-1}) <-- PBKDF2(P, S, 1, p * MFLen) */ - PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, 1, B, B_size); + escrypt_PBKDF2_SHA256(passwd, passwdlen, salt, saltlen, 1, B, B_size); /* 2: for i = 0 to p - 1 do */ for (i = 0; i < p; i++) { /* 3: B_i <-- MF(B_i, N) */ - smix(&B[(size_t) 128 * i * r], r, (uint32_t) N, V, XY); + smix(&B[(size_t) 128 * i * r], r, N, V, XY); } /* 5: DK <-- PBKDF2(P, B, 1, dkLen) */ - PBKDF2_SHA256(passwd, passwdlen, B, B_size, 1, buf, buflen); + escrypt_PBKDF2_SHA256(passwd, passwdlen, B, B_size, 1, buf, buflen); /* Success! */ return 0; } + +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/ref10/x25519_ref10.c b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/ref10/x25519_ref10.c @@ -74,7 +74,7 @@ crypto_scalarmult_curve25519_ref10(unsigned char *q, const unsigned char *n, const unsigned char *p) { - unsigned char *t = q; + unsigned char t[32]; unsigned int i; fe25519 x1; fe25519 x2; @@ -123,7 +123,7 @@ crypto_scalarmult_curve25519_ref10(unsigned char *q, fe25519_mul(x2, tmp1, tmp0); fe25519_sub(tmp1, tmp1, tmp0); fe25519_sq(z2, z2); - fe25519_scalar_product(z3, tmp1, 121666); + fe25519_mul32(z3, tmp1, 121666); fe25519_sq(x3, x3); fe25519_add(tmp0, tmp0, z3); fe25519_mul(z3, x1, z2); @@ -136,6 +136,8 @@ crypto_scalarmult_curve25519_ref10(unsigned char *q, fe25519_mul(x2, x2, z2); fe25519_tobytes(q, x2); + sodium_memzero(t, sizeof t); + return 0; } diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/curve25519_sandy2x.c b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/curve25519_sandy2x.c @@ -15,7 +15,6 @@ #include "fe.h" #include "fe51.h" #include "ladder.h" -#include "ladder_base.h" #define x1 var[0] #define x2 var[1] @@ -25,90 +24,48 @@ static int crypto_scalarmult_curve25519_sandy2x(unsigned char *q, const unsigned char *n, const unsigned char *p) { - unsigned char *t = q; - fe var[3]; - fe51 x_51; - fe51 z_51; - unsigned int i; - - for (i = 0; i < 32; i++) { - t[i] = n[i]; - } - t[0] &= 248; - t[31] &= 127; - t[31] |= 64; - - fe_frombytes(x1, p); - - ladder(var, t); - - z_51.v[0] = (z2[1] << 26) + z2[0]; - z_51.v[1] = (z2[3] << 26) + z2[2]; - z_51.v[2] = (z2[5] << 26) + z2[4]; - z_51.v[3] = (z2[7] << 26) + z2[6]; - z_51.v[4] = (z2[9] << 26) + z2[8]; - - x_51.v[0] = (x2[1] << 26) + x2[0]; - x_51.v[1] = (x2[3] << 26) + x2[2]; - x_51.v[2] = (x2[5] << 26) + x2[4]; - x_51.v[3] = (x2[7] << 26) + x2[6]; - x_51.v[4] = (x2[9] << 26) + x2[8]; - - fe51_invert(&z_51, &z_51); - fe51_mul(&x_51, &x_51, &z_51); - fe51_pack(q, &x_51); - - return 0; -} - -#undef x2 -#undef z2 - -#define x2 var[0] -#define z2 var[1] - -static int -crypto_scalarmult_curve25519_sandy2x_base(unsigned char *q, - const unsigned char *n) -{ - unsigned char *t = q; - fe var[3]; - fe51 x_51; - fe51 z_51; - unsigned int i; - - for (i = 0;i < 32; i++) { - t[i] = n[i]; - } - t[0] &= 248; - t[31] &= 127; - t[31] |= 64; - - ladder_base(var, t); - - z_51.v[0] = (z2[1] << 26) + z2[0]; - z_51.v[1] = (z2[3] << 26) + z2[2]; - z_51.v[2] = (z2[5] << 26) + z2[4]; - z_51.v[3] = (z2[7] << 26) + z2[6]; - z_51.v[4] = (z2[9] << 26) + z2[8]; - - x_51.v[0] = (x2[1] << 26) + x2[0]; - x_51.v[1] = (x2[3] << 26) + x2[2]; - x_51.v[2] = (x2[5] << 26) + x2[4]; - x_51.v[3] = (x2[7] << 26) + x2[6]; - x_51.v[4] = (x2[9] << 26) + x2[8]; - - fe51_invert(&z_51, &z_51); - fe51_mul(&x_51, &x_51, &z_51); - fe51_pack(q, &x_51); - - return 0; + unsigned char t[32]; + fe var[3]; + fe51 x_51; + fe51 z_51; + unsigned int i; + + for (i = 0; i < 32; i++) { + t[i] = n[i]; + } + t[0] &= 248; + t[31] &= 127; + t[31] |= 64; + + fe_frombytes(x1, p); + + ladder(var, t); + + z_51.v[0] = (z2[1] << 26) + z2[0]; + z_51.v[1] = (z2[3] << 26) + z2[2]; + z_51.v[2] = (z2[5] << 26) + z2[4]; + z_51.v[3] = (z2[7] << 26) + z2[6]; + z_51.v[4] = (z2[9] << 26) + z2[8]; + + x_51.v[0] = (x2[1] << 26) + x2[0]; + x_51.v[1] = (x2[3] << 26) + x2[2]; + x_51.v[2] = (x2[5] << 26) + x2[4]; + x_51.v[3] = (x2[7] << 26) + x2[6]; + x_51.v[4] = (x2[9] << 26) + x2[8]; + + fe51_invert(&z_51, &z_51); + fe51_mul(&x_51, &x_51, &z_51); + fe51_pack(q, &x_51); + + sodium_memzero(t, sizeof t); + + return 0; } struct crypto_scalarmult_curve25519_implementation crypto_scalarmult_curve25519_sandy2x_implementation = { SODIUM_C99(.mult = ) crypto_scalarmult_curve25519_sandy2x, - SODIUM_C99(.mult_base = ) crypto_scalarmult_curve25519_sandy2x_base + SODIUM_C99(.mult_base = ) NULL }; #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_mul.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_mul.S @@ -3,6 +3,7 @@ /* This file is basically amd64-51/fe25519_mul.s. */ +#include "private/asm_cet.h" #include "fe51_namespace.h" #include "consts_namespace.h" .text @@ -19,6 +20,8 @@ ASM_HIDE_SYMBOL _fe51_mul #endif fe51_mul: _fe51_mul: + +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $96,%r11 diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_nsquare.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_nsquare.S @@ -4,6 +4,7 @@ This file is adapted from amd64-51/fe25519_square.s: Adding loop to perform n squares. */ +#include "private/asm_cet.h" #include "fe51_namespace.h" #include "consts_namespace.h" .p2align 5 @@ -21,6 +22,7 @@ ASM_HIDE_SYMBOL _fe51_nsquare fe51_nsquare: _fe51_nsquare: +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $64,%r11 diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_pack.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_pack.S @@ -4,6 +4,7 @@ This file is the result of merging amd64-51/fe25519_pack.c and amd64-51/fe25519_freeze.s. */ +#include "private/asm_cet.h" #include "fe51_namespace.h" #include "consts_namespace.h" .p2align 5 @@ -21,6 +22,7 @@ ASM_HIDE_SYMBOL _fe51_pack fe51_pack: _fe51_pack: +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $32,%r11 diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c @@ -9,70 +9,70 @@ static uint64_t load_3(const unsigned char *in) { - uint64_t result; - result = (uint64_t) in[0]; - result |= ((uint64_t) in[1]) << 8; - result |= ((uint64_t) in[2]) << 16; - return result; + uint64_t result; + result = (uint64_t) in[0]; + result |= ((uint64_t) in[1]) << 8; + result |= ((uint64_t) in[2]) << 16; + return result; } static uint64_t load_4(const unsigned char *in) { - uint64_t result; - result = (uint64_t) in[0]; - result |= ((uint64_t) in[1]) << 8; - result |= ((uint64_t) in[2]) << 16; - result |= ((uint64_t) in[3]) << 24; - return result; + uint64_t result; + result = (uint64_t) in[0]; + result |= ((uint64_t) in[1]) << 8; + result |= ((uint64_t) in[2]) << 16; + result |= ((uint64_t) in[3]) << 24; + return result; } void fe_frombytes(fe h, const unsigned char *s) { - uint64_t h0 = load_4(s); - uint64_t h1 = load_3(s + 4) << 6; - uint64_t h2 = load_3(s + 7) << 5; - uint64_t h3 = load_3(s + 10) << 3; - uint64_t h4 = load_3(s + 13) << 2; - uint64_t h5 = load_4(s + 16); - uint64_t h6 = load_3(s + 20) << 7; - uint64_t h7 = load_3(s + 23) << 5; - uint64_t h8 = load_3(s + 26) << 4; - uint64_t h9 = (load_3(s + 29) & 8388607) << 2; - uint64_t carry0; - uint64_t carry1; - uint64_t carry2; - uint64_t carry3; - uint64_t carry4; - uint64_t carry5; - uint64_t carry6; - uint64_t carry7; - uint64_t carry8; - uint64_t carry9; + uint64_t h0 = load_4(s); + uint64_t h1 = load_3(s + 4) << 6; + uint64_t h2 = load_3(s + 7) << 5; + uint64_t h3 = load_3(s + 10) << 3; + uint64_t h4 = load_3(s + 13) << 2; + uint64_t h5 = load_4(s + 16); + uint64_t h6 = load_3(s + 20) << 7; + uint64_t h7 = load_3(s + 23) << 5; + uint64_t h8 = load_3(s + 26) << 4; + uint64_t h9 = (load_3(s + 29) & 8388607) << 2; + uint64_t carry0; + uint64_t carry1; + uint64_t carry2; + uint64_t carry3; + uint64_t carry4; + uint64_t carry5; + uint64_t carry6; + uint64_t carry7; + uint64_t carry8; + uint64_t carry9; - carry9 = h9 >> 25; h0 += carry9 * 19; h9 &= 0x1FFFFFF; - carry1 = h1 >> 25; h2 += carry1; h1 &= 0x1FFFFFF; - carry3 = h3 >> 25; h4 += carry3; h3 &= 0x1FFFFFF; - carry5 = h5 >> 25; h6 += carry5; h5 &= 0x1FFFFFF; - carry7 = h7 >> 25; h8 += carry7; h7 &= 0x1FFFFFF; + carry9 = h9 >> 25; h0 += carry9 * 19; h9 &= 0x1FFFFFF; + carry1 = h1 >> 25; h2 += carry1; h1 &= 0x1FFFFFF; + carry3 = h3 >> 25; h4 += carry3; h3 &= 0x1FFFFFF; + carry5 = h5 >> 25; h6 += carry5; h5 &= 0x1FFFFFF; + carry7 = h7 >> 25; h8 += carry7; h7 &= 0x1FFFFFF; - carry0 = h0 >> 26; h1 += carry0; h0 &= 0x3FFFFFF; - carry2 = h2 >> 26; h3 += carry2; h2 &= 0x3FFFFFF; - carry4 = h4 >> 26; h5 += carry4; h4 &= 0x3FFFFFF; - carry6 = h6 >> 26; h7 += carry6; h6 &= 0x3FFFFFF; - carry8 = h8 >> 26; h9 += carry8; h8 &= 0x3FFFFFF; + carry0 = h0 >> 26; h1 += carry0; h0 &= 0x3FFFFFF; + carry2 = h2 >> 26; h3 += carry2; h2 &= 0x3FFFFFF; + carry4 = h4 >> 26; h5 += carry4; h4 &= 0x3FFFFFF; + carry6 = h6 >> 26; h7 += carry6; h6 &= 0x3FFFFFF; + carry8 = h8 >> 26; h9 += carry8; h8 &= 0x3FFFFFF; - h[0] = h0; - h[1] = h1; - h[2] = h2; - h[3] = h3; - h[4] = h4; - h[5] = h5; - h[6] = h6; - h[7] = h7; - h[8] = h8; - h[9] = h9; + h[0] = h0; + h[1] = h1; + h[2] = h2; + h[3] = h3; + h[4] = h4; + h[5] = h5; + h[6] = h6; + h[7] = h7; + h[8] = h8; + h[9] = h9; } #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder.S @@ -1,5 +1,6 @@ #ifdef IN_SANDY2X +#include "private/asm_cet.h" #include "ladder_namespace.h" #include "consts_namespace.h" .p2align 5 @@ -17,6 +18,7 @@ ASM_HIDE_SYMBOL _ladder ladder: _ladder: +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $1856,%r11 diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base.S @@ -1,1295 +0,0 @@ -#ifdef IN_SANDY2X - -#include "ladder_base_namespace.h" -#include "consts_namespace.h" -.p2align 5 - -#ifdef ASM_HIDE_SYMBOL -ASM_HIDE_SYMBOL ladder_base -ASM_HIDE_SYMBOL _ladder_base -#endif -.globl ladder_base -.globl _ladder_base -#ifdef __ELF__ -.type ladder_base, @function -.type _ladder_base, @function -#endif -ladder_base: -_ladder_base: - -mov %rsp,%r11 -and $31,%r11 -add $1568,%r11 -sub %r11,%rsp -movq %r11,1536(%rsp) -movq %r12,1544(%rsp) -movq %r13,1552(%rsp) -vmovdqa v0_0(%rip),%xmm0 -vmovdqa v1_0(%rip),%xmm1 -vmovdqa v9_0(%rip),%xmm2 -vmovdqa %xmm2,0(%rsp) -vmovdqa %xmm0,16(%rsp) -vmovdqa %xmm0,32(%rsp) -vmovdqa %xmm0,48(%rsp) -vmovdqa %xmm0,64(%rsp) -vmovdqa %xmm1,80(%rsp) -vmovdqa %xmm0,96(%rsp) -vmovdqa %xmm0,112(%rsp) -vmovdqa %xmm0,128(%rsp) -vmovdqa %xmm0,144(%rsp) -vmovdqa %xmm1,%xmm0 -vpxor %xmm1,%xmm1,%xmm1 -vpxor %xmm2,%xmm2,%xmm2 -vpxor %xmm3,%xmm3,%xmm3 -vpxor %xmm4,%xmm4,%xmm4 -vpxor %xmm5,%xmm5,%xmm5 -vpxor %xmm6,%xmm6,%xmm6 -vpxor %xmm7,%xmm7,%xmm7 -vpxor %xmm8,%xmm8,%xmm8 -vpxor %xmm9,%xmm9,%xmm9 -movq 0(%rsi),%rdx -movq 8(%rsi),%rcx -movq 16(%rsi),%r8 -movq 24(%rsi),%r9 -shrd $1,%rcx,%rdx -shrd $1,%r8,%rcx -shrd $1,%r9,%r8 -shr $1,%r9 -xorq 0(%rsi),%rdx -xorq 8(%rsi),%rcx -xorq 16(%rsi),%r8 -xorq 24(%rsi),%r9 -leaq 512(%rsp),%rsi -mov $64,%rax - -.p2align 4 -._ladder_base_small_loop: -mov %rdx,%r10 -mov %rcx,%r11 -mov %r8,%r12 -mov %r9,%r13 -shr $1,%rdx -shr $1,%rcx -shr $1,%r8 -shr $1,%r9 -and $1,%r10d -and $1,%r11d -and $1,%r12d -and $1,%r13d -neg %r10 -neg %r11 -neg %r12 -neg %r13 -movl %r10d,0(%rsi) -movl %r11d,256(%rsi) -movl %r12d,512(%rsi) -movl %r13d,768(%rsi) -add $4,%rsi -sub $1,%rax -jne ._ladder_base_small_loop -mov $255,%rdx -add $760,%rsi - -.p2align 4 -._ladder_base_loop: -sub $1,%rdx -vbroadcastss 0(%rsi),%xmm10 -sub $4,%rsi -vmovdqa 0(%rsp),%xmm11 -vmovdqa 80(%rsp),%xmm12 -vpxor %xmm11,%xmm0,%xmm13 -vpand %xmm10,%xmm13,%xmm13 -vpxor %xmm13,%xmm0,%xmm0 -vpxor %xmm13,%xmm11,%xmm11 -vpxor %xmm12,%xmm1,%xmm13 -vpand %xmm10,%xmm13,%xmm13 -vpxor %xmm13,%xmm1,%xmm1 -vpxor %xmm13,%xmm12,%xmm12 -vmovdqa 16(%rsp),%xmm13 -vmovdqa 96(%rsp),%xmm14 -vpxor %xmm13,%xmm2,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm2,%xmm2 -vpxor %xmm15,%xmm13,%xmm13 -vpxor %xmm14,%xmm3,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm3,%xmm3 -vpxor %xmm15,%xmm14,%xmm14 -vmovdqa %xmm13,0(%rsp) -vmovdqa %xmm14,16(%rsp) -vmovdqa 32(%rsp),%xmm13 -vmovdqa 112(%rsp),%xmm14 -vpxor %xmm13,%xmm4,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm4,%xmm4 -vpxor %xmm15,%xmm13,%xmm13 -vpxor %xmm14,%xmm5,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm5,%xmm5 -vpxor %xmm15,%xmm14,%xmm14 -vmovdqa %xmm13,32(%rsp) -vmovdqa %xmm14,80(%rsp) -vmovdqa 48(%rsp),%xmm13 -vmovdqa 128(%rsp),%xmm14 -vpxor %xmm13,%xmm6,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm6,%xmm6 -vpxor %xmm15,%xmm13,%xmm13 -vpxor %xmm14,%xmm7,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm7,%xmm7 -vpxor %xmm15,%xmm14,%xmm14 -vmovdqa %xmm13,48(%rsp) -vmovdqa %xmm14,96(%rsp) -vmovdqa 64(%rsp),%xmm13 -vmovdqa 144(%rsp),%xmm14 -vpxor %xmm13,%xmm8,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm8,%xmm8 -vpxor %xmm15,%xmm13,%xmm13 -vpxor %xmm14,%xmm9,%xmm15 -vpand %xmm10,%xmm15,%xmm15 -vpxor %xmm15,%xmm9,%xmm9 -vpxor %xmm15,%xmm14,%xmm14 -vmovdqa %xmm13,64(%rsp) -vmovdqa %xmm14,112(%rsp) -vpaddq subc0(%rip),%xmm11,%xmm10 -vpsubq %xmm12,%xmm10,%xmm10 -vpaddq %xmm12,%xmm11,%xmm11 -vpunpckhqdq %xmm10,%xmm11,%xmm12 -vpunpcklqdq %xmm10,%xmm11,%xmm10 -vpaddq %xmm1,%xmm0,%xmm11 -vpaddq subc0(%rip),%xmm0,%xmm0 -vpsubq %xmm1,%xmm0,%xmm0 -vpunpckhqdq %xmm11,%xmm0,%xmm1 -vpunpcklqdq %xmm11,%xmm0,%xmm0 -vpmuludq %xmm0,%xmm10,%xmm11 -vpmuludq %xmm1,%xmm10,%xmm13 -vmovdqa %xmm1,128(%rsp) -vpaddq %xmm1,%xmm1,%xmm1 -vpmuludq %xmm0,%xmm12,%xmm14 -vmovdqa %xmm0,144(%rsp) -vpaddq %xmm14,%xmm13,%xmm13 -vpmuludq %xmm1,%xmm12,%xmm0 -vmovdqa %xmm1,160(%rsp) -vpaddq %xmm3,%xmm2,%xmm1 -vpaddq subc2(%rip),%xmm2,%xmm2 -vpsubq %xmm3,%xmm2,%xmm2 -vpunpckhqdq %xmm1,%xmm2,%xmm3 -vpunpcklqdq %xmm1,%xmm2,%xmm1 -vpmuludq %xmm1,%xmm10,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vpmuludq %xmm3,%xmm10,%xmm2 -vmovdqa %xmm3,176(%rsp) -vpaddq %xmm3,%xmm3,%xmm3 -vpmuludq %xmm1,%xmm12,%xmm14 -vmovdqa %xmm1,192(%rsp) -vpaddq %xmm14,%xmm2,%xmm2 -vpmuludq %xmm3,%xmm12,%xmm1 -vmovdqa %xmm3,208(%rsp) -vpaddq %xmm5,%xmm4,%xmm3 -vpaddq subc2(%rip),%xmm4,%xmm4 -vpsubq %xmm5,%xmm4,%xmm4 -vpunpckhqdq %xmm3,%xmm4,%xmm5 -vpunpcklqdq %xmm3,%xmm4,%xmm3 -vpmuludq %xmm3,%xmm10,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vpmuludq %xmm5,%xmm10,%xmm4 -vmovdqa %xmm5,224(%rsp) -vpaddq %xmm5,%xmm5,%xmm5 -vpmuludq %xmm3,%xmm12,%xmm14 -vmovdqa %xmm3,240(%rsp) -vpaddq %xmm14,%xmm4,%xmm4 -vpaddq %xmm7,%xmm6,%xmm3 -vpaddq subc2(%rip),%xmm6,%xmm6 -vpsubq %xmm7,%xmm6,%xmm6 -vpunpckhqdq %xmm3,%xmm6,%xmm7 -vpunpcklqdq %xmm3,%xmm6,%xmm3 -vpmuludq %xmm3,%xmm10,%xmm6 -vpmuludq %xmm5,%xmm12,%xmm14 -vmovdqa %xmm5,256(%rsp) -vpmuludq v19_19(%rip),%xmm5,%xmm5 -vmovdqa %xmm5,272(%rsp) -vpaddq %xmm14,%xmm6,%xmm6 -vpmuludq %xmm7,%xmm10,%xmm5 -vmovdqa %xmm7,288(%rsp) -vpaddq %xmm7,%xmm7,%xmm7 -vpmuludq %xmm3,%xmm12,%xmm14 -vmovdqa %xmm3,304(%rsp) -vpaddq %xmm14,%xmm5,%xmm5 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vmovdqa %xmm3,320(%rsp) -vpaddq %xmm9,%xmm8,%xmm3 -vpaddq subc2(%rip),%xmm8,%xmm8 -vpsubq %xmm9,%xmm8,%xmm8 -vpunpckhqdq %xmm3,%xmm8,%xmm9 -vpunpcklqdq %xmm3,%xmm8,%xmm3 -vmovdqa %xmm3,336(%rsp) -vpmuludq %xmm7,%xmm12,%xmm8 -vmovdqa %xmm7,352(%rsp) -vpmuludq v19_19(%rip),%xmm7,%xmm7 -vmovdqa %xmm7,368(%rsp) -vpmuludq %xmm3,%xmm10,%xmm7 -vpaddq %xmm7,%xmm8,%xmm8 -vpmuludq %xmm9,%xmm10,%xmm7 -vmovdqa %xmm9,384(%rsp) -vpaddq %xmm9,%xmm9,%xmm9 -vpmuludq %xmm3,%xmm12,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vmovdqa %xmm3,400(%rsp) -vpmuludq v19_19(%rip),%xmm12,%xmm12 -vpmuludq %xmm9,%xmm12,%xmm3 -vmovdqa %xmm9,416(%rsp) -vpaddq %xmm3,%xmm11,%xmm11 -vmovdqa 0(%rsp),%xmm3 -vmovdqa 16(%rsp),%xmm9 -vpaddq subc2(%rip),%xmm3,%xmm10 -vpsubq %xmm9,%xmm10,%xmm10 -vpaddq %xmm9,%xmm3,%xmm3 -vpunpckhqdq %xmm10,%xmm3,%xmm9 -vpunpcklqdq %xmm10,%xmm3,%xmm3 -vpmuludq 144(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm0,%xmm0 -vpmuludq 128(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm2,%xmm2 -vpmuludq 192(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpmuludq 176(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm4,%xmm4 -vpmuludq 240(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm6,%xmm6 -vpmuludq 224(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm5,%xmm5 -vpmuludq 304(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpmuludq 288(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vpmuludq 336(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm11,%xmm11 -vpmuludq 384(%rsp),%xmm3,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 144(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpmuludq 160(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm1,%xmm1 -vpmuludq 192(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpmuludq 208(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpmuludq 240(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 256(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm8,%xmm8 -vpmuludq 304(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm9,%xmm9 -vpmuludq 352(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 336(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 416(%rsp),%xmm9,%xmm9 -vpaddq %xmm9,%xmm0,%xmm0 -vmovdqa 32(%rsp),%xmm3 -vmovdqa 80(%rsp),%xmm9 -vpaddq subc2(%rip),%xmm3,%xmm10 -vpsubq %xmm9,%xmm10,%xmm10 -vpaddq %xmm9,%xmm3,%xmm3 -vpunpckhqdq %xmm10,%xmm3,%xmm9 -vpunpcklqdq %xmm10,%xmm3,%xmm3 -vpmuludq 144(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpmuludq 128(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm4,%xmm4 -vpmuludq 192(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm6,%xmm6 -vpmuludq 176(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm5,%xmm5 -vpmuludq 240(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpmuludq 224(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vpmuludq 304(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm11,%xmm11 -vpmuludq 288(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm13,%xmm13 -vpmuludq 336(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm0,%xmm0 -vpmuludq 384(%rsp),%xmm3,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpmuludq 144(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpmuludq 160(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpmuludq 192(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 208(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm8,%xmm8 -vpmuludq 240(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm9,%xmm9 -vpmuludq 256(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 304(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 352(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm0,%xmm0 -vpmuludq 336(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpmuludq 416(%rsp),%xmm9,%xmm9 -vpaddq %xmm9,%xmm1,%xmm1 -vmovdqa 48(%rsp),%xmm3 -vmovdqa 96(%rsp),%xmm9 -vpaddq subc2(%rip),%xmm3,%xmm10 -vpsubq %xmm9,%xmm10,%xmm10 -vpaddq %xmm9,%xmm3,%xmm3 -vpunpckhqdq %xmm10,%xmm3,%xmm9 -vpunpcklqdq %xmm10,%xmm3,%xmm3 -vpmuludq 144(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm6,%xmm6 -vpmuludq 128(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm5,%xmm5 -vpmuludq 192(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpmuludq 176(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vpmuludq 240(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm11,%xmm11 -vpmuludq 224(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm13,%xmm13 -vpmuludq 304(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm0,%xmm0 -vpmuludq 288(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm2,%xmm2 -vpmuludq 336(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpmuludq 384(%rsp),%xmm3,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpmuludq 144(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 160(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm8,%xmm8 -vpmuludq 192(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm9,%xmm9 -vpmuludq 208(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 240(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 256(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm0,%xmm0 -vpmuludq 304(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpmuludq 352(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm1,%xmm1 -vpmuludq 336(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpmuludq 416(%rsp),%xmm9,%xmm9 -vpaddq %xmm9,%xmm6,%xmm6 -vmovdqa 64(%rsp),%xmm3 -vmovdqa 112(%rsp),%xmm9 -vpaddq subc2(%rip),%xmm3,%xmm10 -vpsubq %xmm9,%xmm10,%xmm10 -vpaddq %xmm9,%xmm3,%xmm3 -vpunpckhqdq %xmm10,%xmm3,%xmm9 -vpunpcklqdq %xmm10,%xmm3,%xmm3 -vpmuludq 144(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpmuludq 128(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm3,%xmm3 -vpmuludq 192(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm11,%xmm11 -vpmuludq 176(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm13,%xmm13 -vpmuludq 240(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm0,%xmm0 -vpmuludq 224(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm2,%xmm2 -vpmuludq 304(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpmuludq 288(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm4,%xmm4 -vpmuludq 336(%rsp),%xmm3,%xmm10 -vpaddq %xmm10,%xmm6,%xmm6 -vpmuludq 384(%rsp),%xmm3,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 144(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq v19_19(%rip),%xmm9,%xmm9 -vpmuludq 160(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 192(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 208(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm0,%xmm0 -vpmuludq 240(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpmuludq 256(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm1,%xmm1 -vpmuludq 304(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpmuludq 352(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpmuludq 336(%rsp),%xmm9,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 416(%rsp),%xmm9,%xmm9 -vpaddq %xmm9,%xmm8,%xmm8 -vpsrlq $25,%xmm4,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpand m25(%rip),%xmm4,%xmm4 -vpsrlq $26,%xmm11,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpand m26(%rip),%xmm11,%xmm11 -vpsrlq $26,%xmm6,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpand m26(%rip),%xmm6,%xmm6 -vpsrlq $25,%xmm13,%xmm3 -vpaddq %xmm3,%xmm0,%xmm0 -vpand m25(%rip),%xmm13,%xmm13 -vpsrlq $25,%xmm5,%xmm3 -vpaddq %xmm3,%xmm8,%xmm8 -vpand m25(%rip),%xmm5,%xmm5 -vpsrlq $26,%xmm0,%xmm3 -vpaddq %xmm3,%xmm2,%xmm2 -vpand m26(%rip),%xmm0,%xmm0 -vpsrlq $26,%xmm8,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpand m26(%rip),%xmm8,%xmm8 -vpsrlq $25,%xmm2,%xmm3 -vpaddq %xmm3,%xmm1,%xmm1 -vpand m25(%rip),%xmm2,%xmm2 -vpsrlq $25,%xmm7,%xmm3 -vpsllq $4,%xmm3,%xmm9 -vpaddq %xmm3,%xmm11,%xmm11 -vpsllq $1,%xmm3,%xmm3 -vpaddq %xmm3,%xmm9,%xmm9 -vpaddq %xmm9,%xmm11,%xmm11 -vpand m25(%rip),%xmm7,%xmm7 -vpsrlq $26,%xmm1,%xmm3 -vpaddq %xmm3,%xmm4,%xmm4 -vpand m26(%rip),%xmm1,%xmm1 -vpsrlq $26,%xmm11,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpand m26(%rip),%xmm11,%xmm11 -vpsrlq $25,%xmm4,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpand m25(%rip),%xmm4,%xmm4 -vpunpcklqdq %xmm13,%xmm11,%xmm3 -vpunpckhqdq %xmm13,%xmm11,%xmm9 -vpaddq subc0(%rip),%xmm9,%xmm10 -vpsubq %xmm3,%xmm10,%xmm10 -vpaddq %xmm9,%xmm3,%xmm3 -vpunpckhqdq %xmm3,%xmm10,%xmm9 -vpunpcklqdq %xmm3,%xmm10,%xmm10 -vpmuludq %xmm10,%xmm10,%xmm3 -vpaddq %xmm10,%xmm10,%xmm10 -vpmuludq %xmm9,%xmm10,%xmm11 -vpunpcklqdq %xmm2,%xmm0,%xmm12 -vpunpckhqdq %xmm2,%xmm0,%xmm0 -vpaddq subc2(%rip),%xmm0,%xmm2 -vpsubq %xmm12,%xmm2,%xmm2 -vpaddq %xmm0,%xmm12,%xmm12 -vpunpckhqdq %xmm12,%xmm2,%xmm0 -vpunpcklqdq %xmm12,%xmm2,%xmm2 -vpmuludq %xmm2,%xmm10,%xmm12 -vpaddq %xmm9,%xmm9,%xmm13 -vpmuludq %xmm13,%xmm9,%xmm9 -vpaddq %xmm9,%xmm12,%xmm12 -vpmuludq %xmm0,%xmm10,%xmm9 -vpmuludq %xmm2,%xmm13,%xmm14 -vpaddq %xmm14,%xmm9,%xmm9 -vpunpcklqdq %xmm4,%xmm1,%xmm14 -vpunpckhqdq %xmm4,%xmm1,%xmm1 -vpaddq subc2(%rip),%xmm1,%xmm4 -vpsubq %xmm14,%xmm4,%xmm4 -vpaddq %xmm1,%xmm14,%xmm14 -vpunpckhqdq %xmm14,%xmm4,%xmm1 -vpunpcklqdq %xmm14,%xmm4,%xmm4 -vmovdqa %xmm1,0(%rsp) -vpaddq %xmm1,%xmm1,%xmm1 -vmovdqa %xmm1,16(%rsp) -vpmuludq v19_19(%rip),%xmm1,%xmm1 -vmovdqa %xmm1,32(%rsp) -vpmuludq %xmm4,%xmm10,%xmm1 -vpmuludq %xmm2,%xmm2,%xmm14 -vpaddq %xmm14,%xmm1,%xmm1 -vpmuludq 0(%rsp),%xmm10,%xmm14 -vpmuludq %xmm4,%xmm13,%xmm15 -vpaddq %xmm15,%xmm14,%xmm14 -vpunpcklqdq %xmm5,%xmm6,%xmm15 -vpunpckhqdq %xmm5,%xmm6,%xmm5 -vpaddq subc2(%rip),%xmm5,%xmm6 -vpsubq %xmm15,%xmm6,%xmm6 -vpaddq %xmm5,%xmm15,%xmm15 -vpunpckhqdq %xmm15,%xmm6,%xmm5 -vpunpcklqdq %xmm15,%xmm6,%xmm6 -vmovdqa %xmm6,48(%rsp) -vpmuludq v19_19(%rip),%xmm6,%xmm6 -vmovdqa %xmm6,64(%rsp) -vmovdqa %xmm5,80(%rsp) -vpmuludq v38_38(%rip),%xmm5,%xmm5 -vmovdqa %xmm5,96(%rsp) -vpmuludq 48(%rsp),%xmm10,%xmm5 -vpaddq %xmm0,%xmm0,%xmm6 -vpmuludq %xmm6,%xmm0,%xmm0 -vpaddq %xmm0,%xmm5,%xmm5 -vpmuludq 80(%rsp),%xmm10,%xmm0 -vpmuludq %xmm4,%xmm6,%xmm15 -vpaddq %xmm15,%xmm0,%xmm0 -vpmuludq %xmm6,%xmm13,%xmm15 -vpaddq %xmm15,%xmm1,%xmm1 -vpmuludq %xmm6,%xmm2,%xmm15 -vpaddq %xmm15,%xmm14,%xmm14 -vpunpcklqdq %xmm7,%xmm8,%xmm15 -vpunpckhqdq %xmm7,%xmm8,%xmm7 -vpaddq subc2(%rip),%xmm7,%xmm8 -vpsubq %xmm15,%xmm8,%xmm8 -vpaddq %xmm7,%xmm15,%xmm15 -vpunpckhqdq %xmm15,%xmm8,%xmm7 -vpunpcklqdq %xmm15,%xmm8,%xmm8 -vmovdqa %xmm8,112(%rsp) -vpmuludq v19_19(%rip),%xmm8,%xmm8 -vmovdqa %xmm8,160(%rsp) -vpmuludq 112(%rsp),%xmm10,%xmm8 -vpmuludq %xmm7,%xmm10,%xmm10 -vpmuludq v38_38(%rip),%xmm7,%xmm15 -vpmuludq %xmm15,%xmm7,%xmm7 -vpaddq %xmm7,%xmm8,%xmm8 -vpmuludq %xmm15,%xmm13,%xmm7 -vpaddq %xmm7,%xmm3,%xmm3 -vpmuludq %xmm15,%xmm2,%xmm7 -vpaddq %xmm7,%xmm11,%xmm11 -vpmuludq 80(%rsp),%xmm13,%xmm7 -vpaddq %xmm7,%xmm7,%xmm7 -vpaddq %xmm7,%xmm8,%xmm8 -vpmuludq 16(%rsp),%xmm13,%xmm7 -vpaddq %xmm7,%xmm5,%xmm5 -vpmuludq 48(%rsp),%xmm13,%xmm7 -vpaddq %xmm7,%xmm0,%xmm0 -vpmuludq 112(%rsp),%xmm13,%xmm7 -vpaddq %xmm7,%xmm10,%xmm10 -vpmuludq %xmm15,%xmm6,%xmm7 -vpaddq %xmm7,%xmm12,%xmm12 -vpmuludq %xmm15,%xmm4,%xmm7 -vpaddq %xmm7,%xmm9,%xmm9 -vpaddq %xmm2,%xmm2,%xmm2 -vpmuludq %xmm4,%xmm2,%xmm7 -vpaddq %xmm7,%xmm5,%xmm5 -vpmuludq 160(%rsp),%xmm2,%xmm7 -vpaddq %xmm7,%xmm3,%xmm3 -vpmuludq 160(%rsp),%xmm6,%xmm7 -vpaddq %xmm7,%xmm11,%xmm11 -vpmuludq 0(%rsp),%xmm2,%xmm7 -vpaddq %xmm7,%xmm0,%xmm0 -vpmuludq 48(%rsp),%xmm2,%xmm7 -vpaddq %xmm7,%xmm8,%xmm8 -vpmuludq 80(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 96(%rsp),%xmm4,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpmuludq %xmm4,%xmm4,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpaddq %xmm4,%xmm4,%xmm2 -vpmuludq 160(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm12,%xmm12 -vpmuludq 16(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vpmuludq 48(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm14,%xmm14 -vpmuludq 96(%rsp),%xmm6,%xmm4 -vpaddq %xmm4,%xmm3,%xmm3 -vmovdqa 16(%rsp),%xmm4 -vpmuludq 160(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm9,%xmm9 -vpmuludq 16(%rsp),%xmm6,%xmm4 -vpaddq %xmm4,%xmm8,%xmm8 -vpmuludq 48(%rsp),%xmm6,%xmm4 -vpaddq %xmm4,%xmm10,%xmm10 -vpmuludq 80(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm4,%xmm4 -vpaddq %xmm4,%xmm5,%xmm5 -vpmuludq 112(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm0,%xmm0 -vmovdqa 48(%rsp),%xmm4 -vpaddq %xmm4,%xmm4,%xmm4 -vpmuludq 160(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vmovdqa 80(%rsp),%xmm4 -vpaddq %xmm4,%xmm4,%xmm4 -vpmuludq 160(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm14,%xmm14 -vpmuludq 64(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm3,%xmm3 -vmovdqa 16(%rsp),%xmm4 -vpmuludq 64(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm11,%xmm11 -vmovdqa 16(%rsp),%xmm4 -vpmuludq 96(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm12,%xmm12 -vmovdqa 48(%rsp),%xmm4 -vpmuludq 96(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm9,%xmm9 -vpmuludq 0(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vmovdqa 32(%rsp),%xmm2 -vpmuludq 0(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm3,%xmm3 -vmovdqa 64(%rsp),%xmm2 -vpmuludq 48(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vmovdqa 96(%rsp),%xmm2 -vpmuludq 80(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm1,%xmm1 -vmovdqa 160(%rsp),%xmm2 -vpmuludq 112(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpsrlq $26,%xmm3,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpand m26(%rip),%xmm3,%xmm3 -vpsrlq $25,%xmm14,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpand m25(%rip),%xmm14,%xmm14 -vpsrlq $25,%xmm11,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpand m25(%rip),%xmm11,%xmm11 -vpsrlq $26,%xmm5,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vpand m26(%rip),%xmm5,%xmm5 -vpsrlq $26,%xmm12,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpand m26(%rip),%xmm12,%xmm12 -vpsrlq $25,%xmm0,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpand m25(%rip),%xmm0,%xmm0 -vpsrlq $25,%xmm9,%xmm2 -vpaddq %xmm2,%xmm1,%xmm1 -vpand m25(%rip),%xmm9,%xmm9 -vpsrlq $26,%xmm8,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpand m26(%rip),%xmm8,%xmm8 -vpsrlq $26,%xmm1,%xmm2 -vpaddq %xmm2,%xmm14,%xmm14 -vpand m26(%rip),%xmm1,%xmm1 -vpsrlq $25,%xmm10,%xmm2 -vpsllq $4,%xmm2,%xmm4 -vpaddq %xmm2,%xmm3,%xmm3 -vpsllq $1,%xmm2,%xmm2 -vpaddq %xmm2,%xmm4,%xmm4 -vpaddq %xmm4,%xmm3,%xmm3 -vpand m25(%rip),%xmm10,%xmm10 -vpsrlq $25,%xmm14,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpand m25(%rip),%xmm14,%xmm14 -vpsrlq $26,%xmm3,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpand m26(%rip),%xmm3,%xmm3 -vpunpckhqdq %xmm11,%xmm3,%xmm2 -vmovdqa %xmm2,0(%rsp) -vpunpcklqdq %xmm11,%xmm3,%xmm2 -vpmuludq v9_9(%rip),%xmm2,%xmm2 -vmovdqa %xmm2,80(%rsp) -vpunpckhqdq %xmm9,%xmm12,%xmm2 -vmovdqa %xmm2,16(%rsp) -vpunpcklqdq %xmm9,%xmm12,%xmm2 -vpmuludq v9_9(%rip),%xmm2,%xmm2 -vmovdqa %xmm2,96(%rsp) -vpunpckhqdq %xmm14,%xmm1,%xmm2 -vmovdqa %xmm2,32(%rsp) -vpunpcklqdq %xmm14,%xmm1,%xmm1 -vpmuludq v9_9(%rip),%xmm1,%xmm1 -vmovdqa %xmm1,112(%rsp) -vpunpckhqdq %xmm0,%xmm5,%xmm1 -vmovdqa %xmm1,48(%rsp) -vpunpcklqdq %xmm0,%xmm5,%xmm0 -vpmuludq v9_9(%rip),%xmm0,%xmm0 -vmovdqa %xmm0,160(%rsp) -vpunpckhqdq %xmm10,%xmm8,%xmm0 -vmovdqa %xmm0,64(%rsp) -vpunpcklqdq %xmm10,%xmm8,%xmm0 -vpmuludq v9_9(%rip),%xmm0,%xmm0 -vmovdqa %xmm0,208(%rsp) -vmovdqa 144(%rsp),%xmm0 -vpmuludq %xmm0,%xmm0,%xmm1 -vpaddq %xmm0,%xmm0,%xmm0 -vmovdqa 128(%rsp),%xmm2 -vpmuludq %xmm2,%xmm0,%xmm3 -vmovdqa 192(%rsp),%xmm4 -vpmuludq %xmm4,%xmm0,%xmm5 -vmovdqa 176(%rsp),%xmm6 -vpmuludq %xmm6,%xmm0,%xmm7 -vmovdqa 240(%rsp),%xmm8 -vpmuludq %xmm8,%xmm0,%xmm9 -vpmuludq 224(%rsp),%xmm0,%xmm10 -vpmuludq 304(%rsp),%xmm0,%xmm11 -vpmuludq 288(%rsp),%xmm0,%xmm12 -vpmuludq 336(%rsp),%xmm0,%xmm13 -vmovdqa 384(%rsp),%xmm14 -vpmuludq %xmm14,%xmm0,%xmm0 -vpmuludq v38_38(%rip),%xmm14,%xmm15 -vpmuludq %xmm15,%xmm14,%xmm14 -vpaddq %xmm14,%xmm13,%xmm13 -vpaddq %xmm6,%xmm6,%xmm14 -vpmuludq %xmm14,%xmm6,%xmm6 -vpaddq %xmm6,%xmm11,%xmm11 -vpaddq %xmm2,%xmm2,%xmm6 -vpmuludq %xmm6,%xmm2,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpmuludq %xmm15,%xmm6,%xmm2 -vpaddq %xmm2,%xmm1,%xmm1 -vpmuludq %xmm15,%xmm4,%xmm2 -vpaddq %xmm2,%xmm3,%xmm3 -vpmuludq 256(%rsp),%xmm6,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpmuludq 304(%rsp),%xmm6,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 352(%rsp),%xmm6,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpmuludq 336(%rsp),%xmm6,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vpmuludq %xmm4,%xmm6,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpmuludq %xmm14,%xmm6,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpmuludq %xmm8,%xmm6,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq %xmm15,%xmm14,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpmuludq %xmm15,%xmm8,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpmuludq %xmm4,%xmm4,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpmuludq %xmm14,%xmm4,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpaddq %xmm4,%xmm4,%xmm2 -vpmuludq %xmm8,%xmm2,%xmm4 -vpaddq %xmm4,%xmm11,%xmm11 -vpmuludq 400(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vpmuludq 400(%rsp),%xmm14,%xmm4 -vpaddq %xmm4,%xmm3,%xmm3 -vpmuludq 224(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm12,%xmm12 -vpmuludq 304(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm13,%xmm13 -vpmuludq 288(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vpmuludq 368(%rsp),%xmm8,%xmm2 -vpaddq %xmm2,%xmm3,%xmm3 -vpmuludq %xmm8,%xmm14,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq %xmm8,%xmm8,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpaddq %xmm8,%xmm8,%xmm2 -vpmuludq 400(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm5,%xmm5 -vpmuludq 256(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm9,%xmm9 -vpmuludq 304(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm10,%xmm10 -vpmuludq 368(%rsp),%xmm14,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vmovdqa 256(%rsp),%xmm4 -vpmuludq 400(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm7,%xmm7 -vpmuludq 256(%rsp),%xmm14,%xmm4 -vpaddq %xmm4,%xmm13,%xmm13 -vpmuludq 304(%rsp),%xmm14,%xmm4 -vpaddq %xmm4,%xmm0,%xmm0 -vpmuludq 352(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm11,%xmm11 -vpmuludq 336(%rsp),%xmm15,%xmm4 -vpaddq %xmm4,%xmm12,%xmm12 -vmovdqa 304(%rsp),%xmm4 -vpaddq %xmm4,%xmm4,%xmm4 -vpmuludq 400(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm9,%xmm9 -vpmuludq 320(%rsp),%xmm2,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vmovdqa 256(%rsp),%xmm4 -vpmuludq 320(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm3,%xmm3 -vmovdqa 256(%rsp),%xmm4 -vpmuludq 368(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm5,%xmm5 -vmovdqa 304(%rsp),%xmm4 -vpmuludq 368(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm7,%xmm7 -vmovdqa 352(%rsp),%xmm4 -vpmuludq 400(%rsp),%xmm4,%xmm4 -vpaddq %xmm4,%xmm10,%xmm10 -vpmuludq 224(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vmovdqa 272(%rsp),%xmm2 -vpmuludq 224(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm1,%xmm1 -vmovdqa 320(%rsp),%xmm2 -vpmuludq 304(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vmovdqa 368(%rsp),%xmm2 -vpmuludq 288(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vmovdqa 400(%rsp),%xmm2 -vpmuludq 336(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpsrlq $26,%xmm1,%xmm2 -vpaddq %xmm2,%xmm3,%xmm3 -vpand m26(%rip),%xmm1,%xmm1 -vpsrlq $25,%xmm10,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpand m25(%rip),%xmm10,%xmm10 -vpsrlq $25,%xmm3,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpand m25(%rip),%xmm3,%xmm3 -vpsrlq $26,%xmm11,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpand m26(%rip),%xmm11,%xmm11 -vpsrlq $26,%xmm5,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpand m26(%rip),%xmm5,%xmm5 -vpsrlq $25,%xmm12,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpand m25(%rip),%xmm12,%xmm12 -vpsrlq $25,%xmm7,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpand m25(%rip),%xmm7,%xmm7 -vpsrlq $26,%xmm13,%xmm2 -vpaddq %xmm2,%xmm0,%xmm0 -vpand m26(%rip),%xmm13,%xmm13 -vpsrlq $26,%xmm9,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpand m26(%rip),%xmm9,%xmm9 -vpsrlq $25,%xmm0,%xmm2 -vpsllq $4,%xmm2,%xmm4 -vpaddq %xmm2,%xmm1,%xmm1 -vpsllq $1,%xmm2,%xmm2 -vpaddq %xmm2,%xmm4,%xmm4 -vpaddq %xmm4,%xmm1,%xmm1 -vpand m25(%rip),%xmm0,%xmm0 -vpsrlq $25,%xmm10,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpand m25(%rip),%xmm10,%xmm10 -vpsrlq $26,%xmm1,%xmm2 -vpaddq %xmm2,%xmm3,%xmm3 -vpand m26(%rip),%xmm1,%xmm1 -vpunpckhqdq %xmm3,%xmm1,%xmm2 -vpunpcklqdq %xmm3,%xmm1,%xmm1 -vmovdqa %xmm1,176(%rsp) -vpaddq subc0(%rip),%xmm2,%xmm3 -vpsubq %xmm1,%xmm3,%xmm3 -vpunpckhqdq %xmm3,%xmm2,%xmm1 -vpunpcklqdq %xmm3,%xmm2,%xmm2 -vmovdqa %xmm2,192(%rsp) -vmovdqa %xmm1,224(%rsp) -vpsllq $1,%xmm1,%xmm1 -vmovdqa %xmm1,240(%rsp) -vpmuludq v121666_121666(%rip),%xmm3,%xmm3 -vmovdqa 80(%rsp),%xmm1 -vpunpcklqdq %xmm1,%xmm3,%xmm2 -vpunpckhqdq %xmm1,%xmm3,%xmm1 -vpunpckhqdq %xmm7,%xmm5,%xmm3 -vpunpcklqdq %xmm7,%xmm5,%xmm4 -vmovdqa %xmm4,256(%rsp) -vpaddq subc2(%rip),%xmm3,%xmm5 -vpsubq %xmm4,%xmm5,%xmm5 -vpunpckhqdq %xmm5,%xmm3,%xmm4 -vpunpcklqdq %xmm5,%xmm3,%xmm3 -vmovdqa %xmm3,272(%rsp) -vmovdqa %xmm4,288(%rsp) -vpsllq $1,%xmm4,%xmm4 -vmovdqa %xmm4,304(%rsp) -vpmuludq v121666_121666(%rip),%xmm5,%xmm5 -vmovdqa 96(%rsp),%xmm3 -vpunpcklqdq %xmm3,%xmm5,%xmm4 -vpunpckhqdq %xmm3,%xmm5,%xmm3 -vpunpckhqdq %xmm10,%xmm9,%xmm5 -vpunpcklqdq %xmm10,%xmm9,%xmm6 -vmovdqa %xmm6,320(%rsp) -vpaddq subc2(%rip),%xmm5,%xmm7 -vpsubq %xmm6,%xmm7,%xmm7 -vpunpckhqdq %xmm7,%xmm5,%xmm6 -vpunpcklqdq %xmm7,%xmm5,%xmm5 -vmovdqa %xmm5,336(%rsp) -vmovdqa %xmm6,352(%rsp) -vpsllq $1,%xmm6,%xmm6 -vmovdqa %xmm6,368(%rsp) -vpmuludq v121666_121666(%rip),%xmm7,%xmm7 -vmovdqa 112(%rsp),%xmm5 -vpunpcklqdq %xmm5,%xmm7,%xmm6 -vpunpckhqdq %xmm5,%xmm7,%xmm5 -vpunpckhqdq %xmm12,%xmm11,%xmm7 -vpunpcklqdq %xmm12,%xmm11,%xmm8 -vmovdqa %xmm8,384(%rsp) -vpaddq subc2(%rip),%xmm7,%xmm9 -vpsubq %xmm8,%xmm9,%xmm9 -vpunpckhqdq %xmm9,%xmm7,%xmm8 -vpunpcklqdq %xmm9,%xmm7,%xmm7 -vmovdqa %xmm7,400(%rsp) -vmovdqa %xmm8,416(%rsp) -vpsllq $1,%xmm8,%xmm8 -vmovdqa %xmm8,432(%rsp) -vpmuludq v121666_121666(%rip),%xmm9,%xmm9 -vmovdqa 160(%rsp),%xmm7 -vpunpcklqdq %xmm7,%xmm9,%xmm8 -vpunpckhqdq %xmm7,%xmm9,%xmm7 -vpunpckhqdq %xmm0,%xmm13,%xmm9 -vpunpcklqdq %xmm0,%xmm13,%xmm0 -vmovdqa %xmm0,160(%rsp) -vpaddq subc2(%rip),%xmm9,%xmm10 -vpsubq %xmm0,%xmm10,%xmm10 -vpunpckhqdq %xmm10,%xmm9,%xmm0 -vpunpcklqdq %xmm10,%xmm9,%xmm9 -vmovdqa %xmm9,448(%rsp) -vmovdqa %xmm0,464(%rsp) -vpsllq $1,%xmm0,%xmm0 -vmovdqa %xmm0,480(%rsp) -vpmuludq v121666_121666(%rip),%xmm10,%xmm10 -vmovdqa 208(%rsp),%xmm0 -vpunpcklqdq %xmm0,%xmm10,%xmm9 -vpunpckhqdq %xmm0,%xmm10,%xmm0 -vpsrlq $26,%xmm2,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpand m26(%rip),%xmm2,%xmm2 -vpsrlq $25,%xmm5,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpand m25(%rip),%xmm5,%xmm5 -vpsrlq $25,%xmm1,%xmm10 -vpaddq %xmm10,%xmm4,%xmm4 -vpand m25(%rip),%xmm1,%xmm1 -vpsrlq $26,%xmm8,%xmm10 -vpaddq %xmm10,%xmm7,%xmm7 -vpand m26(%rip),%xmm8,%xmm8 -vpsrlq $26,%xmm4,%xmm10 -vpaddq %xmm10,%xmm3,%xmm3 -vpand m26(%rip),%xmm4,%xmm4 -vpsrlq $25,%xmm7,%xmm10 -vpaddq %xmm10,%xmm9,%xmm9 -vpand m25(%rip),%xmm7,%xmm7 -vpsrlq $25,%xmm3,%xmm10 -vpaddq %xmm10,%xmm6,%xmm6 -vpand m25(%rip),%xmm3,%xmm3 -vpsrlq $26,%xmm9,%xmm10 -vpaddq %xmm10,%xmm0,%xmm0 -vpand m26(%rip),%xmm9,%xmm9 -vpsrlq $26,%xmm6,%xmm10 -vpaddq %xmm10,%xmm5,%xmm5 -vpand m26(%rip),%xmm6,%xmm6 -vpsrlq $25,%xmm0,%xmm10 -vpsllq $4,%xmm10,%xmm11 -vpaddq %xmm10,%xmm2,%xmm2 -vpsllq $1,%xmm10,%xmm10 -vpaddq %xmm10,%xmm11,%xmm11 -vpaddq %xmm11,%xmm2,%xmm2 -vpand m25(%rip),%xmm0,%xmm0 -vpsrlq $25,%xmm5,%xmm10 -vpaddq %xmm10,%xmm8,%xmm8 -vpand m25(%rip),%xmm5,%xmm5 -vpsrlq $26,%xmm2,%xmm10 -vpaddq %xmm10,%xmm1,%xmm1 -vpand m26(%rip),%xmm2,%xmm2 -vpunpckhqdq %xmm1,%xmm2,%xmm10 -vmovdqa %xmm10,80(%rsp) -vpunpcklqdq %xmm1,%xmm2,%xmm1 -vpunpckhqdq %xmm3,%xmm4,%xmm2 -vmovdqa %xmm2,96(%rsp) -vpunpcklqdq %xmm3,%xmm4,%xmm2 -vpunpckhqdq %xmm5,%xmm6,%xmm3 -vmovdqa %xmm3,112(%rsp) -vpunpcklqdq %xmm5,%xmm6,%xmm3 -vpunpckhqdq %xmm7,%xmm8,%xmm4 -vmovdqa %xmm4,128(%rsp) -vpunpcklqdq %xmm7,%xmm8,%xmm4 -vpunpckhqdq %xmm0,%xmm9,%xmm5 -vmovdqa %xmm5,144(%rsp) -vpunpcklqdq %xmm0,%xmm9,%xmm0 -vmovdqa 176(%rsp),%xmm5 -vpaddq %xmm5,%xmm1,%xmm1 -vpunpcklqdq %xmm1,%xmm5,%xmm6 -vpunpckhqdq %xmm1,%xmm5,%xmm1 -vpmuludq 224(%rsp),%xmm6,%xmm5 -vpmuludq 192(%rsp),%xmm1,%xmm7 -vpaddq %xmm7,%xmm5,%xmm5 -vpmuludq 272(%rsp),%xmm6,%xmm7 -vpmuludq 240(%rsp),%xmm1,%xmm8 -vpaddq %xmm8,%xmm7,%xmm7 -vpmuludq 288(%rsp),%xmm6,%xmm8 -vpmuludq 272(%rsp),%xmm1,%xmm9 -vpaddq %xmm9,%xmm8,%xmm8 -vpmuludq 336(%rsp),%xmm6,%xmm9 -vpmuludq 304(%rsp),%xmm1,%xmm10 -vpaddq %xmm10,%xmm9,%xmm9 -vpmuludq 352(%rsp),%xmm6,%xmm10 -vpmuludq 336(%rsp),%xmm1,%xmm11 -vpaddq %xmm11,%xmm10,%xmm10 -vpmuludq 400(%rsp),%xmm6,%xmm11 -vpmuludq 368(%rsp),%xmm1,%xmm12 -vpaddq %xmm12,%xmm11,%xmm11 -vpmuludq 416(%rsp),%xmm6,%xmm12 -vpmuludq 400(%rsp),%xmm1,%xmm13 -vpaddq %xmm13,%xmm12,%xmm12 -vpmuludq 448(%rsp),%xmm6,%xmm13 -vpmuludq 432(%rsp),%xmm1,%xmm14 -vpaddq %xmm14,%xmm13,%xmm13 -vpmuludq 464(%rsp),%xmm6,%xmm14 -vpmuludq 448(%rsp),%xmm1,%xmm15 -vpaddq %xmm15,%xmm14,%xmm14 -vpmuludq 192(%rsp),%xmm6,%xmm6 -vpmuludq v19_19(%rip),%xmm1,%xmm1 -vpmuludq 480(%rsp),%xmm1,%xmm1 -vpaddq %xmm1,%xmm6,%xmm6 -vmovdqa 256(%rsp),%xmm1 -vpaddq %xmm1,%xmm2,%xmm2 -vpunpcklqdq %xmm2,%xmm1,%xmm15 -vpunpckhqdq %xmm2,%xmm1,%xmm1 -vpmuludq 192(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpmuludq 224(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpmuludq 272(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpmuludq 288(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 336(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpmuludq 352(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 400(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpmuludq 416(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm15,%xmm15 -vpmuludq 448(%rsp),%xmm15,%xmm2 -vpaddq %xmm2,%xmm6,%xmm6 -vpmuludq 464(%rsp),%xmm15,%xmm15 -vpaddq %xmm15,%xmm5,%xmm5 -vpmuludq 192(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpmuludq 240(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpmuludq 272(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 304(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpmuludq 336(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 368(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpmuludq 400(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm1,%xmm1 -vpmuludq 432(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm6,%xmm6 -vpmuludq 448(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpmuludq 480(%rsp),%xmm1,%xmm1 -vpaddq %xmm1,%xmm7,%xmm7 -vmovdqa 320(%rsp),%xmm1 -vpaddq %xmm1,%xmm3,%xmm3 -vpunpcklqdq %xmm3,%xmm1,%xmm2 -vpunpckhqdq %xmm3,%xmm1,%xmm1 -vpmuludq 192(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm9,%xmm9 -vpmuludq 224(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm10,%xmm10 -vpmuludq 272(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 288(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm12,%xmm12 -vpmuludq 336(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 352(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm2,%xmm2 -vpmuludq 400(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpmuludq 416(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 448(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq 464(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpmuludq 192(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 240(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm11,%xmm11 -vpmuludq 272(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 304(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpmuludq 336(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm1,%xmm1 -vpmuludq 368(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm6,%xmm6 -vpmuludq 400(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpmuludq 432(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpmuludq 448(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpmuludq 480(%rsp),%xmm1,%xmm1 -vpaddq %xmm1,%xmm9,%xmm9 -vmovdqa 384(%rsp),%xmm1 -vpaddq %xmm1,%xmm4,%xmm4 -vpunpcklqdq %xmm4,%xmm1,%xmm2 -vpunpckhqdq %xmm4,%xmm1,%xmm1 -vpmuludq 192(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm11,%xmm11 -vpmuludq 224(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm12,%xmm12 -vpmuludq 272(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm13,%xmm13 -vpmuludq 288(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm2,%xmm2 -vpmuludq 336(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm6,%xmm6 -vpmuludq 352(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm5,%xmm5 -vpmuludq 400(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm7,%xmm7 -vpmuludq 416(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm8,%xmm8 -vpmuludq 448(%rsp),%xmm2,%xmm3 -vpaddq %xmm3,%xmm9,%xmm9 -vpmuludq 464(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 192(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 240(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm13,%xmm13 -vpmuludq 272(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm1,%xmm1 -vpmuludq 304(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm6,%xmm6 -vpmuludq 336(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm5,%xmm5 -vpmuludq 368(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm7,%xmm7 -vpmuludq 400(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm8,%xmm8 -vpmuludq 432(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm9,%xmm9 -vpmuludq 448(%rsp),%xmm1,%xmm2 -vpaddq %xmm2,%xmm10,%xmm10 -vpmuludq 480(%rsp),%xmm1,%xmm1 -vpaddq %xmm1,%xmm11,%xmm11 -vmovdqa 160(%rsp),%xmm1 -vpaddq %xmm1,%xmm0,%xmm0 -vpunpcklqdq %xmm0,%xmm1,%xmm2 -vpunpckhqdq %xmm0,%xmm1,%xmm0 -vpmuludq 192(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm13,%xmm13 -vpmuludq 224(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm2,%xmm2 -vpmuludq 272(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm6,%xmm6 -vpmuludq 288(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm5,%xmm5 -vpmuludq 336(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm7,%xmm7 -vpmuludq 352(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm8,%xmm8 -vpmuludq 400(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm9,%xmm9 -vpmuludq 416(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm10,%xmm10 -vpmuludq 448(%rsp),%xmm2,%xmm1 -vpaddq %xmm1,%xmm11,%xmm11 -vpmuludq 464(%rsp),%xmm2,%xmm2 -vpaddq %xmm2,%xmm12,%xmm12 -vpmuludq 192(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm14,%xmm14 -vpmuludq v19_19(%rip),%xmm0,%xmm0 -vpmuludq 240(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm6,%xmm6 -vpmuludq 272(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm5,%xmm5 -vpmuludq 304(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm7,%xmm7 -vpmuludq 336(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm8,%xmm8 -vpmuludq 368(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm9,%xmm9 -vpmuludq 400(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm10,%xmm10 -vpmuludq 432(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm11,%xmm11 -vpmuludq 448(%rsp),%xmm0,%xmm1 -vpaddq %xmm1,%xmm12,%xmm12 -vpmuludq 480(%rsp),%xmm0,%xmm0 -vpaddq %xmm0,%xmm13,%xmm13 -vpsrlq $26,%xmm6,%xmm0 -vpaddq %xmm0,%xmm5,%xmm5 -vpand m26(%rip),%xmm6,%xmm6 -vpsrlq $25,%xmm10,%xmm0 -vpaddq %xmm0,%xmm11,%xmm11 -vpand m25(%rip),%xmm10,%xmm10 -vpsrlq $25,%xmm5,%xmm0 -vpaddq %xmm0,%xmm7,%xmm7 -vpand m25(%rip),%xmm5,%xmm5 -vpsrlq $26,%xmm11,%xmm0 -vpaddq %xmm0,%xmm12,%xmm12 -vpand m26(%rip),%xmm11,%xmm11 -vpsrlq $26,%xmm7,%xmm0 -vpaddq %xmm0,%xmm8,%xmm8 -vpand m26(%rip),%xmm7,%xmm7 -vpsrlq $25,%xmm12,%xmm0 -vpaddq %xmm0,%xmm13,%xmm13 -vpand m25(%rip),%xmm12,%xmm12 -vpsrlq $25,%xmm8,%xmm0 -vpaddq %xmm0,%xmm9,%xmm9 -vpand m25(%rip),%xmm8,%xmm8 -vpsrlq $26,%xmm13,%xmm0 -vpaddq %xmm0,%xmm14,%xmm14 -vpand m26(%rip),%xmm13,%xmm13 -vpsrlq $26,%xmm9,%xmm0 -vpaddq %xmm0,%xmm10,%xmm10 -vpand m26(%rip),%xmm9,%xmm9 -vpsrlq $25,%xmm14,%xmm0 -vpsllq $4,%xmm0,%xmm1 -vpaddq %xmm0,%xmm6,%xmm6 -vpsllq $1,%xmm0,%xmm0 -vpaddq %xmm0,%xmm1,%xmm1 -vpaddq %xmm1,%xmm6,%xmm6 -vpand m25(%rip),%xmm14,%xmm14 -vpsrlq $25,%xmm10,%xmm0 -vpaddq %xmm0,%xmm11,%xmm11 -vpand m25(%rip),%xmm10,%xmm10 -vpsrlq $26,%xmm6,%xmm0 -vpaddq %xmm0,%xmm5,%xmm5 -vpand m26(%rip),%xmm6,%xmm6 -vpunpckhqdq %xmm5,%xmm6,%xmm1 -vpunpcklqdq %xmm5,%xmm6,%xmm0 -vpunpckhqdq %xmm8,%xmm7,%xmm3 -vpunpcklqdq %xmm8,%xmm7,%xmm2 -vpunpckhqdq %xmm10,%xmm9,%xmm5 -vpunpcklqdq %xmm10,%xmm9,%xmm4 -vpunpckhqdq %xmm12,%xmm11,%xmm7 -vpunpcklqdq %xmm12,%xmm11,%xmm6 -vpunpckhqdq %xmm14,%xmm13,%xmm9 -vpunpcklqdq %xmm14,%xmm13,%xmm8 -cmp $0,%rdx -jne ._ladder_base_loop -vmovdqu %xmm1,80(%rdi) -vmovdqu %xmm0,0(%rdi) -vmovdqu %xmm3,96(%rdi) -vmovdqu %xmm2,16(%rdi) -vmovdqu %xmm5,112(%rdi) -vmovdqu %xmm4,32(%rdi) -vmovdqu %xmm7,128(%rdi) -vmovdqu %xmm6,48(%rdi) -vmovdqu %xmm9,144(%rdi) -vmovdqu %xmm8,64(%rdi) -movq 1536(%rsp),%r11 -movq 1544(%rsp),%r12 -movq 1552(%rsp),%r13 -add %r11,%rsp -ret - -#endif diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base.h b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base.h @@ -1,18 +0,0 @@ -#ifndef ladder_base_H -#define ladder_base_H - -#ifdef __cplusplus -extern "C" { -#endif - -#include "fe.h" -#include "ladder_base_namespace.h" - -extern void ladder_base(fe *, const unsigned char *); - -#ifdef __cplusplus -} -#endif - -#endif /* ifndef ladder_base_H */ - diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_base_namespace.h @@ -1,8 +0,0 @@ -#ifndef ladder_base_namespace_H -#define ladder_base_namespace_H - -#define ladder_base crypto_scalarmult_curve25519_sandy2x_ladder_base -#define _ladder_base _crypto_scalarmult_curve25519_sandy2x_ladder_base - -#endif /* ifndef ladder_base_namespace_H */ - diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/sandy2x.S b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/sandy2x/sandy2x.S @@ -8,7 +8,6 @@ #include "fe51_nsquare.S" #include "fe51_pack.S" #include "ladder.S" -#include "ladder_base.S" #if defined(__linux__) && defined(__ELF__) .section .note.GNU-stack,"",%progbits diff --git a/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/scalarmult_curve25519.c b/subprojects/libsodium/src/libsodium/crypto_scalarmult/curve25519/scalarmult_curve25519.c @@ -30,7 +30,8 @@ crypto_scalarmult_curve25519(unsigned char *q, const unsigned char *n, int crypto_scalarmult_curve25519_base(unsigned char *q, const unsigned char *n) { - return implementation->mult_base(q, n); + return crypto_scalarmult_curve25519_ref10_implementation + .mult_base(q, n); } size_t diff --git a/subprojects/libsodium/src/libsodium/crypto_secretbox/crypto_secretbox_easy.c b/subprojects/libsodium/src/libsodium/crypto_secretbox/crypto_secretbox_easy.c @@ -101,9 +101,9 @@ crypto_secretbox_open_detached(unsigned char *m, const unsigned char *c, if (m == NULL) { return 0; } - if (((uintptr_t) c >= (uintptr_t) m && + if (((uintptr_t) c > (uintptr_t) m && (uintptr_t) c - (uintptr_t) m < clen) || - ((uintptr_t) m >= (uintptr_t) c && + ((uintptr_t) m > (uintptr_t) c && (uintptr_t) m - (uintptr_t) c < clen)) { /* LCOV_EXCL_LINE */ memmove(m, c, clen); c = m; @@ -121,6 +121,7 @@ crypto_secretbox_open_detached(unsigned char *m, const unsigned char *c, for (i = 0U; i < mlen0; i++) { m[i] = block0[i + crypto_secretbox_ZEROBYTES]; } + sodium_memzero(block0, sizeof block0); if (clen > mlen0) { crypto_stream_salsa20_xor_ic(m + mlen0, c + mlen0, clen - mlen0, n + 16, 1U, subkey); diff --git a/subprojects/libsodium/src/libsodium/crypto_secretbox/xchacha20poly1305/secretbox_xchacha20poly1305.c b/subprojects/libsodium/src/libsodium/crypto_secretbox/xchacha20poly1305/secretbox_xchacha20poly1305.c @@ -108,9 +108,9 @@ crypto_secretbox_xchacha20poly1305_open_detached(unsigned char *m, if (m == NULL) { return 0; } - if (((uintptr_t) c >= (uintptr_t) m && + if (((uintptr_t) c > (uintptr_t) m && (uintptr_t) c - (uintptr_t) m < clen) || - ((uintptr_t) m >= (uintptr_t) c && + ((uintptr_t) m > (uintptr_t) c && (uintptr_t) m - (uintptr_t) c < clen)) { /* LCOV_EXCL_LINE */ memmove(m, c, clen); c = m; diff --git a/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/keypair.c b/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/keypair.c @@ -56,6 +56,7 @@ crypto_sign_ed25519_pk_to_curve25519(unsigned char *curve25519_pk, return -1; } fe25519_1(one_minus_y); + /* assumes A.Z=1 */ fe25519_sub(one_minus_y, one_minus_y, A.Y); fe25519_1(x); fe25519_add(x, x, A.Y); diff --git a/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/open.c b/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/open.c @@ -7,6 +7,7 @@ #include "crypto_sign_ed25519.h" #include "crypto_verify_32.h" #include "sign_ed25519_ref10.h" +#include "private/common.h" #include "private/ed25519_ref10.h" #include "utils.h" @@ -23,6 +24,7 @@ _crypto_sign_ed25519_verify_detached(const unsigned char *sig, ge25519_p3 A; ge25519_p2 R; + ACQUIRE_FENCE; #ifdef ED25519_COMPAT if (sig[63] & 224) { return -1; diff --git a/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/sign.c b/subprojects/libsodium/src/libsodium/crypto_sign/ed25519/ref10/sign.c @@ -33,31 +33,16 @@ _crypto_sign_ed25519_clamp(unsigned char k[32]) } #ifdef ED25519_NONDETERMINISTIC -/* r = hash(B || empty_labelset || Z || pad1 || k || pad2 || empty_labelset || K || extra || M) (mod q) */ +/* r = hash(k || K || noise || pad || M) (mod q) */ static void _crypto_sign_ed25519_synthetic_r_hv(crypto_hash_sha512_state *hs, - unsigned char Z[32], - const unsigned char sk[64]) + unsigned char tmp[64], + const unsigned char az[64]) { - static const unsigned char B[32] = { - 0x58, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, - 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, - 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, - 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, - }; - static const unsigned char zeros[128] = { 0x00 }; - static const unsigned char empty_labelset[3] = { 0x02, 0x00, 0x00 }; - - crypto_hash_sha512_update(hs, B, 32); - crypto_hash_sha512_update(hs, empty_labelset, 3); - randombytes_buf(Z, 32); - crypto_hash_sha512_update(hs, Z, 32); - crypto_hash_sha512_update(hs, zeros, 128 - (32 + 3 + 32) % 128); - crypto_hash_sha512_update(hs, sk, 32); - crypto_hash_sha512_update(hs, zeros, 128 - 32 % 128); - crypto_hash_sha512_update(hs, empty_labelset, 3); - crypto_hash_sha512_update(hs, sk + 32, 32); - /* empty extra */ + crypto_hash_sha512_update(hs, az, 64); + randombytes_buf(tmp, 32); + memset(tmp + 32, 0, 32); + crypto_hash_sha512_update(hs, tmp, 64); } #endif @@ -76,7 +61,7 @@ _crypto_sign_ed25519_detached(unsigned char *sig, unsigned long long *siglen_p, crypto_hash_sha512(az, sk, 32); #ifdef ED25519_NONDETERMINISTIC - _crypto_sign_ed25519_synthetic_r_hv(&hs, nonce /* Z */, az); + _crypto_sign_ed25519_synthetic_r_hv(&hs, nonce /* tmp */, az); #else crypto_hash_sha512_update(&hs, az + 32, 32); #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-avx2.c b/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-avx2.c @@ -6,23 +6,22 @@ #include "core.h" #include "crypto_stream_chacha20.h" #include "private/common.h" -#include "private/sse2_64_32.h" #include "utils.h" #if defined(HAVE_AVX2INTRIN_H) && defined(HAVE_EMMINTRIN_H) && \ defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") -# pragma GCC target("avx2") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1,avx2") # endif # include <emmintrin.h> # include <immintrin.h> # include <smmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "../stream_chacha20.h" # include "chacha20_dolbeau-avx2.h" @@ -174,4 +173,8 @@ struct crypto_stream_chacha20_implementation SODIUM_C99(.stream_ietf_ext_xor_ic =) stream_ietf_ext_ref_xor_ic }; +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-ssse3.c b/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-ssse3.c @@ -6,18 +6,19 @@ #include "core.h" #include "crypto_stream_chacha20.h" #include "private/common.h" -#include "private/sse2_64_32.h" #include "utils.h" #if defined(HAVE_EMMINTRIN_H) && defined(HAVE_TMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3") # endif # include <emmintrin.h> # include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "../stream_chacha20.h" # include "chacha20_dolbeau-ssse3.h" @@ -168,4 +169,8 @@ struct crypto_stream_chacha20_implementation SODIUM_C99(.stream_ietf_ext_xor_ic =) stream_ietf_ext_ref_xor_ic }; +# ifdef __clang__ +# pragma clang attribute pop +# endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/u8.h b/subprojects/libsodium/src/libsodium/crypto_stream/chacha20/dolbeau/u8.h @@ -2,21 +2,6 @@ #define VEC8_ROT(A, IMM) \ _mm256_or_si256(_mm256_slli_epi32(A, IMM), _mm256_srli_epi32(A, (32 - IMM))) -/* implements a vector quarter round by-the-book (naive!) */ -#define VEC8_QUARTERROUND_NAIVE(A, B, C, D) \ - x_##A = _mm256_add_epi32(x_##A, x_##B); \ - t_##A = _mm256_xor_si256(x_##D, x_##A); \ - x_##D = VEC8_ROT(t_##A, 16); \ - x_##C = _mm256_add_epi32(x_##C, x_##D); \ - t_##C = _mm256_xor_si256(x_##B, x_##C); \ - x_##B = VEC8_ROT(t_##C, 12); \ - x_##A = _mm256_add_epi32(x_##A, x_##B); \ - t_##A = _mm256_xor_si256(x_##D, x_##A); \ - x_##D = VEC8_ROT(t_##A, 8); \ - x_##C = _mm256_add_epi32(x_##C, x_##D); \ - t_##C = _mm256_xor_si256(x_##B, x_##C); \ - x_##B = VEC8_ROT(t_##C, 7) - /* same, but replace 2 of the shift/shift/or "rotation" by byte shuffles (8 & * 16) (better) */ #define VEC8_QUARTERROUND_SHUFFLE(A, B, C, D) \ @@ -33,22 +18,6 @@ t_##C = _mm256_xor_si256(x_##B, x_##C); \ x_##B = VEC8_ROT(t_##C, 7) -/* same, but replace 2 of the shift/shift/or "rotation" by byte & word shuffles - * (8 & 16) (not as good as previous) */ -#define VEC8_QUARTERROUND_SHUFFLE2(A, B, C, D) \ - x_##A = _mm256_add_epi32(x_##A, x_##B); \ - t_##A = _mm256_xor_si256(x_##D, x_##A); \ - x_##D = _mm256_shufflehi_epi16(_mm256_shufflelo_epi16(t_##A, 0xb1), 0xb1); \ - x_##C = _mm256_add_epi32(x_##C, x_##D); \ - t_##C = _mm256_xor_si256(x_##B, x_##C); \ - x_##B = VEC8_ROT(t_##C, 12); \ - x_##A = _mm256_add_epi32(x_##A, x_##B); \ - t_##A = _mm256_xor_si256(x_##D, x_##A); \ - x_##D = _mm256_shuffle_epi8(t_##A, rot8); \ - x_##C = _mm256_add_epi32(x_##C, x_##D); \ - t_##C = _mm256_xor_si256(x_##B, x_##C); \ - x_##B = VEC8_ROT(t_##C, 7) - #define VEC8_QUARTERROUND(A, B, C, D) VEC8_QUARTERROUND_SHUFFLE(A, B, C, D) #define VEC8_LINE1(A, B, C, D) \ diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6/salsa20_xmm6-asm.S b/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6/salsa20_xmm6-asm.S @@ -1,5 +1,7 @@ #ifdef HAVE_AMD64_ASM +#include "private/asm_cet.h" + .text .p2align 5 @@ -15,6 +17,8 @@ ASM_HIDE_SYMBOL _stream_salsa20_xmm6 #endif stream_salsa20_xmm6: _stream_salsa20_xmm6: + +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $512,%r11 @@ -56,6 +60,7 @@ ASM_HIDE_SYMBOL _stream_salsa20_xmm6_xor_ic stream_salsa20_xmm6_xor_ic: _stream_salsa20_xmm6_xor_ic: +_CET_ENDBR mov %rsp,%r11 and $31,%r11 add $512,%r11 diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-avx2.c b/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-avx2.c @@ -5,23 +5,22 @@ #include "crypto_stream_salsa20.h" #include "private/common.h" -#include "private/sse2_64_32.h" #include "utils.h" #if defined(HAVE_AVX2INTRIN_H) && defined(HAVE_EMMINTRIN_H) && \ defined(HAVE_TMMINTRIN_H) && defined(HAVE_SMMINTRIN_H) -# ifdef __GNUC__ -# pragma GCC target("sse2") -# pragma GCC target("ssse3") -# pragma GCC target("sse4.1") -# pragma GCC target("avx2") +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2,ssse3,sse4.1,avx2"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("sse2,ssse3,sse4.1,avx2") # endif -#include <emmintrin.h> -#include <immintrin.h> -#include <smmintrin.h> -#include <tmmintrin.h> +# include <emmintrin.h> +# include <immintrin.h> +# include <smmintrin.h> +# include <tmmintrin.h> +# include "private/sse2_64_32.h" # include "../stream_salsa20.h" # include "salsa20_xmm6int-avx2.h" @@ -128,4 +127,8 @@ struct crypto_stream_salsa20_implementation SODIUM_C99(.stream_xor_ic =) stream_avx2_xor_ic }; +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-sse2.c b/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-sse2.c @@ -5,15 +5,17 @@ #include "crypto_stream_salsa20.h" #include "private/common.h" -#include "private/sse2_64_32.h" #include "utils.h" #ifdef HAVE_EMMINTRIN_H -# ifdef __GNUC__ +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("sse2"))), apply_to = function) +# elif defined(__GNUC__) # pragma GCC target("sse2") # endif # include <emmintrin.h> +# include "private/sse2_64_32.h" # include "../stream_salsa20.h" # include "salsa20_xmm6int-sse2.h" @@ -119,4 +121,8 @@ struct crypto_stream_salsa20_implementation SODIUM_C99(.stream_xor_ic =) stream_sse2_xor_ic }; +#ifdef __clang__ +# pragma clang attribute pop +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/u0.h b/subprojects/libsodium/src/libsodium/crypto_stream/salsa20/xmm6int/u0.h @@ -5,7 +5,7 @@ if (bytes > 0) { __m128i diag3 = _mm_loadu_si128((const __m128i *) (x + 12)); __m128i a0, a1, a2, a3, a4, a5, a6, a7; __m128i b0, b1, b2, b3, b4, b5, b6, b7; - uint8_t partialblock[64]; + uint8_t partialblock[64] = { 0 }; unsigned int i; diff --git a/subprojects/libsodium/src/libsodium/crypto_verify/sodium/verify.c b/subprojects/libsodium/src/libsodium/crypto_verify/sodium/verify.c @@ -1,98 +0,0 @@ - -#include <stddef.h> -#include <stdint.h> - -#include "crypto_verify_16.h" -#include "crypto_verify_32.h" -#include "crypto_verify_64.h" - -size_t -crypto_verify_16_bytes(void) -{ - return crypto_verify_16_BYTES; -} - -size_t -crypto_verify_32_bytes(void) -{ - return crypto_verify_32_BYTES; -} - -size_t -crypto_verify_64_bytes(void) -{ - return crypto_verify_64_BYTES; -} - -#if defined(HAVE_EMMINTRIN_H) && defined(__SSE2__) - -# ifdef __GNUC__ -# pragma GCC target("sse2") -# endif -# include <emmintrin.h> - -static inline int -crypto_verify_n(const unsigned char *x_, const unsigned char *y_, - const int n) -{ - const __m128i zero = _mm_setzero_si128(); - volatile __m128i v1, v2, z; - volatile int m; - int i; - - const volatile __m128i *volatile x = - (const volatile __m128i *volatile) (const void *) x_; - const volatile __m128i *volatile y = - (const volatile __m128i *volatile) (const void *) y_; - v1 = _mm_loadu_si128((const __m128i *) &x[0]); - v2 = _mm_loadu_si128((const __m128i *) &y[0]); - z = _mm_xor_si128(v1, v2); - for (i = 1; i < n / 16; i++) { - v1 = _mm_loadu_si128((const __m128i *) &x[i]); - v2 = _mm_loadu_si128((const __m128i *) &y[i]); - z = _mm_or_si128(z, _mm_xor_si128(v1, v2)); - } - m = _mm_movemask_epi8(_mm_cmpeq_epi32(z, zero)); - v1 = zero; v2 = zero; z = zero; - - return (int) (((uint32_t) m + 1U) >> 16) - 1; -} - -#else - -static inline int -crypto_verify_n(const unsigned char *x_, const unsigned char *y_, - const int n) -{ - const volatile unsigned char *volatile x = - (const volatile unsigned char *volatile) x_; - const volatile unsigned char *volatile y = - (const volatile unsigned char *volatile) y_; - volatile uint_fast16_t d = 0U; - int i; - - for (i = 0; i < n; i++) { - d |= x[i] ^ y[i]; - } - return (1 & ((d - 1) >> 8)) - 1; -} - -#endif - -int -crypto_verify_16(const unsigned char *x, const unsigned char *y) -{ - return crypto_verify_n(x, y, crypto_verify_16_BYTES); -} - -int -crypto_verify_32(const unsigned char *x, const unsigned char *y) -{ - return crypto_verify_n(x, y, crypto_verify_32_BYTES); -} - -int -crypto_verify_64(const unsigned char *x, const unsigned char *y) -{ - return crypto_verify_n(x, y, crypto_verify_64_BYTES); -} diff --git a/subprojects/libsodium/src/libsodium/crypto_verify/verify.c b/subprojects/libsodium/src/libsodium/crypto_verify/verify.c @@ -0,0 +1,103 @@ + +#include <stddef.h> +#include <stdint.h> + +#include "crypto_verify_16.h" +#include "crypto_verify_32.h" +#include "crypto_verify_64.h" + +size_t +crypto_verify_16_bytes(void) +{ + return crypto_verify_16_BYTES; +} + +size_t +crypto_verify_32_bytes(void) +{ + return crypto_verify_32_BYTES; +} + +size_t +crypto_verify_64_bytes(void) +{ + return crypto_verify_64_BYTES; +} + +#if defined(HAVE_EMMINTRIN_H) && defined(__SSE2__) + +# include <emmintrin.h> + +static inline int +crypto_verify_n(const unsigned char *x_, const unsigned char *y_, + const int n) +{ + const __m128i zero = _mm_setzero_si128(); + volatile __m128i v1, v2, z; + volatile int m; + int i; + + const volatile __m128i *volatile x = + (const volatile __m128i *volatile) (const void *) x_; + const volatile __m128i *volatile y = + (const volatile __m128i *volatile) (const void *) y_; + v1 = _mm_loadu_si128((const __m128i *) &x[0]); + v2 = _mm_loadu_si128((const __m128i *) &y[0]); + z = _mm_xor_si128(v1, v2); + for (i = 1; i < n / 16; i++) { + v1 = _mm_loadu_si128((const __m128i *) &x[i]); + v2 = _mm_loadu_si128((const __m128i *) &y[i]); + z = _mm_or_si128(z, _mm_xor_si128(v1, v2)); + } + m = _mm_movemask_epi8(_mm_cmpeq_epi32(z, zero)); + v1 = zero; v2 = zero; z = zero; + + return (int) (((uint32_t) m + 1U) >> 16) - 1; +} + +#else + +static volatile uint16_t optblocker_u16; + +static inline int +crypto_verify_n(const unsigned char *x_, const unsigned char *y_, + const int n) +{ + const volatile unsigned char *volatile x = + (const volatile unsigned char *volatile) x_; + const volatile unsigned char *volatile y = + (const volatile unsigned char *volatile) y_; + volatile uint16_t d = 0U; + int i; + + for (i = 0; i < n; i++) { + d |= x[i] ^ y[i]; + } +# ifdef HAVE_INLINE_ASM + __asm__ __volatile__("" : "+r"(d) :); +# endif + d--; + d = ((d >> 13) ^ optblocker_u16) >> 2; + + return (int) d - 1; +} + +#endif + +int +crypto_verify_16(const unsigned char *x, const unsigned char *y) +{ + return crypto_verify_n(x, y, crypto_verify_16_BYTES); +} + +int +crypto_verify_32(const unsigned char *x, const unsigned char *y) +{ + return crypto_verify_n(x, y, crypto_verify_32_BYTES); +} + +int +crypto_verify_64(const unsigned char *x, const unsigned char *y) +{ + return crypto_verify_n(x, y, crypto_verify_64_BYTES); +} diff --git a/subprojects/libsodium/src/libsodium/include/Makefile.am b/subprojects/libsodium/src/libsodium/include/Makefile.am @@ -3,6 +3,8 @@ SODIUM_EXPORT = \ sodium.h \ sodium/core.h \ sodium/crypto_aead_aes256gcm.h \ + sodium/crypto_aead_aegis128l.h \ + sodium/crypto_aead_aegis256.h \ sodium/crypto_aead_chacha20poly1305.h \ sodium/crypto_aead_xchacha20poly1305.h \ sodium/crypto_auth.h \ @@ -25,6 +27,8 @@ SODIUM_EXPORT = \ sodium/crypto_hash_sha256.h \ sodium/crypto_hash_sha512.h \ sodium/crypto_kdf.h \ + sodium/crypto_kdf_hkdf_sha256.h \ + sodium/crypto_kdf_hkdf_sha512.h \ sodium/crypto_kdf_blake2b.h \ sodium/crypto_kx.h \ sodium/crypto_onetimeauth.h \ diff --git a/subprojects/libsodium/src/libsodium/include/Makefile.in b/subprojects/libsodium/src/libsodium/include/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -70,6 +70,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -88,9 +90,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = src/libsodium/include ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -149,13 +153,16 @@ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ + { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \ } am__installdirs = "$(DESTDIR)$(includedir)" "$(DESTDIR)$(includedir)" HEADERS = $(nobase_include_HEADERS) $(nobase_nodist_include_HEADERS) +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -173,8 +180,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ @@ -182,7 +187,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -194,6 +198,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -206,6 +211,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -222,8 +229,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -266,6 +275,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -291,8 +301,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -326,11 +338,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -340,6 +357,8 @@ SODIUM_EXPORT = \ sodium.h \ sodium/core.h \ sodium/crypto_aead_aes256gcm.h \ + sodium/crypto_aead_aegis128l.h \ + sodium/crypto_aead_aegis256.h \ sodium/crypto_aead_chacha20poly1305.h \ sodium/crypto_aead_xchacha20poly1305.h \ sodium/crypto_auth.h \ @@ -362,6 +381,8 @@ SODIUM_EXPORT = \ sodium/crypto_hash_sha256.h \ sodium/crypto_hash_sha512.h \ sodium/crypto_kdf.h \ + sodium/crypto_kdf_hkdf_sha256.h \ + sodium/crypto_kdf_hkdf_sha512.h \ sodium/crypto_kdf_blake2b.h \ sodium/crypto_kx.h \ sodium/crypto_onetimeauth.h \ @@ -493,6 +514,11 @@ uninstall-nobase_nodist_includeHEADERS: @list='$(nobase_nodist_include_HEADERS)'; test -n "$(includedir)" || list=; \ $(am__nobase_strip_setup); files=`$(am__nobase_strip)`; \ dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir) +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -610,12 +636,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-am + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-am + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-am + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-am + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-am + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am @@ -686,14 +732,18 @@ uninstall-am: uninstall-nobase_includeHEADERS \ .MAKE: install-am install-strip -.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ - clean-libtool cscopelist-am ctags ctags-am distclean \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man \ - install-nobase_includeHEADERS \ +.PHONY: CTAGS GTAGS TAGS all all-am check check-am check-valgrind-am \ + check-valgrind-drd-am check-valgrind-drd-local \ + check-valgrind-helgrind-am check-valgrind-helgrind-local \ + check-valgrind-local check-valgrind-memcheck-am \ + check-valgrind-memcheck-local check-valgrind-sgcheck-am \ + check-valgrind-sgcheck-local clean clean-generic clean-libtool \ + cscopelist-am ctags ctags-am distclean distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-nobase_includeHEADERS \ install-nobase_nodist_includeHEADERS install-pdf \ install-pdf-am install-ps install-ps-am install-strip \ installcheck installcheck-am installdirs maintainer-clean \ @@ -708,3 +758,10 @@ uninstall-am: uninstall-nobase_includeHEADERS \ # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/src/libsodium/include/sodium.h b/subprojects/libsodium/src/libsodium/include/sodium.h @@ -5,6 +5,8 @@ #include "sodium/version.h" #include "sodium/core.h" +#include "sodium/crypto_aead_aegis128l.h" +#include "sodium/crypto_aead_aegis256.h" #include "sodium/crypto_aead_aes256gcm.h" #include "sodium/crypto_aead_chacha20poly1305.h" #include "sodium/crypto_aead_xchacha20poly1305.h" @@ -14,8 +16,8 @@ #include "sodium/crypto_auth_hmacsha512256.h" #include "sodium/crypto_box.h" #include "sodium/crypto_box_curve25519xsalsa20poly1305.h" -#include "sodium/crypto_core_hsalsa20.h" #include "sodium/crypto_core_hchacha20.h" +#include "sodium/crypto_core_hsalsa20.h" #include "sodium/crypto_core_salsa20.h" #include "sodium/crypto_core_salsa2012.h" #include "sodium/crypto_core_salsa208.h" @@ -25,7 +27,11 @@ #include "sodium/crypto_hash_sha256.h" #include "sodium/crypto_hash_sha512.h" #include "sodium/crypto_kdf.h" +#include "sodium/crypto_kdf_hkdf_sha256.h" +#include "sodium/crypto_kdf_hkdf_sha512.h" #include "sodium/crypto_kdf_blake2b.h" +#include "sodium/crypto_kdf_hkdf_sha256.h" +#include "sodium/crypto_kdf_hkdf_sha512.h" #include "sodium/crypto_kx.h" #include "sodium/crypto_onetimeauth.h" #include "sodium/crypto_onetimeauth_poly1305.h" @@ -54,16 +60,16 @@ #include "sodium/utils.h" #ifndef SODIUM_LIBRARY_MINIMAL -# include "sodium/crypto_box_curve25519xchacha20poly1305.h" -# include "sodium/crypto_core_ed25519.h" -# include "sodium/crypto_core_ristretto255.h" -# include "sodium/crypto_scalarmult_ed25519.h" -# include "sodium/crypto_scalarmult_ristretto255.h" -# include "sodium/crypto_secretbox_xchacha20poly1305.h" -# include "sodium/crypto_pwhash_scryptsalsa208sha256.h" -# include "sodium/crypto_stream_salsa2012.h" -# include "sodium/crypto_stream_salsa208.h" -# include "sodium/crypto_stream_xchacha20.h" +#include "sodium/crypto_box_curve25519xchacha20poly1305.h" +#include "sodium/crypto_core_ed25519.h" +#include "sodium/crypto_core_ristretto255.h" +#include "sodium/crypto_pwhash_scryptsalsa208sha256.h" +#include "sodium/crypto_scalarmult_ed25519.h" +#include "sodium/crypto_scalarmult_ristretto255.h" +#include "sodium/crypto_secretbox_xchacha20poly1305.h" +#include "sodium/crypto_stream_salsa2012.h" +#include "sodium/crypto_stream_salsa208.h" +#include "sodium/crypto_stream_xchacha20.h" #endif #endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_aead_aegis128l.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_aead_aegis128l.h @@ -0,0 +1,92 @@ +#ifndef crypto_aead_aegis128l_H +#define crypto_aead_aegis128l_H + +#include <stddef.h> + +#include "export.h" + +#ifdef __cplusplus +#ifdef __GNUC__ +#pragma GCC diagnostic ignored "-Wlong-long" +#endif +extern "C" { +#endif + +#define crypto_aead_aegis128l_KEYBYTES 16U +SODIUM_EXPORT +size_t crypto_aead_aegis128l_keybytes(void); + +#define crypto_aead_aegis128l_NSECBYTES 0U +SODIUM_EXPORT +size_t crypto_aead_aegis128l_nsecbytes(void); + +#define crypto_aead_aegis128l_NPUBBYTES 16U +SODIUM_EXPORT +size_t crypto_aead_aegis128l_npubbytes(void); + +#define crypto_aead_aegis128l_ABYTES 32U +SODIUM_EXPORT +size_t crypto_aead_aegis128l_abytes(void); + +#define crypto_aead_aegis128l_MESSAGEBYTES_MAX \ + SODIUM_MIN(SODIUM_SIZE_MAX - crypto_aead_aegis128l_ABYTES, (1ULL << 61) - 1) +SODIUM_EXPORT +size_t crypto_aead_aegis128l_messagebytes_max(void); + +SODIUM_EXPORT +int crypto_aead_aegis128l_encrypt(unsigned char *c, + unsigned long long *clen_p, + const unsigned char *m, + unsigned long long mlen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *nsec, + const unsigned char *npub, + const unsigned char *k) __attribute__((nonnull(1, 8, 9))); + +SODIUM_EXPORT +int crypto_aead_aegis128l_decrypt(unsigned char *m, + unsigned long long *mlen_p, + unsigned char *nsec, + const unsigned char *c, + unsigned long long clen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *npub, + const unsigned char *k) __attribute__((warn_unused_result)) +__attribute__((nonnull(4, 8, 9))); + +SODIUM_EXPORT +int crypto_aead_aegis128l_encrypt_detached(unsigned char *c, + unsigned char *mac, + unsigned long long *maclen_p, + const unsigned char *m, + unsigned long long mlen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *nsec, + const unsigned char *npub, + const unsigned char *k) + __attribute__((nonnull(1, 2, 9, 10))); + +SODIUM_EXPORT +int crypto_aead_aegis128l_decrypt_detached(unsigned char *m, + unsigned char *nsec, + const unsigned char *c, + unsigned long long clen, + const unsigned char *mac, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *npub, + const unsigned char *k) + __attribute__((warn_unused_result)) __attribute__((nonnull(3, 5, 8, 9))); + +SODIUM_EXPORT +void crypto_aead_aegis128l_keygen(unsigned char k[crypto_aead_aegis128l_KEYBYTES]) + __attribute__((nonnull)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_aead_aegis256.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_aead_aegis256.h @@ -0,0 +1,92 @@ +#ifndef crypto_aead_aegis256_H +#define crypto_aead_aegis256_H + +#include <stddef.h> + +#include "export.h" + +#ifdef __cplusplus +#ifdef __GNUC__ +#pragma GCC diagnostic ignored "-Wlong-long" +#endif +extern "C" { +#endif + +#define crypto_aead_aegis256_KEYBYTES 32U +SODIUM_EXPORT +size_t crypto_aead_aegis256_keybytes(void); + +#define crypto_aead_aegis256_NSECBYTES 0U +SODIUM_EXPORT +size_t crypto_aead_aegis256_nsecbytes(void); + +#define crypto_aead_aegis256_NPUBBYTES 32U +SODIUM_EXPORT +size_t crypto_aead_aegis256_npubbytes(void); + +#define crypto_aead_aegis256_ABYTES 32U +SODIUM_EXPORT +size_t crypto_aead_aegis256_abytes(void); + +#define crypto_aead_aegis256_MESSAGEBYTES_MAX \ + SODIUM_MIN(SODIUM_SIZE_MAX - crypto_aead_aegis256_ABYTES, (1ULL << 61) - 1) +SODIUM_EXPORT +size_t crypto_aead_aegis256_messagebytes_max(void); + +SODIUM_EXPORT +int crypto_aead_aegis256_encrypt(unsigned char *c, + unsigned long long *clen_p, + const unsigned char *m, + unsigned long long mlen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *nsec, + const unsigned char *npub, + const unsigned char *k) __attribute__((nonnull(1, 8, 9))); + +SODIUM_EXPORT +int crypto_aead_aegis256_decrypt(unsigned char *m, + unsigned long long *mlen_p, + unsigned char *nsec, + const unsigned char *c, + unsigned long long clen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *npub, + const unsigned char *k) __attribute__((warn_unused_result)) +__attribute__((nonnull(4, 8, 9))); + +SODIUM_EXPORT +int crypto_aead_aegis256_encrypt_detached(unsigned char *c, + unsigned char *mac, + unsigned long long *maclen_p, + const unsigned char *m, + unsigned long long mlen, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *nsec, + const unsigned char *npub, + const unsigned char *k) + __attribute__((nonnull(1, 2, 9, 10))); + +SODIUM_EXPORT +int crypto_aead_aegis256_decrypt_detached(unsigned char *m, + unsigned char *nsec, + const unsigned char *c, + unsigned long long clen, + const unsigned char *mac, + const unsigned char *ad, + unsigned long long adlen, + const unsigned char *npub, + const unsigned char *k) + __attribute__((warn_unused_result)) __attribute__((nonnull(3, 5, 8, 9))); + +SODIUM_EXPORT +void crypto_aead_aegis256_keygen(unsigned char k[crypto_aead_aegis256_KEYBYTES]) + __attribute__((nonnull)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_core_ed25519.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_core_ed25519.h @@ -48,7 +48,7 @@ int crypto_core_ed25519_from_uniform(unsigned char *p, const unsigned char *r) SODIUM_EXPORT int crypto_core_ed25519_from_hash(unsigned char *p, const unsigned char *h) - __attribute__ ((nonnull)); + __attribute__ ((nonnull)) __attribute__ ((deprecated)); SODIUM_EXPORT void crypto_core_ed25519_random(unsigned char *p) diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_generichash_blake2b.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_generichash_blake2b.h @@ -14,7 +14,9 @@ extern "C" { #endif -#if defined(__IBMC__) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) +#ifdef __IBMC__ +# pragma pack(1) +#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC) # pragma pack(1) #else # pragma pack(push, 1) @@ -24,7 +26,9 @@ typedef struct CRYPTO_ALIGN(64) crypto_generichash_blake2b_state { unsigned char opaque[384]; } crypto_generichash_blake2b_state; -#if defined(__IBMC__) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) +#ifdef __IBMC__ +# pragma pack(pop) +#elif defined(__SUNPRO_C) || defined(__SUNPRO_CC) # pragma pack() #else # pragma pack(pop) diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash.h @@ -2,7 +2,7 @@ #define crypto_hash_H /* - * WARNING: Unless you absolutely need to use SHA512 for interoperatibility, + * WARNING: Unless you absolutely need to use SHA512 for interoperability, * purposes, you might want to consider crypto_generichash() instead. * Unlike SHA512, crypto_generichash() is not vulnerable to length * extension attacks. diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash_sha256.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash_sha256.h @@ -2,7 +2,7 @@ #define crypto_hash_sha256_H /* - * WARNING: Unless you absolutely need to use SHA256 for interoperatibility, + * WARNING: Unless you absolutely need to use SHA256 for interoperability, * purposes, you might want to consider crypto_generichash() instead. * Unlike SHA256, crypto_generichash() is not vulnerable to length * extension attacks. diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash_sha512.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_hash_sha512.h @@ -2,7 +2,7 @@ #define crypto_hash_sha512_H /* - * WARNING: Unless you absolutely need to use SHA512 for interoperatibility, + * WARNING: Unless you absolutely need to use SHA512 for interoperability, * purposes, you might want to consider crypto_generichash() instead. * Unlike SHA512, crypto_generichash() is not vulnerable to length * extension attacks. diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_blake2b.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_blake2b.h @@ -3,8 +3,8 @@ #include <stddef.h> #include <stdint.h> +#include <stdlib.h> -#include "crypto_kdf_blake2b.h" #include "export.h" #ifdef __cplusplus diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_hkdf_sha256.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_hkdf_sha256.h @@ -0,0 +1,74 @@ +#ifndef crypto_kdf_hkdf_sha256_H +#define crypto_kdf_hkdf_sha256_H + +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> + +#include "crypto_kdf.h" +#include "crypto_auth_hmacsha256.h" +#include "export.h" + +#ifdef __cplusplus +# ifdef __GNUC__ +# pragma GCC diagnostic ignored "-Wlong-long" +# endif +extern "C" { +#endif + +#define crypto_kdf_hkdf_sha256_KEYBYTES crypto_auth_hmacsha256_BYTES +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha256_keybytes(void); + +#define crypto_kdf_hkdf_sha256_BYTES_MIN 0U +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha256_bytes_min(void); + +#define crypto_kdf_hkdf_sha256_BYTES_MAX (0xff * crypto_auth_hmacsha256_BYTES) +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha256_bytes_max(void); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha256_extract(unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES], + const unsigned char *salt, size_t salt_len, + const unsigned char *ikm, size_t ikm_len) + __attribute__ ((nonnull(4))); + +SODIUM_EXPORT +void crypto_kdf_hkdf_sha256_keygen(unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha256_expand(unsigned char *out, size_t out_len, + const char *ctx, size_t ctx_len, + const unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]) + __attribute__ ((nonnull(1))); + +/* ------------------------------------------------------------------------- */ + +typedef struct crypto_kdf_hkdf_sha256_state { + crypto_auth_hmacsha256_state st; +} crypto_kdf_hkdf_sha256_state; + +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha256_statebytes(void); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha256_extract_init(crypto_kdf_hkdf_sha256_state *state, + const unsigned char *salt, size_t salt_len) + __attribute__ ((nonnull(1))); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha256_extract_update(crypto_kdf_hkdf_sha256_state *state, + const unsigned char *ikm, size_t ikm_len) + __attribute__ ((nonnull)); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha256_extract_final(crypto_kdf_hkdf_sha256_state *state, + unsigned char prk[crypto_kdf_hkdf_sha256_KEYBYTES]) + __attribute__ ((nonnull)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_hkdf_sha512.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_kdf_hkdf_sha512.h @@ -0,0 +1,75 @@ +#ifndef crypto_kdf_hkdf_sha512_H +#define crypto_kdf_hkdf_sha512_H + +#include <stddef.h> +#include <stdint.h> +#include <stdlib.h> + +#include "crypto_kdf.h" +#include "crypto_auth_hmacsha512.h" +#include "export.h" + +#ifdef __cplusplus +# ifdef __GNUC__ +# pragma GCC diagnostic ignored "-Wlong-long" +# endif +extern "C" { +#endif + +#define crypto_kdf_hkdf_sha512_KEYBYTES crypto_auth_hmacsha512_BYTES +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha512_keybytes(void); + +#define crypto_kdf_hkdf_sha512_BYTES_MIN 0U +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha512_bytes_min(void); + +#define crypto_kdf_hkdf_sha512_BYTES_MAX (0xff * crypto_auth_hmacsha512_BYTES) +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha512_bytes_max(void); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha512_extract(unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES], + const unsigned char *salt, size_t salt_len, + const unsigned char *ikm, size_t ikm_len) + __attribute__ ((nonnull(1))); + +SODIUM_EXPORT +void crypto_kdf_hkdf_sha512_keygen(unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) + __attribute__ ((nonnull)); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha512_expand(unsigned char *out, size_t out_len, + const char *ctx, size_t ctx_len, + const unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) + __attribute__ ((nonnull(1))); + +/* ------------------------------------------------------------------------- */ + +typedef struct crypto_kdf_hkdf_sha512_state { + crypto_auth_hmacsha512_state st; +} crypto_kdf_hkdf_sha512_state; + +SODIUM_EXPORT +size_t crypto_kdf_hkdf_sha512_statebytes(void); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha512_extract_init(crypto_kdf_hkdf_sha512_state *state, + const unsigned char *salt, size_t salt_len) + __attribute__ ((nonnull(1))); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha512_extract_update(crypto_kdf_hkdf_sha512_state *state, + const unsigned char *ikm, size_t ikm_len) + __attribute__ ((nonnull)); + +SODIUM_EXPORT +int crypto_kdf_hkdf_sha512_extract_final(crypto_kdf_hkdf_sha512_state *state, + unsigned char prk[crypto_kdf_hkdf_sha512_KEYBYTES]) + __attribute__ ((nonnull)); + +#ifdef __cplusplus +} +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_onetimeauth_poly1305.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_onetimeauth_poly1305.h @@ -1,13 +1,6 @@ #ifndef crypto_onetimeauth_poly1305_H #define crypto_onetimeauth_poly1305_H -#ifdef __cplusplus -# ifdef __GNUC__ -# pragma GCC diagnostic ignored "-Wlong-long" -# endif -extern "C" { -#endif - #include <stdint.h> #include <stdio.h> #include <stdlib.h> @@ -16,6 +9,13 @@ extern "C" { #include "export.h" +#ifdef __cplusplus +# ifdef __GNUC__ +# pragma GCC diagnostic ignored "-Wlong-long" +# endif +extern "C" { +#endif + typedef struct CRYPTO_ALIGN(16) crypto_onetimeauth_poly1305_state { unsigned char opaque[256]; } crypto_onetimeauth_poly1305_state; diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash.h @@ -125,17 +125,17 @@ int crypto_pwhash_str_alg(char out[crypto_pwhash_STRBYTES], __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_str_verify(const char str[crypto_pwhash_STRBYTES], +int crypto_pwhash_str_verify(const char *str, const char * const passwd, unsigned long long passwdlen) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_str_needs_rehash(const char str[crypto_pwhash_STRBYTES], +int crypto_pwhash_str_needs_rehash(const char *str, unsigned long long opslimit, size_t memlimit) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); -#define crypto_pwhash_PRIMITIVE "argon2i" +#define crypto_pwhash_PRIMITIVE "argon2id,argon2i" SODIUM_EXPORT const char *crypto_pwhash_primitive(void) __attribute__ ((warn_unused_result)); diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_argon2i.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_argon2i.h @@ -105,13 +105,13 @@ int crypto_pwhash_argon2i_str(char out[crypto_pwhash_argon2i_STRBYTES], __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_argon2i_str_verify(const char str[crypto_pwhash_argon2i_STRBYTES], +int crypto_pwhash_argon2i_str_verify(const char * str, const char * const passwd, unsigned long long passwdlen) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_argon2i_str_needs_rehash(const char str[crypto_pwhash_argon2i_STRBYTES], +int crypto_pwhash_argon2i_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_argon2id.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_argon2id.h @@ -105,13 +105,13 @@ int crypto_pwhash_argon2id_str(char out[crypto_pwhash_argon2id_STRBYTES], __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_argon2id_str_verify(const char str[crypto_pwhash_argon2id_STRBYTES], +int crypto_pwhash_argon2id_str_verify(const char * str, const char * const passwd, unsigned long long passwdlen) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_argon2id_str_needs_rehash(const char str[crypto_pwhash_argon2id_STRBYTES], +int crypto_pwhash_argon2id_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); diff --git a/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_scryptsalsa208sha256.h b/subprojects/libsodium/src/libsodium/include/sodium/crypto_pwhash_scryptsalsa208sha256.h @@ -95,7 +95,7 @@ int crypto_pwhash_scryptsalsa208sha256_str(char out[crypto_pwhash_scryptsalsa208 __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_scryptsalsa208sha256_str_verify(const char str[crypto_pwhash_scryptsalsa208sha256_STRBYTES], +int crypto_pwhash_scryptsalsa208sha256_str_verify(const char * str, const char * const passwd, unsigned long long passwdlen) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); @@ -108,7 +108,7 @@ int crypto_pwhash_scryptsalsa208sha256_ll(const uint8_t * passwd, size_t passwdl __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); SODIUM_EXPORT -int crypto_pwhash_scryptsalsa208sha256_str_needs_rehash(const char str[crypto_pwhash_scryptsalsa208sha256_STRBYTES], +int crypto_pwhash_scryptsalsa208sha256_str_needs_rehash(const char * str, unsigned long long opslimit, size_t memlimit) __attribute__ ((warn_unused_result)) __attribute__ ((nonnull)); diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/asm_cet.h b/subprojects/libsodium/src/libsodium/include/sodium/private/asm_cet.h @@ -0,0 +1,11 @@ +#ifndef asm_cet_H +#define asm_cet_H 1 + +#if HAVE_CET_H +# include <cet.h> +#endif +#ifndef _CET_ENDBR +# define _CET_ENDBR +#endif + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/common.h b/subprojects/libsodium/src/libsodium/include/sodium/private/common.h @@ -3,17 +3,17 @@ #if !defined(_MSC_VER) && !defined(DEV_MODE) && 0 # warning *** This is unstable, untested, development code. -# warning It might not compile. It might not work as expected. -# warning It might be totally insecure. -# warning Do not use this except if you are planning to contribute code. -# warning Use releases available at https://download.libsodium.org/libsodium/releases/ instead. -# warning Alternatively, use the "stable" branch in the git repository. +# warning *** It might not compile. It might not work as expected. +# warning *** It might be totally insecure. +# warning *** Do not use this except if you are planning to contribute code. +# warning *** Use releases available at https://download.libsodium.org/libsodium/releases/ instead. +# warning *** Alternatively, use the "stable" branch in the git repository. #endif #if !defined(_MSC_VER) && (!defined(CONFIGURED) || CONFIGURED != 1) # warning *** The library is being compiled using an undocumented method. -# warning This is not supported. It has not been tested, it might not -# warning work as expected, and performance is likely to be suboptimal. +# warning *** This is not supported. It has not been tested, it might not +# warning *** work as expected, and performance is likely to be suboptimal. #endif #include <stdint.h> @@ -30,34 +30,45 @@ typedef unsigned uint128_t __attribute__((mode(TI))); # endif #endif -#define ROTL32(X, B) rotl32((X), (B)) +#ifdef _MSC_VER + +# define ROTL32(X, B) _rotl((X), (B)) +# define ROTL64(X, B) _rotl64((X), (B)) +# define ROTR32(X, B) _rotr((X), (B)) +# define ROTR64(X, B) _rotr64((X), (B)) + +#else + +# define ROTL32(X, B) rotl32((X), (B)) static inline uint32_t rotl32(const uint32_t x, const int b) { return (x << b) | (x >> (32 - b)); } -#define ROTL64(X, B) rotl64((X), (B)) +# define ROTL64(X, B) rotl64((X), (B)) static inline uint64_t rotl64(const uint64_t x, const int b) { return (x << b) | (x >> (64 - b)); } -#define ROTR32(X, B) rotr32((X), (B)) +# define ROTR32(X, B) rotr32((X), (B)) static inline uint32_t rotr32(const uint32_t x, const int b) { return (x >> b) | (x << (32 - b)); } -#define ROTR64(X, B) rotr64((X), (B)) +# define ROTR64(X, B) rotr64((X), (B)) static inline uint64_t rotr64(const uint64_t x, const int b) { return (x >> b) | (x << (64 - b)); } +#endif /* _MSC_VER */ + #define LOAD64_LE(SRC) load64_le(SRC) static inline uint64_t load64_le(const uint8_t src[8]) @@ -226,24 +237,40 @@ xor_buf(unsigned char *out, const unsigned char *in, size_t n) # endif #endif -#if defined(_MSC_VER) && \ - (defined(_M_X64) || defined(_M_AMD64) || defined(_M_IX86)) +#ifdef _MSC_VER -# include <intrin.h> +# if defined(_M_X64) || defined(_M_IX86) +# include <intrin.h> + +# define HAVE_INTRIN_H 1 +# define HAVE_MMINTRIN_H 1 +# define HAVE_EMMINTRIN_H 1 +# define HAVE_PMMINTRIN_H 1 +# define HAVE_TMMINTRIN_H 1 +# define HAVE_SMMINTRIN_H 1 +# define HAVE_AVXINTRIN_H 1 +# if _MSC_VER >= 1600 +# define HAVE_WMMINTRIN_H 1 +# endif +# if _MSC_VER >= 1700 && defined(_M_X64) +# define HAVE_AVX2INTRIN_H 1 +# endif +# if _MSC_VER >= 1910 && defined(_M_X64) +# define HAVE_AVX512FINTRIN_H 1 +# endif + +# elif defined(_M_ARM64) + +# ifndef __ARM_ARCH +# define __ARM_ARCH 1 +# endif +# ifndef __ARM_NEON +# define __ARM_NEON 1 +# endif +# define HAVE_ARMCRYPTO 1 + +# endif /* _MSC_VER */ -# define HAVE_INTRIN_H 1 -# define HAVE_MMINTRIN_H 1 -# define HAVE_EMMINTRIN_H 1 -# define HAVE_PMMINTRIN_H 1 -# define HAVE_TMMINTRIN_H 1 -# define HAVE_SMMINTRIN_H 1 -# define HAVE_AVXINTRIN_H 1 -# if _MSC_VER >= 1600 -# define HAVE_WMMINTRIN_H 1 -# endif -# if _MSC_VER >= 1700 && defined(_M_X64) -# define HAVE_AVX2INTRIN_H 1 -# endif #elif defined(HAVE_INTRIN_H) # include <intrin.h> #endif @@ -258,4 +285,12 @@ extern void ct_unpoison(const void *, size_t); # define UNPOISON(X, L) (void) 0 #endif +#ifdef HAVE_GCC_MEMORY_FENCES +# define ACQUIRE_FENCE __atomic_thread_fence(__ATOMIC_ACQUIRE) +#elif defined(HAVE_C11_MEMORY_FENCES) +# define ACQUIRE_FENCE atomic_thread_fence(memory_order_acquire) +#else +# define ACQUIRE_FENCE (void) 0 +#endif + #endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/ed25519_ref10_fe_25_5.h b/subprojects/libsodium/src/libsodium/include/sodium/private/ed25519_ref10_fe_25_5.h @@ -273,27 +273,7 @@ fe25519_cswap(fe25519 f, fe25519 g, unsigned int b) static inline void fe25519_copy(fe25519 h, const fe25519 f) { - int32_t f0 = f[0]; - int32_t f1 = f[1]; - int32_t f2 = f[2]; - int32_t f3 = f[3]; - int32_t f4 = f[4]; - int32_t f5 = f[5]; - int32_t f6 = f[6]; - int32_t f7 = f[7]; - int32_t f8 = f[8]; - int32_t f9 = f[9]; - - h[0] = f0; - h[1] = f1; - h[2] = f2; - h[3] = f3; - h[4] = f4; - h[5] = f5; - h[6] = f6; - h[7] = f7; - h[8] = f8; - h[9] = f9; + memcpy(h, f, 10 * sizeof h[0]); } /* @@ -978,8 +958,8 @@ fe25519_sq2(fe25519 h, const fe25519 f) h[9] = (int32_t) h9; } -static void -fe25519_scalar_product(fe25519 h, const fe25519 f, uint32_t n) +static inline void +fe25519_mul32(fe25519 h, const fe25519 f, uint32_t n) { int64_t sn = (int64_t) n; int32_t f0 = f[0]; diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/ed25519_ref10_fe_51.h b/subprojects/libsodium/src/libsodium/include/sodium/private/ed25519_ref10_fe_51.h @@ -191,17 +191,7 @@ fe25519_cswap(fe25519 f, fe25519 g, unsigned int b) static inline void fe25519_copy(fe25519 h, const fe25519 f) { - uint64_t f0 = f[0]; - uint64_t f1 = f[1]; - uint64_t f2 = f[2]; - uint64_t f3 = f[3]; - uint64_t f4 = f[4]; - - h[0] = f0; - h[1] = f1; - h[2] = f2; - h[3] = f3; - h[4] = f4; + memcpy(h, f, 5 * sizeof h[0]); } /* @@ -489,8 +479,8 @@ fe25519_sq2(fe25519 h, const fe25519 f) h[4] = r04; } -static void -fe25519_scalar_product(fe25519 h, const fe25519 f, uint32_t n) +static inline void +fe25519_mul32(fe25519 h, const fe25519 f, uint32_t n) { const uint64_t mask = 0x7ffffffffffffULL; uint128_t a; diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/implementations.h b/subprojects/libsodium/src/libsodium/include/sodium/private/implementations.h @@ -7,5 +7,7 @@ int _crypto_pwhash_argon2_pick_best_implementation(void); int _crypto_scalarmult_curve25519_pick_best_implementation(void); int _crypto_stream_chacha20_pick_best_implementation(void); int _crypto_stream_salsa20_pick_best_implementation(void); +int _crypto_aead_aegis128l_pick_best_implementation(void); +int _crypto_aead_aegis256_pick_best_implementation(void); #endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/softaes.h b/subprojects/libsodium/src/libsodium/include/sodium/private/softaes.h @@ -0,0 +1,56 @@ +#ifndef softaes_H +#define softaes_H 1 + +#include <stdint.h> + +#include "private/common.h" + +typedef struct SoftAesBlock { + uint32_t w0; + uint32_t w1; + uint32_t w2; + uint32_t w3; +} SoftAesBlock; + +SoftAesBlock softaes_block_encrypt(const SoftAesBlock block, const SoftAesBlock rk); + +static inline SoftAesBlock +softaes_block_load(const uint8_t in[16]) +{ + const SoftAesBlock out = { LOAD32_LE(in + 0), LOAD32_LE(in + 4), LOAD32_LE(in + 8), + LOAD32_LE(in + 12) }; + return out; +} + +static inline SoftAesBlock +softaes_block_load64x2(const uint64_t a, const uint64_t b) +{ + const SoftAesBlock out = { (uint32_t) b, (uint32_t) (b >> 32), (uint32_t) a, + (uint32_t) (a >> 32) }; + return out; +} + +static inline void +softaes_block_store(uint8_t out[16], const SoftAesBlock in) +{ + STORE32_LE(out + 0, in.w0); + STORE32_LE(out + 4, in.w1); + STORE32_LE(out + 8, in.w2); + STORE32_LE(out + 12, in.w3); +} + +static inline SoftAesBlock +softaes_block_xor(const SoftAesBlock a, const SoftAesBlock b) +{ + const SoftAesBlock out = { a.w0 ^ b.w0, a.w1 ^ b.w1, a.w2 ^ b.w2, a.w3 ^ b.w3 }; + return out; +} + +static inline SoftAesBlock +softaes_block_and(const SoftAesBlock a, const SoftAesBlock b) +{ + const SoftAesBlock out = { a.w0 & b.w0, a.w1 & b.w1, a.w2 & b.w2, a.w3 & b.w3 }; + return out; +} + +#endif diff --git a/subprojects/libsodium/src/libsodium/include/sodium/private/sse2_64_32.h b/subprojects/libsodium/src/libsodium/include/sodium/private/sse2_64_32.h @@ -1,7 +1,7 @@ #ifndef sse2_64_32_H #define sse2_64_32_H 1 -#include "common.h" +#include "private/common.h" #ifdef HAVE_INTRIN_H # include <intrin.h> @@ -9,7 +9,7 @@ #if defined(HAVE_EMMINTRIN_H) && \ !(defined(__amd64) || defined(__amd64__) || defined(__x86_64__) || \ - defined(_M_X64) || defined(_M_AMD64)) + defined(_M_X64)) # include <emmintrin.h> # include <stdint.h> diff --git a/subprojects/libsodium/src/libsodium/include/sodium/randombytes.h b/subprojects/libsodium/src/libsodium/include/sodium/randombytes.h @@ -53,7 +53,7 @@ SODIUM_EXPORT int randombytes_close(void); SODIUM_EXPORT -int randombytes_set_implementation(randombytes_implementation *impl) +int randombytes_set_implementation(const randombytes_implementation *impl) __attribute__ ((nonnull)); SODIUM_EXPORT diff --git a/subprojects/libsodium/src/libsodium/include/sodium/runtime.h b/subprojects/libsodium/src/libsodium/include/sodium/runtime.h @@ -12,6 +12,9 @@ SODIUM_EXPORT_WEAK int sodium_runtime_has_neon(void); SODIUM_EXPORT_WEAK +int sodium_runtime_has_armcrypto(void); + +SODIUM_EXPORT_WEAK int sodium_runtime_has_sse2(void); SODIUM_EXPORT_WEAK diff --git a/subprojects/libsodium/src/libsodium/include/sodium/utils.h b/subprojects/libsodium/src/libsodium/include/sodium/utils.h @@ -109,33 +109,33 @@ int sodium_munlock(void * const addr, const size_t len) * allocation functions. * * They return a pointer to a region filled with 0xd0 bytes, immediately - * followed by a guard page. - * As a result, accessing a single byte after the requested allocation size - * will intentionally trigger a segmentation fault. + * followed by a guard page. As a result, accessing a single byte after the + * requested allocation size will intentionally trigger a segmentation fault. * * A canary and an additional guard page placed before the beginning of the * region may also kill the process if a buffer underflow is detected. * * The memory layout is: * [unprotected region size (read only)][guard page (no access)][unprotected pages (read/write)][guard page (no access)] - * With the layout of the unprotected pages being: + * + * The layout of the unprotected pages is: * [optional padding][16-bytes canary][user region] * - * However: - * - These functions are significantly slower than standard functions - * - Each allocation requires 3 or 4 additional pages + * Important limitations: + * - These functions are significantly slower than standard allocation functions. + * - Each allocation requires 3 or 4 additional pages. * - The returned address will not be aligned if the allocation size is not * a multiple of the required alignment. For this reason, these functions - * are designed to store data, such as secret keys and messages. + * are designed to store data such as secret keys and messages. * * sodium_malloc() can be used to allocate any libsodium data structure. * * The crypto_generichash_state structure is packed and its length is - * either 357 or 361 bytes. For this reason, when using sodium_malloc() to - * allocate a crypto_generichash_state structure, padding must be added in - * order to ensure proper alignment. crypto_generichash_statebytes() - * returns the rounded up structure size, and should be prefered to sizeof(): - * state = sodium_malloc(crypto_generichash_statebytes()); + * either 357 or 361 bytes. When using sodium_malloc() to allocate a + * crypto_generichash_state structure, padding must be added to ensure + * proper alignment. Use crypto_generichash_statebytes() rather than sizeof(): + * + * state = sodium_malloc(crypto_generichash_statebytes()); */ SODIUM_EXPORT diff --git a/subprojects/libsodium/src/libsodium/randombytes/internal/randombytes_internal_random.c b/subprojects/libsodium/src/libsodium/randombytes/internal/randombytes_internal_random.c @@ -5,11 +5,13 @@ #include <limits.h> #include <stdint.h> #include <stdlib.h> -#include <stdlib.h> #include <string.h> #if !defined(_MSC_VER) && !defined(__BORLANDC__) # include <unistd.h> #endif +#if !defined(__STDC_NO_THREADS__) && defined(HAVE_THREADS_H) +# include <threads.h> +#endif #include <sys/types.h> #ifndef _WIN32 @@ -44,10 +46,6 @@ #ifdef BLOCK_ON_DEV_RANDOM # include <poll.h> #endif -#ifdef HAVE_RDRAND -# pragma GCC target("rdrnd") -# include <immintrin.h> -#endif #include "core.h" #include "crypto_core_hchacha20.h" @@ -93,6 +91,10 @@ BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, ULONG RandomBufferLength); # endif #endif +#if !defined(TLS) && !defined(__STDC_NO_THREADS__) && \ + defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L +# define TLS _Thread_local +#endif #ifndef TLS # ifdef _WIN32 # define TLS __declspec(thread) @@ -101,6 +103,15 @@ BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, ULONG RandomBufferLength); # endif #endif +#ifdef HAVE_RDRAND +# ifdef __clang__ +# pragma clang attribute push(__attribute__((target("rdrnd"))), apply_to = function) +# elif defined(__GNUC__) +# pragma GCC target("rdrnd") +# endif +# include <immintrin.h> +#endif + typedef struct InternalRandomGlobal_ { int initialized; int random_data_source_fd; @@ -629,3 +640,9 @@ struct randombytes_implementation randombytes_internal_implementation = { SODIUM_C99(.buf =) randombytes_internal_random_buf, SODIUM_C99(.close =) randombytes_internal_random_close }; + +#ifdef HAVE_RDRAND +# ifdef __clang__ +# pragma clang attribute pop +# endif +#endif diff --git a/subprojects/libsodium/src/libsodium/randombytes/randombytes.c b/subprojects/libsodium/src/libsodium/randombytes/randombytes.c @@ -44,7 +44,7 @@ randombytes_init_if_needed(void) } int -randombytes_set_implementation(randombytes_implementation *impl) +randombytes_set_implementation(const randombytes_implementation *impl) { implementation = impl; @@ -89,6 +89,7 @@ randombytes_stir(void) try { var window_ = 'object' === typeof window ? window : self; var crypto_ = typeof window_.crypto !== 'undefined' ? window_.crypto : window_.msCrypto; + crypto_ = (crypto_ === undefined) ? crypto : crypto_; var randomValuesStandard = function() { var buf = new Uint32Array(1); crypto_.getRandomValues(buf); diff --git a/subprojects/libsodium/src/libsodium/randombytes/sysrandom/randombytes_sysrandom.c b/subprojects/libsodium/src/libsodium/randombytes/sysrandom/randombytes_sysrandom.c @@ -1,4 +1,3 @@ - #include <assert.h> #include <errno.h> #include <fcntl.h> @@ -31,9 +30,10 @@ # define HAVE_LINUX_COMPATIBLE_GETRANDOM # endif # endif -#elif defined(__FreeBSD__) +#elif defined(__FreeBSD__) || defined(__DragonFly__) # include <sys/param.h> -# if defined(__FreeBSD_version) && __FreeBSD_version >= 1200000 +# if (defined(__FreeBSD_version) && __FreeBSD_version >= 1200000) || \ + (defined(__DragonFly_version) && __DragonFly_version >= 500700) # define HAVE_LINUX_COMPATIBLE_GETRANDOM # endif #endif diff --git a/subprojects/libsodium/src/libsodium/sodium/codecs.c b/subprojects/libsodium/src/libsodium/sodium/codecs.c @@ -7,6 +7,7 @@ #include <string.h> #include "core.h" +#include "private/common.h" #include "utils.h" /* Derived from original code by CodesInChaos */ @@ -250,6 +251,7 @@ _sodium_base642bin_skip_padding(const char * const b64, const size_t b64_len, errno = ERANGE; return -1; } + ACQUIRE_FENCE; c = b64[*b64_pos_p]; if (c == '=') { padding_len--; diff --git a/subprojects/libsodium/src/libsodium/sodium/core.c b/subprojects/libsodium/src/libsodium/sodium/core.c @@ -45,6 +45,8 @@ sodium_init(void) _crypto_scalarmult_curve25519_pick_best_implementation(); _crypto_stream_chacha20_pick_best_implementation(); _crypto_stream_salsa20_pick_best_implementation(); + _crypto_aead_aegis128l_pick_best_implementation(); + _crypto_aead_aegis256_pick_best_implementation(); initialized = 1; if (sodium_crit_leave() != 0) { return -1; /* LCOV_EXCL_LINE */ @@ -57,7 +59,7 @@ sodium_init(void) static CRITICAL_SECTION _sodium_lock; static volatile LONG _sodium_lock_initialized; -int +static int _sodium_crit_init(void) { LONG status = 0L; diff --git a/subprojects/libsodium/src/libsodium/sodium/runtime.c b/subprojects/libsodium/src/libsodium/sodium/runtime.c @@ -3,6 +3,14 @@ #ifdef HAVE_ANDROID_GETCPUFEATURES # include <cpu-features.h> #endif +#ifdef __APPLE__ +# include <sys/types.h> +# include <sys/sysctl.h> +# include <mach/machine.h> +#endif +#ifdef HAVE_SYS_AUXV_H +# include <sys/auxv.h> +#endif #include "private/common.h" #include "runtime.h" @@ -10,6 +18,7 @@ typedef struct CPUFeatures_ { int initialized; int has_neon; + int has_armcrypto; int has_sse2; int has_sse3; int has_ssse3; @@ -48,32 +57,100 @@ static CPUFeatures _cpu_features; static int _sodium_runtime_arm_cpu_features(CPUFeatures * const cpu_features) { -#ifndef __arm__ cpu_features->has_neon = 0; - return -1; -#else -# ifdef __APPLE__ -# ifdef __ARM_NEON__ + cpu_features->has_armcrypto = 0; + +#ifndef __ARM_ARCH + return -1; /* LCOV_EXCL_LINE */ +#endif + +#if defined(__ARM_NEON) || defined(__aarch64__) || defined(_M_ARM64) cpu_features->has_neon = 1; -# else - cpu_features->has_neon = 0; -# endif -# elif defined(HAVE_ANDROID_GETCPUFEATURES) && \ - defined(ANDROID_CPU_ARM_FEATURE_NEON) +#elif defined(HAVE_ANDROID_GETCPUFEATURES) cpu_features->has_neon = - (android_getCpuFeatures() & ANDROID_CPU_ARM_FEATURE_NEON) != 0x0; -# else - cpu_features->has_neon = 0; + (android_getCpuFeatures() & ANDROID_CPU_ARM64_FEATURE_ASIMD) != 0x0; +#elif (defined(__aarch64__) || defined(_M_ARM64)) && defined(AT_HWCAP) +# ifdef HAVE_GETAUXVAL + cpu_features->has_neon = (getauxval(AT_HWCAP) & (1L << 1)) != 0; +# elif defined(HAVE_ELF_AUX_INFO) + { + unsigned long buf; + if (elf_aux_info(AT_HWCAP, (void *) &buf, (int) sizeof buf) == 0) { + cpu_features->has_neon = (buf & (1L << 1)) != 0; + } + } +# endif +#elif defined(__arm__) && defined(AT_HWCAP) +# ifdef HAVE_GETAUXVAL + cpu_features->has_neon = (getauxval(AT_HWCAP) & (1L << 12)) != 0; +# elif defined(HAVE_ELF_AUX_INFO) + { + unsigned long buf; + if (elf_aux_info(AT_HWCAP, (void *) &buf, (int) sizeof buf) == 0) { + cpu_features->has_neon = (buf & (1L << 12)) != 0; + } + } # endif - return 0; #endif + + if (cpu_features->has_neon == 0) { + return 0; + } + +#if defined(__ARM_FEATURE_CRYPTO) && defined(__ARM_FEATURE_AES) + cpu_features->has_armcrypto = 1; +#elif defined(_M_ARM64) + cpu_features->has_armcrypto = 1; /* assuming all CPUs supported by ARM Windows have the crypto extensions */ +#elif defined(__APPLE__) && defined(CPU_TYPE_ARM64) && defined(CPU_SUBTYPE_ARM64E) + { + cpu_type_t cpu_type; + cpu_subtype_t cpu_subtype; + size_t cpu_type_len = sizeof cpu_type; + size_t cpu_subtype_len = sizeof cpu_subtype; + + if (sysctlbyname("hw.cputype", &cpu_type, &cpu_type_len, + NULL, 0) == 0 && cpu_type == CPU_TYPE_ARM64 && + sysctlbyname("hw.cpusubtype", &cpu_subtype, &cpu_subtype_len, + NULL, 0) == 0 && + (cpu_subtype == CPU_SUBTYPE_ARM64E || + cpu_subtype == CPU_SUBTYPE_ARM64_V8)) { + cpu_features->has_armcrypto = 1; + } + } +#elif defined(HAVE_ANDROID_GETCPUFEATURES) + cpu_features->has_armcrypto = + (android_getCpuFeatures() & ANDROID_CPU_ARM64_FEATURE_AES) != 0x0; +#elif (defined(__aarch64__) || defined(_M_ARM64)) && defined(AT_HWCAP) +# ifdef HAVE_GETAUXVAL + cpu_features->has_armcrypto = (getauxval(AT_HWCAP) & (1L << 3)) != 0; +# elif defined(HAVE_ELF_AUX_INFO) + { + unsigned long buf; + if (elf_aux_info(AT_HWCAP, (void *) &buf, (int) sizeof buf) == 0) { + cpu_features->has_armcrypto = (buf & (1L << 3)) != 0; + } + } +# endif +#elif defined(__arm__) && defined(AT_HWCAP2) +# ifdef HAVE_GETAUXVAL + cpu_features->has_armcrypto = (getauxval(AT_HWCAP2) & (1L << 0)) != 0; +# elif defined(HAVE_ELF_AUX_INFO) + { + unsigned long buf; + if (elf_aux_info(AT_HWCAP2, (void *) &buf, (int) sizeof buf) == 0) { + cpu_features->has_armcrypto = (buf & (1L << 0)) != 0; + } + } +# endif +#endif + + return 0; } static void _cpuid(unsigned int cpu_info[4U], const unsigned int cpu_info_type) { -#if defined(_MSC_VER) && \ - (defined(_M_X64) || defined(_M_AMD64) || defined(_M_IX86)) +#if defined(_MSC_VER) && (defined(_M_X64) || defined(_M_IX86)) __cpuid((int *) cpu_info, cpu_info_type); #elif defined(HAVE_CPUID) cpu_info[0] = cpu_info[1] = cpu_info[2] = cpu_info[3] = 0; @@ -116,11 +193,10 @@ static int _sodium_runtime_intel_cpu_features(CPUFeatures * const cpu_features) { unsigned int cpu_info[4]; - unsigned int id; uint32_t xcr0 = 0U; _cpuid(cpu_info, 0x0); - if ((id = cpu_info[0]) == 0U) { + if (cpu_info[0] == 0U) { return -1; /* LCOV_EXCL_LINE */ } _cpuid(cpu_info, 0x00000001); @@ -249,6 +325,12 @@ sodium_runtime_has_neon(void) } int +sodium_runtime_has_armcrypto(void) +{ + return _cpu_features.has_armcrypto; +} + +int sodium_runtime_has_sse2(void) { return _cpu_features.has_sse2; diff --git a/subprojects/libsodium/src/libsodium/sodium/utils.c b/subprojects/libsodium/src/libsodium/sodium/utils.c @@ -4,16 +4,23 @@ #include <assert.h> #include <errno.h> #include <limits.h> -#include <signal.h> #include <stddef.h> #include <stdint.h> #include <stdlib.h> #include <string.h> +#if defined(HAVE_RAISE) && !defined(__wasm__) +# include <signal.h> +#endif + #ifdef HAVE_SYS_MMAN_H # include <sys/mman.h> #endif +#ifdef HAVE_SYS_PARAM_H +# include <sys/param.h> +#endif + #ifdef _WIN32 # include <windows.h> # include <wincrypt.h> @@ -59,7 +66,11 @@ void *alloca (size_t); #define GARBAGE_VALUE 0xdb #ifndef MAP_NOCORE -# define MAP_NOCORE 0 +# ifdef MAP_CONCEAL +# define MAP_NOCORE MAP_CONCEAL +# else +# define MAP_NOCORE 0 +# endif #endif #if !defined(MAP_ANON) && defined(MAP_ANONYMOUS) # define MAP_ANON MAP_ANONYMOUS @@ -68,6 +79,7 @@ void *alloca (size_t); defined(HAVE_POSIX_MEMALIGN) # define HAVE_ALIGNED_MALLOC #endif + #if defined(HAVE_MPROTECT) && \ !(defined(PROT_NONE) && defined(PROT_READ) && defined(PROT_WRITE)) # undef HAVE_MPROTECT @@ -81,7 +93,15 @@ void *alloca (size_t); # define MADV_DONTDUMP MADV_NOCORE #endif -static size_t page_size; +#ifndef DEFAULT_PAGE_SIZE +# ifdef PAGE_SIZE +# define DEFAULT_PAGE_SIZE PAGE_SIZE +# else +# define DEFAULT_PAGE_SIZE 0x10000 +# endif +#endif + +static size_t page_size = DEFAULT_PAGE_SIZE; static unsigned char canary[CANARY_SIZE]; /* LCOV_EXCL_START */ @@ -102,7 +122,7 @@ _sodium_dummy_symbol_to_prevent_memzero_lto(void *const pnt, void sodium_memzero(void * const pnt, const size_t len) { -#ifdef _WIN32 +#if defined(_WIN32) && !defined(__CRT_INLINE) SecureZeroMemory(pnt, len); #elif defined(HAVE_MEMSET_S) if (len > 0U && memset_s(pnt, (rsize_t) len, 0, (rsize_t) len) != 0) { @@ -110,6 +130,8 @@ sodium_memzero(void * const pnt, const size_t len) } #elif defined(HAVE_EXPLICIT_BZERO) explicit_bzero(pnt, len); +#elif defined(HAVE_MEMSET_EXPLICIT) + memset_explicit(pnt, 0, len); #elif defined(HAVE_EXPLICIT_MEMSET) explicit_memset(pnt, 0, len); #elif HAVE_WEAK_SYMBOLS @@ -223,8 +245,8 @@ sodium_compare(const unsigned char *b1_, const unsigned char *b2_, size_t len) i--; x1 = b1[i]; x2 = b2[i]; - gt |= ((x2 - x1) >> 8) & eq; - eq &= ((x2 ^ x1) - 1) >> 8; + gt |= (((unsigned int) x2 - (unsigned int) x1) >> 8) & eq; + eq &= (((unsigned int) (x2 ^ x1)) - 1) >> 8; } return (int) (gt + gt + eq) - 1; } @@ -384,7 +406,7 @@ int _sodium_alloc_init(void) { #ifdef HAVE_ALIGNED_MALLOC -# if defined(_SC_PAGESIZE) +# if defined(_SC_PAGESIZE) && defined(HAVE_SYSCONF) long page_size_ = sysconf(_SC_PAGESIZE); if (page_size_ > 0L) { page_size = (size_t) page_size_; @@ -393,6 +415,8 @@ _sodium_alloc_init(void) SYSTEM_INFO si; GetSystemInfo(&si); page_size = (size_t) si.dwPageSize; +# elif !defined(PAGE_SIZE) +# warning Unknown page size # endif if (page_size < CANARY_SIZE || page_size < sizeof(size_t)) { sodium_misuse(); /* LCOV_EXCL_LINE */ @@ -483,8 +507,10 @@ _mprotect_readwrite(void *ptr, size_t size) __attribute__((noreturn)) static void _out_of_bounds(void) { -# ifndef __wasm__ -# ifdef SIGSEGV +# if defined(HAVE_RAISE) && !defined(__wasm__) +# ifdef SIGPROT + raise(SIGPROT); +# elif defined(SIGSEGV) raise(SIGSEGV); # elif defined(SIGKILL) raise(SIGKILL); @@ -593,7 +619,7 @@ _sodium_malloc(const size_t size) memcpy(unprotected_ptr + unprotected_size, canary, sizeof canary); # endif _mprotect_noaccess(unprotected_ptr + unprotected_size, page_size); - sodium_mlock(unprotected_ptr, unprotected_size); + (void) sodium_mlock(unprotected_ptr, unprotected_size); /* not a hard error in the context of sodium_malloc() */ canary_ptr = unprotected_ptr + _page_round(size_with_canary) - size_with_canary; user_ptr = canary_ptr + sizeof canary; @@ -663,7 +689,7 @@ sodium_free(void *ptr) _out_of_bounds(); } # endif - sodium_munlock(unprotected_ptr, unprotected_size); + (void) sodium_munlock(unprotected_ptr, unprotected_size); _free_aligned(base_ptr, total_size); } #endif /* HAVE_ALIGNED_MALLOC */ diff --git a/subprojects/libsodium/test/Makefile.in b/subprojects/libsodium/test/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,9 +89,11 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ subdir = test ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -141,6 +145,10 @@ am__recursive_targets = \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -158,8 +166,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) @@ -193,7 +199,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -205,6 +210,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -217,6 +223,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -233,8 +241,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -277,6 +287,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -302,8 +313,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -337,11 +350,16 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @@ -425,6 +443,11 @@ $(am__recursive_targets): if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -578,12 +601,32 @@ mostlyclean-generic: clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-recursive + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-recursive + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-recursive + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-recursive + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-recursive + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am @@ -653,10 +696,15 @@ uninstall-am: .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ - check-am clean clean-generic clean-libtool cscopelist-am ctags \ - ctags-am distclean distclean-generic distclean-libtool \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-data install-data-am install-dvi \ + check-am check-valgrind-am check-valgrind-drd-am \ + check-valgrind-drd-local check-valgrind-helgrind-am \ + check-valgrind-helgrind-local check-valgrind-local \ + check-valgrind-memcheck-am check-valgrind-memcheck-local \ + check-valgrind-sgcheck-am check-valgrind-sgcheck-local clean \ + clean-generic clean-libtool cscopelist-am ctags ctags-am \ + distclean distclean-generic distclean-libtool distclean-tags \ + distdir dvi dvi-am html html-am info info-am install \ + install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ @@ -671,3 +719,10 @@ uninstall-am: # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/test/constcheck.sh b/subprojects/libsodium/test/constcheck.sh @@ -5,7 +5,7 @@ CT='ct.c' echo '#include <assert.h>' > "$CT" echo '#include <sodium.h>' >> "$CT" echo 'int main(void) {' >> "$CT" -for macro in $(egrep -r '#define crypto_.*BYTES(_[A-Z]+)? ' src/libsodium/include | \ +for macro in $(grep -Er '#define crypto_.*BYTES(_[A-Z]+)? ' src/libsodium/include | \ cut -d: -f2- | cut -d' ' -f2 | \ fgrep -v edwards25519sha512batch | sort -u); do func=$(echo "$macro" | tr A-Z a-z) @@ -14,6 +14,8 @@ done echo "return 0; }" >> "$CT" CPPFLAGS="${CPPFLAGS} -Wno-deprecated-declarations" +CPPFLAGS="${CPPFLAGS} -I/opt/homebrew/include" +LDFLAGS="${LDFLAGS} -L/opt/homebrew/lib" ${CC:-cc} "$CT" $CPPFLAGS $CFLAGS $LDFLAGS -lsodium || exit 1 ./a.out || exit 1 rm -f a.out "$CT" diff --git a/subprojects/libsodium/test/default/Makefile.am b/subprojects/libsodium/test/default/Makefile.am @@ -1,9 +1,12 @@ EXTRA_DIST = \ + run.sh \ cmptest.h \ wasi-test-wrapper.sh \ wintest.bat \ pre.js.inc \ + aead_aegis128l.exp \ + aead_aegis256.exp \ aead_aes256gcm.exp \ aead_aes256gcm2.exp \ aead_chacha20poly1305.exp \ @@ -38,9 +41,9 @@ EXTRA_DIST = \ generichash2.exp \ generichash3.exp \ hash.exp \ - hash2.exp \ hash3.exp \ kdf.exp \ + kdf_hkdf.exp \ keygen.exp \ kx.exp \ metamorphic.exp \ @@ -67,7 +70,7 @@ EXTRA_DIST = \ secretbox8.exp \ secretbox_easy.exp \ secretbox_easy2.exp \ - secretstream.exp \ + secretstream_xchacha20poly1305.exp \ shorthash.exp \ sign.exp \ siphashx24.exp \ @@ -84,6 +87,8 @@ EXTRA_DIST = \ xchacha20.exp DISTCLEANFILES = \ + aead_aegis128l.res \ + aead_aegis256.res \ aead_aes256gcm.res \ aead_aes256gcm2.res \ aead_chacha20poly1305.res \ @@ -121,6 +126,7 @@ DISTCLEANFILES = \ hash2.res \ hash3.res \ kdf.res \ + kdf_hkdf.res \ keygen.res \ kx.res \ metamorphic.res \ @@ -147,7 +153,7 @@ DISTCLEANFILES = \ secretbox8.res \ secretbox_easy.res \ secretbox_easy2.res \ - secretstream.res \ + secretstream_xchacha20poly1305.res \ shorthash.res \ sign.res \ siphashx24.res \ @@ -174,6 +180,8 @@ AM_CPPFLAGS = \ AM_LDFLAGS = @TEST_LDFLAGS@ TESTS_TARGETS = \ + aead_aegis128l \ + aead_aegis256 \ aead_aes256gcm \ aead_aes256gcm2 \ aead_chacha20poly1305 \ @@ -230,7 +238,7 @@ TESTS_TARGETS = \ secretbox8 \ secretbox_easy \ secretbox_easy2 \ - secretstream \ + secretstream_xchacha20poly1305 \ shorthash \ sign \ sodium_core \ @@ -255,6 +263,12 @@ TESTS = $(TESTS_TARGETS) TESTS_LDADD = \ ${top_builddir}/src/libsodium/libsodium.la +aead_aegis128l_SOURCE = cmptest.h aead_aegis128l.c +aead_aegis128l_LDADD = $(TESTS_LDADD) + +aead_aegis256_SOURCE = cmptest.h aead_aegis256.c +aead_aegis256_LDADD = $(TESTS_LDADD) + aead_aes256gcm_SOURCE = cmptest.h aead_aes256gcm.c aead_aes256gcm_LDADD = $(TESTS_LDADD) @@ -363,6 +377,9 @@ hash3_LDADD = $(TESTS_LDADD) kdf_SOURCE = cmptest.h kdf.c kdf_LDADD = $(TESTS_LDADD) +kdf_hkdf_SOURCE = cmptest.h kdf_hkdf.c +kdf_hkdf_LDADD = $(TESTS_LDADD) + keygen_SOURCE = cmptest.h keygen.c keygen_LDADD = $(TESTS_LDADD) @@ -441,8 +458,8 @@ secretbox_easy_LDADD = $(TESTS_LDADD) secretbox_easy2_SOURCE = cmptest.h secretbox_easy2.c secretbox_easy2_LDADD = $(TESTS_LDADD) -secretstream_SOURCE = cmptest.h secretstream.c -secretstream_LDADD = $(TESTS_LDADD) +secretstream_xchacha20poly1305_SOURCE = cmptest.h secretstream_xchacha20poly1305.c +secretstream_xchacha20poly1305_LDADD = $(TESTS_LDADD) shorthash_SOURCE = cmptest.h shorthash.c shorthash_LDADD = $(TESTS_LDADD) @@ -490,6 +507,7 @@ if !MINIMAL TESTS_TARGETS += \ core_ed25519 \ core_ristretto255 \ + kdf_hkdf \ pwhash_scrypt \ pwhash_scrypt_ll \ scalarmult_ed25519 \ diff --git a/subprojects/libsodium/test/default/Makefile.in b/subprojects/libsodium/test/default/Makefile.in @@ -1,7 +1,7 @@ -# Makefile.in generated by automake 1.16.1 from Makefile.am. +# Makefile.in generated by automake 1.18.1 from Makefile.am. # @configure_input@ -# Copyright (C) 1994-2018 Free Software Foundation, Inc. +# Copyright (C) 1994-2025 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, @@ -69,6 +69,8 @@ am__make_running_with_option = \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) +am__rm_f = rm -f $(am__rm_f_notfound) +am__rm_rf = rm -rf $(am__rm_f_notfound) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -87,6 +89,7 @@ PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ +target_triplet = @target@ @EMSCRIPTEN_FALSE@am__append_1 = \ @EMSCRIPTEN_FALSE@ sodium_utils2 \ @EMSCRIPTEN_FALSE@ sodium_utils3 @@ -96,6 +99,7 @@ TESTS = $(am__EXEEXT_3) @MINIMAL_FALSE@am__append_2 = \ @MINIMAL_FALSE@ core_ed25519 \ @MINIMAL_FALSE@ core_ristretto255 \ +@MINIMAL_FALSE@ kdf_hkdf \ @MINIMAL_FALSE@ pwhash_scrypt \ @MINIMAL_FALSE@ pwhash_scrypt_ll \ @MINIMAL_FALSE@ scalarmult_ed25519 \ @@ -105,7 +109,8 @@ TESTS = $(am__EXEEXT_3) subdir = test/default ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ +am__aclocal_m4_deps = $(top_srcdir)/m4/ax_add_fortify_source.m4 \ + $(top_srcdir)/m4/ax_check_catchable_abrt.m4 \ $(top_srcdir)/m4/ax_check_catchable_segv.m4 \ $(top_srcdir)/m4/ax_check_compile_flag.m4 \ $(top_srcdir)/m4/ax_check_define.m4 \ @@ -125,13 +130,14 @@ CONFIG_CLEAN_VPATH_FILES = @EMSCRIPTEN_FALSE@am__EXEEXT_1 = sodium_utils2$(EXEEXT) \ @EMSCRIPTEN_FALSE@ sodium_utils3$(EXEEXT) @MINIMAL_FALSE@am__EXEEXT_2 = core_ed25519$(EXEEXT) \ -@MINIMAL_FALSE@ core_ristretto255$(EXEEXT) \ +@MINIMAL_FALSE@ core_ristretto255$(EXEEXT) kdf_hkdf$(EXEEXT) \ @MINIMAL_FALSE@ pwhash_scrypt$(EXEEXT) \ @MINIMAL_FALSE@ pwhash_scrypt_ll$(EXEEXT) \ @MINIMAL_FALSE@ scalarmult_ed25519$(EXEEXT) \ @MINIMAL_FALSE@ scalarmult_ristretto255$(EXEEXT) \ @MINIMAL_FALSE@ siphashx24$(EXEEXT) xchacha20$(EXEEXT) -am__EXEEXT_3 = aead_aes256gcm$(EXEEXT) aead_aes256gcm2$(EXEEXT) \ +am__EXEEXT_3 = aead_aegis128l$(EXEEXT) aead_aegis256$(EXEEXT) \ + aead_aes256gcm$(EXEEXT) aead_aes256gcm2$(EXEEXT) \ aead_chacha20poly1305$(EXEEXT) aead_chacha20poly13052$(EXEEXT) \ aead_xchacha20poly1305$(EXEEXT) auth$(EXEEXT) auth2$(EXEEXT) \ auth3$(EXEEXT) auth5$(EXEEXT) auth6$(EXEEXT) auth7$(EXEEXT) \ @@ -150,18 +156,25 @@ am__EXEEXT_3 = aead_aes256gcm$(EXEEXT) aead_aes256gcm2$(EXEEXT) \ scalarmult6$(EXEEXT) scalarmult7$(EXEEXT) scalarmult8$(EXEEXT) \ secretbox$(EXEEXT) secretbox2$(EXEEXT) secretbox7$(EXEEXT) \ secretbox8$(EXEEXT) secretbox_easy$(EXEEXT) \ - secretbox_easy2$(EXEEXT) secretstream$(EXEEXT) \ - shorthash$(EXEEXT) sign$(EXEEXT) sodium_core$(EXEEXT) \ - sodium_utils$(EXEEXT) sodium_version$(EXEEXT) stream$(EXEEXT) \ - stream2$(EXEEXT) stream3$(EXEEXT) stream4$(EXEEXT) \ - verify1$(EXEEXT) $(am__EXEEXT_1) $(am__EXEEXT_2) -aead_aes256gcm_SOURCES = aead_aes256gcm.c -aead_aes256gcm_OBJECTS = aead_aes256gcm.$(OBJEXT) -aead_aes256gcm_DEPENDENCIES = $(TESTS_LDADD) + secretbox_easy2$(EXEEXT) \ + secretstream_xchacha20poly1305$(EXEEXT) shorthash$(EXEEXT) \ + sign$(EXEEXT) sodium_core$(EXEEXT) sodium_utils$(EXEEXT) \ + sodium_version$(EXEEXT) stream$(EXEEXT) stream2$(EXEEXT) \ + stream3$(EXEEXT) stream4$(EXEEXT) verify1$(EXEEXT) \ + $(am__EXEEXT_1) $(am__EXEEXT_2) +aead_aegis128l_SOURCES = aead_aegis128l.c +aead_aegis128l_OBJECTS = aead_aegis128l.$(OBJEXT) +aead_aegis128l_DEPENDENCIES = $(TESTS_LDADD) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = +aead_aegis256_SOURCES = aead_aegis256.c +aead_aegis256_OBJECTS = aead_aegis256.$(OBJEXT) +aead_aegis256_DEPENDENCIES = $(TESTS_LDADD) +aead_aes256gcm_SOURCES = aead_aes256gcm.c +aead_aes256gcm_OBJECTS = aead_aes256gcm.$(OBJEXT) +aead_aes256gcm_DEPENDENCIES = $(TESTS_LDADD) aead_aes256gcm2_SOURCES = aead_aes256gcm2.c aead_aes256gcm2_OBJECTS = aead_aes256gcm2.$(OBJEXT) aead_aes256gcm2_DEPENDENCIES = $(TESTS_LDADD) @@ -267,6 +280,9 @@ hash3_DEPENDENCIES = $(TESTS_LDADD) kdf_SOURCES = kdf.c kdf_OBJECTS = kdf.$(OBJEXT) kdf_DEPENDENCIES = $(TESTS_LDADD) +kdf_hkdf_SOURCES = kdf_hkdf.c +kdf_hkdf_OBJECTS = kdf_hkdf.$(OBJEXT) +kdf_hkdf_DEPENDENCIES = $(TESTS_LDADD) keygen_SOURCES = keygen.c keygen_OBJECTS = keygen.$(OBJEXT) keygen_DEPENDENCIES = $(TESTS_LDADD) @@ -345,9 +361,11 @@ secretbox_easy_DEPENDENCIES = $(TESTS_LDADD) secretbox_easy2_SOURCES = secretbox_easy2.c secretbox_easy2_OBJECTS = secretbox_easy2.$(OBJEXT) secretbox_easy2_DEPENDENCIES = $(TESTS_LDADD) -secretstream_SOURCES = secretstream.c -secretstream_OBJECTS = secretstream.$(OBJEXT) -secretstream_DEPENDENCIES = $(TESTS_LDADD) +secretstream_xchacha20poly1305_SOURCES = \ + secretstream_xchacha20poly1305.c +secretstream_xchacha20poly1305_OBJECTS = \ + secretstream_xchacha20poly1305.$(OBJEXT) +secretstream_xchacha20poly1305_DEPENDENCIES = $(TESTS_LDADD) shorthash_SOURCES = shorthash.c shorthash_OBJECTS = shorthash.$(OBJEXT) shorthash_DEPENDENCIES = $(TESTS_LDADD) @@ -405,7 +423,8 @@ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/build-aux/depcomp am__maybe_remake_depfiles = depfiles -am__depfiles_remade = ./$(DEPDIR)/aead_aes256gcm.Po \ +am__depfiles_remade = ./$(DEPDIR)/aead_aegis128l.Po \ + ./$(DEPDIR)/aead_aegis256.Po ./$(DEPDIR)/aead_aes256gcm.Po \ ./$(DEPDIR)/aead_aes256gcm2.Po \ ./$(DEPDIR)/aead_chacha20poly1305.Po \ ./$(DEPDIR)/aead_chacha20poly13052.Po \ @@ -422,28 +441,28 @@ am__depfiles_remade = ./$(DEPDIR)/aead_aes256gcm.Po \ ./$(DEPDIR)/ed25519_convert.Po ./$(DEPDIR)/generichash.Po \ ./$(DEPDIR)/generichash2.Po ./$(DEPDIR)/generichash3.Po \ ./$(DEPDIR)/hash.Po ./$(DEPDIR)/hash3.Po ./$(DEPDIR)/kdf.Po \ - ./$(DEPDIR)/keygen.Po ./$(DEPDIR)/kx.Po \ - ./$(DEPDIR)/metamorphic.Po ./$(DEPDIR)/misuse.Po \ - ./$(DEPDIR)/onetimeauth.Po ./$(DEPDIR)/onetimeauth2.Po \ - ./$(DEPDIR)/onetimeauth7.Po ./$(DEPDIR)/pwhash_argon2i.Po \ - ./$(DEPDIR)/pwhash_argon2id.Po ./$(DEPDIR)/pwhash_scrypt.Po \ - ./$(DEPDIR)/pwhash_scrypt_ll.Po ./$(DEPDIR)/randombytes.Po \ - ./$(DEPDIR)/scalarmult.Po ./$(DEPDIR)/scalarmult2.Po \ - ./$(DEPDIR)/scalarmult5.Po ./$(DEPDIR)/scalarmult6.Po \ - ./$(DEPDIR)/scalarmult7.Po ./$(DEPDIR)/scalarmult8.Po \ - ./$(DEPDIR)/scalarmult_ed25519.Po \ + ./$(DEPDIR)/kdf_hkdf.Po ./$(DEPDIR)/keygen.Po \ + ./$(DEPDIR)/kx.Po ./$(DEPDIR)/metamorphic.Po \ + ./$(DEPDIR)/misuse.Po ./$(DEPDIR)/onetimeauth.Po \ + ./$(DEPDIR)/onetimeauth2.Po ./$(DEPDIR)/onetimeauth7.Po \ + ./$(DEPDIR)/pwhash_argon2i.Po ./$(DEPDIR)/pwhash_argon2id.Po \ + ./$(DEPDIR)/pwhash_scrypt.Po ./$(DEPDIR)/pwhash_scrypt_ll.Po \ + ./$(DEPDIR)/randombytes.Po ./$(DEPDIR)/scalarmult.Po \ + ./$(DEPDIR)/scalarmult2.Po ./$(DEPDIR)/scalarmult5.Po \ + ./$(DEPDIR)/scalarmult6.Po ./$(DEPDIR)/scalarmult7.Po \ + ./$(DEPDIR)/scalarmult8.Po ./$(DEPDIR)/scalarmult_ed25519.Po \ ./$(DEPDIR)/scalarmult_ristretto255.Po \ ./$(DEPDIR)/secretbox.Po ./$(DEPDIR)/secretbox2.Po \ ./$(DEPDIR)/secretbox7.Po ./$(DEPDIR)/secretbox8.Po \ ./$(DEPDIR)/secretbox_easy.Po ./$(DEPDIR)/secretbox_easy2.Po \ - ./$(DEPDIR)/secretstream.Po ./$(DEPDIR)/shorthash.Po \ - ./$(DEPDIR)/sign.Po ./$(DEPDIR)/siphashx24.Po \ - ./$(DEPDIR)/sodium_core.Po ./$(DEPDIR)/sodium_utils.Po \ - ./$(DEPDIR)/sodium_utils2.Po ./$(DEPDIR)/sodium_utils3.Po \ - ./$(DEPDIR)/sodium_version.Po ./$(DEPDIR)/stream.Po \ - ./$(DEPDIR)/stream2.Po ./$(DEPDIR)/stream3.Po \ - ./$(DEPDIR)/stream4.Po ./$(DEPDIR)/verify1.Po \ - ./$(DEPDIR)/xchacha20.Po + ./$(DEPDIR)/secretstream_xchacha20poly1305.Po \ + ./$(DEPDIR)/shorthash.Po ./$(DEPDIR)/sign.Po \ + ./$(DEPDIR)/siphashx24.Po ./$(DEPDIR)/sodium_core.Po \ + ./$(DEPDIR)/sodium_utils.Po ./$(DEPDIR)/sodium_utils2.Po \ + ./$(DEPDIR)/sodium_utils3.Po ./$(DEPDIR)/sodium_version.Po \ + ./$(DEPDIR)/stream.Po ./$(DEPDIR)/stream2.Po \ + ./$(DEPDIR)/stream3.Po ./$(DEPDIR)/stream4.Po \ + ./$(DEPDIR)/verify1.Po ./$(DEPDIR)/xchacha20.Po am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) @@ -463,47 +482,53 @@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = -SOURCES = aead_aes256gcm.c aead_aes256gcm2.c aead_chacha20poly1305.c \ +SOURCES = aead_aegis128l.c aead_aegis256.c aead_aes256gcm.c \ + aead_aes256gcm2.c aead_chacha20poly1305.c \ aead_chacha20poly13052.c aead_xchacha20poly1305.c auth.c \ auth2.c auth3.c auth5.c auth6.c auth7.c box.c box2.c box7.c \ box8.c box_easy.c box_easy2.c box_seal.c box_seed.c chacha20.c \ codecs.c core1.c core2.c core3.c core4.c core5.c core6.c \ core_ed25519.c core_ristretto255.c ed25519_convert.c \ generichash.c generichash2.c generichash3.c hash.c hash3.c \ - kdf.c keygen.c kx.c metamorphic.c misuse.c onetimeauth.c \ - onetimeauth2.c onetimeauth7.c pwhash_argon2i.c \ + kdf.c kdf_hkdf.c keygen.c kx.c metamorphic.c misuse.c \ + onetimeauth.c onetimeauth2.c onetimeauth7.c pwhash_argon2i.c \ pwhash_argon2id.c pwhash_scrypt.c pwhash_scrypt_ll.c \ randombytes.c scalarmult.c scalarmult2.c scalarmult5.c \ scalarmult6.c scalarmult7.c scalarmult8.c scalarmult_ed25519.c \ scalarmult_ristretto255.c secretbox.c secretbox2.c \ secretbox7.c secretbox8.c secretbox_easy.c secretbox_easy2.c \ - secretstream.c shorthash.c sign.c siphashx24.c sodium_core.c \ - sodium_utils.c sodium_utils2.c sodium_utils3.c \ - sodium_version.c stream.c stream2.c stream3.c stream4.c \ - verify1.c xchacha20.c -DIST_SOURCES = aead_aes256gcm.c aead_aes256gcm2.c \ - aead_chacha20poly1305.c aead_chacha20poly13052.c \ - aead_xchacha20poly1305.c auth.c auth2.c auth3.c auth5.c \ - auth6.c auth7.c box.c box2.c box7.c box8.c box_easy.c \ - box_easy2.c box_seal.c box_seed.c chacha20.c codecs.c core1.c \ - core2.c core3.c core4.c core5.c core6.c core_ed25519.c \ - core_ristretto255.c ed25519_convert.c generichash.c \ - generichash2.c generichash3.c hash.c hash3.c kdf.c keygen.c \ - kx.c metamorphic.c misuse.c onetimeauth.c onetimeauth2.c \ - onetimeauth7.c pwhash_argon2i.c pwhash_argon2id.c \ - pwhash_scrypt.c pwhash_scrypt_ll.c randombytes.c scalarmult.c \ - scalarmult2.c scalarmult5.c scalarmult6.c scalarmult7.c \ - scalarmult8.c scalarmult_ed25519.c scalarmult_ristretto255.c \ - secretbox.c secretbox2.c secretbox7.c secretbox8.c \ - secretbox_easy.c secretbox_easy2.c secretstream.c shorthash.c \ - sign.c siphashx24.c sodium_core.c sodium_utils.c \ - sodium_utils2.c sodium_utils3.c sodium_version.c stream.c \ - stream2.c stream3.c stream4.c verify1.c xchacha20.c + secretstream_xchacha20poly1305.c shorthash.c sign.c \ + siphashx24.c sodium_core.c sodium_utils.c sodium_utils2.c \ + sodium_utils3.c sodium_version.c stream.c stream2.c stream3.c \ + stream4.c verify1.c xchacha20.c +DIST_SOURCES = aead_aegis128l.c aead_aegis256.c aead_aes256gcm.c \ + aead_aes256gcm2.c aead_chacha20poly1305.c \ + aead_chacha20poly13052.c aead_xchacha20poly1305.c auth.c \ + auth2.c auth3.c auth5.c auth6.c auth7.c box.c box2.c box7.c \ + box8.c box_easy.c box_easy2.c box_seal.c box_seed.c chacha20.c \ + codecs.c core1.c core2.c core3.c core4.c core5.c core6.c \ + core_ed25519.c core_ristretto255.c ed25519_convert.c \ + generichash.c generichash2.c generichash3.c hash.c hash3.c \ + kdf.c kdf_hkdf.c keygen.c kx.c metamorphic.c misuse.c \ + onetimeauth.c onetimeauth2.c onetimeauth7.c pwhash_argon2i.c \ + pwhash_argon2id.c pwhash_scrypt.c pwhash_scrypt_ll.c \ + randombytes.c scalarmult.c scalarmult2.c scalarmult5.c \ + scalarmult6.c scalarmult7.c scalarmult8.c scalarmult_ed25519.c \ + scalarmult_ristretto255.c secretbox.c secretbox2.c \ + secretbox7.c secretbox8.c secretbox_easy.c secretbox_easy2.c \ + secretstream_xchacha20poly1305.c shorthash.c sign.c \ + siphashx24.c sodium_core.c sodium_utils.c sodium_utils2.c \ + sodium_utils3.c sodium_version.c stream.c stream2.c stream3.c \ + stream4.c verify1.c xchacha20.c am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac +am__extra_recursive_targets = check-valgrind-recursive \ + check-valgrind-memcheck-recursive \ + check-valgrind-helgrind-recursive check-valgrind-drd-recursive \ + check-valgrind-sgcheck-recursive am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is @@ -521,8 +546,6 @@ am__define_uniq_tagged_files = \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` -ETAGS = etags -CTAGS = ctags am__tty_colors_dummy = \ mgn= red= grn= lgn= blu= brg= std=; \ am__color_tests=no @@ -567,10 +590,9 @@ am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ - test -z "$$files" \ - || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ - || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ - $(am__cd) "$$dir" && rm -f $$files; }; \ + { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ + || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ + $(am__cd) "$$dir" && echo $$files | $(am__xargs_n) 40 $(am__rm_f); }; \ } am__recheck_rx = ^[ ]*:recheck:[ ]* am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* @@ -658,12 +680,13 @@ am__sh_e_setup = case $$- in *e*) set +e;; esac # Default flags passed to test drivers. am__common_driver_flags = \ --color-tests "$$am__color_tests" \ + $$am__collect_skipped_logs \ --enable-hard-errors "$$am__enable_hard_errors" \ --expect-failure "$$am__expect_failure" # To be inserted before the command running the test. Creates the # directory for the log if needed. Stores in $dir the directory # containing $f, in $tst the test, in $log the log. Executes the -# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and +# developer-defined test setup AM_TESTS_ENVIRONMENT (if any), and # passes TESTS_ENVIRONMENT. Set up options for the wrapper that # will run the test scripts (or their associated LOG_COMPILER, if # thy have one). @@ -682,6 +705,11 @@ if test -f "./$$f"; then dir=./; \ elif test -f "$$f"; then dir=; \ else dir="$(srcdir)/"; fi; \ tst=$$dir$$f; log='$@'; \ +if test -n '$(IGNORE_SKIPPED_LOGS)'; then \ + am__collect_skipped_logs='--collect-skipped-logs no'; \ +else \ + am__collect_skipped_logs=''; \ +fi; \ if test -n '$(DISABLE_HARD_ERRORS)'; then \ am__enable_hard_errors=no; \ else \ @@ -705,6 +733,7 @@ am__set_TESTS_bases = \ bases='$(TEST_LOGS)'; \ bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ bases=`echo $$bases` +AM_TESTSUITE_SUMMARY_HEADER = ' for $(PACKAGE_STRING)' RECHECK_LOGS = $(TEST_LOGS) AM_RECURSIVE_TARGETS = check recheck TEST_SUITE_LOG = test-suite.log @@ -736,7 +765,6 @@ ALLOCA = @ALLOCA@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ -AS = @AS@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ @@ -748,6 +776,7 @@ CCASFLAGS = @CCASFLAGS@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CFLAGS_AESNI = @CFLAGS_AESNI@ +CFLAGS_ARMCRYPTO = @CFLAGS_ARMCRYPTO@ CFLAGS_AVX = @CFLAGS_AVX@ CFLAGS_AVX2 = @CFLAGS_AVX2@ CFLAGS_AVX512F = @CFLAGS_AVX512F@ @@ -760,6 +789,8 @@ CFLAGS_SSE41 = @CFLAGS_SSE41@ CFLAGS_SSSE3 = @CFLAGS_SSSE3@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ +CSCOPE = @CSCOPE@ +CTAGS = @CTAGS@ CWFLAGS = @CWFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ @@ -776,8 +807,10 @@ ENABLE_VALGRIND_drd = @ENABLE_VALGRIND_drd@ ENABLE_VALGRIND_helgrind = @ENABLE_VALGRIND_helgrind@ ENABLE_VALGRIND_memcheck = @ENABLE_VALGRIND_memcheck@ ENABLE_VALGRIND_sgcheck = @ENABLE_VALGRIND_sgcheck@ +ETAGS = @ETAGS@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ +FILECMD = @FILECMD@ GREP = @GREP@ HAVE_AMD64_ASM_V = @HAVE_AMD64_ASM_V@ HAVE_AVX_ASM_V = @HAVE_AVX_ASM_V@ @@ -820,6 +853,7 @@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKGCONFIG_LIBS_PRIVATE = @PKGCONFIG_LIBS_PRIVATE@ PTHREAD_CC = @PTHREAD_CC@ PTHREAD_CFLAGS = @PTHREAD_CFLAGS@ +PTHREAD_CXX = @PTHREAD_CXX@ PTHREAD_LIBS = @PTHREAD_LIBS@ RANLIB = @RANLIB@ SAFECODE_HOME = @SAFECODE_HOME@ @@ -845,8 +879,10 @@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ +am__rm_f_notfound = @am__rm_f_notfound@ am__tar = @am__tar@ am__untar = @am__untar@ +am__xargs_n = @am__xargs_n@ ax_pthread_config = @ax_pthread_config@ bindir = @bindir@ build = @build@ @@ -880,21 +916,29 @@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ +runstatedir = @runstatedir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ +target = @target@ target_alias = @target_alias@ +target_cpu = @target_cpu@ +target_os = @target_os@ +target_vendor = @target_vendor@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ valgrind_enabled_tools = @valgrind_enabled_tools@ valgrind_tools = @valgrind_tools@ EXTRA_DIST = \ + run.sh \ cmptest.h \ wasi-test-wrapper.sh \ wintest.bat \ pre.js.inc \ + aead_aegis128l.exp \ + aead_aegis256.exp \ aead_aes256gcm.exp \ aead_aes256gcm2.exp \ aead_chacha20poly1305.exp \ @@ -929,9 +973,9 @@ EXTRA_DIST = \ generichash2.exp \ generichash3.exp \ hash.exp \ - hash2.exp \ hash3.exp \ kdf.exp \ + kdf_hkdf.exp \ keygen.exp \ kx.exp \ metamorphic.exp \ @@ -958,7 +1002,7 @@ EXTRA_DIST = \ secretbox8.exp \ secretbox_easy.exp \ secretbox_easy2.exp \ - secretstream.exp \ + secretstream_xchacha20poly1305.exp \ shorthash.exp \ sign.exp \ siphashx24.exp \ @@ -975,6 +1019,8 @@ EXTRA_DIST = \ xchacha20.exp DISTCLEANFILES = \ + aead_aegis128l.res \ + aead_aegis256.res \ aead_aes256gcm.res \ aead_aes256gcm2.res \ aead_chacha20poly1305.res \ @@ -1012,6 +1058,7 @@ DISTCLEANFILES = \ hash2.res \ hash3.res \ kdf.res \ + kdf_hkdf.res \ keygen.res \ kx.res \ metamorphic.res \ @@ -1038,7 +1085,7 @@ DISTCLEANFILES = \ secretbox8.res \ secretbox_easy.res \ secretbox_easy2.res \ - secretstream.res \ + secretstream_xchacha20poly1305.res \ shorthash.res \ sign.res \ siphashx24.res \ @@ -1063,22 +1110,26 @@ AM_CPPFLAGS = \ -I$(top_srcdir)/test/quirks AM_LDFLAGS = @TEST_LDFLAGS@ -TESTS_TARGETS = aead_aes256gcm aead_aes256gcm2 aead_chacha20poly1305 \ - aead_chacha20poly13052 aead_xchacha20poly1305 auth auth2 auth3 \ - auth5 auth6 auth7 box box2 box7 box8 box_easy box_easy2 \ - box_seal box_seed chacha20 codecs core1 core2 core3 core4 \ - core5 core6 ed25519_convert generichash generichash2 \ - generichash3 hash hash3 kdf keygen kx metamorphic misuse \ - onetimeauth onetimeauth2 onetimeauth7 pwhash_argon2i \ - pwhash_argon2id randombytes scalarmult scalarmult2 scalarmult5 \ - scalarmult6 scalarmult7 scalarmult8 secretbox secretbox2 \ - secretbox7 secretbox8 secretbox_easy secretbox_easy2 \ - secretstream shorthash sign sodium_core sodium_utils \ - sodium_version stream stream2 stream3 stream4 verify1 \ - $(am__append_1) $(am__append_2) +TESTS_TARGETS = aead_aegis128l aead_aegis256 aead_aes256gcm \ + aead_aes256gcm2 aead_chacha20poly1305 aead_chacha20poly13052 \ + aead_xchacha20poly1305 auth auth2 auth3 auth5 auth6 auth7 box \ + box2 box7 box8 box_easy box_easy2 box_seal box_seed chacha20 \ + codecs core1 core2 core3 core4 core5 core6 ed25519_convert \ + generichash generichash2 generichash3 hash hash3 kdf keygen kx \ + metamorphic misuse onetimeauth onetimeauth2 onetimeauth7 \ + pwhash_argon2i pwhash_argon2id randombytes scalarmult \ + scalarmult2 scalarmult5 scalarmult6 scalarmult7 scalarmult8 \ + secretbox secretbox2 secretbox7 secretbox8 secretbox_easy \ + secretbox_easy2 secretstream_xchacha20poly1305 shorthash sign \ + sodium_core sodium_utils sodium_version stream stream2 stream3 \ + stream4 verify1 $(am__append_1) $(am__append_2) TESTS_LDADD = \ ${top_builddir}/src/libsodium/libsodium.la +aead_aegis128l_SOURCE = cmptest.h aead_aegis128l.c +aead_aegis128l_LDADD = $(TESTS_LDADD) +aead_aegis256_SOURCE = cmptest.h aead_aegis256.c +aead_aegis256_LDADD = $(TESTS_LDADD) aead_aes256gcm_SOURCE = cmptest.h aead_aes256gcm.c aead_aes256gcm_LDADD = $(TESTS_LDADD) aead_aes256gcm2_SOURCE = cmptest.h aead_aes256gcm2.c @@ -1151,6 +1202,8 @@ hash3_SOURCE = cmptest.h hash3.c hash3_LDADD = $(TESTS_LDADD) kdf_SOURCE = cmptest.h kdf.c kdf_LDADD = $(TESTS_LDADD) +kdf_hkdf_SOURCE = cmptest.h kdf_hkdf.c +kdf_hkdf_LDADD = $(TESTS_LDADD) keygen_SOURCE = cmptest.h keygen.c keygen_LDADD = $(TESTS_LDADD) kx_SOURCE = cmptest.h kx.c @@ -1203,8 +1256,8 @@ secretbox_easy_SOURCE = cmptest.h secretbox_easy.c secretbox_easy_LDADD = $(TESTS_LDADD) secretbox_easy2_SOURCE = cmptest.h secretbox_easy2.c secretbox_easy2_LDADD = $(TESTS_LDADD) -secretstream_SOURCE = cmptest.h secretstream.c -secretstream_LDADD = $(TESTS_LDADD) +secretstream_xchacha20poly1305_SOURCE = cmptest.h secretstream_xchacha20poly1305.c +secretstream_xchacha20poly1305_LDADD = $(TESTS_LDADD) shorthash_SOURCE = cmptest.h shorthash.c shorthash_LDADD = $(TESTS_LDADD) sign_SOURCE = cmptest.h sign.c @@ -1269,13 +1322,16 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) $(am__aclocal_m4_deps): clean-checkPROGRAMS: - @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ - echo " rm -f" $$list; \ - rm -f $$list || exit $$?; \ - test -n "$(EXEEXT)" || exit 0; \ - list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ - echo " rm -f" $$list; \ - rm -f $$list + $(am__rm_f) $(check_PROGRAMS) + test -z "$(EXEEXT)" || $(am__rm_f) $(check_PROGRAMS:$(EXEEXT)=) + +aead_aegis128l$(EXEEXT): $(aead_aegis128l_OBJECTS) $(aead_aegis128l_DEPENDENCIES) $(EXTRA_aead_aegis128l_DEPENDENCIES) + @rm -f aead_aegis128l$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(aead_aegis128l_OBJECTS) $(aead_aegis128l_LDADD) $(LIBS) + +aead_aegis256$(EXEEXT): $(aead_aegis256_OBJECTS) $(aead_aegis256_DEPENDENCIES) $(EXTRA_aead_aegis256_DEPENDENCIES) + @rm -f aead_aegis256$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(aead_aegis256_OBJECTS) $(aead_aegis256_LDADD) $(LIBS) aead_aes256gcm$(EXEEXT): $(aead_aes256gcm_OBJECTS) $(aead_aes256gcm_DEPENDENCIES) $(EXTRA_aead_aes256gcm_DEPENDENCIES) @rm -f aead_aes256gcm$(EXEEXT) @@ -1421,6 +1477,10 @@ kdf$(EXEEXT): $(kdf_OBJECTS) $(kdf_DEPENDENCIES) $(EXTRA_kdf_DEPENDENCIES) @rm -f kdf$(EXEEXT) $(AM_V_CCLD)$(LINK) $(kdf_OBJECTS) $(kdf_LDADD) $(LIBS) +kdf_hkdf$(EXEEXT): $(kdf_hkdf_OBJECTS) $(kdf_hkdf_DEPENDENCIES) $(EXTRA_kdf_hkdf_DEPENDENCIES) + @rm -f kdf_hkdf$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(kdf_hkdf_OBJECTS) $(kdf_hkdf_LDADD) $(LIBS) + keygen$(EXEEXT): $(keygen_OBJECTS) $(keygen_DEPENDENCIES) $(EXTRA_keygen_DEPENDENCIES) @rm -f keygen$(EXEEXT) $(AM_V_CCLD)$(LINK) $(keygen_OBJECTS) $(keygen_LDADD) $(LIBS) @@ -1525,9 +1585,9 @@ secretbox_easy2$(EXEEXT): $(secretbox_easy2_OBJECTS) $(secretbox_easy2_DEPENDENC @rm -f secretbox_easy2$(EXEEXT) $(AM_V_CCLD)$(LINK) $(secretbox_easy2_OBJECTS) $(secretbox_easy2_LDADD) $(LIBS) -secretstream$(EXEEXT): $(secretstream_OBJECTS) $(secretstream_DEPENDENCIES) $(EXTRA_secretstream_DEPENDENCIES) - @rm -f secretstream$(EXEEXT) - $(AM_V_CCLD)$(LINK) $(secretstream_OBJECTS) $(secretstream_LDADD) $(LIBS) +secretstream_xchacha20poly1305$(EXEEXT): $(secretstream_xchacha20poly1305_OBJECTS) $(secretstream_xchacha20poly1305_DEPENDENCIES) $(EXTRA_secretstream_xchacha20poly1305_DEPENDENCIES) + @rm -f secretstream_xchacha20poly1305$(EXEEXT) + $(AM_V_CCLD)$(LINK) $(secretstream_xchacha20poly1305_OBJECTS) $(secretstream_xchacha20poly1305_LDADD) $(LIBS) shorthash$(EXEEXT): $(shorthash_OBJECTS) $(shorthash_DEPENDENCIES) $(EXTRA_shorthash_DEPENDENCIES) @rm -f shorthash$(EXEEXT) @@ -1591,6 +1651,8 @@ mostlyclean-compile: distclean-compile: -rm -f *.tab.c +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aead_aegis128l.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aead_aegis256.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aead_aes256gcm.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aead_aes256gcm2.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aead_chacha20poly1305.Po@am__quote@ # am--include-marker @@ -1627,6 +1689,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hash.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hash3.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kdf.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kdf_hkdf.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/keygen.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/kx.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/metamorphic.Po@am__quote@ # am--include-marker @@ -1653,7 +1716,7 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/secretbox8.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/secretbox_easy.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/secretbox_easy2.Po@am__quote@ # am--include-marker -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/secretstream.Po@am__quote@ # am--include-marker +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/secretstream_xchacha20poly1305.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/shorthash.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sign.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/siphashx24.Po@am__quote@ # am--include-marker @@ -1671,7 +1734,7 @@ distclean-compile: $(am__depfiles_remade): @$(MKDIR_P) $(@D) - @echo '# dummy' >$@-t && $(am__mv) $@-t $@ + @: >>$@ am--depfiles: $(am__depfiles_remade) @@ -1704,6 +1767,11 @@ mostlyclean-libtool: clean-libtool: -rm -rf .libs _libs +check-valgrind-local: +check-valgrind-memcheck-local: +check-valgrind-helgrind-local: +check-valgrind-drd-local: +check-valgrind-sgcheck-local: ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique @@ -1770,7 +1838,6 @@ distclean-tags: am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) am--force-recheck: @: - $(TEST_SUITE_LOG): $(TEST_LOGS) @$(am__set_TESTS_bases); \ am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ @@ -1846,10 +1913,37 @@ $(TEST_SUITE_LOG): $(TEST_LOGS) result_count $$1 "XPASS:" $$xpass "$$red"; \ result_count $$1 "ERROR:" $$error "$$mgn"; \ }; \ + output_system_information () \ + { \ + echo; \ + { uname -a | $(AWK) '{ \ + printf "System information (uname -a):"; \ + for (i = 1; i < NF; ++i) \ + { \ + if (i != 2) \ + printf " %s", $$i; \ + } \ + printf "\n"; \ +}'; } 2>&1; \ + if test -r /etc/os-release; then \ + echo "Distribution information (/etc/os-release):"; \ + sed 8q /etc/os-release; \ + elif test -r /etc/issue; then \ + echo "Distribution information (/etc/issue):"; \ + cat /etc/issue; \ + fi; \ + }; \ + please_report () \ + { \ +echo "Some test(s) failed. Please report this to $(PACKAGE_BUGREPORT),"; \ +echo "together with the test-suite.log file (gzipped) and your system"; \ +echo "information. Thanks."; \ + }; \ { \ echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ $(am__rst_title); \ create_testsuite_report --no-color; \ + output_system_information; \ echo; \ echo ".. contents:: :depth: 2"; \ echo; \ @@ -1864,31 +1958,30 @@ $(TEST_SUITE_LOG): $(TEST_LOGS) test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ fi; \ echo "$${col}$$br$${std}"; \ - echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \ + echo "$${col}Testsuite summary"$(AM_TESTSUITE_SUMMARY_HEADER)"$${std}"; \ echo "$${col}$$br$${std}"; \ create_testsuite_report --maybe-color; \ echo "$$col$$br$$std"; \ if $$success; then :; else \ - echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ + echo "$${col}See $(subdir)/$(TEST_SUITE_LOG) for debugging.$${std}";\ if test -n "$(PACKAGE_BUGREPORT)"; then \ - echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ + please_report | sed -e "s/^/$${col}/" -e s/'$$'/"$${std}"/; \ fi; \ echo "$$col$$br$$std"; \ fi; \ $$success || exit 1 check-TESTS: $(check_PROGRAMS) - @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list - @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @$(am__rm_f) $(RECHECK_LOGS) + @$(am__rm_f) $(RECHECK_LOGS:.log=.trs) + @$(am__rm_f) $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ log_list=`for i in $$bases; do echo $$i.log; done`; \ - trs_list=`for i in $$bases; do echo $$i.trs; done`; \ - log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ + log_list=`echo $$log_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ exit $$?; recheck: all $(check_PROGRAMS) - @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + @$(am__rm_f) $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ bases=`for i in $$bases; do echo $$i; done \ | $(am__list_recheck_tests)` || exit 1; \ @@ -1898,6 +1991,20 @@ recheck: all $(check_PROGRAMS) am__force_recheck=am--force-recheck \ TEST_LOGS="$$log_list"; \ exit $$? +aead_aegis128l.log: aead_aegis128l$(EXEEXT) + @p='aead_aegis128l$(EXEEXT)'; \ + b='aead_aegis128l'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) +aead_aegis256.log: aead_aegis256$(EXEEXT) + @p='aead_aegis256$(EXEEXT)'; \ + b='aead_aegis256'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) aead_aes256gcm.log: aead_aes256gcm$(EXEEXT) @p='aead_aes256gcm$(EXEEXT)'; \ b='aead_aes256gcm'; \ @@ -2290,9 +2397,9 @@ secretbox_easy2.log: secretbox_easy2$(EXEEXT) --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) -secretstream.log: secretstream$(EXEEXT) - @p='secretstream$(EXEEXT)'; \ - b='secretstream'; \ +secretstream_xchacha20poly1305.log: secretstream_xchacha20poly1305$(EXEEXT) + @p='secretstream_xchacha20poly1305$(EXEEXT)'; \ + b='secretstream_xchacha20poly1305'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ @@ -2395,6 +2502,13 @@ core_ristretto255.log: core_ristretto255$(EXEEXT) --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) +kdf_hkdf.log: kdf_hkdf$(EXEEXT) + @p='kdf_hkdf$(EXEEXT)'; \ + b='kdf_hkdf'; \ + $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ + --log-file $$b.log --trs-file $$b.trs \ + $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ + "$$tst" $(AM_TESTS_FD_REDIRECT) pwhash_scrypt.log: pwhash_scrypt$(EXEEXT) @p='pwhash_scrypt$(EXEEXT)'; \ b='pwhash_scrypt'; \ @@ -2511,27 +2625,49 @@ install-strip: "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: - -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) - -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) - -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) + -$(am__rm_f) $(TEST_LOGS) + -$(am__rm_f) $(TEST_LOGS:.log=.trs) + -$(am__rm_f) $(TEST_SUITE_LOG) clean-generic: distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) - -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) + -$(am__rm_f) $(CONFIG_CLEAN_FILES) + -test . = "$(srcdir)" || $(am__rm_f) $(CONFIG_CLEAN_VPATH_FILES) + -$(am__rm_f) $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." +check-valgrind: check-valgrind-am + +check-valgrind-am: check-valgrind-local + +check-valgrind-drd: check-valgrind-drd-am + +check-valgrind-drd-am: check-valgrind-drd-local + +check-valgrind-helgrind: check-valgrind-helgrind-am + +check-valgrind-helgrind-am: check-valgrind-helgrind-local + +check-valgrind-memcheck: check-valgrind-memcheck-am + +check-valgrind-memcheck-am: check-valgrind-memcheck-local + +check-valgrind-sgcheck: check-valgrind-sgcheck-am + +check-valgrind-sgcheck-am: check-valgrind-sgcheck-local + clean: clean-am clean-am: clean-checkPROGRAMS clean-generic clean-libtool \ mostlyclean-am distclean: distclean-am - -rm -f ./$(DEPDIR)/aead_aes256gcm.Po + -rm -f ./$(DEPDIR)/aead_aegis128l.Po + -rm -f ./$(DEPDIR)/aead_aegis256.Po + -rm -f ./$(DEPDIR)/aead_aes256gcm.Po -rm -f ./$(DEPDIR)/aead_aes256gcm2.Po -rm -f ./$(DEPDIR)/aead_chacha20poly1305.Po -rm -f ./$(DEPDIR)/aead_chacha20poly13052.Po @@ -2567,6 +2703,7 @@ distclean: distclean-am -rm -f ./$(DEPDIR)/hash.Po -rm -f ./$(DEPDIR)/hash3.Po -rm -f ./$(DEPDIR)/kdf.Po + -rm -f ./$(DEPDIR)/kdf_hkdf.Po -rm -f ./$(DEPDIR)/keygen.Po -rm -f ./$(DEPDIR)/kx.Po -rm -f ./$(DEPDIR)/metamorphic.Po @@ -2593,7 +2730,7 @@ distclean: distclean-am -rm -f ./$(DEPDIR)/secretbox8.Po -rm -f ./$(DEPDIR)/secretbox_easy.Po -rm -f ./$(DEPDIR)/secretbox_easy2.Po - -rm -f ./$(DEPDIR)/secretstream.Po + -rm -f ./$(DEPDIR)/secretstream_xchacha20poly1305.Po -rm -f ./$(DEPDIR)/shorthash.Po -rm -f ./$(DEPDIR)/sign.Po -rm -f ./$(DEPDIR)/siphashx24.Po @@ -2653,7 +2790,9 @@ install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am - -rm -f ./$(DEPDIR)/aead_aes256gcm.Po + -rm -f ./$(DEPDIR)/aead_aegis128l.Po + -rm -f ./$(DEPDIR)/aead_aegis256.Po + -rm -f ./$(DEPDIR)/aead_aes256gcm.Po -rm -f ./$(DEPDIR)/aead_aes256gcm2.Po -rm -f ./$(DEPDIR)/aead_chacha20poly1305.Po -rm -f ./$(DEPDIR)/aead_chacha20poly13052.Po @@ -2689,6 +2828,7 @@ maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/hash.Po -rm -f ./$(DEPDIR)/hash3.Po -rm -f ./$(DEPDIR)/kdf.Po + -rm -f ./$(DEPDIR)/kdf_hkdf.Po -rm -f ./$(DEPDIR)/keygen.Po -rm -f ./$(DEPDIR)/kx.Po -rm -f ./$(DEPDIR)/metamorphic.Po @@ -2715,7 +2855,7 @@ maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/secretbox8.Po -rm -f ./$(DEPDIR)/secretbox_easy.Po -rm -f ./$(DEPDIR)/secretbox_easy2.Po - -rm -f ./$(DEPDIR)/secretstream.Po + -rm -f ./$(DEPDIR)/secretstream_xchacha20poly1305.Po -rm -f ./$(DEPDIR)/shorthash.Po -rm -f ./$(DEPDIR)/sign.Po -rm -f ./$(DEPDIR)/siphashx24.Po @@ -2751,15 +2891,20 @@ uninstall-am: .MAKE: check-am install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \ - check-am clean clean-checkPROGRAMS clean-generic clean-libtool \ - cscopelist-am ctags ctags-am distclean distclean-compile \ - distclean-generic distclean-libtool distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-dvi install-dvi-am \ - install-exec install-exec-am install-html install-html-am \ - install-info install-info-am install-man install-pdf \ - install-pdf-am install-ps install-ps-am install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ + check-am check-valgrind-am check-valgrind-drd-am \ + check-valgrind-drd-local check-valgrind-helgrind-am \ + check-valgrind-helgrind-local check-valgrind-local \ + check-valgrind-memcheck-am check-valgrind-memcheck-local \ + check-valgrind-sgcheck-am check-valgrind-sgcheck-local clean \ + clean-checkPROGRAMS clean-generic clean-libtool cscopelist-am \ + ctags ctags-am distclean distclean-compile distclean-generic \ + distclean-libtool distclean-tags distdir dvi dvi-am html \ + html-am info info-am install install-am install-data \ + install-data-am install-dvi install-dvi-am install-exec \ + install-exec-am install-html install-html-am install-info \ + install-info-am install-man install-pdf install-pdf-am \ + install-ps install-ps-am install-strip installcheck \ + installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ recheck tags tags-am uninstall uninstall-am @@ -2774,3 +2919,10 @@ verify: check # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: + +# Tell GNU make to disable its built-in pattern rules. +%:: %,v +%:: RCS/%,v +%:: RCS/% +%:: s.% +%:: SCCS/s.% diff --git a/subprojects/libsodium/test/default/aead_aegis128l.c b/subprojects/libsodium/test/default/aead_aegis128l.c @@ -0,0 +1,642 @@ +#define TEST_NAME "aead_aegis128l" +#include "cmptest.h" + +static struct { + const char *key_hex; + const char *nonce_hex; + const char *message_hex; + const char *ad_hex; + const char *ciphertext_hex; + const char *mac_hex; +} tests[] = { + { "54662e55bb4771f9711fe5301d7412fe", "e51d417ab10a2931d8d22a9fffb98e3a", + "04f672f8cdb3e71d032d52c064bc33ecf8aad3d40c41d5806cc306766c057c50b500af5c550d076d34cc3a74a2b4" + "bed195ffa3e8eddf953aefe9aed2bc14349c700ab7e4cb974fb31615a9ff70fb44307055523ab378b133fefc8830" + "13ce23bb01b23aeda15f85e65cdf02a291a0454900cb261872d5205737fd7410", + "3b762e3ab5d06cb2896b852ea70303f289f2775401b7808e30272f", + "d6736371f35eb067244dd7963ad2e0cd3949452cbd4c220be55082498ed3b230f579d78844311652a9958e82f172" + "bb8072c4b1114ec531a6ccb340ddd86caf32a0d4c9c45738e9ec9c0d9154612f7d90465f3a277bebd667c0af0edb" + "6935d8dffbdee96c1a96e4c4318f5d3bc90c1c8d5729e1a402f765bdc9b26b08", + "ee9595bb3f1b32000578ffb751b508655b3cae8fecaf44f40d740fa0347e283a" }, + { "46a5c72e03d900b48f829df00ecb88b9", "b25187e4b77b6770c35c7a962584597d", + "fc8083311b38a80c04e57d069661b273264310906781eb7e4e44c6416f7336267674a44a7c54ed6361b43ef95005" + "14e5d9e71f8b5c33aece756b64f3ed011922facbec7c3ffd27d01a853435bde551372806bd0c", + "b73c81239e01cd81b0de13247ca4e3528b87f3078e2b674a667430b1dbdc3e93657131e654a4182b4c4ab01a33b3" + "6e946f1fcc55aab06fc6f56d", + "51189448af53ae3630c06a167ceefe6b9b5eba746fb9b53f4b3104d2b15b6020fa8998e182eb9c9d6b6463939e50" + "723780f983733206ae6f11b986d95abe83555e64f8d3242d7e8055fcb8e2df8e41d318f06728", + "caf8957f9ebc9a88469c04089962487a3c77040b82661616c5d5c83e974eae1e" }, + { "e343d75de99e6d73543968437d3dcf6a", "317a5808ed5debf6f527a780e0896b2d", + "247045cb40dea9c514a885444c526ac867b1b80e4728a23b63f596", "323094c01e", + "18cb5d2fc5e27bdda5ba16f1320da42049759368548e5bd96f2dbc", + "5d3e88816daf20f11018456b58b2614050b93b222f03be079b39a9bb2de49f47" }, + { "7db9c2721a03931c880f9e714bbf2211", "27f642398299ada7fdda1895ee4589f0", + "dc5180954df0c3391a60b44cbf70aee72b7dbb2addc90a0bf2ceac6113287eb501fe1ea9f4c51822664b82fe0279" + "b039f4", + "6dd5e43033fa6f021059a353edaf1f870387693054d0a2360fd1f6941a68f48ba972a1bc0816a446a6186e4a9a2f" + "9df556bf709470137b8e60d9daa2", + "c8a7d9131cebfa5388003cc30deac523aa9b09d148affff06ba40400e09ca900db770e07cedf5cd0647f6723c810" + "ffcb59", + "2c17a7022f6500450e86c8afdd60d3da535c2322fdf84f3dc67429e6ad92673f" }, + { "bef8a47bbf0ffc4ab56ad5d9899f42b6", "3a2195a5196a0d785e04b38dd62f056d", + "5aa0dc37e4db1de35789398b25dc656d05cdc6737de4e30ce944b304ec752bbd10ebfa51feff99dfcfe26b8526cc" + "9b0cf1ba3d1685fb26cfc0c8888fd3cdf55577a516328b289eebda2e14f15eeb1d0f4207efebe3803618d43d9968" + "8e6c", + "a4a290a0d719b1aaf58f24152402b2f36957f44ea8a2d76b045390f5e0a3559a8ec5b2f871fc6095152183b7be75" + "65d4953b593f854b8477e29ce0cdddce5cf8739ab56288c26c81921f1fbae38b90b287b4622ca8b5b6c0b4b02196" + "e73ee56af6ae427ca7ae3ca0", + "0ead975179d64f2b927440bf9ef666ab921e7a3b0832949f31315c2931451c5ddf810c17ad0330073922c07a18eb" + "665aca01c05de58f7d159a74884f9d90cc10dc8c017ab61b820fc3dd32be52f3f7265e3a7a912a230b2a7ed19992" + "e693", + "f61ace25382fc3f88ec63eab23a6f9f6d1be65d149428bbb778a77428f909863" }, + { "01f1cea5b7e20db64a67502bb4715033", "7336701bbc2d766167b57c452d010f02", + "b3669d31ef8040dd6f462624977d69cfd1869fb19946595759b7265eb98b51f579fddce4bd38452fe3", + "d007e9ce654ec9a8b44e3655dcac889176fbf8012b133c4effe70b716eff43264d67d84a3d8504858c01002957ca" + "c6eb75d94635fb708343a18e20615e4ecb963bd98a8e7bee66520fba5c2991541c1e7863c1c97ae7ba6c3c34f116" + "1518097b6e75dcfb3aa3e93995eb39", + "4e643f7a1b8c0d595c8ff2b00c0145deb5bfa13d8a1b75d7a731f2258b690e1a3b2ce2cbacc6d05c42", + "8f33c6494f971462bcf82a508f341905b8febf9a9d25363ce853d59230d5e60b" }, + { "76d53860e1c45cf60d76d8336948e337", "579c0f0993f13470fa301cd4c6fbe99a", + "d0f5d2b3b824fe01ca36d00d47434519b2112195093a06d9d07d7f4f9c5b8f2a4c68668265c40d6edd6e12b5a350" + "e4af11f1ee6226bf307a1a6c25318c0d3aa0421edf565ad42d524f69d0fef06c236c1f0d0e50261e205f381c3e11" + "96dd8827b9990d674288f8250596", + "a7a77cc847afdfb9dc8ceccc621462302f31233a830b3827ca68618e604c95ba8615f6ebb5ff1c2c66727e70c038" + "554619f96f79d08902fc70111f853766a2db04e51d", + "def4fcb75110820298f08a8a4941434deccb952dec01215f5e7f5a2509fcb9e2a994a77d5eaa617da9cf2f03483f" + "aff5831506e5617707b88e08195b6a993219898c3ead769ebaa002934d3c80023833d7ce4a7a989596de6fe78eb0" + "237e8caab0a9fcd2625af80caad6", + "a4a60bf81cb2ce55df3c5864eac4c93d7748010a1adb6e5110d389e0501d7004" }, + { "cd05e08e14686623fd334780439c4ae3", "d05ba5a655bf7b1be7500f205c9c80b9", + "021c20518825c167a746a728578a0f470b2035c7b39c75f3e492bcc2e6e96035c4fff65dfbfa93cbc7a37828a0cd" + "62bf1b20b3bb89425ae647e021cde586f652eb98c98b1ac1018c6fe3e046f41545bbfdbf94dca48e465aaed8efb7" + "eab5ea143e5b95b72a078f8fb58d8ecfdd9a3a968e2468b6", + "be9255f750498ce672c877285e649318bd5bf07cdc5902b7de61a8415b6fbf20b1e432ebc9f8f9c8e3094ff6dffd" + "1b1e0c3cc5", + "faa851ddfe54b01cf1a3caf34815c6db0145ddebd1f34ca9edd479bd4a3bb4bac21c2b5d365ff4d389a764bcc143" + "6e51267ed3e4f225b7cda1fbf25d221d91b59aed0b4d20f71859f41e85e15a02e2bcd59913d8ae019d1f01ede317" + "b4ff94ed2b05650259a705c3b2be2c2a9c82a4809dab7b03", + "83b60061bc457578effce5462091e0a2b1f8ee35dbdb6a6b17e4e6179df6eb18" }, + { "6870a5652199e2f17407185bd7cf18eb", "942988922482351c317244b26587c560", + "49b2f6765f7f552f8704671271d703b3b02157f71ed84e64481be8bbd4f3493bfd3f313ac62ba4e9a7d86288533a" + "7bc7a4257cad5db04bb80d6574e473519eccd15cd2", + "6cc34a81ee984b436947b31574473e0a849a341db0ebc67f64efb39c9e118f65cfb25d1d898b4ee8052f700cb43c" + "be744d70b71d2086a89ad12dd67feceacb092a861ba80e41808c625fbdce017d51916e1fb5b38b0beebb27478d83" + "90ec79b3f3902a4ac22d79", + "82d3ae3aea3870e40fa48da698adcb596eb43fb063866f6231bb744b687e32e72117a03da08a635e4ed0f255f28f" + "3db6f0b8a7238d0244994a507fe75ddd17138b0605", + "a3feae07a737428751dc2c92301bc012b0d5c9c41a7543d248d6213a90343565" }, + { "15a87aee858f5723beb477b2cc039d14", "6ce71c763784e59fba852ae39b25de3a", + "25d1d38a8e9e8c34564abbfcba69035ce2f78df8626543e7639f2f23d742853e34880e7bc6d684ed3075abdfb91e" + "36076242dc53d60513333f59d139e680aa246b0e7e6092e8d4e6ab471459068c2a83b07e8b7969c911e3bff7558c" + "af02b3f3e6de7ae9122d533558868d993b8242b2328834a88cd656a941", + "26fde5885fd22bdcba8b5c1b5f66d09c7da7bfef2790e6dd2a98a351056044495fe4", + "2e241f3f96e8bde7d2b5cfad94461d6c7282405c77918a2a8731711175211814e20e72ce01139643f58a2336c05c" + "c27458f042ff063bc73fbee2ca8c099ff1f3fbe8517fce6cd3d54567220218cc67b4ef52767f75fe514e8ec49013" + "d9fa787685a5a81efe550248f342eaade9cd61fb5037634f2bf621c944", + "694a5b5ae2081becf4d38b2958d3557438b9f04dbefbe649baa91924e17e4d88" }, + { "23e2250df6b870b6eebbce928cd1a80f", "279f73beda18846d7170c29414590029", + "9cdd4e34495b4a03ca2c5bef9074c1", + "f306eb122b1907b4b6bccc77984ea7be4a28f9ca3615135d4c84ad74d7469efefbbff997bb495806a3d9ab274b42" + "28cb894fceeb24c4905e121efbd3ce8be668dfee4f9e38584ba6c3374337d3c884cdaddcd96f63df225ddc879e0b" + "a4bce0125dd0", + "8821c6d2c36ae97bef1b9d78c1afba", + "155b5b0c92176ed1a2248bc86b04570620e97a2a601a3d730d53236f43696c28" }, + { "82f02cd289d07f40acf9a1d2b1cf7f06", "09162f09c3893bd2c5e4f2c8f6ec9930", + "29f1d0e8aef96c9936eb5bcb32b0f751b25a7a46d4cc5a33d5f96dcaea757b2b", + "4ccb0ba7f1b2eecbe3dc3ba47f797201ca656ab04e5b38df9b95ef24ba02a5ef04a9a8122f954048581d275e", + "6b8f329fa3e905b7c0df490f18a13ab3b6be6701cba59a1ee7c12d054c500e58", + "8c97a1010a25a9e9047d4dded0235450f488d3c18b460316e5ef5517edc82e3b" }, + { "a28c7a79d3d7d7b372c5cb4eb66201ba", "3c27d1ca6e8fd19cbf2dbd81c87d2ac0", + "0ff33640432edcf34a2df2527ca13a0340d5adcae1d10589edbc89701f5093efeaf6d7d3f97a778052a76a6efe7b" + "37021a4fbc8205f26f17dbd0c68b60c6403c4160985255aeac23c3bc88b1d8c11fd4197ba366962c", + "96bec6c8014708e9142a8ea0fd496f89f5a2414f4296ae0a185b13f362f2", + "f20be34587afaa4300683655ea16a292bfc7f2779cb771e520c6b0952e41a2b89e45f6c4b571779d573f1383b5e3" + "11f71ca89379b8a3eb9d9cde72b16e0f782058e9bb4df4731cbd7c67af1c459061ccff149da3bcdc", + "d9dd91cdfc19da4a95fca7229f296a74aafc0d78b2b398e7dc089cfc6309d281" }, + { "24d66092958836e491cf974f34ee7ca9", "1c04e8166ef37a2a5d34b4462a7ca8bd", + "01a77fb558d8d94c16eccc82b49f53823597272de8e6df070fefd202042665ef5788bab86c70dc3e571e3b372654" + "494e552ef00462bf0f7fdeca8efbaa51f3da63e6f18fd13a4668b7fb1a89464a09a17d9ce709b0b8f079d6bf93ed" + "4871c0", + "3c082dae68ee1cd6b8d1ef79593132e68e373eec746d13583f28d42730bfa18ed77ee83ad6c3db24bcda6d5e2925" + "970dc01d1968b744cf3753e597ef831dcab728ce66ef3da0ab872cb0dedf77922a57abfb", + "47ec41abfe34c4ece7ff8f3ba179238f38f3e527d97d7f3f6ada79a9609e715cd0acec31f0a0df25c7ac0bb894fe" + "791cc467a098710e92af75a14e68d9241c160d4587f7da279deaa9cc9d9c5a6e97b231021ab2ba9c63473cf269ef" + "294d1b", + "807d350484ead90c1470efc0c6e334999b204444034151c3b80961faa4b821d3" }, + { "78f67aada609c94a7c79f2fe9bf9c82e", "9ad46b00946c799b17b683ed3d920896", + "3fc884334f762cede042a56b4a89ad9eaf474459371f2daf7c157a352cd5ae6d45662593bd3eaba7bf59ed569429" + "c52153599f02e3263b2784be00e52e30d0347553fe8aa70a071c3f2e34593d1e78692f9a194800571eaaeedcf297" + "0784426959e0", + "80bb105971fd223f89efae15ae1b5e252c7e1c761b6abd5509d8354adbbb5007928763e715aad67b2109ac60afc7" + "3e386a75084c77a5af1021ddb4bc636c32a70ee95c6ef5eea9cba0d1c944754f328208ff78f7b0718899bacdf5d6" + "e603e1b098acbffc83a86a0e122078338e0bd5", + "325ce1b0bb065488f9f74f779bdc433da58412b3834005b4661491e7d9d6c2a371560ca7d649093a7ab2475548ed" + "b37b425c23f75eb1bf79b972714469174fc85665dbe2af774719d803c2426f067ae68da1ae0783ae376970055cc2" + "8d484ecae2e3", + "5f755de0d9a033967a9d23e3357332ad9640983fc121cc9104c8e79b37a9ea6d" }, + { "ba4c7e6a36e4684631fa5ede07b678cf", "ed722d3769b33d82626ce89bb4d212d9", + "ae106ad8029d73ff984de16db70772ca9adec5f2bffb1d92e12412b6f76f855463f47f1739d6e9a1fab5a9b7ff3e" + "ad419efd7fd7b31a0c5b9b992aa8d0ad754cb5ba371adfc60a5cdbcae37c4653b9cf5f46b015d31a03e10e288256" + "7d2c44255c30f1", + "1955a221ff4b3f271876a4bc04cfb41449881f6ff3a7e9aacaa1e992a5218af3294027709c1ec594bf863000ddb7" + "d561ca4c3f42340ee932e71eb8efd1b7dbd19f6ef0de28d437355b2b4cd1527cee849a315fc9a35ecb6e458e4af4" + "df07a9e108a0", + "aa24653b20af5925a19e486d0b28e3bafdb240aa984c8b365792443a5411c8385c8197d0a13f1a8a7686c02cc0f7" + "adbe1230736362afeb3c0ada988dec6d35fd298768866f64aac8dd560250e27bb1007a3fd4c312a8ce3af4af9ed2" + "7d5859ae56a3ac", + "b06f562123bfc9c4e36e2299da0d6987c2c191c2486ac2ff9e2baa156ce6cb81" }, + { "639668e0b0fbb192b83f870048d29c1c", "48ed7de6da13ba38a1e748eb9ea57529", "1ceca7", + "604b7b904ba56e1f2d17556236150e5bd19ba125f92e9adef0f75b38356fc9a1851ba34105805cae7e99dc7bdcf8" + "744c44f06e709c345cadcffde348d2d55c5c36cf5ee1f288509e7a878dc00daa3d9593afafd7a0d94fa78960b3ca" + "9fdb2b7d5746d1f4702080fadaf0cd6785373a16ceed056641aa4afe725e", + "0f5286", "b6b24c01ae14d452da68d75693fe772340ee1310d329281370c6c54231372be2" }, + { "94b94725497880ff10d89572b62d1029", "bbdb56d8112d298fd5686b93787e0011", + "f062bbe085b5f49ae4064f9ffd", "de189cbb1821775cb97888f25d4781ddb82d4664634f41", + "d317f2a31eaa3f23e84fc3eaa9", + "5098967201169e8ab8242b8e09322165127ef2155795f62fc1e55e6a72363fac" }, + { "8e6f1217eaf84aee8e5897f5860f184c", "a4e099068ad0b67f28b6902a40921dca", + "53c939f8d167e49980f8fd3ccc4a2ae3", + "4bb7fccecf15f0b32be37860507fc53812713194e2844855894ef916abbf9b5d", + "92e47292a4f02cc22d3392d1b6a089ce", + "a3eb3e03808499409b00f0bb635c6fbf12062469edb45f5bb252c08748e131ed" }, + { "6968acc00e83184e6024167672c5df8a", "2d5b193c93e8aa5302fb5bb20cd59504", "bd6b6830", + "7f4e725f4b0f84454e823b8193f1d8b39d78a8b12f1a2250beb0def895dd0aef8960652c071a82d9ad89910d9728" + "7e72848fba1623f441d4955a019f5c1a955b054db858722b1f15210c3a752fdbd2bd631620cc56c2c30d78ccb162" + "72eeeea1", + "c01c9b02", "9910104c7d6d91e99c167d027c4190701a21c2fcadc9874b1744cfda7b75b8c6" }, + { "1e7e0ef737799bb1e00ccd4e31da5ff9", "9d1111da7d3d329ab5d824404e4bdd60", + "76cbec797c2364c6ed70901db527c6a3471a84f8d297c64c9dbffd7c3204503ca6e51c8c88757500ed503ba86d73" + "67baf6b9f3f5f2b69308bef97232e67698ae10896ed70a66a7c40115770f3192b9168f66a359270c753bfffc5496" + "58fc7aba3d3943221e125a6f88e025cc024b753693", + "7e6c97d0fee9f249c7510c2a0abf9530ac49cecfffe2ae37c9d38ba60cd012d3e00b696ee54591", + "b04070df9cc5d032d1914eb69f9afeda61559ed98c7e5fbeb81930b242cd30cf097e4130b0cc45b3e3178ba5ff25" + "98493e1d1fe22fd14f3cc2de08fd8cbb3539d4c71c606adb7826c2a9e05ac36a6795293cdfab6d07fcfdedac099f" + "1ab9bfec63a32f7633e424e684ca8744b4ad2288ed", + "a0b933e1a706046c38967971e50c0ce9ececaabd188092313c654e9f297cf18a" }, + { "6dbf15415dae57093e6774f4a1b7e4d8", "bba38b490d740d7b3df0c9283d4a530c", + "fafe1562e69a0f5149e0ee65d14b42098a8a53a58d2cf07fd86f6c64cc4e67d9b5cf3655b5ed7f722d2073a3e9cc" + "8372efd9620a32d6443a328436dd5ae394700ddc171bef8cb0674b1fab87b3e93aa426aee92c7ff733c33f9e4e49" + "f614043a7fb42cf657e4e3c2", + "c742a929d2a766dde0fb0ce2d0faf790bd6c5feb63cb3126402aac7ef7c9ddfd408cd22bc6928a9b67426e20c3d9" + "b340cd7231f87ffbc29a8e6c23602b9dc434f5ab06bb8c049803b45cf088b919e8584091ecfca7259e0d130ddf4c" + "a45d44291024446f58f1271f", + "d8dda53eeb8b375930698379836e64014c22bd885b5b5cafb4dc65ed00aa947acb2792c46dfed8ecd155b21cfc98" + "ff163b403e3a9961805436678fd34942354094bc47663165341ed0b949c0ecb4da5499c1c8c87eab99ddfd0fc2d8" + "0a9a520461e3dc402c3d4b4f", + "f8e4c1f827d4c5dbe00e7794effc567089b8128a5b11e3c6c2e5e36414b4618a" }, + { "a6d38f5cebee041a0afe035caad48443", "cb7e7813c7018b25782f77e0ae7c84c7", + "6ef6c5d92f3acf78b3e2c8334038f364a51193e4e559b1458dd74c44269e69a7a6af22f531680c63270b22ee7154" + "7d72abc9b87bc5639a1b3a13f8613ad4d1742e8209ab", + "d536bed277bbb5a9", + "457fff7d0e1b61def59fbe99e81c08bc370bcac0240c9cec6d6a0de2c37f9950f5b2d12b8b21126af18d757c743a" + "2a9bf451ebcba235f9f48c31a63674f0e8a1c5af5094", + "269ee12821b981d794399bb759d233db2d60c1dcbc3a9a87dbb068551b032f1d" }, + { "753eb1d49c102d1e3a9bcfbcb1cfa369", "0e0cc4395844d363ceccc8a07a92a2d8", + "5166ac0bdba2b660af164fc847e4ad300675cda9f0acda47567f7952eea7084832f6dbfa0aae9f403a5bbbe307ad" + "40845cb08347588063ad3f1df766790c023f160ce21bdf372fb48e0f7e2ced50cb3f86c2fb257ad7863fadc5fe69" + "92bf1c4508308b259480007a628aacee94c258c91cd847f3d05251dadb96", + "5f590a65034eba433e57a9d089b2924f5f8482db6a467ea435478afc", + "f2fa7ed4fccf0388b7bb291977d2214d03dd30c4f81bab2df8f2c1cfaa46ff2fd14733cd7b8fefb6dd020ecab3eb" + "478d1fe0b849e057512fe7b897b171771a2b68d7fe6d9b70dcfbb6307dacba5409b7fdafc49752e4392111474388" + "afb6d79ed21a60c59234bafad676f88f7653765b4dc758c9fd930b2632a0", + "352c935b482696f9a4f40de117ac4efe5c38952c8a45e23242a86c66e79f7f4d" }, + { "711a437629429db2e14058e2a826dcbf", "eb036d6e483a212ff6ee25d970fe1ac3", + "29937c0efb36ed27fe7709d7179b4f38a2fc191b5e8d9616b58f6dc9ba2ab74e13bbdcd233e8726d90f7ded06c38" + "61582f27158732f997df9091446befe75855ab05b348d68f96e45445f44c31e9ba3e4d7be96d9c8e806535e79079" + "139c71fcc599fea8701e0c2edf606986eff1535afdfa51d1be2dfdee", + "", + "4a61f5d6b8e746bf6fb49ca2b16c22f4e9ffcdc89a3137b39bf5445fb6b989d5200f0c8d5538891a5e8979b5cd8c" + "734128b4e4ad98b0cd598c40ec9be74725dbca84c65a52f17ac983330b0b74e4193540f6357c3bcde4e8d8fc6942" + "314ba68115bf2a682756e3c42008803a81532708a0e7b5e3b8436145", + "4af113e2b6165247c2760ab445c6985306c81fb9ccebb8df0e57b0b044c52736" }, + { "a26d6028473bf7de23851d00d514455b", "05b87c16ebee8bb62365d265ac6818a2", + "baeef99e6d4d15be9ff68a5d94aee7afa3d898cf42f94ad572b089659708658534d198dd3fba47a48611e8d78da" + "d", + "5d77dd8066d3cea3b0762602ba6ae3d1ae1c27d1ebe70bfcdc068912def545362a5bd2", + "e4365eac2e7b5d02e7fc6c110895bcf193a0ebe28e81d0f6128a95e3e9183582ebb964d666972bd7fff8cd3870c" + "a", + "515045f7ad90ab569a6c8b90808d64346334e71d03db18d07d19f40b2b94fc7d" }, + { "9bb0e363275374f1771ababb7b96851c", "08cf3a6355ffbe621ea874e917729d4e", + "b380355f794d31e6e85fc81a49fdc2af2104471609692f94c994a710be5cabdc9c9a61b94fc3f76927c1cd5c9a53" + "55a0e8ec55a69ef114b3963ec95137b9ff84240c2a71d3b3459056d1a183eae21cc5a7c109e937faf8f61b6232fa" + "30951f030047d7555b60f85a318833afcea80ee4d88a98", + "a7fc199cb07b6e5e498dbe590af4a4d95d35b043a97d52e11cc1092c70250112e070e49fcb8a3e7bbfca3d0c4467" + "ba332c0dad277a997f2a603fd2d016979c24b3870a", + "f8ec2722a9aa97d0cab77f7833e6bddc9570bb79a159feec2dac9d2366e7eabeb9d74ab53a846fd8ad052a740dba" + "39801b681e4da903939387ac3578eec4547dc97c43a8824db11cdae4e7ca8330c9a2d4249853a7285c54498e59d6" + "45546a5bb5858b8ddfe37a14242d9750b02ccb41b92bbf", + "1f6822430a2fea84595ad870c833951814a0792cce0cd414bf9f744bfa7c9f72" }, + { "7458fcb1fa1a886924a044eccab9c5b2", "30565643aa9bae844b87bd459628d093", + "4227dc17d3e0ec8363c84b989f72d235d3991e57ebe8a6fcbcab1053edf3b323cbf5f5f45aa142494ab0afe78c", + "d07afef73f3cabbed475b69fa30aac8af674b74448cfd4d6ecb0c5c1b5b58d0c7173eaee440be65715d780d61d34" + "6dede7c52724bd76207ada9a3707c1326dffefd04fb29321db617d12b4a607452a5b197460bc524a40672628e5b9" + "d45f821a5b", + "50c568868de4b49df40d33e6b25abd6b2dfd2f22bdc12a18ee2407dfe82cd3bfa2fc344c91ba6544e079446073", + "5d9f885ee5dafd1ef4a2d0a951941f1d03acf8adc3652ec34e5b6ca4bf7ed18b" }, + { "68df4e697e83c55c822bb3637bb52d54", "1b0df23e69aa907856ccb9ca4d6c51b5", + "59242d6e2d7e612d2aee7e8c08f53f172e0f93d57b0c08e7cffda90da5b2703eed8192511f6f1bd59e9ae781b4f1" + "156ae06ec38b5bc1f5dddefee49f561d692f832030f7a1b506c0ebe26447b3eab68172e7e7810b13d425f6c78e1d" + "6591cb4a24a61c5f9554a083283485175c18cf5df4ecf2f87c98615de9ccb3", + "fe9643236be4e7aa3998f44b4336a4c1f8fec28e17", + "46e15eda413037249e584ea1e3007166d70bf9c998ca2a8386bdb8efde70f3bd35a9b0877e333451f7789f4d8b4e" + "797170445eef5f818bd321574e66b7881cdb546eb5528dce75cdd1683e715b2ac7ad259954bca62d8f0f0066fa6a" + "df50f9e13dbe3ca1e503957cb5f8a2dfce0ca7377ca51989e3d8e5275893ab", + "6afa564c9f5a650cdd7284589134c6c1379fb798af9330bec354ab1221539e86" }, + { "a4b06bbf87393d2b921dcba697274f07", "5c14d51c52d95ac040e1060a0ffa21eb", + "8c85ddd8d3f446608e656052062f0cd58e6d58", + "847d3b95895426225d08865cc9a329f6f14e63bc5a66fb6f2a05bf8eb9bc8166e6fef29e1d573acdb4c3bc699dae" + "adff7df5d6e8dbe2ef713008afcf9b6e97ce6cab4d90594fa4430ecba5bb62a7938f03d57869", + "cf6c47fec422ee29226b6cbc5092bf670b5434", + "0d57758c68a9524557fd6f6742d24a00467846456a5bbb1271e2a5e8c3ccbea3" }, + { "50034800a878a3e570364540fc862b77", "bc92f50c2630f7fe354399fa9a6fc48f", + "23a93e636d1924a60f3461de1020b73ba18fc3854c9dc9f166d7d4d1912503bdf1", + "23d5009057b76a00d92db6b280a3a30ba08ba3afec6312197f06ee01dc4a22d73ea010e02b65af7968d8977f9762" + "ff5a6dde278d8b351d3b8efb32cf7cc8a70a7a8b3d79", + "2cf9f00b66c63518354ea59510c178d75499866218eb5a031a0dc4d743ac8c05c9", + "7681550d340ca003acb18bde30e7a26b23022f9e71dc0d7801ea6e9e569784f3" }, + { "d68448b73ae9bd161c9f1f36dbf6163d", "3345d820331958c63dd7a129d3ea0de1", + "ffa236070dc5b464eb034a9332041a014cd7852b498be2dc498dcdab4151d71f47c7a6b17a176c5999a7574fab5f" + "f469cd02226492a38693eb2296a4a7cc2857b28b5b61", + "c790bb04036883e6e4a6912a9b0afc36607e12b0d457d4b5f6c120cf0c009caa087fc2710439", + "1474d60067d082706bb0cd823b22582ddc0fd68412ea0e399b03988e616ac5ca0a7a8da6e6fe29292b57046c289a" + "d8a52360ecd19655bb801c6eaa2ccd66ccb14c4c3748", + "a1d80340487279787a1dcfd1082fe04d557c072f9b558cc78c956c1b06a0683b" }, + { "519fee7049473c7c41f3bcf7b2f63a69", "be227d2bb97f2eef62d5fd9203cb63a9", + "0c121fbcfb4f4f8f150281140e49d71dc5ed82ac4a30263a6b2d92c55ac6fe4f43f64c0f526d3df642c04a5c51e5" + "8703c381701b1f4618cf66e27c60dd5e6558b48028d5fb11339c4f2547a3aefd8100", + "9ebb3c33eda54164b54bf95d4fbe113333edb0fdd62c24532fbd4cb91b11e08b1e74487dbb0f3daaa08c566e759d" + "53ea3974cc3685ec460e608f7d01fd2dc23d9bc283c73ab492bc9fa2ff458d268667504cd47e585826", + "c0e22cc3aa610bda350a2ebe8f530c05cafa19e7060b064c276a06f0bb430b79839c51e6b22aabf429616480382c" + "86f8c04ea397c976bb08caf8f35c38208e476787ce229a7a300c5411471548b15d9a", + "7891d41aa7d6f935761dc0454a7919d511f629fdc3f38f4932eb0148d870a24f" }, + { "58bd2c73aedb31baca592e42d614c68a", "bbf76585731b6334fd314e771d9e404f", + "d238c5f0677c86c001e66691ea9eb8aee429fc490d38abccfed3a546b5f05398288e7232880fa3d485fe3862c546" + "9f980d9ff4caced1cbbe7f97adc15b6919876b8cbdd35320a20eda8a1ad6e853164b0e0ffb2f702e1d6a0eae8b27" + "577bdd4e5a17e6d8", + "86147d2debc30111b82c1ccc41a13dab1aff144bf2810695a40d02bdeaf519669a1b81864edf", + "94fccab0dce48d5aaf42ef59764cba95b42410e2d6b2c87c95d8dbc15421c45d7a556e25296df9167cd46def7d10" + "602aeebd0e7e909c52ab7a22f833e976fb76b9b39b1c2889587582d44ad8f484f0382804d7481f1a8d6c903b1319" + "0c213102ae273378", + "67a012ae5452dc293645179c0fbe23d2f79ecf435e4fa09208ddf8bbd8bf8b37" }, + { "a27d07b0976574c43edba5619b3c1f27", "879f4114bf61f1d7b487bcdff6c90778", + "302994dba80c2268f5b1c77bfad0b780a9be6437a07dcf1fee61e8e72f7fd3ceac24a01be486a2eddc901a19a0f1" + "0eaa94cf46b604f98a90c0f62fa6476d27a338bd046fffc26570", + "b97a43027c5dcb8a95", + "633c76783dcb88ff677a6f567685ada02d787eb9aa3a527a45fd415180f1fc19cfddcb90583621c2609558703c7c" + "5ed548650c98e591fac7a692b1f921284ebd8b86d3a1f26f1ad2", + "1f54a298784b2ad47bdbe5c982b51b2eb5f8c96bc4b46a57dd703dbd7e1b199a" }, + { "d55658dd1f27af02885d0f431fb2ebb2", "0aba0b9dfc9831aef0203bc61a601176", + "05805491b667d9ff38147d96493db29441e188243f72668c7ba61b", + "df403489e3bb67eeae8440569f6fbc1ae072305f5047c5105a7e4e5349d3732d75572298253f60e3821c721941c0" + "2dd761edfb081d09b3c7528a0e786a6fcbab709727e7d614ecc604def19c78fe061040bd636d842b16e96158db07" + "d6c2521ad54778acc78f12b450db0474ef700dfd547f9c5b", + "2e8adbea0e9ef5068fc3abb39ccef59616420d4fa038e2f35b560c", + "d1f27edf1046f8ad30e9900c43a317744dadc934e6ceeb63184e0663ba80df77" }, + { "adff46e4d7d78b3db5c74c712534db37", "c54185637dd281ebf672393cf9bad28f", + "b3850ad942e221753e4bf30140eb5569cfd9972246b9a6a35f7a8512db333aec59d380973d6a6505d99cb004dd47" + "b33e32f4f238b1342e6756d3619414c31bde45", + "59bc7a834189b930c8cbff769ef63b5e1a08c352ed779853b36bcd3d0ca7b4e35bd6cdaf2538ebf0e3a0d7cbcf3b" + "cd2b66b910967c226a1da42f84c4a8f81e19161c6593e2c0a0fdddd3c6ab3a864037fbf976e8aebd33d4450be989" + "3da2e37e728916b663944e3fa6ba543d1010", + "5cc93a30fd8f71befd87fc50112c156b53abfc97466f36e3315915a7d4147f0b3641177b9d08ec13e7315957d078" + "ec73eb0a93a3b7a51e3db63a396e6ea2adfba7", + "9c14e5bcf26a00fa0bb04256cc32736d0f2300ea93a51f8e4ba69d15ff11121a" }, + { "4a5d7c201ddae018edc9783413dd0329", "eb7e038948d3bf61d2cd29d2fe722603", + "3e6a17d47db58690b895619128645a2782d17e9a3735c1450a7c8e13a9f212208fcf256f", + "65b8cebd83d3197118fe81dddce22b3947653e04a48d05b4a2dbc42a89e62b0d6b61d5f31487af", + "a1a858d13540281e1d0a9a82e3caef64ff742e51b1f7476d318729508a68840b371fd300", + "62b25795c2cfc4d7f8c1058256ed2d0e73374f8e33a106319a67778387150217" }, + { "83190fd90c68cf63648dbc5daa442e3e", "3c3683fb5d3f1446f8c0d0127fc59d5f", + "a5136deb0a795dccc18889c23e9bb21640864981a4ecd903e8fb62", + "13066ef4f97501fe1854da6e2d57ed43e4c074ad45b7218536e7dd8368a4ee8c6f2b63199fc0a9a679e2b198bd3a" + "43e6e8bbd6", + "0c8cc3bde1f4933729293718686301b1ce50f5e7521655016f8432", + "cbfa761976091ca1ffaadb4278f141f83bd6b5270f78cbcdf61018a744ae2fe4" }, + { "05bed4c00afcb8ecacda8daba02585a1", "ed014d4e9eb504c70d5d3153473dc146", + "6fab5ff04c5a74a0a96948501de9167597a42fde4c50ab27719dd1e2b0e0fc0fe6e48e97c79d2a71fcb5e7ef60c6" + "7a32bf865decb39bf5ac17969177b2fac849a38e08bbaa3be0d6dcee9ff685ba97e9b54514624d51c270065508c0" + "3e96f28667e3c79f6a68859a85048301779da7e2254b1bd1662ae3ea15e0332c", + "ebb614315ba4b7d69632656d5a4d2810112862ea3e443148100bf2e89d059bc9e2d9563bf34b823c57108ca9a88e" + "4b07441f0ceca4713e2af56f40f35d6f2223d37e9eeb61739a65933712763104a67488d2022a5e033e240969a4d3" + "3966b4527035eef0970c69660ab3ee5c00ac815a9ee52d767b0a937b", + "6edcebf7ac2cd10be8a9a595a00e68e2d3127f5de640323791229141caded658e99fa59539077027ed7b7a433a79" + "4bd523ec59f504978964d3e17eb388956e43395ec89b252a93b317c64580426d1ab0b633a972524084be5d488645" + "8718ed42f47967eddabdf7b2f440818e0aab9d932c10a4c7283d05b84ef74a6b", + "7be2b003c341d5a7d1a7fbbefd6170d8be25e785230bb6adb70785416eabb281" }, + { "53e1b8de6176c05e04f5a4787e733b3e", "574de8c0f914115c9267f7852280fbe8", + "0ef099d6995b41d4e9227c3aa59da313160afaa32e1753422c1eb45bf102e806aa996a54606c78320e85da74deb3" + "9e8b0059bffe32780ec784abf6bd540d3c01e9f13c4209bec2", + "3d9ca3718f31b4f37f988ec676fc3b5492a44792d1a4f8fd7cc4726fae899f102841e7f5c04b2ae2c5f9eb204c5b" + "74222d89c2bd36b1500b2dd81e9643142becec1b88aa7a0d7ea4c81fb7e8fb37ec1a58e0383e", + "5cf9292077dbcc9557a1cef51de815facf02a89c9e29ac62098c8e4d0cb49c4f55ed55dd9dc9c36a634ceb8f4dd4" + "75837582b9be1c17030c0546b335be95fded1c416e4599851e", + "782baaaec2b50b6bcb07d00c6eacb7fa8ac084113bad5a1d6dbe8c80340443e8" }, + { "81118e9376e515a93dbdda15e58ff387", "75a0f02a8e78a0d2d0097cee863aa576", + "f30c353db4dcb2320ba5fba118e50526800fda7ebabef05bdf15aee5d9b70f2ab697937d77a01bb4bb460fcc4233" + "acc3b970f4f434e9ea85f30aed7d247115fc5db1c333ac6a008dfe65ee02b930ea097d046f2923bf84785d47f382" + "b19651948d69a6e4b861a7112c4e1804f6435f70", + "6f75857a795e6aff71994dacae41c2b2d9d6d7e67fbaed6d2e20bf89da461f509ef3d284341a8a2059ef1b97e9e6" + "820f1a72ad703e71999be36fd7156d3e3f35663eb4db44a858e08bceb154af51360feadf3bca8f20", + "0376339c7324168426dbc1f36ee91603f844352817b575ffb25ca6a75e2d0f0d77d853230b7e5a4823195c406298" + "bc3781b40df001d9cfdff16de970df4ffd0aa652fc7732c6311e2665daad93bb2576d43e1a58837513c62a8b74cd" + "e75901f9520a29a10e4dad9e4aa981c5e72d6cc0", + "d5db09ad858cbf4f860e527aac44bafedcfb01653818baeabfc8efeec0e3a9e5" }, + { "2d60824c89bbeb4e2b72434aa0356587", "20ad2c51679a7246ca6d0a47ba7292e8", + "17aa9ed83ff674f959085ecde2a6c5026325265a143d2c772337056a3c66abb5d742f33be39697194fb1", + "283fa29dc399d07116e43c85eec0adc8a76221669a9bba6554f8e828b680", + "40fddfe3b15925fe189b25aeb6616538958d43f0c64806f6286a5efc8a4faee98d02314eace7619bd2a3", + "4d9f99a5248b8c7ed7ecac6397969bb92799a3e206239bcfbca54ca2b2325f9a" }, + { "e2e2a29db958c6a3f68a52825b844c2a", "3210fe0cede911318435fefee1d921d9", "45f5fc3a", + "91209d1202574e", "2067b789", + "8869621138c4b08670fd8b6ede57933e4036e9c2a635e367f12a4dd7b19e1d73" }, + { "24affb4e364dfcb9be823bda04cdf045", "d7db8f0fd20b87ea4ad5e85e026b4b42", + "296e2b8040a3907fbd8789f660f85f3b49c6050092029a2b", + "42f31798f0016547fc9126a6919c14fdee91bc68f839dabb24d2249ff5e001b6a2308b57bfa6baa84e635123e8c2" + "110c", + "3af391d72e60751b10d3f009814673d64cb86a0dc998cbf5", + "388f9d6b3b3765f7361cf130f3418f1d81f3c4220b37046d82ba47ba252424d6" }, + { "e8d14e976fed8be59625b034419fde86", "1d3a06b7b80217caa5a4e237c2b94549", + "fa2d4f764e7399bd346f60f1cee797a9624809373daa3803cdb12717fb48503263b21ab1d99dfde20d588458993d" + "8c33384e897973a9dd74bb7e308c8fdd6a46a9", + "8c0c2e14cf2ed5c7147d8c50b4c28b232a80247344f21a61dfe4065fdc559200b7a0046e58606e3a3615ff54bb60" + "5e7a5f001d215de255ba75366f6be3dd1fd4858aa9e8904ca99647387b1a17c7ff", + "9427f3a18a22e801a3d7d863cccf4fc8dfc23a51bffab61235e2bdbae311ecc321db38128730818cec04f51ba5f0" + "c3e6b7327402a2a63c95c184f7946756f2c94e", + "70a800b87eeed41887887449465656d777659f183f9cb335d2a253fe09816cfe" }, + { "73e9b0ca8fb59181dac10130454e3a7c", "81c9a08c95fb942c42003aff680b11ea", + "971adb65be3d885bc115724cc33a0f53aa47606e7bd5", + "03cc2f305af325f4fa14de7ae8e89a03d040e812f0f4a7f82d72441d83b85a424f3ebc34ad", + "18ff36eaf9e6f49530db6f886fd85a77d55289d85fcd", + "0bde31d7323ac029d9900c897aca4b0d42f33d46bab1974affe35a4095139184" }, + { "59f15a1479f5dbd9c1b879475de9d2e7", "060ac95c956235bcc003dfdc92da5d89", + "a17b5ffce4cc08b23a8b8cd7735e11822f9672691b4dac380835729694f39da377e4d3fd23ef7b8b40a355e271bb" + "fbb8cd632481c7cdb67d99d314609174b10cf370fd9b9ab872346c631127f873573ef61776bb8e154b55bab6d845" + "44cd8fe5f7611840a057", + "9faf2f97e14d2be029", + "3a4986b25ac4ebbdf8c62e74790e79f860c5c131f68b540a7a9f0504cbbc36b7484fe76713a53f354f4970613a97" + "6a4cc55ed7480d5c5acf876977b74e622926c8309b65a5edd3ea2ad7c2805f2859ce1e2805577d409760b2cf8e84" + "cda7097478491bab3fd9", + "81ab6e4c949f5f8552f8a5f067073a0563a4ea6a9ae83810d76937e1a370cda1" }, + { "5dc5206e6145ce81ffbce717cb425955", "a7a6fda319439a67cb679b3cc6076dd7", + "4244fc95829a69089920", + "92f48b403ce97f87118605d24314981ec34b958ca0036f0b6acef5e20bfddee370e13bb2cc676dd8d4547668aacc" + "7dfde6af12727789f6ef811e63b391cfa9c4a68ca89e6bd978f38f9228dd9c24e968c4e59e3d34963d6ee942f788" + "e0b5625ad95bd3eb6ae67ffcaf2e4ee9a9cbbd15c40385ae", + "adc2915b7813f367bd80", "30cff01d2431cc61bacb6445d7e3e604de19ea532a2db3adcc1a978d9cdf3dcf" }, + { "8d88268afada2ee19bdc754147d6b04f", "119588763bcbdec984a226e9dff179ce", + "04deb10354489349a273c5cd5d02ee1d71cbda2a20743bdc2cbc48788b9da779ad2f3f1dec4cceb3132b2e4a1c43" + "02c8f9ecd1d37fef", + "0f32a44fb0edff2f0d2334029e59715f5fe2b8e896068b8488f43b567c0d6fa3de5bfa99c6c8f055e3889309e088" + "22eea3a683d6907675b6f0072438be", + "bda6c7381492f48849c00a86ba72c8162c09981f593547682b88b7bc6e051a9ab9fa1602e879b8f1e5145bb61925" + "30e7faa76be34dc2", + "dac7ad31ca2f77427665d8255bb24e7604403434770869ee202598e649950dae" }, + { "0049493db4ab12f83fe50f0fb2a88961", "fd0dd2556a03ebe50b41446250d56e52", + "1d3139deaf1046e234189942c2249a7aee9d644f934e6a203a8a69e7683557551dfade301cef8abb29d7308c5a28" + "93a52ce6b1493bf2232606e79c0ae51b0a55cfc0434f2e669cbc56fe7176fd04a1278918c14791e00f88de41d563" + "d3", + "4c92be6ed0634323014b9ae5c9401f751c5b710c12df357a694c1c25d906ab3beb5bbaa002208e787f448dd0cef8" + "4d3d", + "dc3bb7e4baadeb7c32f70cef3144d04ad199ec429ca6b695f87f997c6e5db58e9d60b34d89ccfe49d5e62c267a87" + "1ab7818137f523cde68036ad1d8f7db0b80286ceda9734b32ad73f7f0eaf8d19c80fe74866c1cf785f44513b918a" + "24", + "51a9d0fb861eca8a334632ade9f37e319a283d7b33cf0894b2e4e545d01afe75" }, + { "b6279f439261d1dfa4b85151caa60e75", "d0b003ce641633d48413bf3bbcde6b5c", + "39ee6f13a66b4ee74cda034a3bfed3fcf36f101f1e5b646d1c93e019174e4bd850417fcd5755264476124a5ee8e6" + "8cf2fcb9fba50f872fb1d33a025f8c572b4b5ff034d9ad77ecd33981bdfe3e9554253522", + "c635cbbf8eace8f911d093544536f38fcfa14b78b1e1eb069c42a351cbc70b7d1f5e93bceacadaf0c9198d3b2ffe" + "54db45cfac70c05d4aecb0c801194642cc070ed223a9e3b65b735af796373db7fb6e3285ee3fd3579dd74be0cd29" + "37f6f825dc3bd77ff7674b06a9ac", + "9787ff29777e12f86c7281c57c5a345278fa96d8fc6ed949be284bb79f97b34da9f256a6be673ab93829492159e7" + "ba1a19dc727e16ec57e388447c6616626c6af3412cc70432c3dbeafa35b044e7e53456c1", + "9fb598560f6e1085c32baaeb48e643f0ae1b5a2c3a8ffbc0a9d88821c893330f" }, + { "81d8c7bf41cb0e54fa51899660637877", "044d29eb40264aa36b976a766108ac88", + "4712680db09039894cd72e86db111d63c4bcb62058f84f83ef419cc21e36f2169ca340375ff69f9280fa60c99d86" + "a03dec4673901a7029784be2cdae3f63590da312a448d24eef063304545e553fd01ce6ee088e43c8b02c51b155ba" + "da983ea1aca4bad804406aad3c92ac75ce4c", + "897f0ea8d69b962913a9a59ca36b65aa7aefe39d3a", + "1d5cff8679946302451dc9aed1c601ce46a6f31ef17a53af6ab130605cc2a41da08c932a13b72983ba8cc5837604" + "0cc17e3182993dd593f4fc8f2965825173656325942e97db98c584ff0bc913633888a0812ea7675d130d690f9fe8" + "d6eb7f1655de1938fa0163b02c50c8a122df", + "96887b58e80e7c7716cfc5ef37c2b5a6bffb401733b82a0bd31510613f033a05" }, + { "8d35dc035a1039af8f3dc653857cef8c", "a0df1b717a186cfe86a0ac8343e80217", + "572bf5295915e7b2f817bd137a6608e09fcb7bad29887b9209eb29e944f2d3231717f9a112e68756948c1fc71dcf" + "6245a0130bbffeef74ccf3ff3860ca5a23753f7539b7a268fb08434b73ba9adc385e6f9ccbfd213f812d7b64d8d6" + "d7bfce1e236c5fd857", + "94714396e2dc4bc13a6d628563b0db14e189695810a4925a90826de63327942db0508e7453", + "6f2364c357e257e9b412018a1c702f0d0c1170751393b1f73999f77927d4ec1454e78eda131af56b1b46e348f877" + "5e6a022a746b31ee135651bb2a14e21cbc3f333c13df02a3de6d5128ff1145514605d98e984c28dfa89cbfd2f0d8" + "bc41af3e4c73e7ddc0", + "8df601cc113253733da78d2f06eaba71d45d2026e77c30918ff8c176b54f75a5" }, + { "4666ffed66ee2dc3ed18e6345384e828", "8c5c38610ee79b818c18e95ed2baf026", + "dd2baf24c168f99d1868712a43dfda4717650c26c36378127800d8cf", + "196a5357a0d6c588acc29f85cf38b78b61e0810feefb965d", + "a58828aa09a6f25e7d4775ba7a2b303085bd5fb43cd61bcd19c8bb8a", + "3f54d97c03f05417d44d62925d9a0e2c457fcc8befd1c388499c3e38bf89e163" }, + { "2d5464646342ceb3039a9d2fa406b90a", "8f045fec196343f938902e1bf706e34b", + "260ab30c42d3356dc39837b28f6f387accc2527aa853dd58f54426d52cdb9ffc0a5ca5a5c00761a7299e72d48874" + "b46ffe18dfaf38f19cfad76d7c9cb4a4cd7784cfb125a58673972b4bb8c894da2a8969f68cb27fab746f8d62fef6" + "0664900833dfca7e0be03eb5908f12e74bacda9d35b06e", + "d4aa5263a31fcc8ccc9e1127f7ba6ea2d3ccc72cd7e98e442890ad3f8763856d90e362", + "51ede001d1e4ca8a3de43186651a011cd14f4bf93e9375e910a8974ea411343b68e8f6ce80cfc945ae7d9c5adf76" + "e1c0f93de8f5dc48f36b82b65886776f1298b36a2f012140da048da77e09e4d57426abe2b894c425aeb2050b0eea" + "2d8f8255b733bb814abf3ef3d530d87dd7e1504bd683f4", + "890d5d33a9dfa3807e5e20e4824d13fdce5f7ccaeee1f3448a4b21a085277370" }, + { "723efa25ce1bf1748d86d9da611be9b1", "aff260690905ed2e8618c20963e4b7c9", + "f7e3eb593d3966c015d63ea0e9211beceb8fa6d9a202bb4fd4128c3177c5", + "3950b62147fc16429392d41cc4188d5c82537204e93edc7abfe7ce3404f9aa1474ebc4acd8e18aa652a87ee99c24" + "15f9214963becd44720684f67aa814903cde", + "9d7ee643a2cec28c467d2cc88aa539341dfbc82f72b5d940feecd11d4a7d", + "eadd8931af484ec1f3c3e18f7acc0dacec73dd80836e03957b595b2022c8ac21" }, + { "784197d89800aad00105ff7487b6e5df", "fdded94dfbb72c77ad81b2ccaaa2de2e", + "b14ad4fc08d08cb0601289a7ff9127f26c4036606a50bdd2921baadffbc75749b8ca33ddf7b6ac", + "b82cbea4eaf532d52046bf0bfaf22ec2", + "a625b4da553686296d5c6f5ce526c4f84c4af779c67cd328c16a7985c9a28737130da855b1f3aa", + "1807d55856630efb2794c74810522703b71bed188d5d918b8d265fb12a8bdc9b" }, + { "4dda1ff559520020513e0a8e554da28e", "8b183c7e23130aade134ff8e539d8053", + "e56d6364a87fb7f40af02b672fd337705ab8a02a5fbf2c2a639a872da16895774d90658269437160cd22d7370ab0" + "fd3e81d746", + "675b6d9e6c4c479798038b06561f1ac0dba2ce54988efa3393cb6265d901df1f815937a6e42db8c64c76dae0c8ab" + "a0ee20", + "0b2f31b8b15ec535c7e8c732e91f4e119bca192b1fe2eaabdac037dd1568e4a8d786c7048c16ebd4c513324b18ac" + "9ee0281fac", + "4809fc5e0e21e6344364f0dd59d380740c36c1b1d22e22de5c1190c0044a98fa" }, + { "66dbe969ec0adfbe1b99874de53417d8", "13ee71e9dc02d592700c04ca0bcc6344", + "fb420a6751909185796656a952759b4b794bd4eb98c82456af4f596093f5615962e62a9ce3fd9c4e0cb31a649cb5" + "c17d30f66ad3d52e16589b174102cb5ad9973ce03f44cd3776e0d9c538d255ffe81ddff81e06cff8e4d8adef4f08" + "cca416d52ee3aade52341e5cfb5de80c71", + "db499d6cf13840accc40e3d14733662885768f7541b2615138c498b087e51b20f1c0c373a589b510de546d372a40" + "cad0f92ac3f6f7bc1b85290c4553c83b", + "7a7786b03d18c1f2edb2d9015da13a327f364895751c32b8ab840079b08e47870b4ecb49474d2da2bc0a53977aeb" + "4d63f3b4e56f6a3d22ccd64fbe098fb9b27eb5e5b1f179ac69eb3d57175bf9ee37345e6f48161adcaa27bfb53638" + "89e38cf7297b3fb9b41a0d61e751ca5184", + "18d7dd7f471d491883ad31f046ff3451d02dbc85fe59f43c5b67c53c21cd9f19" }, + { "3a00ee1e8877248065cd26e3b9a857de", "950529b19697df5b0ce43a3f429e9509", + "d6fdd1746e8e7c7b84adef010951f60fd19b5aa74b1a8ab1ef2dbd5487318fdf7844b436dd1063f10e609bc58604" + "ada5c41ae2ea1b5303f84c", + "30a5f3a4e4543dca2b4d53a59a6a11b97a7d", + "06ffcb4a0da10ae1a5a1c5b6205ccf4882a9c796370e7793d9b3ff3a857c156b3285e3dcc2181d8c0df26167ab4f" + "8709db6870c9e10e75b90f", + "6127c870f1aad279a83c79ce8226147782f709fe81f8c8740eb47bea34c2a558" }, + { "b611b23912f0c44c8f0a452e181016a3", "aa0321dae967b75f958a3949fa08fda2", + "16320a4eabdcbbb1e600058d308cd8aa650ec35985906489d1ed3210ad402589b33de4a68088cec878461e54ce60" + "ebac399457d4f4ffaea77fef304f9363817fd797afac854d0ca313321fbaca4b0f", + "d0b0ea43a3fcbcf70e5d4b21ad115e503ada6f43a74a0585481b249db3c00645f06005b1b3da91600a14a40ae5c0" + "45127cf8cb6bcb", + "39f3258b852471d9b9a289027f26c3a7e49fa8cb61983c429b3b306edb1f0d34d9718774005d71ef2e89212c6c53" + "8f647335d85a2d0b4c72b97a7eee96d5b6976a602d82a294bc2a4887b16aa327f6", + "411aac7435b623d80d284a1a6533dba99d7a44e4de22bbb22b09a4812c6f27e5" }, + { "2ed2ab0c5548c1e97879a6c3ec7ebadc", "3e15d94c7dd22593caa8be653b6d59d2", + "76b1d92662d472c87ba9b27e2756cf62513ec190f709996e", + "f1e64c14a92e952036305ceef2535f65295b2803f7396a5e88f2ac993e201782e2f1edba92011a1530278b6d3d1c" + "9a", + "8c9fe2da6b58f0a9d40609bfd9ac6855badaef814588ebc8", + "b212a9d7ef27a5228e1c02ba78cc92068c2251c162348e1d87da2afc53616571" }, + { "37263267c4f24129d9db09a2a96d7c14", "39e5c4f2b36c9ed5077765b89cea1bed", "3581b4424c", + "6ea6a9f99350a38601162f2e24928ee2", "9ace0569f7", + "746536436bc496acc8bab10e6ae17d5d1d6113b3fad96df462107c3b4b6bf96e" } +}; + +static int +tv(void) +{ + unsigned char *ad; + unsigned char *ciphertext; + unsigned char *decrypted; + unsigned char *detached_ciphertext; + unsigned char *expected_ciphertext; + unsigned char *key; + unsigned char *message; + unsigned char *mac; + unsigned char *nonce; + char *hex; + unsigned long long found_ciphertext_len; + unsigned long long found_mac_len; + unsigned long long found_message_len; + size_t ad_len; + size_t ciphertext_len; + size_t detached_ciphertext_len; + size_t i = 0U; + size_t message_len; + + key = (unsigned char *) sodium_malloc(crypto_aead_aegis128l_KEYBYTES); + nonce = (unsigned char *) sodium_malloc(crypto_aead_aegis128l_NPUBBYTES); + mac = (unsigned char *) sodium_malloc(crypto_aead_aegis128l_ABYTES); + + do { + assert(strlen(tests[i].key_hex) == 2 * crypto_aead_aegis128l_KEYBYTES); + sodium_hex2bin(key, crypto_aead_aegis128l_KEYBYTES, tests[i].key_hex, + strlen(tests[i].key_hex), NULL, NULL, NULL); + assert(strlen(tests[i].nonce_hex) == 2 * crypto_aead_aegis128l_NPUBBYTES); + sodium_hex2bin(nonce, crypto_aead_aegis128l_NPUBBYTES, tests[i].nonce_hex, + strlen(tests[i].nonce_hex), NULL, NULL, NULL); + message_len = strlen(tests[i].message_hex) / 2; + message = (unsigned char *) sodium_malloc(message_len); + sodium_hex2bin(message, message_len, tests[i].message_hex, strlen(tests[i].message_hex), + NULL, NULL, NULL); + ad_len = strlen(tests[i].ad_hex) / 2; + ad = (unsigned char *) sodium_malloc(ad_len); + sodium_hex2bin(ad, ad_len, tests[i].ad_hex, strlen(tests[i].ad_hex), NULL, NULL, NULL); + ciphertext_len = message_len + crypto_aead_aegis128l_ABYTES; + detached_ciphertext_len = message_len; + expected_ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); + assert(strlen(tests[i].ciphertext_hex) == 2 * message_len); + sodium_hex2bin(expected_ciphertext, message_len, tests[i].ciphertext_hex, + strlen(tests[i].ciphertext_hex), NULL, NULL, NULL); + assert(strlen(tests[i].mac_hex) == 2 * crypto_aead_aegis128l_ABYTES); + sodium_hex2bin(expected_ciphertext + message_len, crypto_aead_aegis128l_ABYTES, + tests[i].mac_hex, strlen(tests[i].mac_hex), NULL, NULL, NULL); + ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); + detached_ciphertext = (unsigned char *) sodium_malloc(detached_ciphertext_len); + + crypto_aead_aegis128l_encrypt_detached(detached_ciphertext, mac, &found_mac_len, message, + message_len, ad, ad_len, NULL, nonce, key); + assert(found_mac_len == crypto_aead_aegis128l_ABYTES); + if (memcmp(detached_ciphertext, expected_ciphertext, detached_ciphertext_len) != 0 || + memcmp(mac, expected_ciphertext + message_len, crypto_aead_aegis128l_ABYTES) != 0) { + printf("Detached encryption of test vector #%u failed\n", (unsigned int) i); + hex = (char *) sodium_malloc((size_t) ciphertext_len * 2 + 1); + sodium_bin2hex(hex, (size_t) ciphertext_len * 2 + 1, ciphertext, ciphertext_len); + printf("Computed: [%s]\n", hex); + sodium_free(hex); + } + + crypto_aead_aegis128l_encrypt(ciphertext, &found_ciphertext_len, message, message_len, ad, + ad_len, NULL, nonce, key); + + assert((size_t) found_ciphertext_len == ciphertext_len); + if (memcmp(ciphertext, expected_ciphertext, ciphertext_len) != 0) { + printf("Encryption of test vector #%u failed\n", (unsigned int) i); + hex = (char *) sodium_malloc((size_t) found_ciphertext_len * 2 + 1); + sodium_bin2hex(hex, (size_t) found_ciphertext_len * 2 + 1, ciphertext, ciphertext_len); + printf("Computed: [%s]\n", hex); + sodium_free(hex); + } + + decrypted = (unsigned char *) sodium_malloc(message_len); + found_message_len = 1; + if (crypto_aead_aegis128l_decrypt(decrypted, &found_message_len, NULL, ciphertext, + randombytes_uniform((uint32_t) ciphertext_len), ad, + ad_len, nonce, key) != -1) { + printf("Verification of test vector #%u after truncation succeeded\n", + (unsigned int) i); + } + if (found_message_len != 0) { + printf("Message length should have been set to zero after a failure\n"); + } + if (crypto_aead_aegis128l_decrypt(decrypted, &found_message_len, NULL, guard_page, + randombytes_uniform(crypto_aead_aegis128l_ABYTES), ad, + ad_len, nonce, key) != -1) { + printf("Verification of test vector #%u with a truncated tag failed\n", + (unsigned int) i); + } + if (i == 0 && crypto_aead_aegis128l_decrypt(NULL, NULL, NULL, ciphertext, ciphertext_len, + ad, ad_len, nonce, key) != 0) { + printf("Verification of test vector #%u's tag failed\n", (unsigned int) i); + } + if (crypto_aead_aegis128l_decrypt(decrypted, &found_message_len, NULL, ciphertext, + ciphertext_len, ad, ad_len, nonce, key) != 0) { + printf("Verification of test vector #%u failed\n", (unsigned int) i); + } + assert((size_t) found_message_len == message_len); + if (memcmp(decrypted, message, message_len) != 0) { + printf("Incorrect decryption of test vector #%u\n", (unsigned int) i); + } + memset(decrypted, 0xd0, message_len); + if (crypto_aead_aegis128l_decrypt_detached(decrypted, NULL, detached_ciphertext, + detached_ciphertext_len, mac, ad, ad_len, nonce, + key) != 0) { + printf("Detached verification of test vector #%u failed\n", (unsigned int) i); + } + if (memcmp(decrypted, message, message_len) != 0) { + printf("Incorrect decryption of test vector #%u\n", (unsigned int) i); + } + + sodium_free(message); + sodium_free(ad); + sodium_free(expected_ciphertext); + sodium_free(ciphertext); + sodium_free(decrypted); + sodium_free(detached_ciphertext); + } while (++i < (sizeof tests) / (sizeof tests[0])); + + sodium_free(key); + sodium_free(mac); + sodium_free(nonce); + + return 0; +} + +int +main(void) +{ + tv(); + assert(crypto_aead_aegis128l_keybytes() == crypto_aead_aegis128l_KEYBYTES); + assert(crypto_aead_aegis128l_nsecbytes() == crypto_aead_aegis128l_NSECBYTES); + assert(crypto_aead_aegis128l_npubbytes() == crypto_aead_aegis128l_NPUBBYTES); + assert(crypto_aead_aegis128l_abytes() == crypto_aead_aegis128l_ABYTES); + assert(crypto_aead_aegis128l_messagebytes_max() == crypto_aead_aegis128l_MESSAGEBYTES_MAX); + printf("OK\n"); + + return 0; +} diff --git a/subprojects/libsodium/test/default/secretstream.exp b/subprojects/libsodium/test/default/aead_aegis128l.exp diff --git a/subprojects/libsodium/test/default/aead_aegis256.c b/subprojects/libsodium/test/default/aead_aegis256.c @@ -0,0 +1,723 @@ +#define TEST_NAME "aead_aegis256" +#include "cmptest.h" + +static struct { + const char *key_hex; + const char *nonce_hex; + const char *message_hex; + const char *ad_hex; + const char *ciphertext_hex; + const char *mac_hex; +} tests[] = { + { "7083505997f52fdf86548d86ee87c1429ed91f108cd56384dc840269ef7fdd73", + "18cd778e6f5b1d35d4ca975fd719a17aaf22c3eba01928b6a78bac5810c92c75", + "5d6691271eb1b2261d1b34fa7560e274b83373343c2e49b2b6a82bc0f20cee85cd608d195c1a16679d720441c95f" + "ae86631f3f2cd27f38f71cedc79aaca7fdddbd4da4eeb97632366db65ca21acd85b41fd1a9de688bddff433a4757" + "eb084e6816dbc8ff93f5995804", + "af5b16a480e6a1400be15c8e6b194c2aca175e3b5c3f3fbbeca865f9390a", + "0943a3e659b86e267ffea969ddd6d6d63aa35d1a1f31fb6f47205104b132da65799cc64cc9f66ffa5ec479550c2c" + "5dfa006f827ef02e3ab4dae3446bf93ccb5c17e1ec0393f161fca94f2944d041f162e9c964558b6b57d3bb393b97" + "43b1f8338ff878a154800fd16c", + "480091eb823480e8b29c7aa96ffd55a026ac3d7fa16787c36c25865131a639a4" }, + { "c88bb05b2aec1218e1a5026511e6d44de7bd502588e9e2a01591b39c5ead76ff", + "4a485f226a73f0c4e16242e8234841cdf6af1771eb278e7f35428d03eb5b4cf0", + "2a4c06941ec356390542d7d7833fd68fc85a00c0452281f87dee6f10180d02182791232c7007fde35dfd5a901afa" + "896296f9f344db717994d078fbd3a4cec8d782d2bdc205f3709827b776fd5c863a952fea97a14a6c2ee3f20432b8" + "baa084470179078bd6a83597478b2fd9ae00ecb424822cb0d61e9a55a4", + "38a9809dbdd2579010d38bf5314f255b", + "b8565db06c2fa493e09b6764f4d09296422095eb6e9890f606654713bfee6f362a123688b61f254f315f18b20bcc" + "5ed8b0b4f2224de9f498e3ef03532a8bcddb361f5ace8ff491bab8b3d06550496501264f9f48ebad277e74921467" + "89d0fc1a3b1e3e81598370a4183683d1fee25a9a1fe359c836932746b9", + "5d5d35e0299dea47956a2e2143cdace4de8d228784d6717ae5a6bf5ea6b3ed04" }, + { "77b473865175ebd5ddf9c382bac227029c25bdb836e683a138e4618cc964488b", + "f183d8de1e6dd4ccefa79fe22fabfda58e68dd29116d13408042f0713a4ee5f8", + "9888b8ee03c3217a777b7558a31e331909570ea196f02c8cffad2c8dc6499b8125363c06a71c057842666bfb5c6a" + "cc937d2eecd960330c2361abdd88a4b191557ddf5102de75ddc7e09aee9862f32e24f1db3847a5f5b379fb32e2ef" + "7ffb0d3a60", + "0679fd74a846965e33e558676115d843e440fa37092fbd5c57c82fd914210fcf948f911b04632d66be46248d772b" + "3eb9f55b537e54b1ec751b63f035c8", + "3464d835302583ade6ed99e23333e865d3308f31a6cb65bcefdc9a1b9b4d0e0f75513188480dac4a64922af44413" + "24ce7de74eb9f7f4e414f6177a4814edc96313694b99ff8dd36b2f7f79c7ecd70ec475abe1c1909238767f172fd6" + "b95e92c025", + "33527e829a3db1929cd643d5251ee19482aab7f2d74635cbf8370f1e1621ecdf" }, + { "b8c6e8cea59ca9fd2922530ee61911c1ed1c5af98be8fb03cbb449adcea0ed83", + "af5bc1abe7bafadee790390277874cdfcc1ac1955f249d1131555d345832f555", + "b6c15f560be043d06aa27e15d8c901af6b19db7a15e1", + "d899366a0b4e4d86cce5ba61aca2a84349c8de5757e008e94e7d7a3703", + "4c8496dfa6c419ef3c4867769a9014bd17118c22eef5", + "f81ceacaaae6263c33f836fa26d92b0f08eb0796135c7fe312c93add6a208e8a" }, + { "d4ed0fe94cda2be7e50d57833158c84180b4cb7dec95d5ba774b6b5e1b0597bd", + "cae41ba20bfd124270b76c13d61c1dffd7a42017731546d41aa071c22b9967cc", + "1cd4b85fa6c14d5adea84ed3167479c1cd18e77792cca73a540aa16a00e50ba62ddd12a62911b21d3ee108651693" + "7f33ed7756c7ec93b3", + "35564745c05bc961994ea03764eb02044f9e7b2f6130d6d1f041580d6b3ea7ade2b6e231dacc5e97db01", + "a1f64f45985a89303d1fdacf6f31ad745a8015350f1afe63d6ecc26677f661addd3c229ed76f4c627b1e902f8ce8" + "c42fd08baef481e86e", + "c706b2f13d4e76b4e024a2d72540637a8d9ff5e626d6bffeb7801c58ccab0c2e" }, + { "d755d9d980e8cb221955b63c19f3989eecce945f61307a0593bd7cbea6577e1d", + "9f83666d787e5ceb0e17fc1b084b3734dc3ea88dda73b1b7ed53be7491f4637f", + "d1093941fdb3d9710cfcbe504be2434c17296d0b7e0f4e4058e79062f2b2cf3cbe2007ae2e5d391ebf3fc1e07e4e" + "e7d1705044c9bc2bf08e97a4d8", + "f2a1432fba86dc01b3bfbf3206943bfa3dc66e9f54b576c57f61ad515555b0c371dcfcec45eaa58ca06654b6cd47" + "6aaaaf1b2602c03f9e41a2cefc265d10f19d42bda0b07aac8e86", + "58e044943cf3b73e48ce75c048464fedb0445b02bffc00c1998b212f48f48c93e89dbfbf36cfade1112629e8deb2" + "67c55118c10ab67b7ef2740fc2", + "0179f0edd217214881e90c1be3b513170d1292603c484a55499e1bc70970d5ed" }, + { "152f15933e4ae26192bd3aaecea29daf77e9b2bcd97e7eae7637025de8a3d3ac", + "e177be02348efb533fc2e9d5a259cef80aabeec97da50c937e8d5f7c6eeb32ce", + "ef86da6d5b0dab27a444a95ef5c237baa5819b863dcf0232d0162dceda8f180e1b9c6b9d94ccc0692eb52923783e" + "f9de17497f1da62d6524bbf432aa6c3bbc1e851310218a03ef97ac6676eb6ec30ba6ab131802b992a11417cd00e6" + "270ac73dec8dad88ecc3cba25734ef7de3b8e3cceb5d19778d6808", + "221b1875425844e48c2111fa59b6df729a924a43b3869ab64f8291dca8f12be34d62d11ac94f9f308e0744d5d5f4" + "564fe9fc1e014cefee3cf7706ace4643871d41f1ad5c616adbcc1e9701a3b4", + "dc48260eb047397f41c4d0a0ffe394557aaff8b149cf4b16e7c22754095f51b626ded66e3db9d4cbd98421ee9d8e" + "7c6eb72b607cd462f1fb3ab0c41b2cc84ad320c781ccda9aefa1a68ff5d280500a17c7959e869f45f97bf09cd0bf" + "2c4c068d2b9603710ca8f71f82acd47faefdebdd0abc9b45c83388", + "97191234839a54c00143463e8e8c863f5710e520ee9d9b9ce051076696bc8b52" }, + { "873edbe818233d0f51bcfc1d5340cc4712c909de36f963e6157f128b8a71e3a8", + "16e7637700a6fc10539c056663d12ec85bd529f1e6adb131a3853578f5d27c12", + "db38cdcecbd99003978832d29cf6a34acb4d0e6293e37d2795fcded538ba37d6a11ed41430dc9f4c0cfd27587d60" + "7846f42aa30682bcc295097053821b80b5869b4a0b852ba7ac1d7b784ea0e76b2d033678011889a5adbf7e091cdb" + "b9754f828b7519f1179e2426ca6bf80a509e34729c854a5052e61adf8d", + "0b0bd264fb5030f84da620f07099f42dfbad57c314102a1f7fc0b452ebb7966ad4b88ea773aa07", + "de67a4eb8821625d4451734993d93e0fafd2c55c761afb097bfccba898e6d634be975d5f2ce8d456785a089c9b40" + "724d8ea41095c1cc80f070c3ababc9258e5eea504831b034baccff61d8f73c220d5bdb1244c8a675f2d6081abea8" + "f59088b99583cae22f8bd37fa030f94d5bfe1c9e799aa71bb41874b17f", + "8665ecac1758be7eea0b5f482ce8024ce3c78b3f51af3ee4e0b440f24db2f451" }, + { "b04b735c74d2286302e5994e126a8a8f52af38d6cb094279ac883b560a52a6a6", + "6af57ad705792ac2f71a61bcea9ab38a9a5acc510de7995b66f3ae4cd2079aa4", + "1c052ab52a21894287fa7f763b12f49b2edd6a0cd266e93207573d08d75ec31b294d171f0098f804020cc12056c6" + "0f8d396ec94d97eae1c07a874849e39a3302e8c3b538de6c9e268fb922f6875ee5bbc264137035a76d9ceb269dc0" + "988517a302c2bace2fb6efc4ffaa2c1455a16b6cd0", + "52618046f112a5a35780e370c713987e24609c38157e5fd5d51ed36324359b0615af70f801b05a98ceb1", + "7183180c37ab14f38ed084bdd2aaa4e8d8e8442b526214f594054e0379a2aba6992804afa8c63bb1e580d7d905d0" + "c46536970e98bf7cb921e95db8faf388e7c98cc08496a7036b90a2e4efdfbcf79610edbc9f905067358b13934825" + "c0ed2e3c3d1f03f7ceb812945f77fcb7731f805b1c", + "483a6b3a7d5de797f0911d2a514350d5ae5af89aefe1245cb08cf8c7487eb99a" }, + { "5bd7cbff6b469c03643cabb99dc50f905091fc9cfcd6d8f28e74ac1a33fd0198", + "3b458a51fdb6b9d5a7071a22825a79f2844c5ac7ae91014ed7862499dcf10461", + "4eda7997fa3b9e12e39eb00b209b43af9949c017660e523e78d0e483f23e9113b662f42a164db3511d", + "808d8a8523a983a2afb2f9daed913efdc19a3c1ca3315382ffe757426e7ef65bc1d83d8e6af95191f3c30de29806" + "5be1e5d14d0dba8f82281aa2fde67684cf7eb6f32ca4de7a116caa796f2b27222f93b9275f4b95f08c4a4e8d6b13" + "cd326c16daf232c8", + "98959acc116ede75df052f4028783105408022ed6db9516e8a27f18c2b4d59f1bcaa7163e0811203a2", + "edff06bd132fd3031cfa5a47803d5169289a29d304f7091b20dec2b284a0e271" }, + { "1bc0dea26d8583e51cece0df7021522adb9336450929715fecb497c43cfba717", + "7cced62d655e703f54824f4e2ceb6e5af1507e2000f1bfec9e50eb87328c2218", + "edeb537b66dc39d20ef6ca5647e6f34df0f5dce2964d227b0c444613f951edbbc532b5576735e9dbf39177ccf807" + "1e5fe9fa011bf8ab7fe9f716acd50847f7a9ce35262b22f04486f1e956e09005249b5ed70e68ca9896802c4ff9b8" + "019fab057bbd5ecddaebb6a079e57cb6e39c95f6748b22cf3703e30a5e", + "36febc6e0763391b6b1031478fd485b54d427b88d06d3582c10263", + "5f75548b3bdc53e80c61fe8659f2b90350a59dff4477fad24764621dbc35ebbb6d71f80c556a825a2bba962561a9" + "db3360311438d4b3eb7452926dc5ec88d451be66eeaa491cc21837ec202b3e71b3ec2d0ed2f53ec59da253fc9920" + "482545f570e3b2e4ecb3629757f3c721fc462a380504aa8fa9fc8880fa", + "9e46a21c41a40101ca413017cadc2fed4fc3ff390a57fc0643784871af07492f" }, + { "230bf249a043d34effa31974328fce207daf3ce10b42e5b44073b70e9566b1bf", + "de67af72aa00fe1798e8b41be2528f36a45aeb3d957bbcc5c01490e4a786437d", + "12403a1905c9da8bd546946612e7d4ddab1c716a533cbd5898240b4c68c675c2f18b72dd40c218bc6f7599edb573" + "f89af867ab3c05fcef8c78b9bd0a267e8db3d9ab1dd04dd14a11f9c9e0", + "77fe28a72f7029da86bfbcddcb819f7068afc07a249e207ae80f0acb90", + "e9f1c7e28b1581f25448b1e21de4fe67c3ff432338b2f7364460b6b1f666a2ddb5b9cc896c3f410445d00c146952" + "180ad1a36944aad13956e6ff95449bcf8bb6cdb1b3e87112507663441c", + "7174e0d47bd83c1a8cf9cb14127d26bad67bf413e146bdfceab4e79b7ef13c70" }, + { "c9675c6e2c0d8cf9f45f17faff568943e4a9038df4472908dd631c5ba8a29c2f", + "bc07c8de4778d50f5dbf324e3f9e377b82e6defdb84163bc9447f156bb70beb7", + "d2c4c2773ac5fcbfe43869bafa8278709a32dc395be3df8360562184d47675133ff716c620fe4d18902dfb41d09b" + "205c87a9a2acd268f9d5662c9e4b12c50181d93ec7b676cb7afd0639f2b3c1154f7489cdf926a85f51c62eb16c47" + "b1bde2b46df56ffc9438b395", + "88a976fd2e7ab25e492f90a1901d7d3982b678217d4b248066c6d8e7a97af0aa93d04300eb0fc0be23a5db41b1c5" + "62efc21c6057c57cd723894d9735d3a651240c6c30e7afc2be2192081c4622ff1d7390e81182642a4d532dda34e2" + "ed45994ce50e1524ce", + "15f5a70290975933cbb70f830200fdd876732952577ef9c0bce0293e78c0525a1209eba2531d9c58cb742ecb4555" + "d4c9cb6bbe69c62a0910e633d14351d3b8f0c3c6734ed9adc384c294bc4935d0026fcd50d513750826da12ecb5f4" + "6b7c6595550547b963de030e", + "da44d1dc3de8523cb2dc0b3d5012f0920ef4665fb676bd4ff66fd6662db058ea" }, + { "c4de2cc53d61339da13f360f88ae40b1895067680a7a9d28b3d281bb2a7d2f34", + "29428c6b06edddd68e8f4973fc2a698fc49c71230bb97da4fbcdafb7f945c9de", + "e9d1f0438a405d57816cf8eb37d3bbada217837db578d7c8e26355ecffc3b497732a54ae509fe8402f30239dca95" + "9b0aa7bd436f23c31e2b9cec889f3bc82d4ad2d4af9c6f978a14b1a8dd325d8976368af2d3f04b83ee343a0bea47" + "0bf8d56913986121402a49ed4a68c6526cb53d41ac", + "74", + "f1bc93dc853b7989e79d34615742488c52221d9d277560406fae0dca1a086ec09ae034a37424556922cd6661bb01" + "a389aa00823fe3e2fb84e9811a078bdcbb4da5e949fefd45988131846259c64b45b279b7cce15ad2b1ba0b52db1d" + "e7d39b07458bba7b26a4a4081fa3b0b6aa53b73d6d", + "ff4527b7c136c8c92b151e0658ff456262fe74a07747f9437445d9336919939a" }, + { "0d0b70db983f4afeac46cb5e042ca51a6a85cdc500f2dfb2f97282d2f96d3235", + "a1280a20ba18cf8977c63450318ff1f6c4303b20c111fc733212e37e11cbd38e", + "d9db68a084a6aaacdbfa1cfd7ab1f9b4fde06f18ff093d9f5a04afb9f1a23a573125906fbe126e8fc0f51e65465a" + "09c1167bb6fbb623f311fe07f564ad4216a01b597d4d756acfc736b905a26dcbad3c6aae8bb7043039d06561ff59" + "7924d623767105024c170113b6", + "0a9d9525935e346ede23c3eee268c24f1070959d392d1aa1c4234cc19cce7807c477ac8e9062ff302015952aa910" + "6de9db40c8d20e022f3617", + "2f517ff86b32f3841fd9cfd34fbbf2bfb77b190dd2bdb74f438914d95809d52d20f07af6fa7a03913a517a6cf3dc" + "591045eb4fd7fa0b55d80ca54d48ee85d56841fd44db7585e5d0ad8f27264751157be2190b85f224623a40c4c821" + "cc8c7c680c548204e7f742d749", + "054df03cbd4f45572ecee0a8fe80b37eeca1f17881bd12c42ad6575a5ef304c5" }, + { "8011b1043674d753172302aa123478a121640daf4317957545749d0be6a91698", + "57bd1ac0f3db407989f88a762f60b3eabd03d3bc3bae577f3818b15c0974ae9c", + "be1833fd169fd745acaa7d8584c457657433e6a3237225a086d47806804120613d78344e097ecc6a5f869d07", + "", + "e34dff511e16bf12570a6828843c414b8fdced120db36ea0223e8700f57bea4c9dfbec5d3195caa633d52ee8", + "0ac3f0459608a7f38b5b77c3f38c73f9ebc48253b316830b9583bcd51ba5c995" }, + { "d4af433d4d7598a8bf02f3e34ba9014a85f92e7ff946d51ea7fa9a4f5cab09dc", + "4fa45413eca04bccc3c732e18fc6442646e5d809afc00e1e749a8b8f84d6926c", + "b867dea7593a03b7b7762052e58b18483163c0828f5ebecb8cbbe4d55c7f1a4ceadf55f4c3a979e619763377cfba" + "4f88e9e692c2794ee862b2aed63902879e11c5ee167ea4fc266a4556fbb54357ad243f92418a1d13c987f5b260e" + "d", + "ee4ff169ca", + "e2e12b2510c72d2d59ad8bf30235d14f3e85824e19b09f4e84eed629325b5a5368178dc94dac13b9aa262f12592f" + "8748bbed8581dad74895fe73dac4cc3a5f17ba480903ab86d349d68cfa0e4dcedea3321ffe1023b092cc77853a0" + "7", + "07a59bb7b8f5805195197a01bf6f628c689024dd64218f0a2a9b77aa5cd6b357" }, + { "2eb12f163119cd1262e0dbb26338486bc75c183026cbc71bed601f6cde324bb7", + "c59654bef68ff95760ce8fdd39f480a3655c650647d00e49620b9938f917535d", + "9cf103fd377ee14f1fd775530b5153eb31789755382697aef6008f59b0404bcf3fe34509835308cfac8cfed2678f" + "523815615423831317ad7770ef74145db7a72ca9462ecd50d7b19a0d50e894bdadbb0f63d6624c80c85836bfabf4" + "4359f700fe04b5e6bf1db1b4ded24fe9054e7318", + "a3fb893a7baf646371e92f3c34c6700e6a9306bd7e905a25be4bd7d6239416ca94a1a31b59068729", + "22139c2d9bedf4a0535c22de56fe441df6752a692a99c10c186b439fde9954e815d6e81d0bfa0a7c3caf60808343" + "3e9b8d32321392f41ae03e5b67cd7801362c371223a98989b00c79fb42d4b25cc222ef6a4fe415654030e67ec506" + "44bbc93fe83c20e1a30259a14ae1ec82ac4759d8", + "83b054697569ad69e55ee1b1491b9353255c4cef4c0f31a0db8090b7dd06ce0b" }, + { "553928dbf68b2dfdacd75bacda2cbb4fb33d81f55731f8ac6615631ed4169784", + "92e86bd57fafd57c88a090397a72f7af5967fb623eec8892b358abd1665f88ac", + "b305ac06529bc8483fdc6d765a535ccbc8125a27b8d72fa2450053ad4be45beede300f87e035a05538b3", + "1f80c2c7694a35f5653ab2fc2cc93614d959f2136bd4cf2918d2a20d6440e8ae73a652e08b7987d1df8c", + "4885419082270c83c03f5d4869adc63cd2f940bf527e8474c7c61a748fc883b74e5ffbd8b0cd3e780a92", + "ef4b2bbe41b9c4e58e207fe9fdbb0e9aed224989d9b9a77e78003b1c2fd7bc31" }, + { "4d6ffdfc693ab2d94d760163bb9b31728a2762c26236f04859b7b31b98c0e159", + "e412d9b3b1b40c740ce56cdc0bec430c0ba4f95f5d83124244cebae8295b31c5", + "ff03d03191d459d57a628a8d69d398214699bf88c2ce8694e2dcbe6d9c987056a50319ef387363b6266fb8d3e15a" + "fe3b2eeb964800799c0686c3d6f0b27d9523592690ba7d765e9a21d62e113788076267cb50193d64b43156b3683e" + "7ab0758e", + "78c96946f355a8153659dd06b41b75b8109b0c31c0d6ff2feb90c875a3b211f01061f73a88a9d42550c807676dd3" + "a405516da1d2639395cb4df526e046d621ec997c1c4fc858b60ff9051f2ee093fc8f032f367bf25b3f32361d8aec" + "5c0e239dbb129316411e96da198d6fb512", + "4c3083ed17c2de0981fcfd38bc244c6e6d0756fa3c23b22fe770c0c952159b6e112c6f4b6686aef4bbd0be98bcb2" + "c32c44af09425f70cbe031d08798ef258a820dcd3029d2b0a857615a939e2a008ef14b949f5bd4ccb4607c8a8a4f" + "c5f1236e", + "bfa101aea1676baa3b5205d45b572425ef7da415984796d2b76f01fe5e37e919" }, + { "c9bde00bad3334e5792b5c1e5a8fda8ea7f7eed152c0a3feceb565208017af73", + "2ee41bb5c473206ec00ec597548161573e8c2adf7387f88e4fcf64c84a2f5905", + "b7dac21337a4029b80ae0ce7578eb0eb45c76eb84d68c4dde73690162b377118237fd1f466ce1d7d7638945779e0" + "b148047c61b63c7e05c877f75f4a52865efe94fb65ee99e4b0d79242c69c3aad1c425d017a71eb26adc2594a6a52" + "16eb72b736f40a91001b13c91d13d5b057ff05ea883ccff3eb6033679b7b41a62f", + "26b1dbda8f99f9492955fab6891c3de81e4535ed525fdc6d98beebef67067fefb1674359525cacb2119d016876fe" + "b5dd", + "6249b44800c9d47ca20cfc1726563befbedf20639735d441917f52cbcc7ef72d5b095c6a15a7bf1239f8b93a62d9" + "bd5e7f47b05ab9f12b4da72392ab4ba093de150fb8b7b61ea92e6a3204b178e2e1c066102ea9aea6241749ebdfba" + "4b307ab0a5471d1d43fc930dc29a1ed5e687d41883c69d0de38ffdd25ce4d8ea33", + "53bf7cee58474076330dc64d1eeff748df909700dd942d8d59da2447b9f84fec" }, + { "6466a65e9fe920b026739645b446cafb70919a5d03a7e890537bf88c620c5bdf", + "db812442fcc36f2deb4b04a9c32354579abd8a57c185654dc8ce5af21f5e5463", + "39917090786a9532f0700bbdd94d960491d89b68b2b9b1425ef8db67b735ff08d73cb171d911eb94eda3354e252b" + "ee238408ced860a8c1657fdf8c9afea4f4bd041173ae22f236c238d38e469c89b2b2bc73d3ec88cda37530362939" + "34732295e29dda", + "34c8b124c1e26a893aeee4b228214ce840cd9e49f1ab7bbfbb4d90c808215be99c9da5d0d426d5933f6aaf9d1af5" + "78c1a6f2b56e6b4c2ef41f6fa67e7f2693f36b3e21223a5428a8a24d2db24d", + "e1d4206c53b1072c317a494b43323a65d4f17afd6f02f865d94c425f80153add9d611175e9f0bb45c51d7f469272" + "10bfeafdcbf29cf3e1de3c01f4fc3fa94848af52293e3f48be11d1efa5d6e2aefb62385c97ab1dc7aaa96bd0210b" + "af8a7c732386b8", + "bb406b111937304d1ede67719247747cb082efa5e8743364b763ef0e9af1059b" }, + { "be69e13f684ade9206fc567da10871fa4bface67e86e23b9bab7da87f5c2f39c", + "d8b143fd6fe42e1ddf4460592c2c3239e2dd97bad39066b86d121b658395bdce", + "4f7c016b4ad5d4822e125851ea3cff387ed83933c6e20965225c34e5da784ba36585e38293c6508eca322e9a9bfb" + "21b3d5b5b0866c2d32b850072abfebf5417f9cf7c1b3e995338b99cab418b9812863c051fd03131c82b999bfa107" + "bb987a83528931e75a5f4ca0de75f0", + "0d32bb65ce4936e3c9eed5cea33bec6cdc7c4e105c132a2dd663bb2cb0fa2ca62fa1fd55ee46ba39853c04655a84" + "fcb4eec40e5a810e8ecc01063420cae63259ed33cb3fac23b343cbfaa7d9bb30ea45f824d0eaff4d836845baf675" + "6564c66e3aef9457baa1c70e3a9b6cf4", + "4cb6bb6308675a9a03f72d1fbf1d2b7b092bb4743e6f8e6d4f8bc176e1778eb226efd8b33a14c3bf0a554d7cd648" + "80dff4adf7fe622d8b2a51d5a3becc06f77046eb98f6f8b7e4c9a9cbf24eb7a384f87912146662a065f22b984e9f" + "11bbba929183d4152c2dd607f87714", + "c06e27543c2dad50440824ab41013fa2fb34bc1c47222e5a157fe2a8d8324c18" }, + { "e365b446bd38e82eec6f10ef0ab21ee388ad485f08935ab5b27d812c77c8c2eb", + "b5d1efebc38b831ef46617bfc282e47e20a844c326c35981b0af5e97cf151cef", + "a04e8c9a01dcc73001fc6a53", "c6064f3f164594ab4bfe65c76c753d81e110a255d3cd9e512c3ef38d54", + "bca8a253d89f09d92b364671", + "4ef59bdf41cb393aada19b052ed31e568855c6edb37d286078ea3c8b8969061b" }, + { "f6c8e88d9e0da3770d3499977a5b9f9d071731244c6b0ccac921261ca799c4ca", + "de6b3d103cf9efc4cb7d60dd3458e7c5a348692ab63a87c8ff611a336f0bf63b", + "5eda6f7400227d5f0c4f8910c621dcd6ef0c4f9d2d9fb3feab68b3b162fc3db362acfb61c55b06febf04546a3bb0" + "02dd6f3b9e2f531cafb7a6b1d31c29483526b2958eddbc9f2eab5717e1", + "0dff4615b2084f8e01dce6ecf3edfc785f1cc51361f32f29b7e5c49c82f9666454f2143b9fffaac5ad9ef9fc0aab" + "e91245cc050d5e21dd3d31bb508072d8a23d3e289aede9e95bef1bc8c8dd6d1401409234237f7e4df6db44cf9290" + "ebca5ee8a69768eb6dc29dcc5aabde", + "50c1b3be72fed8b6feeeeac72b999bf7f24bec747d30dee62f91753e7a26fdb4666cbea2f437232e57edb331ef32" + "7119b8b41572e8a6198fd4377e6657520d6e833fac4b2b2b1ea4c01923", + "342804e54894f812c0879615dd7d4b8959d36f00b03c3e183148ebba41d34d88" }, + { "c9268f6053542789747187da6140b7566024b623dc9691a534bd730764b20a63", + "b0cd1ad38a01130f0b312be85a9dd570937c0fa1050ec7c3aa31befc400b8283", "60bf644abf31501722", + "3091f60cfb9fa8946e8a06b1a663e60b54a24f2e5f8eb5282d980a21878c794efaa2f6f699300e3facc64197c5", + "a3bdd452eecc7c431d", "32d6f160b3c802fc4a92344f6edd6bd47cc83630ac76b3f7d2d8ea38bf1d8886" }, + { "491c6c8be1926521f6abfdaff5f95c5fc6ee07a800fffb4715e36c5de167e8f3", + "747cf6c78d7462846364b00f21a26b18c49d7bc3878f478af38a7dedf86c9ab1", + "9ca6b63dce33c54e7122ef72a5bec5552b1cd8099596ed8917ff694390e970248f1ef672e985121c", + "3d545120992929ab79fbe41da239705bbd20ab461daeb3f13b74069b0797b02699abe360382669e6752564f6525c" + "349b0bf6a8833445d14ad99d2cfa1212e20874603760682769ec1abdf33186de04d33621d8", + "f5a2cf25a6e22b71786ebf2adeb78d0675d08711b0cc9f1bbc6b065f056f1948570ebf4dc8df1574", + "8c7250ec14c5e10239d1d8d275059a09dce220b496a4869f82718258f52d004f" }, + { "512cb5bfea47aa81a414e0e9c866daa1f2f7d7562a9ff7616ca182642695e9c2", + "39f87cc65699610a3a5b84abaf4d8333e1f83f640b7673ba630d53eb608f3c57", + "371b10a048dc329eadda98b1ab87a8fbcf817eac1fc0a40f5a8c3e34e1b735dd4bf2f185964a", + "96fdeb760af9a39b819676fbd7cf6e025de97d9a735012b0fc2aaf2f845b4d76e97220920b7beb1b7f920e0795cd" + "e96ff923865a5eec1a08fd88c837b2ac0b38e860b1ac5d5054e46c6538fd916f46e8bb17751cf152a3dd531762a8" + "abbafe38198dfbd35ce232ec1927b8f47d1833db9bdebf6f7d92eb029056835ae0", + "dfa26829a13b2383e59180b896920d0a8dc02d11ab91fcea5e004416517cbb465f951447237b", + "7325d446ad6af8023893386201dc1a8c7b3d603d13241a5bbc33f6248d42cd48" }, + { "f2ffec87944d3061075de87038cfed1797276d8c6857433c9458677f67e090b8", + "7aef11906a27ec49ace7193bf61183e4c67835c9c26b50381c7ec18b81e4bac4", + "1460c5acbb61d26d0af31b565d3696e50d6dc022c528f11569dde0ad691b32fb20538236028d51b98d441ba5ef52" + "7ace9a59ee9784c9ff14e8a1d03b2450bb75aba2a91ddf1827c14ef131", + "d95e3d49c922e70c4c34edbde880239eec5bad1c13158a07d6a13462a8978158cadb13ee5f2cc95a21673b6ce25d" + "7c30f0c8acdfa55c259c6d03a4b25d22fa65", + "bfb8d129ab8a3898eb71aa46e2d976c44d790803420ce1b6c77c399ac19842b1486339571b82d84a0461a946664a" + "68e6387b4bec56ee0acc08bec0100175d670ebdb6a9c36fcd13126762a", + "2956d57d9089e44a5c34400b411210dd35c261a9354f6ef1d07235224f2f3b85" }, + { "5c2b46c8c5e5a4661c26ad19be10a781cb845c824a403a6bb708c738e90d9c46", + "b80e79dc4b26bb75d284f0346697816efd98b0412549d4ab09e5453b14a1362f", + "ead1a7d4f2a4d5d5a979e16cdbd32005a5b5506968e18d68a598ba5c0fe2863839ecb029450b0b2d0966558a890c" + "af2b2c5ee750be7784f583b6d3e0bed0cb5d4fa6f7fd098dbe05ba8416c400faf2034c3074dc1ef7d7ee63ea1cfe" + "d18526d394c445848a959fee", + "9aa44ce6a70328ac8455e5648a34176e", + "09633b3761e956bca7602b876d9b5429e64e56c2b39ee00484ce92ffa7395751cfd43f6c46ac3b0552fbc2280404" + "df446cdd8632a41fc7989c4d603b3f6b7efbd075aaceeb3e01bbe60ef88b696ac22f41fec3d7b65b35c0c45d8bfb" + "0cc99d80316b913968089e28", + "2e1954215e5487ac78177f851a580067ff75de270b664e962240f38a42f67150" }, + { "05fead6fb5a0f2be62533e0a29377010bac0a25c753155d56de340a094e7c426", + "aa6663a20646cdcc620fcf23c31deac51ef80b68bc8c5df1f91197066763eb39", + "5e9162142770449251a541fcb7798ee6a59ef56c518a96742b4186f3d27e3a8ef9855dd5c0c586cf957725726a5d" + "9518919c54b07b87630c8f5079b49aa656d03b0a10ae7aa498c1eaf4bf0660ff999c8080524843ff8a8137d95921" + "b8425ff6a3cbac4f52c198f9932af067ef734ca00b682f6ad0ef0e", + "08fffcc594bc5d08a1f6473b604289aa885d9b199c2acbc56493cbd740a5127ed1e218a719076a310301954e54f3" + "8b682eb9f50cb05d2335e7d82bb88487f333", + "211957354e5bd50bc25009e2cdb0adbad870d25aa02c3759bebb29ea2de74afd194aa82edf530086b07569588e5f" + "bc3618f762712d63844c8177d7d24b2d9d5f6be5ff98cf7ea678ac7022a15c17430c20213ef276284ceb7f35e00f" + "2b33a124a88d9aa6ca5eb37afa4076b051f94e2c2018cd90bfb499", + "79edf8d61edd0c8d23e2337c3cc7db00a622215540796800dd4c01be03958587" }, + { "96cfab5f246dfcf8b33a9e80fb15f90a089a9078dabacbe767082da806cb4fc9", + "6a0ad0d16594d33730b03a7b40b86581fda3661264ea17f3a4327160a30f181d", + "61b0d79387c11ac4a87c37a9b3", "a62d02eac118d047cae4ebd58ce97a7c99ed90f4a4bee9a442", + "d0762aa4c8d20934e91a999ca5", + "c0dc96d5ad1cdff9445e163c0df739880bb4dd741f4ca70eef655b213b53773e" }, + { "4206ea8a06c8fdfa6aa47e76e317c3108169d142f6de50927345a2825767a7db", + "b9c7d7ce4503a4ca01b8762ff383f0c13c240d0c9ad691cabb61a73fb1ea7dd0", + "0915f9ff74e3b4cc4d9faedd463176e8b4d259aca80b64fedb9427394fc5950d1db2ee8a57", + "4b283f58f0938a62ba97144ac872b231bd93c8bc14c7bbe22f993598544d90991d713e289cc3", + "963202b6d18e7742621ccdefd04ba47457aa639ec78ea6ebc277d062117fcb7f7efbe926e7", + "33d965ed6fff8369f9e2173f784c19795ba93776e9de83fe0292830c0ad52dc5" }, + { "7729253efc6935859e8e7cbb15850aeb37e0e3fbc017754c9583d7b4353d37f6", + "8b66e8adf9bdc7907e2127485410c30bd8488901d0c75857b35c087eb9e21d18", + "ea7d864e9e1b537c409601fa7b35ed10e66b71ad6a81aae70ab07cc69123a459b9020034dd165a46035ce9ab29e7" + "01d3622a76947e7adbf6c6fecfb4316f35e24fb01a5f46cf57", + "a3788e4450cd6edc283dc66866a7d03b1250b8868364bdfa6017cd9a518046304c4e46f5203e547fbf9c5f416429" + "41b198ea1f640ae2f6431caf544fff17a09fb288904fc3f1686c496f7c3dd47f9fe013a9", + "01a5877237bc6b94f0597df25ff9482976a5ff545dd26759efa03b10280d5f9a058c7bb1c230be66977d463df1ae" + "3ddc3d7ab02c10313320b5dab74a22dc0a6d9158cd3900a184", + "7539465a447f836c3d2e6abfc53a8d9af7914d2fcb738735d64051f8f14d59c0" }, + { "d0c627cef866ebdab7a8030be47a9aae4e97311a3a1896de7971c78feba16dfa", + "505b133a1f82a9eb4c57c485d139197fd3e59dbb07b9c8a02a32438f6502fd90", + "206f537aac47c77eff924a9b3e74ea85623945e1c24490", + "636238aea904adc5f4582d48a00357c4aa57ff1f822fdbf49cadf780f5e346f0153d8ecd353073517fe4f080", + "c44ce4e69f32651596fc5fec1f9f59cfa62c7a44f7281f", + "36d1db8dfadc687ed88ccedc2796b8aa76337ed49e999091186659586295b6a8" }, + { "e13e72cd7f25a23b4f605050771ce73980ac37ea3c2104a17a6dccfae70b795f", + "3720f810b9d2fc0c01abe11477689b78ba6515488483b747fdf66f243f2bb387", + "f2468d65f0c10f82d7989e84b500178f011bc98c199f0bc299c882644373f554ef4a6eb8ff008bf005aa8b40da2" + "1", + "1041f65b724df64dd279659ade61cddf90672f490453aed4f019dd86fe5eee3c15c359b01d0f91a34a67bb67b4ac" + "f51e229ada29499a0503fcb6eff20be9f59b4ff57b73e173dcb1faddbb111e645149321883c02b7f2ec265009e1e" + "8331905cef72a24111fd80de344b420b51e4daa88e6b3b054dd96f4536f5", + "79e9eb1f7879d2c2b27e52f3f00fa7c0e813da9bd741f1a3955ea9de04703a8624f6b7b91b0d720c95432bb57fd" + "a", + "4071822c3d3d92142be2437266fba4701e5c28cab4c11e3ac32d245351b66135" }, + { "1caf2693aa463ae93d13f6b687d7a19fdf047c30d054c2fdb5e07e88b5ab5a08", + "86603e8c83f17abf6af5d8571e4f78955440c1aa97bb6a6e146d787fcc1d4e50", + "ea9eddcc4ac951c60afae654d012b307f21c823da4ca44b3276c7f7006ce82c07d8caefa665636d6f5031e31bc7" + "7", + "cfbaf3cac9237f19986571ec0e39ed09b1a5107cfde57bea24b3f5dba56bb7db7459c4fa82ade76f63ec59e9400f" + "4f51188734811bb563131f49c2e2d71841334b596a63470b2dfe3a421cc657129b449628e5c1ce39a57ff07f2130" + "643a725637014eeba27ff95146a99a06e2584cb9bb3f12", + "de9912a8bec65989ba4c82daaeebb14aa21246bdcd52d01ae5d4e1aa3d70a12277651c75d62569349e0e4cebd80" + "b", + "7af7d1875ed73bf8db71707992f07ffb5fcaa82f5a821c0d3a9000443db1bc45" }, + { "cb1a72f1752672a7fc0ccaf10c76257c047fb767f42c3f23cabc78d35a8cae4d", + "a48db1fa02317b85f1787ed869f1b13250d7f582304594fdf4a2899d50e22c3f", + "25f09554ecaab85e2d00c6e76e31222a9ac91b79fe9eccadb6fd38bdb948502849ea5ed30470d0d94335a64fbfe0" + "d01f5a5b6afb95a40c5406c43e022520c2c727d53f66846e35fa3fedb4c7efa44a16", + "72c88fc1764d922dcc6f3a61e444213e6f7877ef585c65a57ab9814813c9ae73b5a4619b316a6cec5e34241ed2f3" + "cc530d105de4e5ca356ad66cb95f2aef4cedff42a0522f5f7d9d7a9f2fa54901e914a5b733791ef5236b78d06533" + "5477a5eac9d626da94b36a76c3f702", + "ca4afd213fa1a13a18e6ec57488012451cb648902e367edf72902944422f3dddbfd4946f5b34292c39ddd84e5c76" + "91afa22f359cec4dd14afd210a5df66a5799aea2bb57c17f29fcf9c3aeb9c528c260", + "21ac240f5e13978f67a5a233e6ecadc5e555fa3c5637d29661ed9196556b231e" }, + { "34eeeed632897724c59cc20d82ec745af1a6b43665ac88290c11b9baeda6b80a", + "562c76d4ff6201116aa3ba82056b43d8106565553efa4f65be2776ec7346156c", + "485560e1c34a3f1068a77cfd144054f1add7ac802d013adf462fa1e112fef5ca2ee8b48c1a37f1d62c06", + "26f75dda69bd27835c891b9d556fb7312ed524c8f4fed9029ad963eae7a43f85a6dec0146b919e195bcbcf7eeac0" + "09ac5aac9ec784175e0d18a25693", + "4a7861fc50e5c17910876b4cc45b1249ca8b8ed3940e82f5f6bf6e0a161263c66005ce91edd32f876c4c", + "72b792ed7d8e1d5c044c452daab093029c63881044bfa97a819204f8fd87c499" }, + { "ffae6a920ea2fc5baea3c3278f8cbba1f1ab3f07f2499cc87eeb3df3858d67d4", + "81a53e4c40e507e2071b7f9464914a273065ec7f24c5e6e5d0bb77f6fce20b76", + "484672fe6dbd8223fa1cc097886e9b73e971a6120b9f909dec308cf1df8d02181216b35ca756025dc50f6bfe3d19" + "2cc5531ad9bb4dccbc1687afc507539b5fd6259c80f55fb55cee1708485f78d013a03851e4e6ce28c0", + "8bb27c47b62c7048b6117e0c631313d2e165c277742a2a1cdddd", + "8027f08446e70cb72e52679809488940fe1965ec18bf1c56882cc412e41f7727efc55acd6c2b996b5fac79bf13bf" + "ddc7e03b3900f57589215a37ff34241329ca7b5da9ee238ed7fdaf5b1bbbb172e040d1dccc6acbd8ae", + "d25734872533b137110dec26861bcb77fe062c0c41775a2a05ccb86365bcac09" }, + { "57f2386e011a547a48e5c8c170bdc2758e246d4fdb4b5f90f06945efb6bf6c9e", + "8647b48a6ac27f0b6b68f09d9a264963b0b62c8cc8b454ccef9c503e6d568b33", + "523120a8a391e743e7e2d60fa509345da8145db83631881bcf21c0c56b47990966ee08a36b361d2660268bfebaa2" + "2d4f5a8584c1c04a27693adfef76e910eeac0454c4c1aa3b", + "e7b43a9582ba177e97df8725092ae30620a9066c1cdfa627dda1042f5a325a46496c4b200baff0e0709c52ed0ed8" + "2ab11af1efec1e05d044f50d25a38eaf6da2fc2709e609df95f2dc6500d30caca60e421a169ac0f1f69b1d774f37" + "5b942edfc4151e0c78", + "a032008e9601e05f87694a001918c0389b66d13ea514f4c2d5c891591856a3e45472f74b14c409376060ecd90de7" + "b700b0048cd84bac232f5211768e4185086d7992103be87e", + "ce7174bc583746a5183676f5af292df91213a864bae6e6783cc51543cd18e80c" }, + { "29f1e4ad600bc24f64d2a99669f7317add8e61d5d3a3dcda1968b398e7ab3a8d", + "15190e8300313a59c0c6c4dcb0358cc88f7e856240091f1b1bc599a2ff3aca00", + "b01d68b18df703fa9d166efd6aa3ac15fd48dc99f4ac806194f0f500be971560b3135ae422095a", + "cf90cd99d137d5bb0203c0a97f5d4842f4c0ad975df8a5dd863269b37e94fbcd941f220736ea4987e9cfb73b17c9" + "39be601c40daa99133b9a0f98bdc4e4b77bc47d307354119a2fab2771285048a273aa859f99a4ceb6bcf5bae19d7" + "b9d766529d53e29a384304af8de07e", + "321523038cedbe3da195d701835cf62941e6260c3c4ce5466e1fe14b36bccfc0bfcf4955f1f061", + "75b72ea023300ea4fd27926d097e49d4955c6dd6747ea38d2c33bb21ca61e168" }, + { "4600adc836738547a6e1fb257d6a7c290d4895dcbff2e071dc38bac04f338a30", + "ab2f8f6a728f1bab52541407027c51a1619c1db32985120f5ab40cef22e08edd", "f8cbb1362eab78f7", + "7adb0527d13748950fc60a8f6879ec1116c73817e343958965359c8f7f7465b26fe5da1f43112465be72751de684" + "600456e97856aee757161f6157dafac3", + "26baa1fd39aa3c33", "147f674a8345d803d23714b057bf8c030ffb002b6f9dac1a1a7d7582dd89b746" }, + { "01f560d41c4dcdb3906e687c5fe23c070b9a8a9653987706f3357037d7d512d2", + "a47633929b3fbfafd2c29d25ab1e8e3b6402aeecff25d60761355ef44ace4cb0", + "6e085d40606a8042e71fc16b720cec34e47d9bd5e0676f74b6be17f7c78b53ab910980ed7b0622c248006c0ff9e9" + "4b66b8944acfe6857f3241d0abdd8d70a4a81eb0c0a86dde53849e34643b9f37e173ed218d88bea948a240", + "d7631a8eea17f31555b3d4abf16439f763501827180a1f5e58389f796f1c0b468f41ea3ff2e1c76cd02d180c9df1" + "e19f6524b2a8d006f2f954f340a2f0a5a97946d39c34b935f5da5b081f18ecf457b6f0b33a37185ea8af64aa0ade" + "40026580dafe1a5dfd2c4a7acfa8a8254897c7fd3b", + "c309272b71ffd6ee1ed80b91ad22fe88d0488fa7c2dc4539f3452d6d6d1508c162bb8df3ec1fa5ebbd8ab738387d" + "5b0e649cfd83e17b3e943ccedf4548171c82cb8f0b2ae39c48d78df07e282cc40c3068dc70f1fc080114c1", + "786061e81d76bc07550cab11bc1ba1765b41e2967bc8736e11029968cbd85ba4" }, + { "c440e9504cfb4544932adc72ff5fc1b657ba0aae703b1bff33805b7f9b81412d", + "df08a05337a532382953728ef1e921b772d435803e671a02e9cdba82522714a1", + "9dfa0945de0d4c2cb76aa55f8b55761911163b87993db7964760dc5e807f003b6875f74eb34cc160942f580bfba4" + "d96d967d50b1b20b0643ae1a2c73691b6bfb64403350272686fc8bb3a8e3a5674761c2204ca240e37005", + "0c9f5ad3e58b9bf021e09b83564c8d74b1b2bf7c8cba0dc8177084a4e1a07bb84c30c3566103f538", + "279ac5eb9bf6e01cd50a0eda161658f331226f4c8d43fdb793ae07f353e6fc2f2821a01a02be62f515af80633215" + "a908aad8e5199c4ff23a38277ff8f16f15058d69fca995718c0d837b6db3bbb5842dd21c07ca35b21bd4", + "16f09ea8657c053e907bdf8f822936f2cac056af25e0240633c80ae0baf7ade2" }, + { "ca81440758e13fe0b847ea81be8037b1be4cf995f805d4f40c1f421c9864ab9d", + "aed156910fd8af6af094c74c0ca0fba932b436bc282e0c5c910ffd3651777117", "fd83897f98974ac8", + "64ff6ab0506574c5020e14c45a009192a7a17ffbf6761393e17a86aaf339264a5c72e9e2b7fd22832a999076dbd4" + "9c75145228ba6d36b0372042e22435f34577a2c3e1c89e2e1846dbc393d57064f016d0487d591fc6b7f8499701f8" + "2568182041929386c821b74a53232dd596b300a13fa09949939967e58b2c0cf2de5b8b", + "cc1913d2e48750a0", "59db1143754b19f380fb1d1b9296fa992b7c2f5adc56f451349d1ff95cd2a1d9" }, + { "a657ee84d894bb98db137d57121d149eee96447353225f701b4c0c8bfc5d9497", + "1edcd529feb85cd69e484c0989a9b60776437dd4dcf988e3bfcce5bead13f331", + "4fd8a593ef021f81603e430e0c9eef2fa2e7cab56d86b13a9ecfee70fb96a7bb0cdc7b23df061ff73b96a289faf0" + "c0756f0c2e4692489e58391eae3574539f40189fb8735735deda0c8d71ff361155a0d3a574b193a31746f0272001" + "fbe8f840dbb4f16f522c90096ae5d76209af6eb2e423109d2bf0", + "fd167c49f8e588d06df1ac5d94d61538e399d0c531aa0ac0f9a1c030dbd3e8b649796917f4f8f8078b104352b156" + "4a042ccffd30c19340e067d4f17b0bacc47e121a8808d06b1ea6bcc06ffbc1bdaed0999dca79212c8df6ec", + "99f8a75bbaef042167ebfb927e6ff5bdc23e3a2084e539780ffbdc20d9be6d21e761381f23937f3179aeff80469b" + "a65b8d2169c5695ad2dc64e39d165eb7e57ded4ab07182ca59e516b41dc463c2093425d9dcf6a377312e4437d441" + "6d063324d24945f86c57a060cdb4c182fb3c9094e6c43af38a8d", + "977af18c47b4e1bf3f6ee45ae865d3e3dd6ebc953c4ee636c3e560beb433c5d6" }, + { "0cb4ac9b372daf29e69a698a434c67bf822f88eabe81c2fbd1869b151bec66ad", + "b34c3f1d39ac43e9a10ed22019b858a679fc4c629b7554e4b205ec3f31d601d7", + "40da148ae0cd9eb7d108fe5b04664e6369ac4f24465737a33f2a16164e67a84a403a66ea3f4166b4304f", + "1559e36d745dd40b60d8006bfa6ad62f9f1a8a7992de66bbc71d8ddf18fd68ce01e7910a972a028334f686c3b214" + "d725d3606eb3b762d69fb1460b95e949a724d09977c41b13fb094e16e186ddd429515e939e641cc38e5f6c492f3c" + "f7495cbe2b474c48f1890e214edfb8580d1de07855084d69ae241b421ae6", + "e2c7a3fcd1d66a1f71301dfcfc459ad8c3485f2586a4594a02e46d35dbc4e637e9562cee2e317adc7120", + "feae706283fea438eaa7c20641bb8446e9695cd9a0292f99b3b3ed4609a28dee" }, + { "b38e1805f202898c64975134d2369d065b808ca28ac8562bef3dd97b96650b3c", + "1bd55d1c60a6f84094c52906fb2f711aacb93831fee6dc27fb6a746f4c412012", + "d4817734cb56d6bd3321c7a3dc4e23d5481703d72075ae6127f1f366a0624bc1e2ac175db9ee2fe4a9c0a016d1d9" + "955c652970a05dbb4b16f7d2e7275b9a915bc39df5effea00190b77eeb6fd056cb2951cada1d8ef9c8e9ca0de03d" + "7b2d659c947c9a82ab512641ae734f82", + "1be672d193cec78c85db5636ebdfe4f087ab5a2fccff0885fb39b60f901e8d6921e4d285b5daa19dac9032d6b03a" + "2a81740ba4ffd833e90a942253e607a800c1ff92", + "5be3df33c976077a603612ee85cfdf388953e958e5ee0c53271058258dbcc1fa8e493e044467fd00229b64337644" + "8e9958dae478e59808839daa20c983159be864a905f97e7e00bf82ac97bfd9d005f3282886b7c1df0b505f75741c" + "518bedea91f800fcb135688940a38022", + "5fe7fac48f68d44c9c8d8be7ac95025fb4bf890650af092d1228c4858a8c1a9f" }, + { "bdeb596ed2056c8a78eb1f33340d2b8b0789cc456d6e8db9bb45516233900e29", + "7096012b1bf4f66f48c1f26ab48d8594d244be86426438993ed1cfad84376c90", + "5f3638865cb87188951620dfbcf77c6da914372635542fca218b74f5808090f8ff72919975744dff1a6693a759da" + "7579ee01c449246e12783546333d9201ddd0e9941acbedc6c1995b09", + "186d83c27e4831ef0c472840230860513d15b0f3df6a27ce2decb7a53c15e38c3b043c8a", + "399b4dbc243c979b481b18a29415fff5065c9da5367679a2bbe60b5864352fa096c65cc51c9d5054844b8f0cdacb" + "c638f8defdc81b7d80a9f5b1fa58201f0c513dbb192ea93a05dda87f", + "7f5644fb9adcbc68a86621c4d6d7b1b32a62cda6ccdbe2d5fa8e708a4de8a3f5" }, + { "42985b7c9c97ec16bba3c36bcf82e93205c35a57428262d9e45a7fd494a9020d", + "be4b2dd3dde2e7a773f7b85f0acb48d65bdbf4d8bfc103eee72697c8834a5058", + "6bfc05bc2457a43f50a7391a2c38627fb0429a446ac684e7552cd54c07b9608f716ceeb50d6bc0563247163213e6" + "2ca2bbb5067dd00b3d884795a11dab0c96e23419ce7779554bf39c50edd6ae225998cf96d1effe70c81d348a938b" + "116fcae5d402f35aa2900673376576", + "a7f9f0d4a1cdeb5abf1d927f6968beab9c6ead6995f484c016", + "985b208c4938d0fd9ac7b653e0d04445fd9666044e79a766c746354cf7c949e8724170dd76245f2af71ac34d379b" + "0be203bcb863f40081564ba161087605a9863f5b39c2c7d0f7876c84b02d9131f5284ce5d837662575efedcbb3b0" + "12053e2c4b15ef4ee0010840552759", + "ac55330373905d10205b0884596166370c6c9c52af6a358bbf09195b3e2f2626" }, + { "50034fdf7205a542055cf377ef546d1fe01ae8c7581806688c04279aeccf76de", + "215de8afdde0916097f91dda6fecbd18c5e65bc685e10488e99a225a5887d92b", + "dcd4b2ef9dd40e50adc8ce3fb674801d650e", + "6f1ce70899b24793fd8ad89784d62ebc43b750faa9bc63fa44e707cb6877dc400dbcb85500a386add1052bbf090c" + "637c8c618428040226209023a0db954ac26824ce40ba5021bb19d1a65ee3e3c4261c9801bd85b9c282753072", + "df3e9901518fa830aaacab9a5635c861aab5", + "b2a32c41c181a42175cd9108135f815663981c51f43af547e7942f77ebdc46aa" }, + { "782358a4bf3258130b1ab345e76184bd37eeff55c6efe7b8489626e5ba01741b", + "3ae5c450b1f426cedd3f5445ee785b6c2718d587f4239053cbad839e7e19f044", "454e", + "bc5971d3c8a7284f6218685581fc0e67572e5f124405136021536da07ec4d443015de3a708e72eaa943f5b5fb8f4" + "85472a3999e95dc3ab7cf72ecba533006681a49f39b5d5768e9ed22e3cfc7d20d3744308a6518d46a0", + "8a75", "d5cf51a52be53fc9b297efd9c0f3421e598143718f7f46fc3dd542f166a65e8f" }, + { "5958a371e26fff28efef8a6e71a0b81b4a14e3cf57ac75d215376e050468806b", + "1293abdd7b6c43483f8caa43836922fb3a92feb4eb1476f4fa5ec4f06a0431f7", + "06544eb4f4baafd8880df8a4e1da38d3111149aef41669b56ae2", "5f6cd8814bf4915f08cbf1", + "e4b718de939d6fbb41e32b57098b08fa16bd39ccc085625d0546", + "d1a48afe22b3c7d28e239f103b93b0a200428f4bb8e80fcb2e5110fd1ed780eb" }, + { "7bdcad0b011743f3dec12c999ac89b28f60e03564cd076fbf0183457846e606b", + "e008a14a3fb5e56e89e02d5fec31b37b3fb6357682bc3db3368f25987f6205c2", + "c2bc1a650114c6d522d2f928c6a65fb6abcca554336dfb70b51f61558a349387b35462bba19c3f8f13488fd4812f" + "9d6d58d04a6ca93e8dad62a5f695a0834dd99f876294", + "18066e9f8cdd274090f075f3047a455ca6be1ec4d1672acb013f328a1d981bece9b9c9f0f38dd25db8523b885b47" + "cfaba4844d5bb3972591bdc2b68062e7fb0e08773506e7851a18fbc6cd29c29358a347ea195a10f5a7d874010909" + "278395f2f9820ee8eb6655602b7b44c6c1642b9c157cc5c1a454e1b18b46", + "bcf887985dc0e45a156b522f02c4b2adbf90a2b30f4a30ee68505df9c61d3857a6216a827c98d1d7df6dc664a526" + "32b61361f4d86ca646c83f690015535b149c545efed3", + "bd2cbde77f6ef4955e956d440226534942f7a41a659eb826647b3a99a57efa87" }, + { "21505992872622190e47da3d4a985ceaf356b35e096429bdff8e4a21fcbeccac", + "8b4ab2427a4177cd205fda2b2b31f8f5ecc5ff591262791f88f54535f3054977", + "1ceea40aba4d9328718e9939eaba25f5b558ed0df855e743cc958506b4d0c5e44d0690b9637bf94a30e861ed9260" + "e254d602be895f173453a7977236846c4687d2b38470f074b07e16e67721646989421cf5081555fa7bef42a83066" + "6e6c2c9b61ba14932210", + "106f5b1fed2f5d3a102733ef6fbb7e190e508e7e8cb73766bf18fa4d50b87d6f83144f9b616dceef6c0b085f09e4" + "27f7f0985a535fd9edf3bc05aa8dbc0db601cb4f90761420164fba50a68c5a87322fecbe28c902b03035e88d499a" + "f758eb2049659f2561ee6c5210579f8c0c", + "1562c0d501518e478b0c5561b32a79bbf5249d0eb8db411190454b4f3a458bfc200f65af91a22eb0fce63c726cb2" + "b51023d294c9a35e0ff842da517d6f91b6126c0ecfccd72cfc35d7ef98f11ebbb4cd071c2eafeda598a5ccf4e09d" + "8cff52ed583d968525a7", + "1dfe935ef87488e515897c850bc899d4a9844d512969802e98be90c0343bc146" }, + { "337bd1641222ad96608b0928eb3e05fee02a6fb1e2f66cb4c9b698d1d96ee39b", + "b532f2e6485513a5b21a6326beded2b3a74bc49c74db3f7a23e440e5bc864e7d", + "9cdf9d6c42cff95ca0bf8d199962f55ce013348fb06d878b10a344ad5a7b2b2981b0e44ddb7dda1f74bcd24f3ff1" + "bb63da249bb02234edf123305759780e45ace82aac7a95adbd1c7e72741e374c82a4524146d13589ef28ee593678" + "9e65724b10406aff6d19d0fee8289033c094bed67df3fd45b0bdd52fccc25492cd335a", + "efa6fdd7e4c161a5cc2eb6d67b14d6d8f16ecd3c52e8c9720709c321de05973b51750a7286120a50b3039e54c4c5" + "e09785f815ddb5eb528b43e972bf4c60e41252", + "4616337212a9b1fb827ad8729cf40a8309330dcc958ac0d5f73c9e57279de69280065e13fd1309153243c1303cf1" + "16227392c9ce4b8ab505a580c06926587378c83f49c30021a1f4038180fedbe90259a9d468c87bdff827da1d01a1" + "23fbd5b091d62d3b17e3ce7f4e83cba4510dc1e41b420c2ffc7544464befe9eb5a898d", + "709914dea13632a2127159bf004a73349efc090a46bfecec911c63679a1540e6" }, + { "88f3c9cd7b2f27295c5defc7ba7071996ae5d558192c1a4788efe8a3bc3559d0", + "d1ec8bbec1bd039825009a00b35522ad81c8de7bbfb698551f880b05319330c6", + "5fc7d4fba7f9018c91533584a5e61be925559d1c8b1270621aaa2f0f51ec69ee7b14628841e2a234f3ed4279e589" + "bc40339928d600f79a051db41699a98a263864ae34909a7c37e9c833c106bc5e996c730879d7b94d18c87741a3e7" + "2bbbd30a5c7a", + "9c", + "efec904dfe14b42ca52b083ca46fc0ab80877b425e8cfbafdbcdf8600bcaa64afa05119ebbdd0f8db82ae71236c2" + "4cac6cc53b9e0ec701f94ae4a9217f9f63ad426394793cebb1f0af7ba4bf0dc8ac621c48e2a435955afc79f095ba" + "518e20bbe360", + "1ed588fb6966a006fccc5f5a6e57949f9389f89c3e346bd8851610a0b159e958" }, + { "db7c3c7c7e5aa8a1c5cd5173bfb0d25958db4038a3d8deb705c102935fea8f21", + "315686635d388d5b2ecf3b12a8450280d92555a6920f6ad3b48ba3b4f8ec5053", + "939b319d85880267f8be72b69d2a22ba2460bbd7ce68cfc9398afce09c4f0005cf510db2aa894dcbf08120f07640" + "255a9464056ec16765521f23d602b5af51cab7133cf01123b3038cd7dc47fdd7801c46fd628de0aa", + "b2da", + "783dbc7d88eb43f69d7330326e58555f58df2e75a019586beb5e4a303a3b3e4439677fd7e00a6826372cb2bc15c2" + "5ab445bb0dfa8aae1f4d9b5d6ded219e69037c161c7fd5911bf08e3179419dbef05d37df75fb19c2", + "b96409a14cdac61218fcc2ece389e570ac6c665856f36d98fa01be4d767b960c" }, + { "cf1f1538739072f57ebf0fa4090a63c72cf8f5bb904effb6051073596ed1dd19", + "41e11d23771626febef2435eaefddf0c93a484ea6c4c7fa0bfd48f93e50b646d", + "a22ba67dac88efd1988863f8991bfc9dbb9dc1a34e3866b0a51e088671971225fed3bc0369b0bccb436249d6fa30" + "e7", + "80d7f1fc70203411f8827cd7eec9888f26e39e055d8fd1c2876e1e252b3b14363f493100f157d8246c29b973a490" + "338dfa0bcb52221d260875a65e22a56f655a55330933b35e2937c53a625a55bf40564fc58f742ecf54aed0536ca3" + "f7c59f6d", + "b3c76b03eb90c78ca281f178f30a92a98ed9966698ceb24f15f6c5ebf2e65ec4880543847005a58006a0829d2d00" + "b3", + "22f4354c7487a2db0c8c2249fe96909ea1cc9a053447b4a83ad396e3b3ec87ca" }, + { "38a7aa902690a3e1b285953e0121eae7304815e12a015fa98cbd227e6f7d73c1", + "f23f9ac01c0b118b684f10031836f7c92e8a70eea0e916dba2952b685ae2c148", + "995580acc337ee1216802b1a45daf0df12280eb94953ac61916d35eee038e5ea1d1f53da1c6a3e17d54dd1555e79" + "c4ac988494f805715f59f2404eee2fdb592fa538928d", + "6b726ca02fa44684e7d92ddb0b6e2f30d6a6e75b537f209d21bf2375718b4092286ea592f3c1750af21b12f64961" + "1370ee4bfac05e0281c9731242c507a56d9d6522c26e172fb406f3e61efbf3c346917988a1dc85c829d51d3954a0" + "825d2ca4d0e2a784c78ea07bfc5973e80fe6b34ccfe72457", + "c73f3832441f59ce54910fd16dca9e2bd59a168ccd658ba3eb87fbb1ba561f63ad73ecf9618481bc6e8c8020c60e" + "8194cc65bdea155f0f6cc79adaf2334c099793efba4a", + "5c52422a24f79990f26224082d375bf81eaf5df242389c894cf89c4d0131d01e" }, + { "aa54db3f1c5e6405d443afcf4a463974448435f4002d64044a21a04c269759b9", + "0711d3a79176e4c75ac8cc1ecdbadd4203a6a4b9eda4c2ef17150f493d645b8b", + "5a80d351e6a2682a6ceeb374acf59de7e7", + "171077e40c0a689d44003bd1ce56c08b81f6fa3c118cf448f5e8b6386328d5e3465132e5bdf4f73e60b1b1e6e021" + "d05f6881fe7ec8be523ae7e6c57dd1b0af6939b79dc785d584400dfb71aabc336817e295a922aa1d46b873ad3863" + "3099ffbecbf43527a1e64f98d82cf85a18", + "5026a9cbdd2239c6a9abd45e36d5b46b14", + "afe7bea6340c227c0f062e73a05e1be4aa63b93d35f2322322d3e855e0ef5887" }, + { "c3dddd6891c6081f6b478a6cf89574636c8905efbc8079ef1924b97036a050ef", + "abc30e2892910e8c3fb83d4cb6f93eea614a7ff03b750e31ad5fc74ab77e0715", + "079db15c3fc075189ca979ae738e72f0e5a35410b0b746d2d92874f58214cedd7e69a5337485ff038a44f18cbb6c" + "9bb02bc396aa128b87e7888011e803fd9f43dd43494dfb2b58981d1f95820be9d37cec3bc4f779861cf59137f764" + "dd88ea41cf044d9a", + "56c59f42c3429832f9f2333099d2c422ea40cf36162b162e6cda56a9", + "6910f3c047011cf301c6d8458ca4d1c40aafc129476a9c89da7b35ced9479edd3c7cbd5c1ae7a8fabff159cce121" + "c170c1e1a884255b08758d640371d26eb031ae92d1deb7091f202bff0698ca059eae8ae572ada217b6d3df5d446a" + "a5aef503eda02f5e", + "f5d285ebf784c68df40ff4324bf79d0808d43f0739d297f4238b833a7cf9c013" }, + { "77716c56b9f0e158530b24ae8bc160f827eb4a11ee3b1bb3fbef3922e41d58c1", + "f340f377c03ffca01829e013ba7a175b158ac51e5ec84e13dcc1a1974e157557", + "2b9b2bf80c7c65d0a2d243cfac9d01ec9a0250b5e985d430f5eed4ca6aa62b31e3f5d4256a9c998fc588c69486ad" + "41618d8b9094468f9e74b6", + "d314a97f25ebbb16aa2d8a444c70474b5733fa18507c544515ac905450507c708868a7c3847705fcc3b7651a72a2" + "15675a24d44aec160c562c1d68f859dcd4b9aa3569595e040ef6", + "a58d41ed071ccfd12e01de4038783e6b23f84f55354dc0368a025cb9ceff0aa01d9e77badba040fdbc5cd984f95f" + "4c6c6ad1151f02b5687ffd", + "f66ee48f6ab2bbdf3ebd292a11c997bfd6f81ef5a9b61f0c9c5f9e77d7fa2624" } +}; + +static int +tv(void) +{ + unsigned char *ad; + unsigned char *ciphertext; + unsigned char *decrypted; + unsigned char *detached_ciphertext; + unsigned char *expected_ciphertext; + unsigned char *key; + unsigned char *message; + unsigned char *mac; + unsigned char *nonce; + char *hex; + unsigned long long found_ciphertext_len; + unsigned long long found_mac_len; + unsigned long long found_message_len; + size_t ad_len; + size_t ciphertext_len; + size_t detached_ciphertext_len; + size_t i = 0U; + size_t message_len; + + key = (unsigned char *) sodium_malloc(crypto_aead_aegis256_KEYBYTES); + nonce = (unsigned char *) sodium_malloc(crypto_aead_aegis256_NPUBBYTES); + mac = (unsigned char *) sodium_malloc(crypto_aead_aegis256_ABYTES); + + do { + assert(strlen(tests[i].key_hex) == 2 * crypto_aead_aegis256_KEYBYTES); + sodium_hex2bin(key, crypto_aead_aegis256_KEYBYTES, tests[i].key_hex, + strlen(tests[i].key_hex), NULL, NULL, NULL); + assert(strlen(tests[i].nonce_hex) == 2 * crypto_aead_aegis256_NPUBBYTES); + sodium_hex2bin(nonce, crypto_aead_aegis256_NPUBBYTES, tests[i].nonce_hex, + strlen(tests[i].nonce_hex), NULL, NULL, NULL); + message_len = strlen(tests[i].message_hex) / 2; + message = (unsigned char *) sodium_malloc(message_len); + sodium_hex2bin(message, message_len, tests[i].message_hex, strlen(tests[i].message_hex), + NULL, NULL, NULL); + ad_len = strlen(tests[i].ad_hex) / 2; + ad = (unsigned char *) sodium_malloc(ad_len); + sodium_hex2bin(ad, ad_len, tests[i].ad_hex, strlen(tests[i].ad_hex), NULL, NULL, NULL); + ciphertext_len = message_len + crypto_aead_aegis256_ABYTES; + detached_ciphertext_len = message_len; + expected_ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); + assert(strlen(tests[i].ciphertext_hex) == 2 * message_len); + sodium_hex2bin(expected_ciphertext, message_len, tests[i].ciphertext_hex, + strlen(tests[i].ciphertext_hex), NULL, NULL, NULL); + assert(strlen(tests[i].mac_hex) == 2 * crypto_aead_aegis256_ABYTES); + sodium_hex2bin(expected_ciphertext + message_len, crypto_aead_aegis256_ABYTES, + tests[i].mac_hex, strlen(tests[i].mac_hex), NULL, NULL, NULL); + ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); + detached_ciphertext = (unsigned char *) sodium_malloc(detached_ciphertext_len); + + crypto_aead_aegis256_encrypt_detached(detached_ciphertext, mac, &found_mac_len, message, + message_len, ad, ad_len, NULL, nonce, key); + assert(found_mac_len == crypto_aead_aegis256_ABYTES); + if (memcmp(detached_ciphertext, expected_ciphertext, detached_ciphertext_len) != 0 || + memcmp(mac, expected_ciphertext + message_len, crypto_aead_aegis256_ABYTES) != 0) { + printf("Detached encryption of test vector #%u failed\n", (unsigned int) i); + hex = (char *) sodium_malloc((size_t) ciphertext_len * 2 + 1); + sodium_bin2hex(hex, (size_t) ciphertext_len * 2 + 1, ciphertext, ciphertext_len); + printf("Computed: [%s]\n", hex); + sodium_free(hex); + } + + crypto_aead_aegis256_encrypt(ciphertext, &found_ciphertext_len, message, message_len, ad, + ad_len, NULL, nonce, key); + + assert((size_t) found_ciphertext_len == ciphertext_len); + if (memcmp(ciphertext, expected_ciphertext, ciphertext_len) != 0) { + printf("Encryption of test vector #%u failed\n", (unsigned int) i); + hex = (char *) sodium_malloc((size_t) found_ciphertext_len * 2 + 1); + sodium_bin2hex(hex, (size_t) found_ciphertext_len * 2 + 1, ciphertext, ciphertext_len); + printf("Computed: [%s]\n", hex); + sodium_free(hex); + } + + decrypted = (unsigned char *) sodium_malloc(message_len); + found_message_len = 1; + if (crypto_aead_aegis256_decrypt(decrypted, &found_message_len, NULL, ciphertext, + randombytes_uniform((uint32_t) ciphertext_len), ad, ad_len, + nonce, key) != -1) { + printf("Verification of test vector #%u after truncation succeeded\n", + (unsigned int) i); + } + if (found_message_len != 0) { + printf("Message length should have been set to zero after a failure\n"); + } + if (crypto_aead_aegis256_decrypt(decrypted, &found_message_len, NULL, guard_page, + randombytes_uniform(crypto_aead_aegis256_ABYTES), ad, + ad_len, nonce, key) != -1) { + printf("Verification of test vector #%u with a truncated tag failed\n", + (unsigned int) i); + } + if (i == 0 && crypto_aead_aegis256_decrypt(NULL, NULL, NULL, ciphertext, ciphertext_len, ad, + ad_len, nonce, key) != 0) { + printf("Verification of test vector #%u's tag failed\n", (unsigned int) i); + } + if (crypto_aead_aegis256_decrypt(decrypted, &found_message_len, NULL, ciphertext, + ciphertext_len, ad, ad_len, nonce, key) != 0) { + printf("Verification of test vector #%u failed\n", (unsigned int) i); + } + assert((size_t) found_message_len == message_len); + if (memcmp(decrypted, message, message_len) != 0) { + printf("Incorrect decryption of test vector #%u\n", (unsigned int) i); + } + memset(decrypted, 0xd0, message_len); + if (crypto_aead_aegis256_decrypt_detached(decrypted, NULL, detached_ciphertext, + detached_ciphertext_len, mac, ad, ad_len, nonce, + key) != 0) { + printf("Detached verification of test vector #%u failed\n", (unsigned int) i); + } + if (memcmp(decrypted, message, message_len) != 0) { + printf("Incorrect decryption of test vector #%u\n", (unsigned int) i); + } + + sodium_free(message); + sodium_free(ad); + sodium_free(expected_ciphertext); + sodium_free(ciphertext); + sodium_free(decrypted); + sodium_free(detached_ciphertext); + } while (++i < (sizeof tests) / (sizeof tests[0])); + + sodium_free(key); + sodium_free(mac); + sodium_free(nonce); + + return 0; +} + +int +main(void) +{ + tv(); + assert(crypto_aead_aegis256_keybytes() == crypto_aead_aegis256_KEYBYTES); + assert(crypto_aead_aegis256_nsecbytes() == crypto_aead_aegis256_NSECBYTES); + assert(crypto_aead_aegis256_npubbytes() == crypto_aead_aegis256_NPUBBYTES); + assert(crypto_aead_aegis256_abytes() == crypto_aead_aegis256_ABYTES); + assert(crypto_aead_aegis256_messagebytes_max() == crypto_aead_aegis256_MESSAGEBYTES_MAX); + printf("OK\n"); + + return 0; +} diff --git a/subprojects/libsodium/test/default/secretstream.exp b/subprojects/libsodium/test/default/aead_aegis256.exp diff --git a/subprojects/libsodium/test/default/aead_aes256gcm.c b/subprojects/libsodium/test/default/aead_aes256gcm.c @@ -3081,6 +3081,7 @@ tv(void) { unsigned char *ad; unsigned char *ciphertext; + unsigned char *ciphertext2; unsigned char *decrypted; unsigned char *detached_ciphertext; unsigned char *expected_ciphertext; @@ -3097,6 +3098,7 @@ tv(void) size_t detached_ciphertext_len; size_t i = 0U; size_t message_len; + int res; key = (unsigned char *) sodium_malloc(crypto_aead_aes256gcm_KEYBYTES); nonce = (unsigned char *) sodium_malloc(crypto_aead_aes256gcm_NPUBBYTES); @@ -3135,34 +3137,48 @@ tv(void) ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); detached_ciphertext = (unsigned char *) sodium_malloc(detached_ciphertext_len); - crypto_aead_aes256gcm_encrypt_detached(detached_ciphertext, mac, - &found_mac_len, - message, message_len, - ad, ad_len, NULL, nonce, key); + res = crypto_aead_aes256gcm_encrypt_detached(detached_ciphertext, mac, + &found_mac_len, + message, message_len, + ad, ad_len, NULL, nonce, key); assert(found_mac_len == crypto_aead_aes256gcm_ABYTES); if (memcmp(detached_ciphertext, expected_ciphertext, detached_ciphertext_len) != 0 || memcmp(mac, expected_ciphertext + message_len, crypto_aead_aes256gcm_ABYTES) != 0) { - printf("Detached encryption of test vector #%u failed\n", (unsigned int) i); + printf("Detached encryption of test vector #%u failed (res=%d)\n", + (unsigned int) i, res); hex = (char *) sodium_malloc((size_t) ciphertext_len * 2 + 1); - sodium_bin2hex(hex, (size_t) ciphertext_len * 2 + 1, - ciphertext, ciphertext_len); + sodium_bin2hex(hex, (size_t) detached_ciphertext_len * 2 + 1, + detached_ciphertext, detached_ciphertext_len); printf("Computed: [%s]\n", hex); + sodium_bin2hex(hex, (size_t) detached_ciphertext_len * 2 + 1, + expected_ciphertext, detached_ciphertext_len); + printf("Expected: [%s]\n", hex); + sodium_bin2hex(hex, (size_t) found_mac_len * 2 + 1, + mac, found_mac_len); + printf("Computed mac: [%s]\n", hex); + sodium_bin2hex(hex, (size_t) found_mac_len * 2 + 1, + expected_ciphertext + message_len, found_mac_len); + printf("Expected mac: [%s]\n", hex); sodium_free(hex); } - crypto_aead_aes256gcm_encrypt(ciphertext, &found_ciphertext_len, - message, message_len, - ad, ad_len, NULL, nonce, key); + res = crypto_aead_aes256gcm_encrypt(ciphertext, &found_ciphertext_len, + message, message_len, + ad, ad_len, NULL, nonce, key); assert((size_t) found_ciphertext_len == ciphertext_len); if (memcmp(ciphertext, expected_ciphertext, ciphertext_len) != 0) { - printf("Encryption of test vector #%u failed\n", (unsigned int) i); + printf("Encryption of test vector #%u failed (res=%d)\n", + (unsigned int) i, res); hex = (char *) sodium_malloc((size_t) found_ciphertext_len * 2 + 1); sodium_bin2hex(hex, (size_t) found_ciphertext_len * 2 + 1, ciphertext, ciphertext_len); printf("Computed: [%s]\n", hex); + sodium_bin2hex(hex, (size_t) ciphertext_len * 2 + 1, + expected_ciphertext, ciphertext_len); + printf("Expected: [%s]\n", hex); sodium_free(hex); } @@ -3210,6 +3226,32 @@ tv(void) printf("Incorrect decryption of test vector #%u\n", (unsigned int) i); } + ciphertext2 = (unsigned char *) sodium_malloc(ciphertext_len); + crypto_aead_aes256gcm_encrypt(ciphertext, &found_ciphertext_len, message, + message_len, ad, ad_len, NULL, nonce, key); + assert(found_ciphertext_len == ciphertext_len); + memcpy(ciphertext2, message, message_len); + crypto_aead_aes256gcm_encrypt(ciphertext2, &found_ciphertext_len, + ciphertext2, message_len, ad, ad_len, NULL, + nonce, key); + assert(found_ciphertext_len == ciphertext_len); + assert(memcmp(ciphertext, ciphertext2, ciphertext_len) == 0); + if (crypto_aead_aes256gcm_decrypt(ciphertext2, &found_message_len, NULL, + ciphertext2, ciphertext_len, ad, ad_len, + nonce, key) != 0) { + printf("In-place decryption of vector #%u failed\n", (unsigned int) i); + } + assert(found_message_len == message_len); + assert(memcmp(ciphertext2, message, message_len) == 0); + if (crypto_aead_aes256gcm_decrypt(message, &found_message_len, NULL, + ciphertext, ciphertext_len, ad, ad_len, + nonce, key) != 0) { + printf("Decryption of vector #%u failed\n", (unsigned int) i); + } + assert(found_message_len == message_len); + assert(memcmp(ciphertext2, message, message_len) == 0); + + sodium_free(ciphertext2); sodium_free(message); sodium_free(ad); sodium_free(expected_ciphertext); @@ -3225,11 +3267,54 @@ tv(void) return 0; } +static int +tv2(void) +{ + unsigned char *ciphertext; + unsigned char *message; + unsigned char *message2; + unsigned char *nonce; + unsigned char *key; + size_t message_len; + size_t ciphertext_len; + int i; + + for (i = 0; i < 250; i++) { + message_len = randombytes_uniform(1000); + ciphertext_len = message_len + crypto_aead_aes256gcm_ABYTES; + message = (unsigned char *) sodium_malloc(message_len); + message2 = (unsigned char *) sodium_malloc(message_len); + ciphertext = (unsigned char *) sodium_malloc(ciphertext_len); + nonce = (unsigned char *) sodium_malloc(crypto_aead_aes256gcm_NPUBBYTES); + key = (unsigned char *) sodium_malloc(crypto_aead_aes256gcm_KEYBYTES); + + crypto_aead_aes256gcm_keygen(key); + randombytes_buf(nonce, crypto_aead_aes256gcm_NPUBBYTES); + randombytes_buf(message, message_len); + crypto_aead_aes256gcm_encrypt(ciphertext, NULL, message, message_len, + NULL, 0, NULL, nonce, key); + if (crypto_aead_aes256gcm_decrypt(message2, NULL, NULL, + ciphertext, ciphertext_len, + NULL, 0, nonce, key) != 0) { + printf("Decryption of random ciphertext failed"); + } + assert(message_len == 0 || memcmp(message, message2, message_len) == 0); + sodium_free(key); + sodium_free(nonce); + sodium_free(ciphertext); + sodium_free(message2); + sodium_free(message); + } + + return 0; +} + int main(void) { if (crypto_aead_aes256gcm_is_available()) { tv(); + tv2(); } assert(crypto_aead_aes256gcm_keybytes() == crypto_aead_aes256gcm_KEYBYTES); assert(crypto_aead_aes256gcm_nsecbytes() == crypto_aead_aes256gcm_NSECBYTES); diff --git a/subprojects/libsodium/test/default/box_seal.c b/subprojects/libsodium/test/default/box_seal.c @@ -41,10 +41,39 @@ void tv1(void) assert(crypto_box_sealbytes() == crypto_box_SEALBYTES); } -#ifndef SODIUM_LIBRARY_MINIMAL static void tv2(void) { + unsigned char pk[crypto_box_PUBLICKEYBYTES]; + unsigned char sk[crypto_box_SECRETKEYBYTES]; + unsigned char *cm; + unsigned char *m2; + size_t m_len; + size_t cm_len; + + crypto_box_keypair(pk, sk); + m_len = (size_t) randombytes_uniform(1000); + cm_len = crypto_box_SEALBYTES + m_len; + m2 = (unsigned char *) sodium_malloc(m_len); + cm = (unsigned char *) sodium_malloc(cm_len); + randombytes_buf(cm, m_len); + if (crypto_box_seal(cm, cm, m_len, pk) != 0) { + printf("crypto_box_seal() failure\n"); + return; + } + if (crypto_box_seal_open(m2, cm, cm_len, pk, sk) != 0) { + printf("crypto_box_seal_open() failure\n"); + return; + } + assert(m_len < 8 || memcmp(cm, m2, m_len) != 0); + sodium_free(cm); + sodium_free(m2); +} + +#ifndef SODIUM_LIBRARY_MINIMAL +static +void tv3(void) +{ unsigned char pk[crypto_box_curve25519xchacha20poly1305_PUBLICKEYBYTES]; unsigned char sk[crypto_box_curve25519xchacha20poly1305_SECRETKEYBYTES]; unsigned char *c; @@ -82,13 +111,46 @@ void tv2(void) crypto_box_curve25519xchacha20poly1305_SEALBYTES); } +static +void tv4(void) +{ + unsigned char pk[crypto_box_curve25519xchacha20poly1305_PUBLICKEYBYTES]; + unsigned char sk[crypto_box_curve25519xchacha20poly1305_SECRETKEYBYTES]; + unsigned char *cm; + unsigned char *m2; + size_t m_len; + size_t cm_len; + + crypto_box_curve25519xchacha20poly1305_keypair(pk, sk); + m_len = (size_t) randombytes_uniform(1000); + cm_len = crypto_box_curve25519xchacha20poly1305_SEALBYTES + m_len; + m2 = (unsigned char *) sodium_malloc(m_len); + cm = (unsigned char *) sodium_malloc(cm_len); + randombytes_buf(cm, m_len); + if (crypto_box_curve25519xchacha20poly1305_seal(cm, cm, m_len, pk) != 0) { + printf("crypto_box_curve25519xchacha20poly1305_seal() failure\n"); + return; + } + if (crypto_box_curve25519xchacha20poly1305_seal_open(m2, cm, cm_len, pk, sk) != 0) { + printf("crypto_box_curve25519xchacha20poly1305_seal_open() failure\n"); + return; + } + assert(m_len < 8 || memcmp(cm, m2, m_len) != 0); + sodium_free(cm); + sodium_free(m2); +} + #else static -void tv2(void) +void tv3(void) { printf("0\n-1\n-1\n-1\n"); } + +static +void tv4(void) +{ } #endif int @@ -96,6 +158,8 @@ main(void) { tv1(); tv2(); + tv3(); + tv4(); return 0; } diff --git a/subprojects/libsodium/test/default/chacha20.c b/subprojects/libsodium/test/default/chacha20.c @@ -137,7 +137,7 @@ void tv_ietf(void) assert(66 <= sizeof out); for (plen = 1U; plen < 66; plen += 3) { memset(out, (int) (plen & 0xff), sizeof out); - crypto_stream_chacha20(out, plen, nonce, key); + crypto_stream_chacha20_ietf(out, plen, nonce, key); sodium_bin2hex(out_hex, sizeof out_hex, out, sizeof out); printf("[%s]\n", out_hex); } diff --git a/subprojects/libsodium/test/default/chacha20.exp b/subprojects/libsodium/test/default/chacha20.exp @@ -36,28 +36,28 @@ [c2c64d378cd536374ae204b9ef933fcd1a8b2288b3dfa49672ab765b54ee27c78a970e0e955c14f3a88e741b97c286f75f8fc299e8148362fa198a39531bed6d1a91288c874ec254f322c2a197340c55bb3e9b3998f7de2309486a0bb494abd20c9c5ef99c1370d61e77f408ac5514f49202bcc6828d45409d2d1416f8ae106b06ebd2541256264fa415bd54cb12e1d4449ed85299a1b7a249b75ff6c89b2e3f] [10f1e7e4d13b5915500fdd1fa32071c4c7d1f4c733c068030422aa9ac3d46c4ed2826446079faa0914c2d705d98b02a2b5129cd1de164eb9cbd083e8a2503c4e0a88837739d7bf4ef8ccacb0ea2bb9d69d56c394aa351dfda5bf459f0a2e9fe8e721f89255f9c486bf21679c683d4f9c5cf2fa27865526005b06ca374c86af3bdcbfbdcb83be65862ed5c20eae5a43241d6a92da6dca9a156be25297f51c2718] [75924bad7831b25662dbac54b46827990b6168ae990e7bd7e1fd2ad282bf23ef052c7d1a0a6c1ef862070943a0d4da24705fbc006dfb85e2af18c0a264d772a44c70fbedac9d6a6867ff6be0a32826507f2c784101583211c9e2453d4cc8b283d5e86682bd4bf511271b91dbd351415f5a009d1f78b64085a9a4341be7d42e2679d57e2747097f0129950e2c9e9ca1356022d45da252af71ac37f351a2e77911] -[61010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101] -[6146f256040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404] -[6146f2564fe1bd070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707] -[6146f2564fe1bdf9bccd0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a] -[6146f2564fe1bdf9bccd0fe1ed0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d] -[6146f2564fe1bdf9bccd0fe1edf0da5d101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb00161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af1021c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7081f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f6222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c2973032e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2e34130343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2e3413018ff7e373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2e3413018ff7ed87cfa3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2e3413018ff7ed87cfa95b60f3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d] -[6146f2564fe1bdf9bccd0fe1edf0da5d92f1fa76cb002937ba9af10230a7085f55f67bf6ab410fba060c2c297303ace1e2e3413018ff7ed87cfa95b60f094ee5404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040] +[8a010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101] +[8adc91fd040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404] +[8adc91fd9ff4f0070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707070707] +[8adc91fd9ff4f0f51b0f0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a0a] +[8adc91fd9ff4f0f51b0fad50ff0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d] +[8adc91fd9ff4f0f51b0fad50ff15d637101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efd131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616161616] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919191919] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a742001c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c1c] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c151f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f1f] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd98222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525252525] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d5282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828282828] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f492e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69c313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131313131] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1f343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434343434] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1ff9e939373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737373737] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1ff9e939a755843a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1ff9e939a75584c52d693d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d3d] +[8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1ff9e939a75584c52d690a35d4404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040] [8adc91fd9ff4f0f51b0fad50ff15d637e40efda206cc52c783a74200503c1582cd9833367d0a54d57d3c9e998f490ee69ca34c1ff9e939a75584c52d690a35d410f1e7e4d13b5915500fdd1fa32071c4c7d1f4c733c068030422aa9ac3d46c4ed2826446079faa0914c2d705d98b02a2b5129cd1de164eb9cbd083e8a2503c4e0a88837739d7bf4ef8ccacb0ea2bb9d69d56c394aa351dfda5bf459f0a2e9fe8] [c89ed3bfddb6b2b7594def12bd579475a64cbfe0448e1085c1e50042127e57c08fda71743f4816973f7edcdbcd0b4ca4dee10e5dbbab7be517c6876f2b48779652b3a5a693791b57124d9f5de16233868593b68571822a414660e8d881962e0c90c0260445dde84b568095479bc940e0f750de939c540cfb8992c1aae0127e0c48cac1357b95fd0cba8eeef2a869fb94df1481d6e8775fbfe7fd07dd486cddaa] [42424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242424242] diff --git a/subprojects/libsodium/test/default/cmptest.h b/subprojects/libsodium/test/default/cmptest.h @@ -118,16 +118,23 @@ static int mempool_free_all(void) static unsigned long long now(void) { - struct timeval tp; - unsigned long long now; +#if defined(HAVE_CLOCK_GETTIME) && defined(CLOCK_MONOTONIC) + struct timespec tp; + + if (clock_gettime(CLOCK_MONOTONIC, &tp) != 0) { + abort(); + } + return (unsigned long long) tp.tv_sec * 1000000ULL + + (unsigned long long) tp.tv_nsec / 1000ULL; +#else + struct timeval tp; if (gettimeofday(&tp, NULL) != 0) { abort(); } - now = ((unsigned long long) tp.tv_sec * 1000000ULL) + + return (unsigned long long) tp.tv_sec * 1000000ULL + (unsigned long long) tp.tv_usec; - - return now; +#endif } int main(void) @@ -190,6 +197,7 @@ int main(void) if (xmain() != 0) { return 99; } + fflush(fp_res); rewind(fp_res); if ((fp_out = fopen(TEST_NAME_OUT, "r")) == NULL) { perror("fopen(" TEST_NAME_OUT ")"); diff --git a/subprojects/libsodium/test/default/codecs.c b/subprojects/libsodium/test/default/codecs.c @@ -200,6 +200,12 @@ main(void) assert(sodium_base642bin(buf1, sizeof buf1, "O", (size_t) 1U, NULL, NULL, NULL, sodium_base64_VARIANT_ORIGINAL_NO_PADDING) == -1); + assert(sodium_base642bin(buf1, sizeof buf1, "", (size_t) 0U, NULL, NULL, NULL, + sodium_base64_VARIANT_ORIGINAL) == 0); + assert(sodium_base642bin(buf1, sizeof buf1, "A", (size_t) 1U, NULL, NULL, NULL, + sodium_base64_VARIANT_ORIGINAL) == -1); + assert(sodium_base642bin(buf1, sizeof buf1, "AA", (size_t) 2U, NULL, NULL, NULL, + sodium_base64_VARIANT_ORIGINAL) == -1); assert(sodium_base642bin(buf1, sizeof buf1, "kaw", (size_t) 3U, NULL, NULL, NULL, sodium_base64_VARIANT_ORIGINAL) == -1); assert(sodium_base642bin(buf1, sizeof buf1, "kQ*", (size_t) 3U, "@", NULL, NULL, diff --git a/subprojects/libsodium/test/default/core_ed25519.c b/subprojects/libsodium/test/default/core_ed25519.c @@ -13,6 +13,26 @@ static const unsigned char max_canonical_p[32] = { 0xe4, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x7f }; +static const unsigned char L_p1[32] = { + 0xee, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58, 0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10 +}; +static const unsigned char L[32] = { + 0xed, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58, 0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10 +}; +static const unsigned char L_1[32] = { + 0xec, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58, 0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10 +}; +static const unsigned char sc_8[32] = { + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 +}; +static const unsigned char sc_highbit[32] = { + 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80 +}; static void add_P(unsigned char * const S) @@ -48,6 +68,7 @@ main(void) unsigned char *p, *p2, *p3; unsigned char *sc, *sc2, *sc3; unsigned char *sc64; + unsigned char *seed; char *hex; unsigned int i, j; @@ -62,15 +83,6 @@ main(void) if (crypto_core_ed25519_is_valid_point(p) == 0) { printf("crypto_core_ed25519_from_uniform() returned an invalid point\n"); } - - randombytes_buf(h, crypto_core_ed25519_HASHBYTES); - if (crypto_core_ed25519_from_hash(p, h) != 0) { - printf("crypto_core_ed25519_from_hash() failed\n"); - } - if (crypto_core_ed25519_is_valid_point(p) == 0) { - printf("crypto_core_ed25519_from_hash() returned an invalid point\n"); - } - crypto_core_ed25519_random(p); if (crypto_core_ed25519_is_valid_point(p) == 0) { printf("crypto_core_ed25519_random() returned an invalid point\n"); @@ -387,6 +399,126 @@ main(void) crypto_core_ed25519_scalar_mul(sc3, sc, sc2); assert(memcmp(sc3, sc, crypto_core_ed25519_SCALARBYTES) != 0); } + + seed = (unsigned char *) sodium_malloc(randombytes_SEEDBYTES); + for (i = 0; i < 15; i++) { + randombytes_buf_deterministic(r, crypto_core_ed25519_UNIFORMBYTES, seed); + if (crypto_core_ed25519_from_uniform(p, r) != 0) { + printf("crypto_core_ed25519_from_uniform() failed\n"); + } + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + p, crypto_core_ed25519_BYTES); + printf("from_uniform_deterministic (%u): %s\n", i, hex); + sodium_increment(seed, randombytes_SEEDBYTES); + } + crypto_core_ed25519_scalar_mul(sc, L_1, sc_8); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)*8: %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, sc_8, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("8(L-1): %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, L_1, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)^2: %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, L, sc_8); + + crypto_core_ed25519_scalar_mul(sc, L_p1, sc_8); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)*8: %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, sc_8, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("8(L+1): %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, L_p1, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)^2: %s\n", hex); + + crypto_core_ed25519_scalar_mul(sc, L_1, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)h: %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, sc_highbit, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h(L-1): %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, L_p1, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)h: %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, sc_highbit, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h(L+1): %s\n", hex); + crypto_core_ed25519_scalar_mul(sc, sc_highbit, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h^2: %s\n", hex); + + crypto_core_ed25519_scalar_mul(sc, L, sc_8); + assert(sodium_is_zero(sc, crypto_core_ed25519_SCALARBYTES)); + crypto_core_ed25519_scalar_mul(sc, sc_8, L); + assert(sodium_is_zero(sc, crypto_core_ed25519_SCALARBYTES)); + crypto_core_ed25519_scalar_mul(sc, L, L); + assert(sodium_is_zero(sc, crypto_core_ed25519_SCALARBYTES)); + crypto_core_ed25519_scalar_mul(sc, L, L_1); + assert(sodium_is_zero(sc, crypto_core_ed25519_SCALARBYTES)); + crypto_core_ed25519_scalar_mul(sc, L_1, L); + assert(sodium_is_zero(sc, crypto_core_ed25519_SCALARBYTES)); + + crypto_core_ed25519_scalar_add(sc, L_1, sc_8); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)+8: %s\n", hex); + crypto_core_ed25519_scalar_add(sc, sc_8, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("8+(L-1): %s\n", hex); + crypto_core_ed25519_scalar_add(sc, L_1, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)*2: %s\n", hex); + crypto_core_ed25519_scalar_add(sc, L, sc_8); + + crypto_core_ed25519_scalar_add(sc, L_p1, sc_8); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)+8: %s\n", hex); + crypto_core_ed25519_scalar_add(sc, sc_8, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("8+(L+1): %s\n", hex); + crypto_core_ed25519_scalar_add(sc, L_p1, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)*2: %s\n", hex); + + crypto_core_ed25519_scalar_add(sc, L_1, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L-1)+h: %s\n", hex); + crypto_core_ed25519_scalar_add(sc, sc_highbit, L_1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h+(L-1): %s\n", hex); + crypto_core_ed25519_scalar_add(sc, L_p1, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("(L+1)+h: %s\n", hex); + crypto_core_ed25519_scalar_add(sc, sc_highbit, L_p1); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h+(L+1): %s\n", hex); + crypto_core_ed25519_scalar_add(sc, sc_highbit, sc_highbit); + sodium_bin2hex(hex, crypto_core_ed25519_SCALARBYTES * 2 + 1, + sc, crypto_core_ed25519_SCALARBYTES); + printf("h*2: %s\n", hex); + + sodium_free(seed); sodium_free(hex); sodium_free(sc64); sodium_free(sc3); diff --git a/subprojects/libsodium/test/default/core_ed25519.exp b/subprojects/libsodium/test/default/core_ed25519.exp @@ -15,4 +15,41 @@ sub1: f67c79849de0253ba142949e1db6224b13121212121212121212121212121202 add2: b02e8581ce62f69922427c23f970f7e951525252525252525252525252525202 sub2: 3da570db4b001cbeb35a7b7fe588e72aaeadadadadadadadadadadadadadad0d mul: 4453ef38408c06677c1b810e4bf8b1991f01c88716fbfa2f075a518b77da400b +from_uniform_deterministic (0): b18e62cf804b022fec392b0e2d6539d0f059732616c11913f510f73ae2544ebc +from_uniform_deterministic (1): b9d23004e78c58e22da72e109550133e3d3bb9e46afcc066b82326319653d62c +from_uniform_deterministic (2): 14063782c8b8a677dce09c4e51719b1cf942bf71bc765c1ec9832a8b4446983c +from_uniform_deterministic (3): 02d6dbac70f6a14de72f4e17386016b08d6506336a086f10e719fbad8831d550 +from_uniform_deterministic (4): 11c851408e7892c2eae37584423a8f9c797e3649d45946b53e64319318a750b0 +from_uniform_deterministic (5): d4b9eaf70ffdc238c88725e294bdd02a6ce85577c5e7add7ca07041873019842 +from_uniform_deterministic (6): 740a6141079285c1b9e84ed463dcce5d3d40a167fa13129463eaf97d2a7bf654 +from_uniform_deterministic (7): e504a3e00bbf506cbe388784d85e85b10c428c37eba04ebd19a60948b71ad2cf +from_uniform_deterministic (8): 67cd50902c40c943f22c479c587fb3e5da2f8f1ad402049ac49ddc45ec20884c +from_uniform_deterministic (9): 658bffa23b425a91268ee17559073c4b1548209054ed7cf00ffe582696dda8dc +from_uniform_deterministic (10): b55b93e7a0fe554f86f1f4c991871a27756fee359a8c6bb7554ec91d5d552c49 +from_uniform_deterministic (11): fbc2bb45df1d806489a5a6415898c719c45c932d3467b6ce948ee80c0e8122c9 +from_uniform_deterministic (12): 93164e57b5e3ae6826ac9e0c31ddecf94e21a39a29ba9d1d24e9e588fe065d95 +from_uniform_deterministic (13): 16824d74c9482890dc57b0ec843a0a5231b581d2ce3909934d7658389f169093 +from_uniform_deterministic (14): 2f5b0336c7f0af520badeae99450f92835c27224ab4cd117f55b176afb6f0001 +(L-1)*8: e5d3f55c1a631258d69cf7a2def9de1400000000000000000000000000000010 +8(L-1): e5d3f55c1a631258d69cf7a2def9de1400000000000000000000000000000010 +(L-1)^2: 0100000000000000000000000000000000000000000000000000000000000000 +(L+1)*8: 0800000000000000000000000000000000000000000000000000000000000000 +8(L+1): 0800000000000000000000000000000000000000000000000000000000000000 +(L+1)^2: 0100000000000000000000000000000000000000000000000000000000000000 +(L-1)h: 609faee7d21893c0b2e6bc17f5cef7a600000000000000000000000000000000 +h(L-1): 609faee7d21893c0b2e6bc17f5cef7a600000000000000000000000000000000 +(L+1)h: 8d344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +h(L+1): 8d344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +h^2: 726cf51b9ec1dda146af8c58ffd22d148f6ffd85f41cbb738f260cdf4650e60c +(L-1)+8: 0700000000000000000000000000000000000000000000000000000000000000 +8+(L-1): 0700000000000000000000000000000000000000000000000000000000000000 +(L-1)*2: ebd3f55c1a631258d69cf7a2def9de1400000000000000000000000000000010 +(L+1)+8: 0900000000000000000000000000000000000000000000000000000000000000 +8+(L+1): 0900000000000000000000000000000000000000000000000000000000000000 +(L+1)*2: 0200000000000000000000000000000000000000000000000000000000000000 +(L-1)+h: 8c344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +h+(L-1): 8c344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +(L+1)+h: 8e344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +h+(L+1): 8e344775474a7f9723b63a8be92ae76dffffffffffffffffffffffffffffff0f +h*2: 1000000000000000000000000000000000000000000000000000000000000000 OK diff --git a/subprojects/libsodium/test/default/core_ristretto255.c b/subprojects/libsodium/test/default/core_ristretto255.c @@ -10,6 +10,7 @@ tv1(void) "ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff7f", "f3ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff7f", "edffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff7f", + "0100000000000000000000000000000000000000000000000000000000000080", /* Negative field elements */ "0100000000000000000000000000000000000000000000000000000000000000", @@ -171,7 +172,7 @@ tv3(void) printf("addition failed"); } if (crypto_core_ristretto255_sub(s2, s2, s_) != 0) { - printf("substraction failed"); + printf("subtraction failed"); } if (crypto_core_ristretto255_is_valid_point(s2) == 0) { printf("invalid point"); @@ -180,7 +181,7 @@ tv3(void) printf("s2 + s - s_ != s\n"); } if (crypto_core_ristretto255_sub(s2, s2, s) != 0) { - printf("substraction failed"); + printf("subtraction failed"); } if (crypto_core_ristretto255_is_valid_point(s2) == -1) { printf("s + s' - s - s' != 0"); diff --git a/subprojects/libsodium/test/default/hash2.exp b/subprojects/libsodium/test/default/hash2.exp @@ -1 +0,0 @@ -24f950aac7b9ea9b3cb728228a0c82b67c39e96b4b344798870d5daee93e3ae5931baae8c7cacfea4b629452c38026a81d138bc7aad1af3ef7bfd5ec646d6c28 diff --git a/subprojects/libsodium/test/default/index.html.tpl b/subprojects/libsodium/test/default/index.html.tpl @@ -1,8 +1,8 @@ <!doctype html> <html> <head> -<style> <meta name="google" content="notranslate" /> +<style> body { background: white; color: black; diff --git a/subprojects/libsodium/test/default/kdf.c b/subprojects/libsodium/test/default/kdf.c @@ -15,7 +15,7 @@ tv_kdf(void) context = (char *) sodium_malloc(crypto_kdf_CONTEXTBYTES); master_key = (unsigned char *) sodium_malloc(crypto_kdf_KEYBYTES); - memcpy(context, "KDF test", sizeof "KDF test" -1U); + memcpy(context, "KDF test", sizeof "KDF test" - 1U); for (i = 0; i < crypto_kdf_KEYBYTES; i++) { master_key[i] = i; } diff --git a/subprojects/libsodium/test/default/kdf_hkdf.c b/subprojects/libsodium/test/default/kdf_hkdf.c @@ -0,0 +1,102 @@ + +#define TEST_NAME "kdf_hkdf" +#include "cmptest.h" + +static void +tv_kdf_hkdf(void) +{ + unsigned char *master_key; + size_t master_key_len = 66; + unsigned char *prk256; + size_t prk256_len = crypto_kdf_hkdf_sha256_KEYBYTES; + unsigned char *prk512; + size_t prk512_len = crypto_kdf_hkdf_sha512_KEYBYTES; + unsigned char *salt; + size_t salt_len = 77; + char *context; + size_t context_len = 88; + unsigned char *out; + size_t out_len = 99; + char hex[99 * 2 + 1]; + size_t i; + int ret; + + master_key = (unsigned char *) sodium_malloc(master_key_len); + prk256 = (unsigned char *) sodium_malloc(prk256_len); + prk512 = (unsigned char *) sodium_malloc(prk512_len); + salt = (unsigned char *) sodium_malloc(salt_len); + context = (char *) sodium_malloc(context_len); + out = (unsigned char *) sodium_malloc(out_len); + for (i = 0; i < master_key_len; i++) { + master_key[i] = i; + } + for (i = 0; i < salt_len; i++) { + salt[i] = (unsigned char) ~i; + } + for (i = 0; i < context_len; i++) { + context[i] = (unsigned char) (i + 111); + } + + printf("\nHKDF/SHA-256:\n"); + crypto_kdf_hkdf_sha256_keygen(prk256); + if (crypto_kdf_hkdf_sha256_extract(prk256, salt, salt_len, + master_key, master_key_len) != 0) { + printf("hkdf_sha256_extract() failed\n"); + } + printf("PRK: %s\n", sodium_bin2hex(hex, sizeof hex, prk256, prk256_len)); + + for (i = 0; i < out_len; i++) { + context[0] = i; + if (crypto_kdf_hkdf_sha256_expand(out, i, + context, context_len, prk256) != 0) { + printf("hkdf_sha256_expand() failed\n"); + } + printf("%s\n", sodium_bin2hex(hex, sizeof hex, out, i)); + } + + printf("\nHKDF/SHA-512:\n"); + crypto_kdf_hkdf_sha256_keygen(prk512); + if (crypto_kdf_hkdf_sha512_extract(prk512, salt, salt_len, + master_key, master_key_len) != 0) { + printf("hkdf_sha512_extract() failed\n"); + } + printf("PRK: %s\n", sodium_bin2hex(hex, sizeof hex, prk512, prk512_len)); + + for (i = 0; i < out_len; i++) { + context[0] = i; + if (crypto_kdf_hkdf_sha512_expand(out, i, + context, context_len, prk512) != 0) { + printf("hkdf_sha512_expand() failed\n"); + } + printf("%s\n", sodium_bin2hex(hex, sizeof hex, out, i)); + } + + sodium_free(out); + sodium_free(context); + sodium_free(salt); + sodium_free(master_key); + sodium_free(prk512); + sodium_free(prk256); + + assert(crypto_kdf_hkdf_sha512_bytes_min() == crypto_kdf_hkdf_sha512_BYTES_MIN); + assert(crypto_kdf_hkdf_sha512_bytes_max() == crypto_kdf_hkdf_sha512_BYTES_MAX); + assert(crypto_kdf_hkdf_sha512_keybytes() == crypto_kdf_hkdf_sha512_KEYBYTES); + assert(crypto_kdf_hkdf_sha512_statebytes() >= sizeof (crypto_kdf_hkdf_sha512_state)); + + assert(crypto_kdf_hkdf_sha256_bytes_min() == crypto_kdf_hkdf_sha256_BYTES_MIN); + assert(crypto_kdf_hkdf_sha256_bytes_max() == crypto_kdf_hkdf_sha256_BYTES_MAX); + assert(crypto_kdf_hkdf_sha256_keybytes() == crypto_kdf_hkdf_sha256_KEYBYTES); + assert(crypto_kdf_hkdf_sha256_statebytes() >= sizeof (crypto_kdf_hkdf_sha256_state)); + + assert(crypto_kdf_hkdf_sha256_KEYBYTES < crypto_kdf_hkdf_sha512_KEYBYTES); + + printf("tv_kdf_hkdf: ok\n"); +} + +int +main(void) +{ + tv_kdf_hkdf(); + + return 0; +} diff --git a/subprojects/libsodium/test/default/kdf_hkdf.exp b/subprojects/libsodium/test/default/kdf_hkdf.exp @@ -0,0 +1,205 @@ + +HKDF/SHA-256: +PRK: 8c3725c0ea8e14106d8c342887ccd1218cc205acecd8095ae1efc099ec195e7e + +92 +2ebf +e29531 +8e563a1b +1fa58d77ee +50f1a4e15ba2 +4fb3724b7d4174 +d10853ceb46b11db +0fdf31228221242833 +98acb29e0993ec45f8cc +f4481a5e6d263d7bdc59ed +e620eb399337a9aace16765c +dbe8924351577475584731979f +371a112305dfd4264feb29c28a2f +d0a4b022f748c96141ec6b4aac6dcb +d2b38fe15e0f95bcff87822ff4df3d90 +e4bf8fde7d77899a5f85d68b039ee7119b +6766b092971ec2e616286925708c7ed6c9e9 +c4f9d36cddfe89b3194282a084881e6c429099 +49be5bc10c278f39b5be391a55e765560deca0ad +6e7d3031d08c5658a19a7d647dad0250418435febc +07cb6356aa7f978cbab87e7814fa90af9ce729aa2b3f +2ea1c08eb04c75806f80ccf0fca683a8998bb663e99993 +bb111699f6c32263474dc5569a6950c767e3b8201f838345 +e81e9086d3e035cc1a288fa521ce8b43b7f93d3d9bbac5085b +29c398bfafa672bc315e192110575691607118759f9e7669f3c5 +60840e8bc6d86733752787232a0321257c82d691722bfba07af839 +b0ec22e547dae3f04fc6ef146203604f0d604a8ce8a20fce229a688f +81ae6add3344b25d14115a38bc10553a75ce0a4be3aa8f3579299227f7 +242c65f95ee0bce1c5e1b01b1ff68e8634fac096edb18997dfd3baf3817d +14b5afe2cc0d8fe10e5359667b2b310365fba93d62f7fd3df2dddfc34c1de5 +24a79d4c0c69e0a524ca91f356e64ab40345973ba82ce68992dbdd16bf161cbe +3edbfc22f9a1e3a5c774cfec8fff3cc4febdfc61d98aecedf6a16eca0546316b56 +b8bad2b04b9b382f9ad2559afc33b8dece4a7fe9b8ac9d74557dfc51ed8949b78ee8 +1d01316d7767f068171f08a8c2f05d2cd571f623fd5fc9916b3476115aac9d7f635cb4 +a7c5763a3b678ee2fa05a57dab377b67e448a38f94531ce83bab9eff8035e105e8889b91 +ab6721825aefb2cb9f9d0ce5123882573abebe94404e0e3a923a7aac84efc084f84ee5b2ed +4815da740c872a9816850c8757be64cb3096dca7994f3af7bd8c10e83a2d3bbb14b40da93d40 +abb141fbb64faec34c09e9c784b1e8aba15b6e916f70996ad803b963d2de676669ebff3ed4b711 +231a7a47a81c21dd6a0969c67b6ff446a73a145fb1d4f0a2d268af8fd56ac6d67b6ef55d13194440 +74e40130ca102c22acc109cc6b8b66d840b984fe729c156edd05eb4f44d1869e6ae6260b41931179ff +3817d2cf7b7c7c7bfe4ab51e9178343f31fa8eea20899ec96d21eebdbf55f44327e7dc23cf669e215c02 +d5ab755f5631d08b70718d2ba3e2775fbc3cdfe69b7ac74afcc73ffbd7b91b9d3a7fef364cda9816c8c367 +93c15afc2cf1baec84b8e3c89f50a3e4cc3a2c1b72aeaa894a45bf09f22aac0711994f0873ac69b099e47d02 +7b359dd2abb995a8bb0d1a01a986bfcf28d47b9215f000b240f5080dc78a84cc65e34ff098074ae237a0238b6f +182ec78776f5ba3818c2ccc7b84aa7bb1a54386134b3215e8f8f709757f3c8e4f9bef3800e3a9eda8b9794e95f8a +0cf1874215b38ab1900ce7137d9b8817fbe99d3196eab5b845971a46a38c479d81fc8033a641533e2c39dd550e672a +3f5a283ca862e6a5f79c5ab39f8d4984b54a86e132d40adcca249f6419caf5b61fbbf61d54d80e78af3e613adfea5f9e +ce6bceffd4ae50e8465c3d5179c661da2f18dcb37f95f9cc66808d2f848b55dd0c1d2201bb37a2e339e9385233e687a711 +7ce3f4575d3edab2f989b0a975b279ac21af117184130911dba4e7c70e19f96b5595ec8910e737c019f3392390f8b9af6439 +9c1b37296ed2ad9b556938d30814c47f822807be8cf9bfb26a05651061015493d4ed551f8a6f1a5cef7df88dd7426f03681935 +0d1f6f49c38c4d6fbc57103193b544ec1a73f40ed8aaac53da2b1a28a4a35838036ec9d50d719af22f3f89ebb7f340f50ce8c180 +fe6786d7d7728a1ed057c329f68cf698b163ae1e6c1b48290e6ba2c325740155f0f90f216111f3bc16d61b8338d910d429241899c4 +c729c63757fa5a421704ba88f8c13f23606e59cb1e7d2396a130742c31b98dc9461cc1fa9d8d24f79f7303dd416bf66adbb08562f832 +44cf07d63adc85de7c0aa524962c29dfad1b37b253fc9559fd1f5b8237d8bd6e6449e5f3997d6b0571ae50da1e164be845523c8630b1df +c1040513a53f652e0ba7bc30f84deaaec13a15919855dd76148ae1fc86cd147ba686ff0ee025f9a00cbf7b6e190c7b87ea458974cf147ae3 +0a67afc69f00ddbdd6794ed7b06285c00d70fd86fb8b959bd8c686e96c72032f2726c4f0fb607a7f4d4f66b410eff17354b6db803c9c910a72 +faad9414932446902309147f8f2c1d2d48c95a7ddb8856219aa36ed30f971e160542ed8272ef9bdf72551cd059ca6c81ea76b5a3b49cbfb07738 +14ee2fc3899650164beb828a557afc7253e4b89cba8a1908d3641d47eb23d50ef34a0dafaa1388328fc33b1db37f2f74db6934d398bacbec785f03 +2333128e004f61ba45c524dbf72a9973fdcc288d76236402f63b0f4a39867b18e73135f35945f1791ae537b215c69941194258103419558c0a477fa9 +70f1a4c027d950573c5ea8f9b34069d1b85ac0b6daabc9de5c4cd1844d6781c0b15ca7b01c2a33dd06272e7c8729b74ea71a0f35486252461a3d83bc62 +8b9199ebc5ae61365d6cc78c9d1b1a466565639c50c317cddcdc13db96b4f6ec612bbc1c6e5d2479147040f313a168e4471b9093f47548899265d8472aab +5f420864258d597766beb7c55ef0dc9c85aab5e296677e1fd9201a8c8a0c7b74b573276b0ce11f797a5816e5ed7ea3a02ca5c338f78c0c6a41322e0cdbb5d6 +13029325fb0fbbe2221caaa6c3797a967335c4a857fafe23b4fb221433afc84da6876cbd74ac631d18f2478aae8def5a85a227b3bb496a81e9d29171a5b501fc +44ef825de340dbcb1b2ce9325eb78650d574d1c9fc13ed3b4517ee3f2f95bd97c8ab62988455a1639d0e4b2e404d661c3881dbdb52d86b7bd5593713b10e8d1086 +2c67d0e2fbdb55cf649c97e1053c717636c526ee4f58f86e9671a1086e5ef6ef7ae109eca2cd482affb1add956aad7225debca3420c4cae6cf590e8e8c1a0398a9cd +6900b97c5783d5856e4eda7816e27326cb71f8c9cda3bfdc88c4a5aa49b580aa4341cd100fd3084b447a24c9d521c8ddb7a55af52c998c4a9b53bae6c86caa02424df6 +c63f43dd3d29e0e92fc2adf18a50e33f11dbe9746f16bfc518397e0df3bd4eff491963cd2a0d25022c535a425fe3cfcea4ffd7dfbe98e2ae9fb40a007012acc31460ef25 +dd61268207f4452ce4a1f212aa4f4ffff1d0cd4df9ac1730b0f4acc07f75e86afb02c0d99aeb512bf3bb138183364a4b800af446b403add2b30d73eca024fb5e3eeebf10dc +4eb2c6dc6159bb82eba32aa839bc4b3d46be87cd358f47aeb7b488d91230414a40fe35a2c0bcde81de243b6974c49ac0af113904a8995928931e867f5b7d131c2c9caf4adde5 +22cef8bbb9f6874c1be53adc6687e3b28d0b9b8574d22212e4d60074585d17751fdcb80a1ed6143a7471fd3b1a0dddbce5b8b1ae859441413d99b069252f39c3a0b7eafc65ab34 +6f0a07f43c6d00649b516cc986fce770aed949875a17164beed5305ceaf74131574eb2cf489dc13fad53e2b10cb757b69eecb481a76a8d99a7cfb2e0aee40dde6f7d44c2be5a5e63 +bf701b835481d47ee85d390caa8f63bd3e7dfa48f4307d51989b4660e465de31329589bd5e3293f75b63d320b8f53211cf1209e426869c3c3b506dde3f819cae07672af9ef74f36de6 +92cc25c67b65fc9c57381457e7752441782dc4d2d62828c13992a7c2eda57811fe7c2de66b725e08f361fee4d8370d3dff2cdba6c603cd03ae54d813e44793387ded1add2c006b320058 +e3ec7f8ccf313fac832d3ef5c3b8b10f1faf5ae8ec32bce0f5f98b9f4464624a58b0f74ffdb827d52d94fa77a8456ca550017f3c31d8e8e6827b6a9ac9664355bc57e9b46cc66b6e396a50 +636ffbeb1cb2e834ae37213247ca8e615fc52f00e79c13f37874edc549f4b629901312b685f3e1ae3394a6beebc5e0c1364c562b3579f34cbbe9ed80c5cc045b9ab7a749950d005e785832e0 +3ae686a5e1abf936d472963d6272226f920c8df4eed5c4b26d9afc910f509c205ffb56a0289fb62d38790dca4f85028f76b4339e9eee32c1c2690abd02c74ef9a7cc822f901ae596ef1b2f2f42 +e542066a18aed627ea3feea7a962b9c69a9a2f00bc0f22c7186c389701283807801d2cd79d678010d91379cfc6d72cf30830a34fd9983a0c011e775be61eb0d093a1432493abb703c8b5bf99ad63 +1392b4676365c1ee01f75811cabe0fa989faa6a222b65e72bf4016f7767c0e9f822de2ad0034098dd9867a787abe9b97adb1a345e96b345aea898682d71fc3febc0e2ef579874da073285d0ba4edc4 +2ddd472dd4090528036d7bf01cacfca7c71ce3d89bab2299b3d6f1b987c51e5f884cfed55ca25008811fa4f44d9bb8563d83cfeccc580865978972cec981f431e4b74857e2a565e5d6e0bc9f0a3c45ec +d2a855d0e2a912ce3ff5ffa99c464c215d9ae1195e92b022d4518dde9fa5ecbdbac4f1877c1a94df35421a122a04073dbe7fce959c87497cb30774bac3441140089b4b714e025509fa3cd41d683ab46edf +00bcf365897640b9268fad068977a11b7eb3006482b51c97543ba4359db31adcd18497d174844c9ec47a0f6132b16d14aa5a02c42583aabd033e520a8a9c5c430cc6708e8b9cdd4fd56c1023a744af67fd14 +0e20beb1a84e9c252b54c4db895324e85436f29e4855cdfa5bf4bbe7868bdbc51b7f0ac428ce54750e2cd16829051e95cd97f2f40c5a1a3db17f90b68570a05ac55a9eaa7c8bf377c7a752666de779ef46764f +20ddf3ccd89c8bf4c084324858c0f0c7d4dcfd4a76a7526183a5bf4344f62320f29e7c0650d3c55ad587128e667d5d4e69689850fa741b49d3ceef45b134327ac89186248d1157aa4b16263731138777811e508b +2a8fadda7001128cf59e3fcc93dc5c98e75ac92d66d536330eb90a558920e4416c210658b3bf44a451db23c62caac1a79fad1437a81d66ab98e4423d8a1ce9ed9a0586a160c4819a019a93781775c6510c6ed09cb9 +9049524d223052ee507450e65112e1f4331c4d7fd71e8237b8f79feb2fa30504c856d6907cc4eb814694e9a7b8a8b10d85f956df72062c5f4752dc42d37f164eae1a3155a11ecb413f92a0e49e0a89d398c21d76e100 +86a92236b4e0dc16e0a17e92825e31b66a417784b7f6c0a53c274ca5100847a929c0a30430ff67e6c8913a41c3437d8313fd11b2c0eebc75e5bdffeb95a4d100c7eb36216494f3c7a8f19403080941e3d1c9e319ede000 +4b15b094db5789ff78fafabdd0f0aa06d3f4ded903c89e8ae22982d152017295de63ad0b43d3d303243de1bbf2637e8e0c042024e307739ab3b02a5b7d299167909edd51f82229c0093a68768d56c2e774285ed95bdc24d9 +9bbca463a5142ea7dad0522f073eabc7eed63e4baea13efec9d7c198b75a9c4db88623c406edc5bf61ec61e047357358541aa66e44a364b779b6a8842c1b1e8131c594ac8298755ba532937b5bdbcbbd1f2c2152d03af55120 +edc5fe50b3f3a7de5ddc14b467e41ec0ce68a44f734c4cd46b5ee1d98337d8a917cf1dd13e09946d22918eaf31f83de1e035209a6f2de32bb7caf119d0db73e4075cb9a714adb84b4d0a6163aac56bb4299a71e8979a97e363f4 +e2770541945a0395fbf597fb58cc4e6f6a2883b707aa79df9c2da5a7165a8838b1e7f4736b5418bd2f99d3eb8020f9b4cb7ff3a620f8bef276f22f3e98ffe20adeac2f62a9e5758136d222a9c562f81f151d3980bdad54f52dbf55 +248474ddc86ce5e07be50fdd3a6a113ab7f2319e3fb86f1d2d361372fa1d89926ef501c5a62b9d2efeb409d0be8fb67f12c1624d04bcf9d555dad09dffdba76948b0eecba430110ab9e738db70e51c4e2f27350a49aecf1282410ab8 +37d75ee27cc14c95c9d930bb1324d8aa6cc77ba833504253d91002fb622d9e578a3f3b1439dad7d9d7af8ea17cebee86fe13c59f316434d46208c019c2e673168b5aaa397525cbce3a0b2f1c59c853600711e719218311e15d1ab9a0cf +981461afd5756cc5d6a953c188b0a537fbcd18b41034cc4f40870cc2c97bcc48e3e4d563c2ee1d60d8c9f714996fc32e2977aaf7c3544e437f40f61d7281548efc22d7c298853304444c4184605b7b55148c24e88f362e41a8c919bf0288 +d65ac485824f9490c5f70fe674fe1da39b4583b25f3580b636a06135761eb0fb5e36a59dcb070dd9bfd5b2d69503a5c3ef295eb9cb3a9346578556d56fdd0c81cbdd960d292f8410681643af154b2550e2d586119b82cb17a79c1447cb26f6 +cdd5bd495ed8c2c41dc511577051ffa30ee02eddb95b3650337e8aeae161d2b81a9ebc1514524c52dbe2c4d0739706dbdcea1a7ba21d9cab36ca10f753fc82b218c01094e288bbcd96d6678e06e1a03f55c3bc6aea67b9637e87a4ce8e2aa0e8 +1d07389dad745981eb7ae03162bf249996cb836316872a4de4241d1fea49044541b9ababc2a10f7d5455ad3c0519997698a52039fd5517c53f7963aea8917e1b8ce3c63c5a2b23331cc473c1ff0986b08e8dd1257847256ded17e6d0409855f8e5 +a1245e0117a0e7c3cfbcd3d3eeb21a5aa7f2a73aea4465f4d83c8d0c6237c5c093ada99ada6ad75dcf18d1eb58982c7316d5c366ce5128a832d433c960e6bf7be42e4dce2747e3cc78101ed44aebcdbbf6bcd42f5160ca40784ea3ee3dd6be537475 + +HKDF/SHA-512: +PRK: 2502bc897dc1b23f9f2d8c35d519c5280ea960bf9154ebb07d377a12a81a4794ea8bdc0cb6ec59ab3303f5cbd713027825715f8af2ac0203e560fd2e55f4ff2b + +4c +abec +6d7647 +a3397e73 +15b3f69cec +fb5c266f8785 +7147d8a6bff246 +1dd7f9b2ab2583ab +725aee4e2d8d7f1f90 +046f63a1e2d606d7893e +fc2026603b032dc6c862de +03127d298ea441e3ae1d3781 +a8f163b5b9476eb50dcb304bc2 +9430c3aa31857951320feaa65e4e +14e4918f7b7eaa9c6d39dc08e9abc1 +3480c9854b8f0bb4a97920338dce7573 +42714ad1af787467b0388cb6663864ba89 +700cd7f28075fc3a28d98672207b45df5b20 +528c93053c63c5fa5ff1f0a6e7cde8d4aec5a8 +d225940fcd325eecf827666ebcb9ea3881dbfc3f +0341475a114b87cdae767a4a68432889145748b0aa +bbbf499a74a2c22dc4a2295bc904fdcd7d4e91b32060 +deb06fe0b094b65da9febfed81f990ae77fd3f458a1bf3 +f64b7ac1473232a727ff461af2f650cc8a8419d7c97b7298 +3ca9c302e1096302185e2288beb6d91124c6abc9f9f97d5a4f +81dfa7213143feb429dae2c641d25bf913aca03feead6ab7df10 +5d428190aad0539c0c2e6037e7745218dbf4e5c5aa0102996ceead +7e76c9dcd614d730eaab145be60584c7bbe925bddc64d9dccde16142 +4b2be1c3dd5cd41d53ead2ce0aa220823ec4f3cf8656b14449e50cb48b +4ceb80935422dba37af63ba59a460204dcd6639741d478185fd1a1e48de6 +633e555556c5288d808b2483d7e99bcc9876b42b61cbcc4d3e9ed42bcaee33 +0d28411da5a660b2eb063af0ed7e031c463a64eddd6c48882add6fad4cc9da92 +30b734f5768d26c4f8d641037b3e425c3d75c5c0c97cf8a3e684d1d2f1ba4f37b6 +970db4152321c2bac15898927aa25db90246c494017765b01ff21ae9a6aef7b89b88 +f168959f62696ea32a46ee67cdd3375684533f799e346fd1d26ad29aecd51de7c2c473 +76a81fa4b90ee1d1b05986c837f10f098cf1ac8f7d6be8097caec980b125185e8f9ee56d +ed95ff4a9919f45c08151fb7f610f5155dac10c92e84bebf2a6bf0fc653585158c19ef59fe +16ff87fb87760dfbaa53a2820c9ef365ee3b539b4a7fd1a4e626d313f24db495319f98c247d3 +f514b605b74bb3a35b86f8c96fb08e751d916b3ecd8b5e84b364e57f1fb6e5928a3a46f4cf7b1a +ecef871f30ca56fbd6b242b9d095a33b9d60472da4914af80dbb8672a84d8ba4640ff1b459cb9b1d +9220ed520c628b7e7e249c334573ff2402d573e34b27c25c4ba22e2b472ccdd2ef4d060eeef5387dc6 +b431fd9eaba69bc20967d1d02014913637df29c855faa6e93a8571ea3c27ad2c542700c77f9f3d19e5bb +7ebd91db579ec5879f81a922c58ee82a91b8cb648294f63b97f728a53411438f54157cb6459ae762b5ef3f +c28a1322e46a89f7a2b6b3dd6d39cbcaa84368bca33a53c04bb7bc90c3f51065143d8e93a279a403aea8ca8a +089ca5fb6e4de86c77cac49f92c8d3356697a1fa51c8e4a207ec44428c4da0b82aadad5f196510d0ae7abc25ab +31b08873dafc0d8c11afacb5efd3fcabbb7cc5ff7aab6e1d40a7451ec715de4a4a6e7e15f9d1f9f832a0e1bc39d7 +984f57235036e6d44777a7bf41fa4333f3077d3f2d92b46bc36c29b123de8580d81e22b2969d9a5abf3bb5fb7b422d +2730edbf85f4e35152af0f22fbc4f23f7968cb430fde9685cf4e1bb64611ba6459acedad777fe1a6d70c88733d83661f +0eb2a97a6d6a5901535399caa5ccb7192e1f1488f9a06d3150ccafe1eeaa8d6e50e039a9344f68d1783973fcb34719c2fa +24d7e154d4b7382daa4d1fb47a8badf0d1020e97f75efe74f302b983584e26bc1865d44c3761b65c4d745766da0bfce5682a +cb7503ad874932bfc2c7b18176d3e03f3e66666613e3e8e2ac83a29965b56afb0aa74d1080ac2ffeb1c43ee160c9f120cc4c61 +0ad5086f6cf363dfbf14c13e82faf14dde185b7142bd0ae44da8692339ed31f47f10773578af23cd7a632352087d07a7f4133474 +72873f68ad5874e1146a70e96c98360ccf0e5e9a5e31e4e38c7829241a531b0712eee8f22729e244da3d94d92703d975e54d84c36c +b05200d914edd05309a7aaafcde50cfbc201d988387d2b7fb7b7315b56d58ecaebc2f7c7b5d2607d041dfd3486e849cf2535c8ef76f4 +6324ea52a00274312457f451953302d02e3e9107aed0a4007c04d26f4b5ce37f31fbc5a2606575a464f64b507691646e2d773c62aac387 +e0c68ed5571a90bc8db36c948b5ffd9179cd80218ae47b86cc7bf4aa4adccc438ddf670ea817d324ca709b612522d510913eb64012462acb +61d3ec6537c084df5981a79545847cbf204c3a267080e2cba06a29b4fa591bc43668f701cc0d9e33e123b774b066e212fd1989d253120bfdf6 +7b74db37484227d237eb7d4039ddade342827d0075322c14de32985d616ffe38c4786e2e0df89de856051796e1f922b6b47578c3428fade6b372 +feea8d891c65fb37dc20095946b9f5db5aa936a2331fc9609ea45ee146107bf561710edceef2cea29e7c25032cb6764bc361eac0c148553e62ca5d +a95341f8f7536d95f14181e4aa01c540a345bd172b67279f5b6dfebe2c8fb7b366edb8ad7e4545eed29903eeb6f486fa9f9d825185a0333eeddd2b45 +5b7fd7b9d6623c25d508712d585fd541089c8b4721b9dc219baa9cfe14022b5ffb0ded9a546ddf183c543d1f26f9c4183f4c7ff012d61de8cb822bccb4 +fa0fc08f49144cf85dcefd25717f37de8469a943fdeaa8c764bbf483af7a37b0dcf1f50451b20e693635e94976c44ead0ef83ac632eec781e9d50efb2f9d +6ec1e621af3a878ad836aeb322e67752de29a310d7e6fbe6d164bb79e8f939d7a8f9f77a72733482d323c50ae7dc2170b90a48c59da782865eb7a9e254aba3 +10d13645bc853dcac6b71dadf4327ea0c7497822a6e0691d93a5e9d32cbafb883f9ff0c245126e391666fed31747e92c81ab886d5e75bb057faac5b3b0f1afa8 +dfb3872da01656cddd9abcb389e75a4a01d89d0d49f571e77655ad1ae0c14c87d4146accaf59f3e402767e6666228ef8e52aa32cd18306f69666769159423d8141 +d3a86236f119fa35c480d5b4b71d3aec93e226db5d2173c04e5d1d88c696594f51ec36470487fb72044a039cc081607be2a99e5d8f1c653848176f97cd2e9d50a742 +0d1f5a47c4917f6158b039e68fdeda5fa3889bbac6dff571f6353f83ada55c26bb99dac4416b2dea7d0fec2b585877aed2709f2b25516551004fee20b68e21efded761 +79a910c7f74b303d5844b609148a5a723e31c6b00d16a773547fb6d97fd35bf4a452eefd7ac3466ea520d61be4b75493156c9ae39ce6698e7120e92ebb366adeafb21d09 +a893878e100dc628ec674c4b48556c067419a3c317be94ed37cfd8ed8cae2ff035985579238f4dc13576677d527f21cde829a54466a911ab81888016c2094fda50e6dab622 +6faefe6e6bad59fab2a801aefd26d05ea3ac3ce546b0abfff524ec2ea80f3cc5c8c7015d18ae766cc84a2de75bc4c8a44cafb3743c6147e934d5de803d74ff8ca507d505065b +ef32b102fb18681c02cee796ba8bb602d927d3428c4387150a5c342532380d3234d69e58a607396af5802cfeece1554de5722931f4e09fe51ae4b74dcd7e851e9a95cf4218f96e +efe653c021ff38cabba1a76f8df2b0737ccffe6dba0506074143c88f6547afb06bcf1a36ba8e48bad9e7ee76c70717e089e1c31f052ee8859f65d6cc0d4bdccf845c8a8955d316bb +8bf54ff6ef8b0f73a569d908ef432227d7fff0e1300503c1d41f3b2618b089ba76873cc5abd22039f3bffd2bb88b4a169e1f55b8280ba8b474aee9a19a93710cdc05a51062ea5970a2 +126a003e4194b577fbf4070e8ecd47f3807afc7d9e733760a23b350649e924ebe702eaefedb70490b77fc8dbccd068baab02bcd64517aee6005d37a496f8dd92093ec34f5ec6af703836 +3b025057a1a889389b105956cffae970b21e3a1179382bb626856c793727ba9ca14706741b94b4704ce0089a378c1efadb7961fbbfd146d657b6ee605231d9ffc60eadcc6af32c43ec7e75 +0c2eadac7883bb59c278aa115b10b8d1459066b9e0061b7e4e2e1ec4caca02c6fc443e5f78c80779360f260507bc2d49beae6bf7470da5c8dca5ee51d251ed1db892db23a43c62fe088d07fc +2f40a09aea1a9b7c32e7b68845de40452c9b753c31c46118d14d3b34c8c7f3eae0f3c0018300ce4d583715debeb9bac31de392080fe2630225a0f0e0d4c5b6e19ff1fa5bf5a0cb8840fed794fc +155e5eef1e32ec06bd7a51741fbeafcbd82bddbb18fc34a984e9018f4b62d1b7ed4fc0b0d7843d4e8983ccdba6bb30d28f964994650e692a5b0b746171563be70a0c622f6a022ac4c655f216bb68 +142e1d62a31895b3a916453a0c01ca2a096d9b0747b3a2c9584822819cbffdab6c6461d4e4374e4d9363f8cc52861e2be1f4ad4edbdf4a72f1fc3667903df83a32a8810398e156ea8dd3385d416e9a +08a01d87455bfb057d64a6374f8da7ae52f4575af5085e7aa3c390de0fe528c14767525b9af87e7e5ef053bf03b2390c98f7eef36161ae1c0d9eba83c4a78d9ae5d4322cbd0b3f7aaed183f18616e49d +1c8ccae6d387f360c2fca138f1c65410918ca0cb47c15cbdee931ed03cbcec6e871f11f2692a9b9136f82b274a338805e863f87c5c0f99604c03484b1a2020732e5473bec84ced8ba05cd9490e75563628 +ac3916dc874442f05ca2409bd5c63957bca4c5363dda23846a5901010818c57874aff1787bd7c554c95aae8e354ec55beb1b79966bae64197d4383c894485c8a509064957abe7f3fa4154dc0f0e958121fcc +f0b7a82a962c7faa238acb98ebe4b904e8d5998e1856dbf68aea0933dfb3d80a44f0eaad678dacf31ee5c985fe6f9844f9490319745e89bf790d3e0cf2a788a177de8401119ebc9f7e48f58c279ef723fda7cc +6d87c3942bc4ebbc224fac383f1b22af13a4ccdfae5ee66ab8f954ebbb874f583ef07152872ce03de5c3584574b91d91d2f6fc4b14625e3e2bdfd04fc7b9441d73f9c09411f08938429c9f12e31caea17e094d9d +2e0d7c7f1c03ce9d4479fa800645abda4aade87bca0bbe547e889f8d32af7530d212171baae32831ecbd84cc27bb3da8496982a183e2785a0731220677341bcf75ae345ddb8bcdb7dccd2c4e1094d33ca53b0768cf +9bec3f01c35ba5436e44b01a96077f41aa61516dff5cef6185818e7f57d2dd0b9d9ebfeb35a0cff1ae8d98975a0cdcf2b626dd7b1f8fa2534ffc058abc1b81e1c68aaeaf8e9b255c3eabe1d675399220d4b6d967fc5f +b0d54ba8f86b01d511acb7ddb567198dabe835512d0033991a221b2bdf815d8063d073d1bbf5704f954df8f73a4ecec48417c2fec643f9e15d1d41b51f955f2422a69a2a8f73b6154881e6f6721f8e73a80efa5bfb1717 +cd41ad000e15e9b261e52b459bf79c7f7ffeb281629fba3c986c08b90a058abf76799dc72e430a1df8b64641cc2e03339ebb37fe7eabced490f77b58b3dcf492f981687036dcb94328cd9ad9f4e489de5d06bbd3671a9bf1 +21233d332c3fa9b056520c06fe55aa388773ee12ae893395df1d75c4932b54a5d679637d33930f2f8afa22be2fb4b1fd36a6c83b51057611c8119bd8cdb1efd8ee7063d5f13c09d2f8e5f8888eda3ece738e34f667aee451b9 +86418350d07d8f9d8b7e1190eb13634dc0a59f267730afe9409cecab0ac4f57feacaee8dec7321b8512991d51d4fe3b7cc2cbb5e6728ba115f022087606d15b39810032b3945e052574c7464c2b2434b2a54a801991d093f9390 +5501bfd8c7b1784515a192c0db6516b1fda893702ed45db7a5c07b32b3d9d41f396f9ed61cc4f9a143d4b4ab16c9f6975ee0a8851c62f80ddd4fdfef6c9f6f27c130a13109cd20779e4bab78200129900ecedae564c790153d2227 +7d45d142bdeff8e1b941537dab8685697988e60cd0ca0926dacc9a227de9f33e0dca5c7c17bcb3f3d3a1f39c4999313786933cb931c725b6359a1b10e31b77cd30f28e3bd4ebe898ef0ae1ee5e3a28a911fdc3759d04929c74321a9d +36f11d276af5958a737c5f457ae997455025cde0503ecf1431ea68b6567530cf3abeee2391c1c549fd3bb274120b0613828839ae74b6a071ee9d29b6247ca6a8a1cd2195d24c6215f58be04e197b541828b99e3a71d0991be8245303ad +efe64e5b4341239a2e60d342b89a302c2b8cbd45a33a5301936a051f69dd1644164bf7e24d269d341285a2c22aaa93517b1e9ae6a3d6b18961d4b1f58b357a113a12e9c6519ce7533f602b026dbd885c0584f21e099e74516d5db197dec0 +e5d90cf622738f73973fc448b7be40b044fac3dfc65d36db47f3fa9d01d41fb9808ad83e51729c0c2c35cc08226fbcd20a988ea24bb8373991e702c911d1764b309eda4d1500592ce0fee42fe111e9f9e346734b9e2758194ff9f0713613d1 +1444dfb0694d36937eb77a0b1f04c2e29e9904d1dcf03cf8d420315c5cb38463f8f3327df5cd34485b0e6db3eefedcd9015f4953a99c125f3ee803c4727c10e0ca943408d82a0c6c1b797a7a3a9e6446df53b8de29894309e81d09a321564b40 +171e9fb9e3867ac3ae4cbe09884cccb7561c2c0773ea8200c492ac338512f2017bc843b1ae5fb998c7d1f155b01b707f70dcbf68dab56d74a561b5fe7759788b5651a9ab0fe7006d0c096cacbc9ba93736bda0b967b7f1ebfb4c7a032e73f40392 +db14a6d9c6311aadd73d9fb5b38b654bf306e0ea3880d22a12032971115d22dc38f9bf03ac83a177a0e36be7f710d4a903934601d15911942f11364692d77958be02be75eb6c697e3d963f6ca2c26449272bd05cd3ec41b884a6a97381f57f19d70c +tv_kdf_hkdf: ok diff --git a/subprojects/libsodium/test/default/misuse.c b/subprojects/libsodium/test/default/misuse.c @@ -4,12 +4,15 @@ #ifdef HAVE_CATCHABLE_ABRT # include <signal.h> +#ifndef _WIN32 +# include <unistd.h> +#endif static void sigabrt_handler_15(int sig) { (void) sig; - exit(0); + _exit(0); } # ifndef SODIUM_LIBRARY_MINIMAL @@ -21,7 +24,7 @@ sigabrt_handler_14(int sig) assert(crypto_box_curve25519xchacha20poly1305_easy (guard_page, guard_page, crypto_stream_xchacha20_MESSAGEBYTES_MAX - 1, guard_page, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -32,7 +35,7 @@ sigabrt_handler_13(int sig) assert(crypto_box_curve25519xchacha20poly1305_easy_afternm (guard_page, guard_page, crypto_stream_xchacha20_MESSAGEBYTES_MAX - 1, guard_page, guard_page) == -1); - exit(1); + _exit(1); } # endif @@ -47,7 +50,7 @@ sigabrt_handler_12(int sig) # endif assert(crypto_pwhash_str_alg((char *) guard_page, "", 0U, 1U, 1U, -1) == -1); - exit(1); + _exit(1); } static void @@ -58,7 +61,7 @@ sigabrt_handler_11(int sig) assert(crypto_box_easy(guard_page, guard_page, crypto_stream_xsalsa20_MESSAGEBYTES_MAX, guard_page, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -69,7 +72,7 @@ sigabrt_handler_10(int sig) assert(crypto_box_easy_afternm(guard_page, guard_page, crypto_stream_xsalsa20_MESSAGEBYTES_MAX, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -79,7 +82,7 @@ sigabrt_handler_9(int sig) signal(SIGABRT, sigabrt_handler_10); assert(sodium_base642bin(guard_page, 1, (const char *) guard_page, 1, NULL, NULL, NULL, -1) == -1); - exit(1); + _exit(1); } static void @@ -89,7 +92,7 @@ sigabrt_handler_8(int sig) signal(SIGABRT, sigabrt_handler_9); assert(sodium_bin2base64((char *) guard_page, 1, guard_page, 1, sodium_base64_VARIANT_ORIGINAL) == NULL); - exit(1); + _exit(1); } static void @@ -99,7 +102,7 @@ sigabrt_handler_7(int sig) signal(SIGABRT, sigabrt_handler_8); assert(sodium_bin2base64((char *) guard_page, 1, guard_page, 1, -1) == NULL); - exit(1); + _exit(1); } static void @@ -108,7 +111,7 @@ sigabrt_handler_6(int sig) (void) sig; signal(SIGABRT, sigabrt_handler_7); assert(sodium_pad(NULL, guard_page, SIZE_MAX, 16, 1) == -1); - exit(1); + _exit(1); } static void @@ -119,7 +122,7 @@ sigabrt_handler_5(int sig) assert(crypto_aead_xchacha20poly1305_ietf_encrypt(guard_page, NULL, NULL, UINT64_MAX, NULL, 0, NULL, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -130,7 +133,7 @@ sigabrt_handler_4(int sig) assert(crypto_aead_chacha20poly1305_ietf_encrypt(guard_page, NULL, NULL, UINT64_MAX, NULL, 0, NULL, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -141,7 +144,7 @@ sigabrt_handler_3(int sig) assert(crypto_aead_chacha20poly1305_encrypt(guard_page, NULL, NULL, UINT64_MAX, NULL, 0, NULL, guard_page, guard_page) == -1); - exit(1); + _exit(1); } static void @@ -154,7 +157,7 @@ sigabrt_handler_2(int sig) #else abort(); #endif - exit(1); + _exit(1); } static void @@ -164,7 +167,7 @@ sigabrt_handler_1(int sig) signal(SIGABRT, sigabrt_handler_2); assert(crypto_kx_server_session_keys(NULL, NULL, guard_page, guard_page, guard_page) == -1); - exit(1); + _exit(1); } int diff --git a/subprojects/libsodium/test/default/pwhash_argon2i.c b/subprojects/libsodium/test/default/pwhash_argon2i.c @@ -290,10 +290,24 @@ str_tests(void) -1) { printf("pwhash_str() with a small opslimit should have failed\n"); } - if (crypto_pwhash_argon2i_str_verify("$argon2i$m=65536,t=2,p=1c29tZXNhbHQ" - "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ", - "password", 0x100000000ULL) != -1) { - printf("pwhash_str_verify(invalid(0)) failure\n"); + { + const char *str_in_ = "$argon2i$m=65536,t=2,p=1c29tZXNhbHQ" + "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ"; + char *str_in = (char *) sodium_malloc(strlen(str_in_) + 1U); + + const char *password_in_ = "password"; + char *password_in = (char *) sodium_malloc(strlen(password_in_) + 1U); + + memcpy(str_in, str_in_, strlen(str_in_) + 1U); + memcpy(password_in, password_in_, strlen(password_in_) + 1U); + + if (crypto_pwhash_argon2i_str_verify(str_in, password_in, + 0x100000000ULL) != -1) { + printf("pwhash_str_verify(invalid(0)) failure\n"); + } + + sodium_free(password_in); + sodium_free(str_in); } if (crypto_pwhash_argon2i_str_verify("$argon2i$m=65536,t=2,p=1c29tZXNhbHQ" "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ", diff --git a/subprojects/libsodium/test/default/pwhash_argon2id.c b/subprojects/libsodium/test/default/pwhash_argon2id.c @@ -304,10 +304,24 @@ str_tests(void) if (crypto_pwhash_str(str_out2, passwd, strlen(passwd), 0, MEMLIMIT) != -1) { printf("pwhash_argon2id_str() with a null opslimit should have failed\n"); } - if (crypto_pwhash_str_verify("$argon2id$m=65536,t=2,p=1c29tZXNhbHQ" - "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ", - "password", 0x100000000ULL) != -1) { - printf("pwhash_str_verify(invalid(0)) failure\n"); + { + const char *str_in_ ="$argon2id$m=65536,t=2,p=1c29tZXNhbHQ" + "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ"; + char *str_in = (char *) sodium_malloc(strlen(str_in_) + 1U); + + const char *password_in_ = "password"; + char *password_in = (char *) sodium_malloc(strlen(password_in_) + 1U); + + memcpy(str_in, str_in_, strlen(str_in_) + 1U); + memcpy(password_in, password_in_, strlen(password_in_) + 1U); + + if (crypto_pwhash_argon2i_str_verify(str_in, password_in, + 0x100000000ULL) != -1) { + printf("pwhash_str_verify(invalid(0)) failure\n"); + } + + sodium_free(password_in); + sodium_free(str_in); } if (crypto_pwhash_str_verify("$argon2id$m=65536,t=2,p=1c29tZXNhbHQ" "$9sTbSlTio3Biev89thdrlKKiCaYsjjYVJxGAL3swxpQ", @@ -418,7 +432,7 @@ main(void) assert(crypto_pwhash_memlimit_moderate() > 0U); assert(crypto_pwhash_opslimit_sensitive() > 0U); assert(crypto_pwhash_memlimit_sensitive() > 0U); - assert(strcmp(crypto_pwhash_primitive(), "argon2i") == 0); + assert(strcmp(crypto_pwhash_primitive(), "argon2id,argon2i") == 0); assert(crypto_pwhash_bytes_min() == crypto_pwhash_BYTES_MIN); assert(crypto_pwhash_bytes_max() == crypto_pwhash_BYTES_MAX); diff --git a/subprojects/libsodium/test/default/pwhash_scrypt.c b/subprojects/libsodium/test/default/pwhash_scrypt.c @@ -297,16 +297,12 @@ str_tests(void) { char *str_out; char *str_out2; - char *salt; const char *passwd = "Correct Horse Battery Staple"; - salt = (char *) sodium_malloc(crypto_pwhash_scryptsalsa208sha256_SALTBYTES); str_out = (char *) sodium_malloc(crypto_pwhash_scryptsalsa208sha256_STRBYTES); str_out2 = (char *) sodium_malloc(crypto_pwhash_scryptsalsa208sha256_STRBYTES); - memcpy(salt, "[<~A 32-bytes salt for scrypt~>]", - crypto_pwhash_scryptsalsa208sha256_SALTBYTES); if (crypto_pwhash_scryptsalsa208sha256_str(str_out, passwd, strlen(passwd), OPSLIMIT, MEMLIMIT) != 0) { printf("pwhash_str failure\n"); @@ -360,7 +356,6 @@ str_tests(void) assert(crypto_pwhash_scryptsalsa208sha256_str_needs_rehash ("", OPSLIMIT, MEMLIMIT) == -1); - sodium_free(salt); sodium_free(str_out); sodium_free(str_out2); } diff --git a/subprojects/libsodium/test/default/run.sh b/subprojects/libsodium/test/default/run.sh @@ -0,0 +1,9 @@ +#! /bin/sh + +find . -type f -perm -100 -print | grep -v run.sh | sort | while read -r x; do + echo "[$x]" + if ! "$x"; then + echo "*** [$x] FAILED" >&2 + exit 1 + fi +done diff --git a/subprojects/libsodium/test/default/scalarmult.c b/subprojects/libsodium/test/default/scalarmult.c @@ -52,6 +52,12 @@ main(void) sodium_bin2hex(hex, sizeof hex, k, crypto_scalarmult_BYTES); printf("%s\n", hex); + alicepk[31] ^= 0x80; + ret = crypto_scalarmult(k, bobsk, alicepk); + assert(ret == 0); + sodium_bin2hex(hex, sizeof hex, k, crypto_scalarmult_BYTES); + printf("%s\n", hex); + ret = crypto_scalarmult(k, bobsk, small_order_p); assert(ret == -1); diff --git a/subprojects/libsodium/test/default/scalarmult.exp b/subprojects/libsodium/test/default/scalarmult.exp @@ -2,3 +2,4 @@ de9edb7d7b7dc1b4d35b61c2ece435373f8343c85b78674dadfc7e146f882b4f 4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742 4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742 +4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742 diff --git a/subprojects/libsodium/test/default/scalarmult2.c b/subprojects/libsodium/test/default/scalarmult2.c @@ -8,25 +8,15 @@ static unsigned char bobsk[32] = { 0x5d, 0xab, 0x08, 0x7e, 0x62, 0x4a, 0x8a, 0x18, 0xb6, 0xfd, 0x1c, 0x2f, 0x8b, 0x27, 0xff, 0x88, 0xe0, 0xeb }; -static unsigned char bobpk[32]; - int main(void) { - int i; + unsigned char bobpk[32]; + char hex[65]; crypto_scalarmult_base(bobpk, bobsk); + sodium_bin2hex(hex, sizeof hex, bobpk, sizeof bobpk); + printf("%s\n", hex); - for (i = 0; i < 32; ++i) { - if (i > 0) { - printf(","); - } else { - printf(" "); - } - printf("0x%02x", (unsigned int) bobpk[i]); - if (i % 8 == 7) { - printf("\n"); - } - } return 0; } diff --git a/subprojects/libsodium/test/default/scalarmult2.exp b/subprojects/libsodium/test/default/scalarmult2.exp @@ -1,4 +1 @@ - 0xde,0x9e,0xdb,0x7d,0x7b,0x7d,0xc1,0xb4 -,0xd3,0x5b,0x61,0xc2,0xec,0xe4,0x35,0x37 -,0x3f,0x83,0x43,0xc8,0x5b,0x78,0x67,0x4d -,0xad,0xfc,0x7e,0x14,0x6f,0x88,0x2b,0x4f +de9edb7d7b7dc1b4d35b61c2ece435373f8343c85b78674dadfc7e146f882b4f diff --git a/subprojects/libsodium/test/default/scalarmult5.c b/subprojects/libsodium/test/default/scalarmult5.c @@ -14,27 +14,17 @@ static unsigned char bobpk[32] = { 0xde, 0x9e, 0xdb, 0x7d, 0x7b, 0x7d, 0xc1, 0x78, 0x67, 0x4d, 0xad, 0xfc, 0x7e, 0x14, 0x6f, 0x88, 0x2b, 0x4f }; -static unsigned char k[32]; - int main(void) { - int i; - int ret; + unsigned char k[32]; + char hex[65]; + int ret; ret = crypto_scalarmult(k, alicesk, bobpk); assert(ret == 0); + sodium_bin2hex(hex, sizeof hex, k, sizeof k); + printf("%s\n", hex); - for (i = 0; i < 32; ++i) { - if (i > 0) { - printf(","); - } else { - printf(" "); - } - printf("0x%02x", (unsigned int) k[i]); - if (i % 8 == 7) { - printf("\n"); - } - } return 0; } diff --git a/subprojects/libsodium/test/default/scalarmult5.exp b/subprojects/libsodium/test/default/scalarmult5.exp @@ -1,4 +1 @@ - 0x4a,0x5d,0x9d,0x5b,0xa4,0xce,0x2d,0xe1 -,0x72,0x8e,0x3b,0xf4,0x80,0x35,0x0f,0x25 -,0xe0,0x7e,0x21,0xc9,0x47,0xd1,0x9e,0x33 -,0x76,0xf0,0x9b,0x3c,0x1e,0x16,0x17,0x42 +4a5d9d5ba4ce2de1728e3bf480350f25e07e21c947d19e3376f09b3c1e161742 diff --git a/subprojects/libsodium/test/default/secretstream.c b/subprojects/libsodium/test/default/secretstream.c @@ -1,329 +0,0 @@ - -#define TEST_NAME "secretstream" -#include "cmptest.h" - -int -main(void) -{ - crypto_secretstream_xchacha20poly1305_state *state, *statesave; - crypto_secretstream_xchacha20poly1305_state state_copy; - unsigned char *ad; - unsigned char *header; - unsigned char *k; - unsigned char *c1, *c2, *c3, *csave; - unsigned char *m1, *m2, *m3; - unsigned char *m1_, *m2_, *m3_; - unsigned long long res_len; - size_t ad_len; - size_t m1_len, m2_len, m3_len; - int ret; - unsigned char tag; - - state = (crypto_secretstream_xchacha20poly1305_state *) - sodium_malloc(crypto_secretstream_xchacha20poly1305_statebytes()); - statesave = (crypto_secretstream_xchacha20poly1305_state *) - sodium_malloc(crypto_secretstream_xchacha20poly1305_statebytes()); - header = (unsigned char *) - sodium_malloc(crypto_secretstream_xchacha20poly1305_HEADERBYTES); - - ad_len = randombytes_uniform(100); - m1_len = randombytes_uniform(1000); - m2_len = randombytes_uniform(1000); - m3_len = randombytes_uniform(1000); - - c1 = (unsigned char *) - sodium_malloc(m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); - c2 = (unsigned char *) - sodium_malloc(m2_len + crypto_secretstream_xchacha20poly1305_ABYTES); - c3 = (unsigned char *) - sodium_malloc(m3_len + crypto_secretstream_xchacha20poly1305_ABYTES); - csave = (unsigned char *) - sodium_malloc((m1_len | m2_len | m3_len) + crypto_secretstream_xchacha20poly1305_ABYTES); - - ad = (unsigned char *) sodium_malloc(ad_len); - m1 = (unsigned char *) sodium_malloc(m1_len); - m2 = (unsigned char *) sodium_malloc(m2_len); - m3 = (unsigned char *) sodium_malloc(m3_len); - m1_ = (unsigned char *) sodium_malloc(m1_len); - m2_ = (unsigned char *) sodium_malloc(m2_len); - m3_ = (unsigned char *) sodium_malloc(m3_len); - - randombytes_buf(ad, ad_len); - - randombytes_buf(m1, m1_len); - memcpy(m1_, m1, m1_len); - randombytes_buf(m2, m2_len); - memcpy(m2_, m2, m2_len); - randombytes_buf(m3, m3_len); - memcpy(m3_, m3, m3_len); - - k = (unsigned char *) - sodium_malloc(crypto_secretstream_xchacha20poly1305_KEYBYTES); - crypto_secretstream_xchacha20poly1305_keygen(k); - - /* push */ - - ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, &res_len, m1, m1_len, NULL, 0, 0); - assert(ret == 0); - assert(res_len == m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, ad, 0, 0); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c3, NULL, m3, m3_len, ad, ad_len, - crypto_secretstream_xchacha20poly1305_TAG_FINAL); - assert(ret == 0); - - /* pull */ - - ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m1, &res_len, &tag, - c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - assert(tag == 0); - assert(memcmp(m1, m1_, m1_len) == 0); - assert(res_len == m1_len); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - assert(tag == 0); - assert(memcmp(m2, m2_, m2_len) == 0); - - if (ad_len > 0) { - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m3, NULL, &tag, - c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == -1); - } - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m3, NULL, &tag, - c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, ad, ad_len); - assert(ret == 0); - assert(tag == crypto_secretstream_xchacha20poly1305_TAG_FINAL); - assert(memcmp(m3, m3_, m3_len) == 0); - - /* previous with FINAL tag */ - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m3, NULL, &tag, - c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, ad, ad_len); - assert(ret == -1); - - /* previous without a tag */ - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == -1); - - /* short ciphertext */ - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, c2, - randombytes_uniform(crypto_secretstream_xchacha20poly1305_ABYTES), - NULL, 0); - assert(ret == -1); - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, c2, 0, NULL, 0); - assert(ret == -1); - - /* empty ciphertext */ - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, c2, - crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == -1); - - /* without explicit rekeying */ - - ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, NULL, m1, m1_len, NULL, 0, 0); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, NULL, 0, 0); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m1, NULL, &tag, - c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - - /* with explicit rekeying */ - - ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, NULL, m1, m1_len, NULL, 0, 0); - assert(ret == 0); - - crypto_secretstream_xchacha20poly1305_rekey(state); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, NULL, 0, 0); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m1, NULL, &tag, - c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == -1); - - crypto_secretstream_xchacha20poly1305_rekey(state); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - - /* with explicit rekeying using TAG_REKEY */ - - ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); - assert(ret == 0); - - memcpy(statesave, state, sizeof *state); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, NULL, m1, m1_len, NULL, 0, crypto_secretstream_xchacha20poly1305_TAG_REKEY); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, NULL, 0, 0); - assert(ret == 0); - - memcpy(csave, c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES); - - ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); - assert(ret == 0); - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m1, NULL, &tag, - c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, &tag, 0); - assert(ret == 0); - assert(tag == crypto_secretstream_xchacha20poly1305_TAG_REKEY); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, &tag, 0); - assert(ret == 0); - assert(tag == 0); - - memcpy(state, statesave, sizeof *state); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, NULL, m1, m1_len, NULL, 0, 0); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, NULL, 0, 0); - assert(ret == 0); - - assert(memcmp(csave, c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES) != 0); - - /* New stream */ - - ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c1, &res_len, m1, m1_len, NULL, 0, - crypto_secretstream_xchacha20poly1305_TAG_PUSH); - assert(ret == 0); - assert(res_len == m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); - - /* Force a counter overflow, check that the key has been updated - * even though the tag was not changed to REKEY */ - - memset(state->nonce, 0xff, 4U); - state_copy = *state; - - ret = crypto_secretstream_xchacha20poly1305_push - (state, c2, NULL, m2, m2_len, ad, 0, 0); - assert(ret == 0); - - assert(memcmp(state_copy.k, state->k, sizeof state->k) != 0); - assert(memcmp(state_copy.nonce, state->nonce, sizeof state->nonce) != 0); - assert(state->nonce[0] == 1U); - assert(sodium_is_zero(state->nonce + 1, 3U)); - - ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); - assert(ret == 0); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m1, &res_len, &tag, - c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - assert(tag == crypto_secretstream_xchacha20poly1305_TAG_PUSH); - assert(memcmp(m1, m1_, m1_len) == 0); - assert(res_len == m1_len); - - memset(state->nonce, 0xff, 4U); - - ret = crypto_secretstream_xchacha20poly1305_pull - (state, m2, NULL, &tag, - c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); - assert(ret == 0); - assert(tag == 0); - assert(memcmp(m2, m2_, m2_len) == 0); - - sodium_free(m3_); - sodium_free(m2_); - sodium_free(m1_); - sodium_free(m3); - sodium_free(m2); - sodium_free(m1); - sodium_free(ad); - sodium_free(csave); - sodium_free(c3); - sodium_free(c2); - sodium_free(c1); - sodium_free(k); - sodium_free(header); - sodium_free(statesave); - sodium_free(state); - - assert(crypto_secretstream_xchacha20poly1305_abytes() == - crypto_secretstream_xchacha20poly1305_ABYTES); - assert(crypto_secretstream_xchacha20poly1305_headerbytes() == - crypto_secretstream_xchacha20poly1305_HEADERBYTES); - assert(crypto_secretstream_xchacha20poly1305_keybytes() == - crypto_secretstream_xchacha20poly1305_KEYBYTES); - assert(crypto_secretstream_xchacha20poly1305_messagebytes_max() == - crypto_secretstream_xchacha20poly1305_MESSAGEBYTES_MAX); - - assert(crypto_secretstream_xchacha20poly1305_tag_message() == - crypto_secretstream_xchacha20poly1305_TAG_MESSAGE); - assert(crypto_secretstream_xchacha20poly1305_tag_push() == - crypto_secretstream_xchacha20poly1305_TAG_PUSH); - assert(crypto_secretstream_xchacha20poly1305_tag_rekey() == - crypto_secretstream_xchacha20poly1305_TAG_REKEY); - assert(crypto_secretstream_xchacha20poly1305_tag_final() == - crypto_secretstream_xchacha20poly1305_TAG_FINAL); - - printf("OK\n"); - - return 0; -} diff --git a/subprojects/libsodium/test/default/secretstream_xchacha20poly1305.c b/subprojects/libsodium/test/default/secretstream_xchacha20poly1305.c @@ -0,0 +1,329 @@ + +#define TEST_NAME "secretstream_xchacha20poly1305" +#include "cmptest.h" + +int +main(void) +{ + crypto_secretstream_xchacha20poly1305_state *state, *statesave; + crypto_secretstream_xchacha20poly1305_state state_copy; + unsigned char *ad; + unsigned char *header; + unsigned char *k; + unsigned char *c1, *c2, *c3, *csave; + unsigned char *m1, *m2, *m3; + unsigned char *m1_, *m2_, *m3_; + unsigned long long res_len; + size_t ad_len; + size_t m1_len, m2_len, m3_len; + int ret; + unsigned char tag; + + state = (crypto_secretstream_xchacha20poly1305_state *) + sodium_malloc(crypto_secretstream_xchacha20poly1305_statebytes()); + statesave = (crypto_secretstream_xchacha20poly1305_state *) + sodium_malloc(crypto_secretstream_xchacha20poly1305_statebytes()); + header = (unsigned char *) + sodium_malloc(crypto_secretstream_xchacha20poly1305_HEADERBYTES); + + ad_len = randombytes_uniform(100); + m1_len = randombytes_uniform(1000); + m2_len = randombytes_uniform(1000); + m3_len = randombytes_uniform(1000); + + c1 = (unsigned char *) + sodium_malloc(m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); + c2 = (unsigned char *) + sodium_malloc(m2_len + crypto_secretstream_xchacha20poly1305_ABYTES); + c3 = (unsigned char *) + sodium_malloc(m3_len + crypto_secretstream_xchacha20poly1305_ABYTES); + csave = (unsigned char *) + sodium_malloc((m1_len | m2_len | m3_len) + crypto_secretstream_xchacha20poly1305_ABYTES); + + ad = (unsigned char *) sodium_malloc(ad_len); + m1 = (unsigned char *) sodium_malloc(m1_len); + m2 = (unsigned char *) sodium_malloc(m2_len); + m3 = (unsigned char *) sodium_malloc(m3_len); + m1_ = (unsigned char *) sodium_malloc(m1_len); + m2_ = (unsigned char *) sodium_malloc(m2_len); + m3_ = (unsigned char *) sodium_malloc(m3_len); + + randombytes_buf(ad, ad_len); + + randombytes_buf(m1, m1_len); + memcpy(m1_, m1, m1_len); + randombytes_buf(m2, m2_len); + memcpy(m2_, m2, m2_len); + randombytes_buf(m3, m3_len); + memcpy(m3_, m3, m3_len); + + k = (unsigned char *) + sodium_malloc(crypto_secretstream_xchacha20poly1305_KEYBYTES); + crypto_secretstream_xchacha20poly1305_keygen(k); + + /* push */ + + ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, &res_len, m1, m1_len, NULL, 0, 0); + assert(ret == 0); + assert(res_len == m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, ad, 0, 0); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c3, NULL, m3, m3_len, ad, ad_len, + crypto_secretstream_xchacha20poly1305_TAG_FINAL); + assert(ret == 0); + + /* pull */ + + ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m1, &res_len, &tag, + c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + assert(tag == 0); + assert(memcmp(m1, m1_, m1_len) == 0); + assert(res_len == m1_len); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + assert(tag == 0); + assert(memcmp(m2, m2_, m2_len) == 0); + + if (ad_len > 0) { + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m3, NULL, &tag, + c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == -1); + } + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m3, NULL, &tag, + c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, ad, ad_len); + assert(ret == 0); + assert(tag == crypto_secretstream_xchacha20poly1305_TAG_FINAL); + assert(memcmp(m3, m3_, m3_len) == 0); + + /* previous with FINAL tag */ + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m3, NULL, &tag, + c3, m3_len + crypto_secretstream_xchacha20poly1305_ABYTES, ad, ad_len); + assert(ret == -1); + + /* previous without a tag */ + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == -1); + + /* short ciphertext */ + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, c2, + randombytes_uniform(crypto_secretstream_xchacha20poly1305_ABYTES), + NULL, 0); + assert(ret == -1); + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, c2, 0, NULL, 0); + assert(ret == -1); + + /* empty ciphertext */ + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, c2, + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == -1); + + /* without explicit rekeying */ + + ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, NULL, m1, m1_len, NULL, 0, 0); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, NULL, 0, 0); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m1, NULL, &tag, + c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + + /* with explicit rekeying */ + + ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, NULL, m1, m1_len, NULL, 0, 0); + assert(ret == 0); + + crypto_secretstream_xchacha20poly1305_rekey(state); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, NULL, 0, 0); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m1, NULL, &tag, + c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == -1); + + crypto_secretstream_xchacha20poly1305_rekey(state); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + + /* with explicit rekeying using TAG_REKEY */ + + ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); + assert(ret == 0); + + memcpy(statesave, state, sizeof *state); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, NULL, m1, m1_len, NULL, 0, crypto_secretstream_xchacha20poly1305_TAG_REKEY); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, NULL, 0, 0); + assert(ret == 0); + + memcpy(csave, c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES); + + ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); + assert(ret == 0); + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m1, NULL, &tag, + c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, &tag, 0); + assert(ret == 0); + assert(tag == crypto_secretstream_xchacha20poly1305_TAG_REKEY); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, &tag, 0); + assert(ret == 0); + assert(tag == 0); + + memcpy(state, statesave, sizeof *state); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, NULL, m1, m1_len, NULL, 0, 0); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, NULL, 0, 0); + assert(ret == 0); + + assert(memcmp(csave, c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES) != 0); + + /* New stream */ + + ret = crypto_secretstream_xchacha20poly1305_init_push(state, header, k); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c1, &res_len, m1, m1_len, NULL, 0, + crypto_secretstream_xchacha20poly1305_TAG_PUSH); + assert(ret == 0); + assert(res_len == m1_len + crypto_secretstream_xchacha20poly1305_ABYTES); + + /* Force a counter overflow, check that the key has been updated + * even though the tag was not changed to REKEY */ + + memset(state->nonce, 0xff, 4U); + state_copy = *state; + + ret = crypto_secretstream_xchacha20poly1305_push + (state, c2, NULL, m2, m2_len, ad, 0, 0); + assert(ret == 0); + + assert(memcmp(state_copy.k, state->k, sizeof state->k) != 0); + assert(memcmp(state_copy.nonce, state->nonce, sizeof state->nonce) != 0); + assert(state->nonce[0] == 1U); + assert(sodium_is_zero(state->nonce + 1, 3U)); + + ret = crypto_secretstream_xchacha20poly1305_init_pull(state, header, k); + assert(ret == 0); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m1, &res_len, &tag, + c1, m1_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + assert(tag == crypto_secretstream_xchacha20poly1305_TAG_PUSH); + assert(memcmp(m1, m1_, m1_len) == 0); + assert(res_len == m1_len); + + memset(state->nonce, 0xff, 4U); + + ret = crypto_secretstream_xchacha20poly1305_pull + (state, m2, NULL, &tag, + c2, m2_len + crypto_secretstream_xchacha20poly1305_ABYTES, NULL, 0); + assert(ret == 0); + assert(tag == 0); + assert(memcmp(m2, m2_, m2_len) == 0); + + sodium_free(m3_); + sodium_free(m2_); + sodium_free(m1_); + sodium_free(m3); + sodium_free(m2); + sodium_free(m1); + sodium_free(ad); + sodium_free(csave); + sodium_free(c3); + sodium_free(c2); + sodium_free(c1); + sodium_free(k); + sodium_free(header); + sodium_free(statesave); + sodium_free(state); + + assert(crypto_secretstream_xchacha20poly1305_abytes() == + crypto_secretstream_xchacha20poly1305_ABYTES); + assert(crypto_secretstream_xchacha20poly1305_headerbytes() == + crypto_secretstream_xchacha20poly1305_HEADERBYTES); + assert(crypto_secretstream_xchacha20poly1305_keybytes() == + crypto_secretstream_xchacha20poly1305_KEYBYTES); + assert(crypto_secretstream_xchacha20poly1305_messagebytes_max() == + crypto_secretstream_xchacha20poly1305_MESSAGEBYTES_MAX); + + assert(crypto_secretstream_xchacha20poly1305_tag_message() == + crypto_secretstream_xchacha20poly1305_TAG_MESSAGE); + assert(crypto_secretstream_xchacha20poly1305_tag_push() == + crypto_secretstream_xchacha20poly1305_TAG_PUSH); + assert(crypto_secretstream_xchacha20poly1305_tag_rekey() == + crypto_secretstream_xchacha20poly1305_TAG_REKEY); + assert(crypto_secretstream_xchacha20poly1305_tag_final() == + crypto_secretstream_xchacha20poly1305_TAG_FINAL); + + printf("OK\n"); + + return 0; +} diff --git a/subprojects/libsodium/test/default/secretstream.exp b/subprojects/libsodium/test/default/secretstream_xchacha20poly1305.exp diff --git a/subprojects/libsodium/test/default/sodium_core.c b/subprojects/libsodium/test/default/sodium_core.c @@ -19,6 +19,7 @@ main(void) assert(sodium_init() == 1); (void) sodium_runtime_has_neon(); + (void) sodium_runtime_has_armcrypto(); (void) sodium_runtime_has_sse2(); (void) sodium_runtime_has_sse3(); (void) sodium_runtime_has_ssse3(); @@ -31,11 +32,11 @@ main(void) (void) sodium_runtime_has_rdrand(); sodium_set_misuse_handler(misuse_handler); -#ifndef __EMSCRIPTEN__ +#if defined(__EMSCRIPTEN__) || defined(__wasm__) || defined(BENCHMARKS) + printf("misuse_handler()\n"); +#else sodium_misuse(); printf("Misuse handler returned\n"); -#else - printf("misuse_handler()\n"); #endif return 0; diff --git a/subprojects/libsodium/test/default/sodium_utils2.c b/subprojects/libsodium/test/default/sodium_utils2.c @@ -3,7 +3,12 @@ #include <sys/types.h> #include <limits.h> -#include <signal.h> +#ifdef HAVE_CATCHABLE_SEGV +# include <signal.h> +#endif +#ifndef _WIN32 +# include <unistd.h> +#endif #define TEST_NAME "sodium_utils2" #include "cmptest.h" @@ -24,6 +29,9 @@ segv_handler(int sig) printf("Intentional segfault / bus error caught\n"); printf("OK\n"); #ifdef SIG_DFL +# ifdef SIGPROT + signal(SIGPROT, SIG_DFL); +# endif # ifdef SIGSEGV signal(SIGSEGV, SIG_DFL); # endif @@ -34,15 +42,19 @@ segv_handler(int sig) signal(SIGABRT, SIG_DFL); # endif #endif - exit(0); + _exit(0); } int main(void) { - void * buf; - size_t size; - unsigned int i; + void *buf; + size_t size; + unsigned int i; + +#ifdef BENCHMARKS + return 0; +#endif if (sodium_malloc(SIZE_MAX - 1U) != NULL) { return 1; @@ -73,6 +85,9 @@ main(void) } printf("OK\n"); #ifdef SIG_DFL +# ifdef SIGPROT + signal(SIGPROT, segv_handler); +# endif # ifdef SIGSEGV signal(SIGSEGV, segv_handler); # endif diff --git a/subprojects/libsodium/test/default/sodium_utils3.c b/subprojects/libsodium/test/default/sodium_utils3.c @@ -3,7 +3,12 @@ #include <sys/types.h> #include <limits.h> -#include <signal.h> +#ifdef HAVE_CATCHABLE_SEGV +# include <signal.h> +#endif +#ifndef _WIN32 +# include <unistd.h> +#endif #define TEST_NAME "sodium_utils3" #include "cmptest.h" @@ -11,6 +16,9 @@ #ifdef __SANITIZE_ADDRESS__ # warning The sodium_utils3 test is expected to fail with address sanitizer #endif +#ifdef __SANITIZE_THREAD__ +# warning The sodium_utils3 test is expected to fail with thread sanitizer +#endif __attribute__((noreturn)) static void segv_handler(int sig) @@ -20,6 +28,9 @@ segv_handler(int sig) printf("Intentional segfault / bus error caught\n"); printf("OK\n"); #ifdef SIG_DFL +# ifdef SIGPROT + signal(SIGPROT, SIG_DFL); +# endif # ifdef SIGSEGV signal(SIGSEGV, SIG_DFL); # endif @@ -30,7 +41,7 @@ segv_handler(int sig) signal(SIGABRT, SIG_DFL); # endif #endif - exit(0); + _exit(0); } int @@ -39,7 +50,14 @@ main(void) void * buf; size_t size; +#ifdef BENCHMARKS + return 0; +#endif + #ifdef SIG_DFL +# ifdef SIGPROT + signal(SIGPROT, segv_handler); +# endif # ifdef SIGSEGV signal(SIGSEGV, segv_handler); # endif @@ -60,7 +78,7 @@ main(void) sodium_mprotect_readwrite(buf); #endif -#if defined(HAVE_CATCHABLE_SEGV) && !defined(__EMSCRIPTEN__) && !defined(__SANITIZE_ADDRESS__) +#if defined(HAVE_CATCHABLE_SEGV) && !defined(__EMSCRIPTEN__) && !defined(__SANITIZE_ADDRESS__) && !defined(__SANITIZE_THREAD__) sodium_memzero(((unsigned char *) buf) - 8, 8U); sodium_mprotect_readonly(buf); sodium_free(buf); diff --git a/subprojects/libsodium/test/default/stream3.c b/subprojects/libsodium/test/default/stream3.c @@ -24,8 +24,9 @@ main(void) for (i = 0; i < 32; ++i) { printf(",0x%02x", (unsigned int) rs[i]); - if (i % 8 == 7) + if (i % 8 == 7) { printf("\n"); + } } return 0; } diff --git a/subprojects/libsodium/test/default/stream4.c b/subprojects/libsodium/test/default/stream4.c @@ -41,8 +41,9 @@ main(void) for (i = 32; i < 163; ++i) { printf(",0x%02x", (unsigned int) c[i]); - if (i % 8 == 7) + if (i % 8 == 7) { printf("\n"); + } } printf("\n"); diff --git a/subprojects/libsodium/test/default/wasi-test-wrapper.sh b/subprojects/libsodium/test/default/wasi-test-wrapper.sh @@ -1,26 +1,96 @@ #! /bin/sh -MAX_MEMORY_TESTS="67108864" +unset LDFLAGS +unset CFLAGS + +if command -v wasm-opt >/dev/null; then + wasm-opt -O4 -o "${1}.tmp" "$1" && mv -f "${1}.tmp" "$1" +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasmedge" ]; then + if command -v wasmedgec >/dev/null && command -v wasmedge >/dev/null; then + wasmedgec "$1" "${1}.so" >/dev/null && + wasmedge --dir=.:. "${1}.so" && + rm -f "${1}.so" && + exit 0 + fi +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasmer" ]; then + if command -v wasmer >/dev/null; then + wasmer run "$1" "--${WASMER_BACKEND:-cranelift}" --dir=. && exit 0 + fi +fi if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasmtime" ]; then if command -v wasmtime >/dev/null; then - wasmtime -o --dir=. "$1" && exit 0 + wasmtime run --dir=. "$1" && exit 0 fi fi -if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "lucet" ]; then - if command -v lucetc-wasi >/dev/null && command -v lucet-wasi >/dev/null; then - lucetc-wasi \ - --reserved-size "${MAX_MEMORY_TESTS}" \ - -o "${1}.so" --opt-level fast "$1" && - lucet-wasi --dir=.:. --max-heap-size "${MAX_MEMORY_TESTS}" "${1}.so" && - rm -f "${1}.so" && exit 0 +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "bun" ]; then + if echo | bun help >/dev/null 2>&1; then + { + echo "import fs from 'fs'; import { init, WASI } from '@wasmer/wasi';" + echo "await init();" + echo "const wasi = new WASI({args: process.argv, env: process.env, preopens: {'.':'/'}});" + echo "await (async function() {" + echo " const wasm = await WebAssembly.compile(fs.readFileSync('${1}'));" + echo " await wasi.instantiate(wasm, {});" + echo " wasi.start();" + echo " console.log(wasi.getStdoutString());" + echo "})().catch(e => { console.error(e); process.exit(1); });" + } >"${1}.mjs" + bun run "${1}.mjs" 2>/tmp/err && + rm -f "${1}.mjs" && exit 0 fi fi -if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasmer" ]; then - if command -v wasmer >/dev/null; then - wasmer run "$1" --backend "${WASMER_BACKEND:-cranelift}" --dir=. && exit 0 +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "node" ]; then + if echo | node --experimental-wasi-unstable-preview1 >/dev/null 2>&1; then + { + echo "import fs from 'fs'; import { WASI } from 'wasi';" + echo "const wasi = new WASI({args: process.argv, env: process.env, preopens: {'.':'.'}});" + echo "const importObject = { wasi_snapshot_preview1: wasi.wasiImport };" + echo "await (async function() {" + echo " const wasm = await WebAssembly.compile(fs.readFileSync('${1}'));" + echo " const instance = await WebAssembly.instantiate(wasm, importObject);" + echo " wasi.start(instance);" + echo "})().catch(e => { console.error(e); process.exit(1); });" + } >"${1}.mjs" + node --experimental-wasi-unstable-preview1 "${1}.mjs" 2>/tmp/err && + rm -f "${1}.mjs" && exit 0 + fi +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasm3" ]; then + if command -v wasm3 >/dev/null; then + wasm3 "$1" && exit 0 + fi +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "iwasm" ]; then + if command -v iwasm >/dev/null; then + if iwasm | grep -qi wasi >/dev/null 2>&1; then + if wamrc --version; then + wamrc -o "${1}.o" "$1" >/dev/null && + iwasm --dir=. "${1}.o" && exit 0 + else + iwasm --dir=. "$1" && exit 0 + fi + fi + fi +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wazero" ]; then + if command -v wazero >/dev/null; then + wazero run -mount .:/ "$1" && exit 0 + fi +fi + +if [ -z "$WASI_RUNTIME" ] || [ "$WASI_RUNTIME" = "wasmer-js" ]; then + if command -v wasmer-js >/dev/null; then + wasmer-js run "$1" --dir=. && exit 0 fi fi diff --git a/subprojects/libsodium/test/default/wintest.bat b/subprojects/libsodium/test/default/wintest.bat @@ -1,7 +1,7 @@ @ECHO OFF if "%1" == "" ( - echo "Usage: wintest.bat <Release | ReleaseDLL | Debug | DebugDLL" + echo "Usage: wintest.bat <Release | ReleaseDLL | Debug | DebugDLL> [ <x64 | ARM64> ]" goto :END ) @@ -13,7 +13,8 @@ if not exist sodium_version.c ( ) ) -if "%2" == "x64" (SET ARCH=x64) else (SET ARCH=Win32) +if "%2" == "x64" (SET ARCH=x64) else if "%2" == "ARM64" (SET ARCH=ARM64) else (SET ARCH=ARM64) +if "%2" == "ARM64" (SET CROSSCOMPILE=1) else (SET CROSSCOMPILE=0) SET CFLAGS=/nologo /DTEST_SRCDIR=\".\" /I..\..\src\libsodium\include\sodium /I..\..\src\libsodium\include /I..\quirks SET LDFLAGS=/link /LTCG advapi32.lib ..\..\Build\%1\%ARCH%\libsodium.lib if "%1" == "ReleaseDLL" ( goto :ReleaseDLL ) @@ -44,11 +45,15 @@ FOR %%f in (*.c) DO ( echo %%f compile failed goto :END ) - %%f.exe - if errorlevel 1 ( - echo %%f failed + if %CROSSCOMPILE% == 1 ( + echo %%f skipped ) else ( - echo %%f ok + %%f.exe + if errorlevel 1 ( + echo %%f failed + ) else ( + echo %%f ok + ) ) ) REM Remove temporary files