From 2efca6a62035cc4edd9149362c47b45346ac57c3 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Sat, 13 Dec 2025 22:36:01 -0600 Subject: [PATCH 01/38] Initial clang-format --- .clang-format | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 .clang-format diff --git a/.clang-format b/.clang-format new file mode 100644 index 000000000..7ee83d5b1 --- /dev/null +++ b/.clang-format @@ -0,0 +1,15 @@ +# yaml-language-server: $schema=https://json.schemastore.org/clang-format-21.x.json +--- +BasedOnStyle: WebKit +IncludeBlocks: Regroup +IncludeCategories: + - Regex: '^("|<)(gtest|gmock)/' + Priority: 5 + - Regex: '^"trick/' + Priority: 2 + - Regex: '^("|<)(llvm|clang)/' + Priority: 3 + - Regex: "^<.*>" + Priority: 4 + - Regex: ".*" + Priority: 1 From 6a70671e94bc311d53bfea19f16bb038f56b14e5 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 1 Apr 2026 15:58:44 -0500 Subject: [PATCH 02/38] Update .clang-format --- .clang-format | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/.clang-format b/.clang-format index 7ee83d5b1..0b8d23dfd 100644 --- a/.clang-format +++ b/.clang-format @@ -1,15 +1,20 @@ -# yaml-language-server: $schema=https://json.schemastore.org/clang-format-21.x.json --- BasedOnStyle: WebKit IncludeBlocks: Regroup IncludeCategories: - - Regex: '^("|<)(gtest|gmock)/' - Priority: 5 - - Regex: '^"trick/' + - Regex: '^("|<)trick/' Priority: 2 - - Regex: '^("|<)(llvm|clang)/' + + - Regex: '^("|<)(llvm|llvm-c|clang|clang-c)/' Priority: 3 + CaseSensitive: true + + - Regex: '^("|<)(gtest|gmock)/' + Priority: 5 + - Regex: "^<.*>" Priority: 4 + - Regex: ".*" Priority: 1 +... From cbb592351089e4460d228779bbc248da1a69b190 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 1 Apr 2026 16:19:57 -0500 Subject: [PATCH 03/38] Update .clang-format --- .clang-format | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.clang-format b/.clang-format index 0b8d23dfd..9fd640b7a 100644 --- a/.clang-format +++ b/.clang-format @@ -4,17 +4,12 @@ IncludeBlocks: Regroup IncludeCategories: - Regex: '^("|<)trick/' Priority: 2 - - Regex: '^("|<)(llvm|llvm-c|clang|clang-c)/' Priority: 3 - CaseSensitive: true - - Regex: '^("|<)(gtest|gmock)/' Priority: 5 - - Regex: "^<.*>" Priority: 4 - - Regex: ".*" Priority: 1 ... From 193b719e27772dfb67b549d4728a39ba9e55096f Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 9 Apr 2026 15:57:02 -0500 Subject: [PATCH 04/38] ci: Adopt style ci --- .github/workflows/code_coverage.yml | 18 +++++++------ .github/workflows/report_linux.yml | 2 +- .github/workflows/style.yml | 40 +++++++++++++++++++++++++++++ .github/workflows/test_linux.yml | 20 ++++++++------- .github/workflows/test_macos.yml | 18 +++++++------ .github/workflows/trickops.yml | 34 ++++++++++++++---------- 6 files changed, 93 insertions(+), 39 deletions(-) create mode 100644 .github/workflows/style.yml diff --git a/.github/workflows/code_coverage.yml b/.github/workflows/code_coverage.yml index c2a05dee2..d49f8cec0 100644 --- a/.github/workflows/code_coverage.yml +++ b/.github/workflows/code_coverage.yml @@ -10,13 +10,9 @@ on: - "!.github/workflows/**" - ".github/workflows/code_coverage.yml" - "!Formula/**" - pull_request: - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/code_coverage.yml" - - "!Formula/**" + workflow_run: + workflows: ["Style"] + types: [completed] workflow_dispatch: concurrency: @@ -30,6 +26,10 @@ jobs: code-coverage: runs-on: ubuntu-latest container: docker://oraclelinux:8 + if: >- + github.event_name != 'workflow_run' || + (github.event.workflow_run.conclusion == 'success' && + github.event.workflow_run.event == 'pull_request') steps: - name: Update Package Manager run: | @@ -47,7 +47,9 @@ jobs: dnf install -y gtest-devel gmock-devel - name: Checkout repository - uses: actions/checkout@v4 + uses: actions/checkout@v6 + with: + ref: ${{ github.event.workflow_run.head_sha }} - name: Configure Trick run: | diff --git a/.github/workflows/report_linux.yml b/.github/workflows/report_linux.yml index a023dbeb7..64dad0f12 100644 --- a/.github/workflows/report_linux.yml +++ b/.github/workflows/report_linux.yml @@ -11,7 +11,7 @@ jobs: matrix: cfg: #-------- Operating Systems ---------------- - - { os: ubuntu, tag: 22.04, arch: debian, arch_ver: 12 } + - { os: ubuntu, tag: 24.04, arch: debian, arch_ver: 12 } - { os: oraclelinux, tag: 8, arch: rhel, arch_ver: 8 } - { os: rockylinux, tag: 8, arch: rhel, arch_ver: 8 } - { os: rockylinux, tag: 9, arch: rhel, arch_ver: 9 } diff --git a/.github/workflows/style.yml b/.github/workflows/style.yml new file mode 100644 index 000000000..5e5a949fb --- /dev/null +++ b/.github/workflows/style.yml @@ -0,0 +1,40 @@ +name: Style + +on: + pull_request: + workflow_dispatch: + +permissions: + contents: read + +concurrency: + group: style-${{ github.ref }} + cancel-in-progress: true + +jobs: + clang-format: + name: clang-format + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v6 + with: + fetch-depth: 0 + + - name: Install clang-format + run: | + sudo apt-get update -qq + sudo apt-get install -y clang-format clang-format + + - name: Check formatting of changed lines + run: | + BASE=$(git merge-base HEAD origin/${{ github.base_ref }}) + DIFF=$(git clang-format --diff "$BASE") + if echo "$DIFF" | grep -q '^diff'; then + echo "$DIFF" + echo "" + echo "::error::Changed C/C++ lines are not correctly formatted." + echo "::error::To fix, run: git clang-format ${{ github.base_ref }}" + exit 1 + fi + echo "All changed C/C++ files are correctly formatted." diff --git a/.github/workflows/test_linux.yml b/.github/workflows/test_linux.yml index 0b8202e66..1ef0e0144 100644 --- a/.github/workflows/test_linux.yml +++ b/.github/workflows/test_linux.yml @@ -10,13 +10,9 @@ on: - "!.github/workflows/**" - ".github/workflows/test_linux.yml" - "!Formula/**" - pull_request: - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/test_linux.yml" - - "!Formula/**" + workflow_run: + workflows: ["Style"] + types: [completed] workflow_dispatch: concurrency: @@ -35,7 +31,7 @@ jobs: #-------- Operating Systems ---------------- - { os: ubuntu, - tag: 22.04, + tag: 24.04, arch: debian, arch_ver: 12, image: ubuntu, @@ -178,6 +174,10 @@ jobs: #-------- Job definition ---------------- runs-on: ubuntu-latest container: docker://${{matrix.cfg.image}}:${{matrix.cfg.tag}} + if: >- + github.event_name != 'workflow_run' || + (github.event.workflow_run.conclusion == 'success' && + github.event.workflow_run.event == 'pull_request') steps: - name: Update Package Manager run: ${{matrix.conf_pkg}} @@ -190,7 +190,9 @@ jobs: - name: Install GTest run: ${{matrix.install_gtest}} - name: Checkout repository - uses: actions/checkout@v4 + uses: actions/checkout@v6 + with: + ref: ${{ github.event.workflow_run.head_sha }} - name: Configure Trick run: | export MAKEFLAGS=-j`nproc` diff --git a/.github/workflows/test_macos.yml b/.github/workflows/test_macos.yml index c2558b68c..e6d62d1c4 100644 --- a/.github/workflows/test_macos.yml +++ b/.github/workflows/test_macos.yml @@ -10,13 +10,9 @@ on: - "!.github/workflows/**" - ".github/workflows/test_macos.yml" - "!Formula/**" - pull_request: - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/test_macos.yml" - - "!Formula/**" + workflow_run: + workflows: ["Style"] + types: [completed] workflow_dispatch: concurrency: @@ -29,9 +25,15 @@ concurrency: jobs: macOS: runs-on: macos-15 + if: >- + github.event_name != 'workflow_run' || + (github.event.workflow_run.conclusion == 'success' && + github.event.workflow_run.event == 'pull_request') steps: - name: Checkout repository - uses: actions/checkout@v4 + uses: actions/checkout@v6 + with: + ref: ${{ github.event.workflow_run.head_sha }} # Install googletest version 1.17.0 — the latest stable release as of 6/6/25 # Note: Need to periodically update googletest version to ensure tests can run # against the latest. diff --git a/.github/workflows/trickops.yml b/.github/workflows/trickops.yml index 05b5154e1..756a883e2 100644 --- a/.github/workflows/trickops.yml +++ b/.github/workflows/trickops.yml @@ -10,13 +10,9 @@ on: - "!.github/workflows/**" - ".github/workflows/trickops.yml" - "!Formula/**" - pull_request: - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/trickops.yml" - - "!Formula/**" + workflow_run: + workflows: ["Style"] + types: [completed] workflow_dispatch: concurrency: @@ -32,11 +28,17 @@ defaults: jobs: trickops-tests-ubuntu: - name: Unit Tests Ubuntu:22.04 - runs-on: ubuntu-22.04 - container: ubuntu:22.04 + name: Unit Tests Ubuntu:24.04 + runs-on: ubuntu-latest + container: ubuntu:24.04 + if: >- + github.event_name != 'workflow_run' || + (github.event.workflow_run.conclusion == 'success' && + github.event.workflow_run.event == 'pull_request') steps: - - uses: actions/checkout@master + - uses: actions/checkout@v6 + with: + ref: ${{ github.event.workflow_run.head_sha }} - name: install dependencies # Note that perl is for trick-gte which TrickOps runs and qt and everything after it is for koviz run: | @@ -65,10 +67,16 @@ jobs: trickops-tests-rockylinux8: name: Unit Tests RockyLinux8 - runs-on: ubuntu-22.04 + runs-on: ubuntu-latest container: rockylinux:8 + if: >- + github.event_name != 'workflow_run' || + (github.event.workflow_run.conclusion == 'success' && + github.event.workflow_run.event == 'pull_request') steps: - - uses: actions/checkout@master + - uses: actions/checkout@v6 + with: + ref: ${{ github.event.workflow_run.head_sha }} - name: install dependencies # Note that perl is for trick-gte which TrickOps runs and qt and everything after it is for koviz run: | From a967f85620939d8ea60423f8ecef77afcb321644 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Fri, 10 Apr 2026 15:14:43 -0500 Subject: [PATCH 05/38] ci: single-file ci! --- .github/workflows/ci.yml | 484 ++++++++++++++++++++++++++++ .github/workflows/code_coverage.yml | 92 ------ .github/workflows/report_linux.yml | 27 -- .github/workflows/report_macos.yml | 22 -- .github/workflows/style.yml | 40 --- .github/workflows/test_linux.yml | 229 ------------- .github/workflows/test_macos.yml | 78 ----- .github/workflows/trickops.yml | 111 ------- 8 files changed, 484 insertions(+), 599 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/code_coverage.yml delete mode 100644 .github/workflows/report_linux.yml delete mode 100644 .github/workflows/report_macos.yml delete mode 100644 .github/workflows/style.yml delete mode 100644 .github/workflows/test_linux.yml delete mode 100644 .github/workflows/test_macos.yml delete mode 100644 .github/workflows/trickops.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 000000000..a73bb259c --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,484 @@ +name: CI + +on: + push: + branches: + - master + paths-ignore: + - "docs/**" + - "Formula/**" + pull_request: + paths-ignore: + - "docs/**" + - "Formula/**" + workflow_dispatch: + +permissions: + contents: read + checks: write + actions: read + +concurrency: + group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} + cancel-in-progress: true + +# ────────────────────────────────────────────────────────────────────────────── +# Stage 1: Style checks +# ────────────────────────────────────────────────────────────────────────────── + +jobs: + style: + name: Style Check + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v6 + with: + fetch-depth: 0 + + - name: Install clang-format + run: | + sudo apt-get update -qq + sudo apt-get install -y clang-format + + - name: Check formatting of changed lines + run: | + set -euo pipefail + + if [ "${{ github.event_name }}" = "pull_request" ]; then + BASE=${{ github.event.pull_request.base.sha }} + else + git fetch origin master + BASE=$(git merge-base origin/master HEAD) + fi + + DIFF=$(git clang-format --diff "$BASE" --extensions c,h,cpp,hpp,cc,hh) + + if echo "$DIFF" | grep -q '^diff'; then + echo "$DIFF" + echo "" + echo "::error::Changed lines are not correctly formatted." + echo "::error::To fix, run: git clang-format ${{ github.base_ref || 'master' }}" + exit 1 + fi + echo "All changed C/C++ lines are correctly formatted." + + # TODO: Once the codebase is fully formatted, switch to whole-file checking: + # + # - name: Check formatting of changed files + # run: | + # set -euo pipefail + # + # if [ "${{ github.event_name }}" = "pull_request" ]; then + # BASE=${{ github.event.pull_request.base.sha }} + # else + # git fetch origin master + # BASE=$(git merge-base origin/master HEAD) + # fi + # + # FAILED=0 + # while IFS= read -r f; do + # [ -z "$f" ] && continue + # if ! clang-format -n --Werror --style=file "$f"; then + # echo "::error file=$f::$f is not correctly formatted." + # FAILED=1 + # fi + # done < <(git diff --diff-filter=ACMR --name-only "$BASE" -- \ + # '*.[hc]pp' '*.cc' '*.[ch]' '*.hh') + # + # if [ $FAILED -ne 0 ]; then + # echo "" + # echo "::error::To fix, run: clang-format -i --style=file " + # exit 1 + # fi + # echo "All changed C/C++ files are correctly formatted." + + # ────────────────────────────────────────────────────────────────────────── + # Stage 2: Build & test + # ────────────────────────────────────────────────────────────────────────── + + test-linux: + name: Linux (${{ matrix.cfg.os }} ${{ matrix.cfg.tag }}) + needs: [style] + runs-on: ubuntu-latest + container: docker://${{ matrix.cfg.image }}:${{ matrix.cfg.tag }} + strategy: + fail-fast: false + matrix: + cfg: + - { + os: ubuntu, + tag: 24.04, + arch: debian, + arch_ver: 12, + image: ubuntu, + } + - { + os: oraclelinux, + tag: 8, + arch: rhel, + arch_ver: 8, + image: oraclelinux, + } + - { + os: rockylinux, + tag: 8, + arch: rhel, + arch_ver: 8, + image: rockylinux/rockylinux, + } + - { + os: rockylinux, + tag: 9, + arch: rhel, + arch_ver: 9, + image: rockylinux/rockylinux, + } + - { + os: rockylinux, + tag: 10, + arch: rhel, + arch_ver: 10, + image: rockylinux/rockylinux, + } + include: + - cfg: {} + deps: >- + bison + clang + flex + git + llvm + make + maven + cmake + zip + gdb + install_gtest: echo gtest already installed + conf_pkg: echo package manager already configured + install_cmd: install -y + + #-------- Debian-based Dependencies ---------------- + - cfg: { arch: debian } + pkg_mgr: apt-get + conf_pkg: apt-get update + arch_deps: >- + swig + curl + g++ + libx11-dev + libxml2-dev + libxt-dev + libmotif-common + libmotif-dev + zlib1g-dev + llvm-dev + libclang-dev + libudunits2-dev + libgtest-dev + default-jdk + python3-dev + python3-pip + python3-venv + install_gtest: | + apt-get install -y libgtest-dev libgmock-dev + cd /usr/src/gtest + cmake . + make + cp lib/libgtest* /usr/lib/ + + #-------- RHEL-based Dependencies (all versions) ---------------- + - cfg: { arch: rhel } + pkg_mgr: dnf + conf_pkg: | + dnf -y install epel-release + dnf -y update + dnf install -y 'dnf-command(config-manager)' + arch_deps: >- + clang-devel + diffutils + gcc + gcc-c++ + java-21-openjdk-devel + libxml2-devel + llvm-devel + llvm-static + ncurses-devel + openmotif + openmotif-devel + perl + perl-Digest-MD5 + swig + udunits2 + udunits2-devel + which + zlib-devel + python3-devel + + #-------- RHEL 8-only Dependencies ---------------- + - cfg: { arch: rhel, arch_ver: 8 } + install_gtest: | + dnf config-manager --enable powertools + dnf install -y gtest-devel gmock-devel + + #-------- RHEL 9-only Dependencies ---------------- + - cfg: { arch: rhel, arch_ver: 9 } + conf_pkg: | + dnf -y install epel-release + dnf -y update + dnf install -y 'dnf-command(config-manager)' + dnf config-manager --enable crb + install_gtest: | + dnf install -y gtest-devel gmock-devel + + #-------- RHEL 10-only Dependencies ---------------- + - cfg: { arch: rhel, arch_ver: 10 } + conf_pkg: | + dnf -y install epel-release + dnf -y update + dnf install -y 'dnf-command(config-manager)' + dnf config-manager --enable crb + install_gtest: | + dnf install -y gtest-devel gmock-devel + + #-------- OL 8 Dependencies ---------------- + - cfg: { os: oraclelinux, arch_ver: 8 } + install_gtest: | + dnf config-manager --enable ol8_codeready_builder + dnf install -y gtest-devel gmock-devel + + steps: + - name: Set noninteractive mode + run: echo "DEBIAN_FRONTEND=noninteractive" >> "$GITHUB_ENV" + if: matrix.cfg.arch == 'debian' + - name: Update Package Manager + run: ${{ matrix.conf_pkg }} + - name: Install Dependencies + run: > + ${{ matrix.pkg_mgr }} + ${{ matrix.install_cmd }} + ${{ matrix.deps }} + ${{ matrix.arch_deps }} + - name: Install GTest + run: ${{ matrix.install_gtest }} + - name: Checkout repository + uses: actions/checkout@v6 + - name: Configure Trick + run: | + export MAKEFLAGS=-j`nproc` + ./configure + - name: Build Trick + run: | + export MAKEFLAGS=-j`nproc` + export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) + make + - name: Test + run: | + cd share/trick/trickops/ + python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt + cd ../../../; make test + - name: Upload Tests + uses: actions/upload-artifact@v7 + if: success() || failure() + with: + name: Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} + path: trick_test/*.xml + if-no-files-found: warn + retention-days: 1 + + test-macos: + name: macOS + needs: [style] + runs-on: macos-15 + steps: + - name: Checkout repository + uses: actions/checkout@v6 + # Install googletest version 1.17.0 — the latest stable release as of 6/6/25 + # Note: Need to periodically update googletest version to ensure tests can run + # against the latest. + # Specifying the version to ensure CI builds are stable and not unexpectedly + # broken by upstream changes. + - name: Install gtest 1.17.0 + run: | + wget https://github.com/google/googletest/archive/refs/tags/v1.17.0.tar.gz + tar -xvf v1.17.0.tar.gz + cd googletest-1.17.0 + cmake -S . -B build -DCMAKE_INSTALL_PREFIX=/opt/homebrew + cmake --build build + sudo cmake --install build + - name: Install dependencies + run: | + brew update + brew upgrade || true + brew install --cask xquartz + brew install udunits openmotif maven + brew install swig llvm + - name: Build Trick + run: | + export MAKEFLAGS=-j4 + ./configure + make + - name: Test + run: | + cd share/trick/trickops/ + python3 -m venv .venv && source .venv/bin/activate && pip3 install -r requirements.txt + export MAKEFLAGS=-j4 + cd ../../../; make test + - name: Upload Tests + uses: actions/upload-artifact@v7 + if: success() || failure() + with: + name: Trick_macos + path: trick_test/*.xml + if-no-files-found: warn + retention-days: 1 + + trickops: + name: TrickOps (${{ matrix.name }}) + needs: [style] + runs-on: ubuntu-latest + container: ${{ matrix.image }} + strategy: + fail-fast: false + matrix: + include: + - name: Ubuntu 24.04 + image: ubuntu:24.04 + install: | + export DEBIAN_FRONTEND=noninteractive + apt-get update + apt-get install -y git python3 python3-venv perl perl-modules-5.38 qtbase5-dev wget unzip g++ make flex bison + qmake: qmake + - name: RockyLinux 8 + image: rockylinux:8 + install: | + dnf install -y git python3-devel which perl perl-Digest-MD5 qt5-qtbase-devel bison clang flex make gcc gcc-c++ wget + qmake: qmake-qt5 + defaults: + run: + shell: bash + steps: + - name: Checkout repository + uses: actions/checkout@v6 + - name: Install dependencies + run: ${{ matrix.install }} + - name: Create virtual environment + run: | + cd share/trick/trickops/ + python3 -m venv .venv && source .venv/bin/activate && pip3 install --upgrade pip && pip3 install -r requirements.txt + - name: Build koviz + run: | + cd /tmp/ && wget -q https://github.com/nasa/koviz/archive/refs/heads/master.zip && unzip master.zip + cd /tmp/koviz-master/ && ${{ matrix.qmake }} && make + - name: Run unit and doc tests + run: | + cd share/trick/trickops/tests/ + source ../.venv/bin/activate + export PATH="/tmp/koviz-master/bin:${PATH}" + ./run_tests.py + - name: Upload test logs + uses: actions/upload-artifact@v7 + if: always() + with: + name: trickops_${{ strategy.job-index }} + path: | + share/trick/trickops/tests/*_doctest_log.txt + /tmp/log.* + + code-coverage: + name: Code Coverage + needs: [style] + runs-on: ubuntu-latest + container: docker://oraclelinux:8 + env: + CFLAGS: "-fprofile-arcs -ftest-coverage -O0" + CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_CFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_SYSTEM_LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_SYSTEM_CFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_SYSTEM_CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + steps: + - name: Update Package Manager + run: | + dnf -y install epel-release + dnf -y update + dnf install -y 'dnf-command(config-manager)' + + - name: Install Dependencies + run: | + dnf install -y bison clang flex git llvm make maven cmake zip clang-devel gcc gcc-c++ java-11-openjdk-devel libxml2-devel llvm-devel llvm-static ncurses-devel openmotif openmotif-devel perl perl-Digest-MD5 udunits2 udunits2-devel which zlib-devel python2-devel python3-devel swig diffutils lcov + + - name: Install GTest + run: | + dnf config-manager --enable ol8_codeready_builder + dnf install -y gtest-devel gmock-devel + + - name: Checkout repository + uses: actions/checkout@v6 + + - name: Configure Trick + run: | + export MAKEFLAGS=-j`nproc` + export PYTHON_VERSION=3 + ./configure + - name: Build Trick + run: | + export MAKEFLAGS=-j`nproc` + export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) + make + - name: Generate Code Coverage + run: | + export MAKEFLAGS=-j`nproc` + cd share/trick/trickops/ + python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt + cd ../../../ + make code-coverage + - name: Upload to Coveralls + uses: coverallsapp/github-action@v2 + continue-on-error: true + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + path-to-lcov: "./coverage.info" + + # ────────────────────────────────────────────────────────────────────────── + # Stage 3: Report results + # ────────────────────────────────────────────────────────────────────────── + + report-linux: + name: Report (${{ matrix.cfg.os }} ${{ matrix.cfg.tag }}) + needs: [test-linux] + if: always() + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + cfg: + - { os: ubuntu, tag: 24.04 } + - { os: oraclelinux, tag: 8 } + - { os: rockylinux, tag: 8 } + - { os: rockylinux, tag: 9 } + - { os: rockylinux, tag: 10 } + steps: + - name: Publish Test Report + uses: dorny/test-reporter@v2 + with: + artifact: Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} + name: Results_Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} + path: "*.xml" + reporter: java-junit + + report-macos: + name: Report (macOS) + needs: [test-macos] + if: always() + runs-on: ubuntu-latest + steps: + - name: Publish Test Report + uses: dorny/test-reporter@v2 + with: + artifact: Trick_macos + name: Results_Trick_macos + path: "*.xml" + reporter: java-junit diff --git a/.github/workflows/code_coverage.yml b/.github/workflows/code_coverage.yml deleted file mode 100644 index d49f8cec0..000000000 --- a/.github/workflows/code_coverage.yml +++ /dev/null @@ -1,92 +0,0 @@ -name: Code Coverage - -on: - push: - branches: - - master - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/code_coverage.yml" - - "!Formula/**" - workflow_run: - workflows: ["Style"] - types: [completed] - workflow_dispatch: - -concurrency: - # On PRs, cancel in-progress runs on the same branch when new commits are pushed. - # On master and workflow_dispatch, head_ref is undefined so run_id is used as fallback, - # which is unique per run and prevents any cancellation. - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - code-coverage: - runs-on: ubuntu-latest - container: docker://oraclelinux:8 - if: >- - github.event_name != 'workflow_run' || - (github.event.workflow_run.conclusion == 'success' && - github.event.workflow_run.event == 'pull_request') - steps: - - name: Update Package Manager - run: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - - - name: Install Dependencies - run: | - dnf install -y bison clang flex git llvm make maven cmake zip clang-devel gcc gcc-c++ java-11-openjdk-devel libxml2-devel llvm-devel llvm-static ncurses-devel openmotif openmotif-devel perl perl-Digest-MD5 udunits2 udunits2-devel which zlib-devel python2-devel python3-devel swig diffutils lcov - - - name: Install GTest - run: | - dnf config-manager --enable ol8_codeready_builder - dnf install -y gtest-devel gmock-devel - - - name: Checkout repository - uses: actions/checkout@v6 - with: - ref: ${{ github.event.workflow_run.head_sha }} - - - name: Configure Trick - run: | - export MAKEFLAGS=-j`nproc` - export PYTHON_VERSION=3 - ./configure - - name: Build Trick - run: | - export MAKEFLAGS=-j`nproc` - export CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - export LDFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_LDFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - make - - name: Generate Code Coverage - run: | - export MAKEFLAGS=-j`nproc` - export CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - export LDFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_LDFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_CFLAGS="-fprofile-arcs -ftest-coverage -O0" - export TRICK_SYSTEM_CXXFLAGS="-fprofile-arcs -ftest-coverage -O0" - cd share/trick/trickops/ - python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt - cd ../../../ - make code-coverage - - name: Upload to Coveralls - uses: coverallsapp/github-action@master - continue-on-error: true - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - path-to-lcov: "./coverage.info" diff --git a/.github/workflows/report_linux.yml b/.github/workflows/report_linux.yml deleted file mode 100644 index 64dad0f12..000000000 --- a/.github/workflows/report_linux.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: "Report Linux" -on: - workflow_run: - workflows: ["Linux"] # runs after CI workflow - types: - - completed -jobs: - report: - strategy: - fail-fast: false - matrix: - cfg: - #-------- Operating Systems ---------------- - - { os: ubuntu, tag: 24.04, arch: debian, arch_ver: 12 } - - { os: oraclelinux, tag: 8, arch: rhel, arch_ver: 8 } - - { os: rockylinux, tag: 8, arch: rhel, arch_ver: 8 } - - { os: rockylinux, tag: 9, arch: rhel, arch_ver: 9 } - - { os: rockylinux, tag: 10, arch: rhel, arch_ver: 10 } - - runs-on: ubuntu-latest - steps: - - uses: dorny/test-reporter@v2 - with: - artifact: Trick_${{matrix.cfg.os}}${{matrix.cfg.tag}} # artifact name - name: Results_Trick_${{matrix.cfg.os}}${{matrix.cfg.tag}} # Name of the check run which will be created - path: "*.xml" # Path to test results (inside artifact .zip) - reporter: java-junit # Format of test results diff --git a/.github/workflows/report_macos.yml b/.github/workflows/report_macos.yml deleted file mode 100644 index 360d3f9a2..000000000 --- a/.github/workflows/report_macos.yml +++ /dev/null @@ -1,22 +0,0 @@ -name: "Report macOS" - -on: - workflow_run: - workflows: ["macOS"] # runs after CI workflow - types: - - completed -jobs: - report: - runs-on: ubuntu-latest - permissions: - actions: read # Allow reading actions - checks: write # Allow creating check runs - steps: - - name: Publish Test Report - uses: dorny/test-reporter@v2 - with: - # Match artifact from the specific attempt that triggered this report - artifact: Trick_macos_attempt_${{ github.event.workflow_run.run_attempt }} - name: Results_Trick_macos # Name of the check run which will be created - path: "*.xml" # Path to test results (inside the artifact .zip) - reporter: java-junit # Format of test results diff --git a/.github/workflows/style.yml b/.github/workflows/style.yml deleted file mode 100644 index 5e5a949fb..000000000 --- a/.github/workflows/style.yml +++ /dev/null @@ -1,40 +0,0 @@ -name: Style - -on: - pull_request: - workflow_dispatch: - -permissions: - contents: read - -concurrency: - group: style-${{ github.ref }} - cancel-in-progress: true - -jobs: - clang-format: - name: clang-format - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v6 - with: - fetch-depth: 0 - - - name: Install clang-format - run: | - sudo apt-get update -qq - sudo apt-get install -y clang-format clang-format - - - name: Check formatting of changed lines - run: | - BASE=$(git merge-base HEAD origin/${{ github.base_ref }}) - DIFF=$(git clang-format --diff "$BASE") - if echo "$DIFF" | grep -q '^diff'; then - echo "$DIFF" - echo "" - echo "::error::Changed C/C++ lines are not correctly formatted." - echo "::error::To fix, run: git clang-format ${{ github.base_ref }}" - exit 1 - fi - echo "All changed C/C++ files are correctly formatted." diff --git a/.github/workflows/test_linux.yml b/.github/workflows/test_linux.yml deleted file mode 100644 index 1ef0e0144..000000000 --- a/.github/workflows/test_linux.yml +++ /dev/null @@ -1,229 +0,0 @@ -name: Linux - -on: - push: - branches: - - master - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/test_linux.yml" - - "!Formula/**" - workflow_run: - workflows: ["Style"] - types: [completed] - workflow_dispatch: - -concurrency: - # On PRs, cancel in-progress runs on the same branch when new commits are pushed. - # On master and workflow_dispatch, head_ref is undefined so run_id is used as fallback, - # which is unique per run and prevents any cancellation. - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - build: - strategy: - fail-fast: false - matrix: - cfg: - #-------- Operating Systems ---------------- - - { - os: ubuntu, - tag: 24.04, - arch: debian, - arch_ver: 12, - image: ubuntu, - } - - { - os: oraclelinux, - tag: 8, - arch: rhel, - arch_ver: 8, - image: oraclelinux, - } - - { - os: rockylinux, - tag: 8, - arch: rhel, - arch_ver: 8, - image: rockylinux/rockylinux, - } - - { - os: rockylinux, - tag: 9, - arch: rhel, - arch_ver: 9, - image: rockylinux/rockylinux, - } - - { - os: rockylinux, - tag: 10, - arch: rhel, - arch_ver: 10, - image: rockylinux/rockylinux, - } - #-------- Defaults -------------------------- - include: - - cfg: {} - deps: >- - bison - clang - flex - git - llvm - make - maven - cmake - zip - gdb - install_gtest: echo gtest already installed - conf_pkg: echo package manager already configured - install_cmd: install -y - - #-------- Debian-based Dependencies ---------------- - - cfg: { arch: debian } - pkg_mgr: apt-get - conf_pkg: apt-get update - arch_deps: >- - swig - curl - g++ - libx11-dev - libxml2-dev - libxt-dev - libmotif-common - libmotif-dev - zlib1g-dev - llvm-dev - libclang-dev - libudunits2-dev - libgtest-dev - default-jdk - python3-dev - python3-pip - python3-venv - install_gtest: | - apt-get install -y libgtest-dev libgmock-dev - cd /usr/src/gtest - cmake . - make - cp lib/libgtest* /usr/lib/ - - #-------- RHEL-based Dependencies (all versions) ---------------- - - cfg: { arch: rhel } - pkg_mgr: dnf - conf_pkg: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - arch_deps: >- - clang-devel - diffutils - gcc - gcc-c++ - java-21-openjdk-devel - libxml2-devel - llvm-devel - llvm-static - ncurses-devel - openmotif - openmotif-devel - perl - perl-Digest-MD5 - swig - udunits2 - udunits2-devel - which - zlib-devel - python3-devel - - #-------- RHEL 8-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 8 } - install_gtest: | - dnf config-manager --enable powertools - dnf install -y gtest-devel gmock-devel - - #-------- RHEL 9-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 9 } - conf_pkg: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - dnf config-manager --enable crb - install_gtest: | - dnf install -y gtest-devel gmock-devel - - #-------- RHEL 10-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 10 } - conf_pkg: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - dnf config-manager --enable crb - install_gtest: | - dnf install -y gtest-devel gmock-devel - - #-------- OL 8 Dependencies ---------------- - - cfg: { os: oraclelinux, arch_ver: 8 } - install_gtest: | - dnf config-manager --enable ol8_codeready_builder - dnf install -y gtest-devel gmock-devel - - #-------- Job definition ---------------- - runs-on: ubuntu-latest - container: docker://${{matrix.cfg.image}}:${{matrix.cfg.tag}} - if: >- - github.event_name != 'workflow_run' || - (github.event.workflow_run.conclusion == 'success' && - github.event.workflow_run.event == 'pull_request') - steps: - - name: Update Package Manager - run: ${{matrix.conf_pkg}} - - name: Install Dependencies - run: > - ${{matrix.pkg_mgr}} - ${{matrix.install_cmd}} - ${{matrix.deps}} - ${{matrix.arch_deps}} - - name: Install GTest - run: ${{matrix.install_gtest}} - - name: Checkout repository - uses: actions/checkout@v6 - with: - ref: ${{ github.event.workflow_run.head_sha }} - - name: Configure Trick - run: | - export MAKEFLAGS=-j`nproc` - ./configure - - name: Build Trick - run: | - export MAKEFLAGS=-j`nproc` - export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - make - - name: Test - run: | - cd share/trick/trickops/ - python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt - cd ../../../; make test - - name: Upload Tests - uses: actions/upload-artifact@v7 - if: success() || failure() # run this step even if previous step failed - with: - name: Trick_${{matrix.cfg.os}}${{matrix.cfg.tag}} - path: trick_test/*.xml - retention-days: 1 - -# Uncomment for build artifacts -# - name: Upload Trick Build -# uses: actions/upload-artifact@v3.0.0 -# with: -# name: Trick_${{matrix.cfg.os}}${{matrix.cfg.tag}} -# path: | -# bin -# include -# lib -# share -# libexec -# retention-days: 1 diff --git a/.github/workflows/test_macos.yml b/.github/workflows/test_macos.yml deleted file mode 100644 index e6d62d1c4..000000000 --- a/.github/workflows/test_macos.yml +++ /dev/null @@ -1,78 +0,0 @@ -name: macOS - -on: - push: - branches: - - master - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/test_macos.yml" - - "!Formula/**" - workflow_run: - workflows: ["Style"] - types: [completed] - workflow_dispatch: - -concurrency: - # On PRs, cancel in-progress runs on the same branch when new commits are pushed. - # On master and workflow_dispatch, head_ref is undefined so run_id is used as fallback, - # which is unique per run and prevents any cancellation. - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -jobs: - macOS: - runs-on: macos-15 - if: >- - github.event_name != 'workflow_run' || - (github.event.workflow_run.conclusion == 'success' && - github.event.workflow_run.event == 'pull_request') - steps: - - name: Checkout repository - uses: actions/checkout@v6 - with: - ref: ${{ github.event.workflow_run.head_sha }} - # Install googletest version 1.17.0 — the latest stable release as of 6/6/25 - # Note: Need to periodically update googletest version to ensure tests can run - # against the latest. - # Specifying the version to ensure CI builds are stable and not unexpectedly - # broken by upstream changes. - - name: Install gtest 1.17.0 - run: | - wget https://github.com/google/googletest/archive/refs/tags/v1.17.0.tar.gz - tar -xvf v1.17.0.tar.gz - cd googletest-1.17.0 - cmake -S . -B build -DCMAKE_INSTALL_PREFIX=/opt/homebrew - cmake --build build - sudo cmake --install build - - name: Install dependencies - run: | - brew update - brew upgrade || true - brew install --cask xquartz - brew install udunits openmotif maven - brew install swig llvm - - name: Build Trick - run: | - export MAKEFLAGS=-j4 - # Image YAML labels macos-14 and macos-15 use arm64, while macos-13 is intel-based. - # The configure script has been updated to find /opt/homebrew automatically for arm64 as of 6/6/25 - # Please note that if using the intel one, --with-xxx options are needed to specify the path - ./configure - make - - name: Test - run: | - cd share/trick/trickops/ - python3 -m venv .venv && source .venv/bin/activate && pip3 install -r requirements.txt - export MAKEFLAGS=-j4 - cd ../../../; make test - - name: Upload Tests - uses: actions/upload-artifact@v7 - if: success() || failure() # run this step even if previous step failed - with: - # Include run attempt in artifact name so report workflow can fetch the latest attempt - name: Trick_macos_attempt_${{ github.run_attempt }} - path: trick_test/*.xml - retention-days: 1 diff --git a/.github/workflows/trickops.yml b/.github/workflows/trickops.yml deleted file mode 100644 index 756a883e2..000000000 --- a/.github/workflows/trickops.yml +++ /dev/null @@ -1,111 +0,0 @@ -name: TrickOps - -on: - push: - branches: - - master - paths: - - "**" - - "!docs/**" - - "!.github/workflows/**" - - ".github/workflows/trickops.yml" - - "!Formula/**" - workflow_run: - workflows: ["Style"] - types: [completed] - workflow_dispatch: - -concurrency: - # On PRs, cancel in-progress runs on the same branch when new commits are pushed. - # On master and workflow_dispatch, head_ref is undefined so run_id is used as fallback, - # which is unique per run and prevents any cancellation. - group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} - cancel-in-progress: true - -defaults: - run: - shell: bash - -jobs: - trickops-tests-ubuntu: - name: Unit Tests Ubuntu:24.04 - runs-on: ubuntu-latest - container: ubuntu:24.04 - if: >- - github.event_name != 'workflow_run' || - (github.event.workflow_run.conclusion == 'success' && - github.event.workflow_run.event == 'pull_request') - steps: - - uses: actions/checkout@v6 - with: - ref: ${{ github.event.workflow_run.head_sha }} - - name: install dependencies - # Note that perl is for trick-gte which TrickOps runs and qt and everything after it is for koviz - run: | - export DEBIAN_FRONTEND=noninteractive && apt-get update && apt-get install -y git python3 python3-venv perl perl-modules-5.34 qtbase5-dev wget unzip g++ make flex bison - - name: create virtual environment - run: | - cd share/trick/trickops/ - python3 -m venv .venv && source .venv/bin/activate && pip3 install --upgrade pip && pip3 install -r requirements.txt - - name: get and build koviz - run: | - cd /tmp/ && wget -q https://github.com/nasa/koviz/archive/refs/heads/master.zip && unzip master.zip - cd /tmp/koviz-master/ && qmake && make - - name: run unit and doc tests - run: | - cd share/trick/trickops/tests/ - source ../.venv/bin/activate - export PATH="/tmp/koviz-master/bin:${PATH}" - ./run_tests.py - - uses: actions/upload-artifact@v4 - if: ${{ always() }} - with: - name: doctests_${{ github.run_id }}_${{ github.job }} - path: | - share/trick/trickops/tests/*_doctest_log.txt - /tmp/log.* - - trickops-tests-rockylinux8: - name: Unit Tests RockyLinux8 - runs-on: ubuntu-latest - container: rockylinux:8 - if: >- - github.event_name != 'workflow_run' || - (github.event.workflow_run.conclusion == 'success' && - github.event.workflow_run.event == 'pull_request') - steps: - - uses: actions/checkout@v6 - with: - ref: ${{ github.event.workflow_run.head_sha }} - - name: install dependencies - # Note that perl is for trick-gte which TrickOps runs and qt and everything after it is for koviz - run: | - dnf install -y git python3-devel which perl perl-Digest-MD5 qt5-qtbase-devel bison clang flex make gcc gcc-c++ wget - - name: create virtual environment - run: | - cd share/trick/trickops/ - python3 -m venv .venv && source .venv/bin/activate && pip3 install -r requirements.txt - - name: get and build koviz - run: | - cd /tmp/ && wget -q https://github.com/nasa/koviz/archive/refs/heads/master.zip && unzip master.zip - cd /tmp/koviz-master/ && qmake-qt5 && make - - name: run unit and doc tests - run: | - cd share/trick/trickops/tests/ - source ../.venv/bin/activate - export PATH="/tmp/koviz-master/bin:${PATH}" - ./run_tests.py - - uses: actions/upload-artifact@v7 - if: ${{ always() }} - with: - name: doctests_${{ github.run_id }}_${{ github.job }} - path: | - share/trick/trickops/tests/*_doctest_log.txt - /tmp/log.* - -# TODO: ExampleWorkflow.py is not included here because it needs a built Trick -# to function correctly and I don't want to duplicate the Trick build testing -# here to provide testing of what is essentially an example provided for -# documentation purposes. If we could leverage artifacts from a previous -# stage and/or stable containers where Trick is already pre-built, we should -# consider adding ExampleWorfklow.py to testing in this file. -Jordan 4/2021 From 3b218bb505d9daa5d7a1a73e2408e92efc05c21a Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Fri, 10 Apr 2026 15:38:28 -0500 Subject: [PATCH 06/38] ci: add perl formatting --- .github/workflows/ci.yml | 47 ++++++++++++++++++++++++++++++++++++++-- .perltidyrc | 15 +++++++++++++ 2 files changed, 60 insertions(+), 2 deletions(-) create mode 100644 .perltidyrc diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a73bb259c..e5de9f693 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,10 +36,10 @@ jobs: with: fetch-depth: 0 - - name: Install clang-format + - name: Install tools run: | sudo apt-get update -qq - sudo apt-get install -y clang-format + sudo apt-get install -y clang-format perltidy - name: Check formatting of changed lines run: | @@ -63,6 +63,49 @@ jobs: fi echo "All changed C/C++ lines are correctly formatted." + - name: Check perltidy on changed Perl files + run: | + set -euo pipefail + + if [ "${{ github.event_name }}" = "pull_request" ]; then + BASE=${{ github.event.pull_request.base.sha }} + else + git fetch origin master + BASE=$(git merge-base origin/master HEAD) + fi + + # Collect changed Perl files: by extension and by shebang + PERL_FILES=() + while IFS= read -r f; do + [ -z "$f" ] && continue + case "$f" in + *.pl|*.pm|*.t) PERL_FILES+=("$f") ;; + *) if head -1 "$f" 2>/dev/null | grep -q '^#!.*perl'; then + PERL_FILES+=("$f") + fi ;; + esac + done < <(git diff --diff-filter=ACMR --name-only "$BASE") + + if [ ${#PERL_FILES[@]} -eq 0 ]; then + echo "No changed Perl files to check." + exit 0 + fi + + FAILED=0 + for f in "${PERL_FILES[@]}"; do + if ! perltidy -st -se -nb "$f" | diff -u "$f" -; then + echo "::error file=$f::$f is not perltidy-compliant." + FAILED=1 + fi + done + + if [ $FAILED -ne 0 ]; then + echo "" + echo "::error::To fix, run: perltidy -b " + exit 1 + fi + echo "All changed Perl files are correctly formatted." + # TODO: Once the codebase is fully formatted, switch to whole-file checking: # # - name: Check formatting of changed files diff --git a/.perltidyrc b/.perltidyrc new file mode 100644 index 000000000..2abc0114a --- /dev/null +++ b/.perltidyrc @@ -0,0 +1,15 @@ +# .perltidyrc — Trick project Perl formatting rules +-l=100 +-i=4 +-ci=4 +-xci +-mci +-nst +-b +-bext='/' +-se +-nolq +-pt=1 +-sbt=1 +-bt=1 +-conv From c32cfe9749b35a7eefba626bf44b58c351dd31ff Mon Sep 17 00:00:00 2001 From: brendan Date: Tue, 14 Apr 2026 19:16:16 -0500 Subject: [PATCH 07/38] Update .clang-format for alignment and brace style --- .clang-format | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.clang-format b/.clang-format index 9fd640b7a..fe45aace2 100644 --- a/.clang-format +++ b/.clang-format @@ -1,5 +1,9 @@ --- BasedOnStyle: WebKit +AlignConsecutiveAssignments: AcrossEmptyLines +AlignTrailingComments: + Kind: Always +BreakBeforeBraces: Allman IncludeBlocks: Regroup IncludeCategories: - Regex: '^("|<)trick/' From 25af92927259d99b425c723f93f9289b1a7c5c02 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 22 Apr 2026 17:29:54 -0500 Subject: [PATCH 08/38] ci: split test-reports off from CI to account for forks --- .github/workflows/ci.yml | 47 ++----------------------------- .github/workflows/test-report.yml | 29 +++++++++++++++++++ 2 files changed, 31 insertions(+), 45 deletions(-) create mode 100644 .github/workflows/test-report.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e5de9f693..ea5473085 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,8 +15,6 @@ on: permissions: contents: read - checks: write - actions: read concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} @@ -322,7 +320,7 @@ jobs: cd ../../../; make test - name: Upload Tests uses: actions/upload-artifact@v7 - if: success() || failure() + if: ${{ !cancelled() }} with: name: Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} path: trick_test/*.xml @@ -369,7 +367,7 @@ jobs: cd ../../../; make test - name: Upload Tests uses: actions/upload-artifact@v7 - if: success() || failure() + if: ${{ !cancelled() }} with: name: Trick_macos path: trick_test/*.xml @@ -484,44 +482,3 @@ jobs: with: github-token: ${{ secrets.GITHUB_TOKEN }} path-to-lcov: "./coverage.info" - - # ────────────────────────────────────────────────────────────────────────── - # Stage 3: Report results - # ────────────────────────────────────────────────────────────────────────── - - report-linux: - name: Report (${{ matrix.cfg.os }} ${{ matrix.cfg.tag }}) - needs: [test-linux] - if: always() - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - cfg: - - { os: ubuntu, tag: 24.04 } - - { os: oraclelinux, tag: 8 } - - { os: rockylinux, tag: 8 } - - { os: rockylinux, tag: 9 } - - { os: rockylinux, tag: 10 } - steps: - - name: Publish Test Report - uses: dorny/test-reporter@v2 - with: - artifact: Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} - name: Results_Trick_${{ matrix.cfg.os }}${{ matrix.cfg.tag }} - path: "*.xml" - reporter: java-junit - - report-macos: - name: Report (macOS) - needs: [test-macos] - if: always() - runs-on: ubuntu-latest - steps: - - name: Publish Test Report - uses: dorny/test-reporter@v2 - with: - artifact: Trick_macos - name: Results_Trick_macos - path: "*.xml" - reporter: java-junit diff --git a/.github/workflows/test-report.yml b/.github/workflows/test-report.yml new file mode 100644 index 000000000..6694ab2c2 --- /dev/null +++ b/.github/workflows/test-report.yml @@ -0,0 +1,29 @@ +name: Test Report + +on: + workflow_run: + workflows: [CI] + types: [completed] + +permissions: + contents: read + actions: read + checks: write + +jobs: + report: + name: Publish Test Results + runs-on: ubuntu-latest + if: ${{ github.event.workflow_run.conclusion != 'skipped' }} + steps: + - name: Publish Test Report + uses: dorny/test-reporter@v3 + with: + # Matches all Trick_* artifacts uploaded by the CI workflow. + artifact: /Trick_(.*)/ + name: Test Results ($1) + path: "*.xml" + reporter: java-junit + fail-on-error: false + fail-on-empty: false + max-annotations: 50 From c280dc53d26c03b3eed50defa298772cfb75a037 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 22 Apr 2026 18:00:18 -0500 Subject: [PATCH 09/38] add 120 column limit and remove empty lines --- .clang-format | 5 +++++ .perltidyrc | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.clang-format b/.clang-format index fe45aace2..f5852e346 100644 --- a/.clang-format +++ b/.clang-format @@ -4,6 +4,7 @@ AlignConsecutiveAssignments: AcrossEmptyLines AlignTrailingComments: Kind: Always BreakBeforeBraces: Allman +ColumnLimit: 120 IncludeBlocks: Regroup IncludeCategories: - Regex: '^("|<)trick/' @@ -16,4 +17,8 @@ IncludeCategories: Priority: 4 - Regex: ".*" Priority: 1 +KeepEmptyLines: + AtEndOfFile: false + AtStartOfBlock: false + AtStartOfFile: false ... diff --git a/.perltidyrc b/.perltidyrc index 2abc0114a..d37616d8d 100644 --- a/.perltidyrc +++ b/.perltidyrc @@ -1,5 +1,5 @@ # .perltidyrc — Trick project Perl formatting rules --l=100 +-l=120 -i=4 -ci=4 -xci From 02d47236cf7e4b101f304e8f4f9f63774f4a8710 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 11:42:01 -0500 Subject: [PATCH 10/38] Update makeflag handling --- .github/workflows/ci.yml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ea5473085..b32bc7aa7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -306,11 +306,10 @@ jobs: uses: actions/checkout@v6 - name: Configure Trick run: | - export MAKEFLAGS=-j`nproc` + echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" ./configure - name: Build Trick run: | - export MAKEFLAGS=-j`nproc` export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) make - name: Test @@ -331,6 +330,8 @@ jobs: name: macOS needs: [style] runs-on: macos-15 + env: + MAKEFLAGS: -j4 steps: - name: Checkout repository uses: actions/checkout@v6 @@ -356,14 +357,12 @@ jobs: brew install swig llvm - name: Build Trick run: | - export MAKEFLAGS=-j4 ./configure make - name: Test run: | cd share/trick/trickops/ python3 -m venv .venv && source .venv/bin/activate && pip3 install -r requirements.txt - export MAKEFLAGS=-j4 cd ../../../; make test - name: Upload Tests uses: actions/upload-artifact@v7 @@ -432,6 +431,7 @@ jobs: runs-on: ubuntu-latest container: docker://oraclelinux:8 env: + MAKEFLAGS: -j4 CFLAGS: "-fprofile-arcs -ftest-coverage -O0" CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" @@ -458,20 +458,14 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - - name: Configure Trick - run: | - export MAKEFLAGS=-j`nproc` - export PYTHON_VERSION=3 - ./configure + run: ./configure - name: Build Trick run: | - export MAKEFLAGS=-j`nproc` export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) make - name: Generate Code Coverage run: | - export MAKEFLAGS=-j`nproc` cd share/trick/trickops/ python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt cd ../../../ From c01c49345c1a8df4903c5d7a580daa6c957c01ee Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 11:42:24 -0500 Subject: [PATCH 11/38] Add Ubuntu 26 testing --- .github/workflows/ci.yml | 49 ++++++++-------------------------------- 1 file changed, 10 insertions(+), 39 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b32bc7aa7..3884bbfbf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -147,41 +147,12 @@ jobs: fail-fast: false matrix: cfg: - - { - os: ubuntu, - tag: 24.04, - arch: debian, - arch_ver: 12, - image: ubuntu, - } - - { - os: oraclelinux, - tag: 8, - arch: rhel, - arch_ver: 8, - image: oraclelinux, - } - - { - os: rockylinux, - tag: 8, - arch: rhel, - arch_ver: 8, - image: rockylinux/rockylinux, - } - - { - os: rockylinux, - tag: 9, - arch: rhel, - arch_ver: 9, - image: rockylinux/rockylinux, - } - - { - os: rockylinux, - tag: 10, - arch: rhel, - arch_ver: 10, - image: rockylinux/rockylinux, - } + - { os: ubuntu, tag: 24.04, arch: debian, image: ubuntu } + - { os: ubuntu, tag: 26.04, arch: debian, image: ubuntu } + - { os: oraclelinux, tag: 8, arch: rhel, image: oraclelinux } + - { os: rockylinux, tag: 8, arch: rhel, image: rockylinux/rockylinux } + - { os: rockylinux, tag: 9, arch: rhel, image: rockylinux/rockylinux } + - { os: rockylinux, tag: 10, arch: rhel, image: rockylinux/rockylinux } include: - cfg: {} deps: >- @@ -257,13 +228,13 @@ jobs: python3-devel #-------- RHEL 8-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 8 } + - cfg: { arch: rhel, tag: 8 } install_gtest: | dnf config-manager --enable powertools dnf install -y gtest-devel gmock-devel #-------- RHEL 9-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 9 } + - cfg: { arch: rhel, tag: 9 } conf_pkg: | dnf -y install epel-release dnf -y update @@ -273,7 +244,7 @@ jobs: dnf install -y gtest-devel gmock-devel #-------- RHEL 10-only Dependencies ---------------- - - cfg: { arch: rhel, arch_ver: 10 } + - cfg: { arch: rhel, tag: 10 } conf_pkg: | dnf -y install epel-release dnf -y update @@ -283,7 +254,7 @@ jobs: dnf install -y gtest-devel gmock-devel #-------- OL 8 Dependencies ---------------- - - cfg: { os: oraclelinux, arch_ver: 8 } + - cfg: { os: oraclelinux, tag: 8 } install_gtest: | dnf config-manager --enable ol8_codeready_builder dnf install -y gtest-devel gmock-devel From 963a7e6c186d52b7c4be0472543358f1569a90d8 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 11:42:49 -0500 Subject: [PATCH 12/38] Switch code-coverage to run on ubuntu-latest --- .github/workflows/ci.yml | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3884bbfbf..97d540ac3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -400,7 +400,6 @@ jobs: name: Code Coverage needs: [style] runs-on: ubuntu-latest - container: docker://oraclelinux:8 env: MAKEFLAGS: -j4 CFLAGS: "-fprofile-arcs -ftest-coverage -O0" @@ -412,21 +411,16 @@ jobs: TRICK_SYSTEM_CFLAGS: "-fprofile-arcs -ftest-coverage -O0" TRICK_SYSTEM_CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" steps: - - name: Update Package Manager - run: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - - name: Install Dependencies run: | - dnf install -y bison clang flex git llvm make maven cmake zip clang-devel gcc gcc-c++ java-11-openjdk-devel libxml2-devel llvm-devel llvm-static ncurses-devel openmotif openmotif-devel perl perl-Digest-MD5 udunits2 udunits2-devel which zlib-devel python2-devel python3-devel swig diffutils lcov - - - name: Install GTest - run: | - dnf config-manager --enable ol8_codeready_builder - dnf install -y gtest-devel gmock-devel - + sudo apt-get update -qq + sudo apt-get install -y \ + bison clang flex git llvm make maven cmake zip \ + g++ libclang-dev llvm-dev \ + default-jdk libxml2-dev libmotif-dev libxt-dev \ + perl libdigest-md5-perl libudunits2-dev zlib1g-dev \ + python3-dev python3-pip python3-venv swig \ + libgtest-dev libgmock-dev lcov - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick From 52688d86db8f9607b4f830374a8e6dff550b5e37 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 11:53:58 -0500 Subject: [PATCH 13/38] more fixes for flaky gh actions --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 97d540ac3..ca716259f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -321,7 +321,7 @@ jobs: sudo cmake --install build - name: Install dependencies run: | - brew update + brew update || true brew upgrade || true brew install --cask xquartz brew install udunits openmotif maven From 63adc624e0c13890e6fa87300ddf782f91481ba0 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 12:18:04 -0500 Subject: [PATCH 14/38] code-coverage: ignore errors --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 69423f6a4..b46933f90 100644 --- a/Makefile +++ b/Makefile @@ -335,7 +335,7 @@ extra-coverage-builds: @ $(MAKE) test -C trick_source/trick_utils/SAIntegrator code-coverage: test extra-coverage-builds - lcov --capture $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info + lcov --capture --ignore-errors mismatch $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From bad103bc3e16b66026a2e2f92d22ad7e2f23928c Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 12:32:39 -0500 Subject: [PATCH 15/38] Update test_client.hh --- .../SIM_mtv/models/test_client/test_client.hh | 28 ++++++++++++------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/test/SIM_mtv/models/test_client/test_client.hh b/test/SIM_mtv/models/test_client/test_client.hh index 7f66e1afa..647e2175f 100644 --- a/test/SIM_mtv/models/test_client/test_client.hh +++ b/test/SIM_mtv/models/test_client/test_client.hh @@ -2,6 +2,7 @@ #include #include +#include #include #include #include @@ -28,12 +29,8 @@ public: { } - int init(const std::string& host, int port) + int init(const std::string& host, int port, int timeout_sec = 10) { - _fd = socket(AF_INET, SOCK_STREAM, 0); - if (_fd < 0) - return -1; - struct sockaddr_in addr; memset(&addr, 0, sizeof(addr)); addr.sin_family = AF_INET; @@ -41,11 +38,22 @@ public: if (inet_pton(AF_INET, "127.0.0.1", &addr.sin_addr) <= 0) return -1; - if (connect(_fd, (struct sockaddr*)&addr, sizeof(addr)) < 0) - return -1; - - _ok = true; - return 0; + time_t deadline = time(nullptr) + timeout_sec; + while (time(nullptr) < deadline) + { + _fd = socket(AF_INET, SOCK_STREAM, 0); + if (_fd < 0) + return -1; + if (connect(_fd, (struct sockaddr*)&addr, sizeof(addr)) == 0) + { + _ok = true; + return 0; + } + ::close(_fd); + _fd = -1; + usleep(100000); // 100 ms between retries + } + return -1; } void close() From 02e0fcc20bcaeae6820dbf63bfd4c458aad86c77 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 12:34:28 -0500 Subject: [PATCH 16/38] Update .clang-format --- .clang-format | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.clang-format b/.clang-format index f5852e346..eaecc7ed6 100644 --- a/.clang-format +++ b/.clang-format @@ -17,8 +17,4 @@ IncludeCategories: Priority: 4 - Regex: ".*" Priority: 1 -KeepEmptyLines: - AtEndOfFile: false - AtStartOfBlock: false - AtStartOfFile: false ... From af1adb74c6ba60159193ad2be2635e04191d5ee9 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 12:55:24 -0500 Subject: [PATCH 17/38] Update code-coverage flags --- .github/workflows/ci.yml | 12 ++++++------ Makefile | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ca716259f..b1b06be04 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -402,14 +402,14 @@ jobs: runs-on: ubuntu-latest env: MAKEFLAGS: -j4 - CFLAGS: "-fprofile-arcs -ftest-coverage -O0" - CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + CFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" + CXXFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" - TRICK_CFLAGS: "-fprofile-arcs -ftest-coverage -O0" - TRICK_CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_CFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" + TRICK_CXXFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" TRICK_SYSTEM_LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" - TRICK_SYSTEM_CFLAGS: "-fprofile-arcs -ftest-coverage -O0" - TRICK_SYSTEM_CXXFLAGS: "-fprofile-arcs -ftest-coverage -O0" + TRICK_SYSTEM_CFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" + TRICK_SYSTEM_CXXFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" steps: - name: Install Dependencies run: | diff --git a/Makefile b/Makefile index b46933f90..046fec1c8 100644 --- a/Makefile +++ b/Makefile @@ -335,7 +335,7 @@ extra-coverage-builds: @ $(MAKE) test -C trick_source/trick_utils/SAIntegrator code-coverage: test extra-coverage-builds - lcov --capture --ignore-errors mismatch $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info + lcov --capture --ignore-errors mismatch,negative $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From 5e98602c81915eca26a14d4a336c4349b826fc5e Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 13:37:06 -0500 Subject: [PATCH 18/38] more simplification --- .github/workflows/ci.yml | 107 ++++++++++++++++----------------------- 1 file changed, 44 insertions(+), 63 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b1b06be04..97864e5d5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -158,16 +158,18 @@ jobs: deps: >- bison clang + curl flex git llvm make maven cmake + swig zip gdb - install_gtest: echo gtest already installed conf_pkg: echo package manager already configured + enable_repo: "" install_cmd: install -y #-------- Debian-based Dependencies ---------------- @@ -175,8 +177,6 @@ jobs: pkg_mgr: apt-get conf_pkg: apt-get update arch_deps: >- - swig - curl g++ libx11-dev libxml2-dev @@ -188,16 +188,11 @@ jobs: libclang-dev libudunits2-dev libgtest-dev + libgmock-dev default-jdk python3-dev python3-pip python3-venv - install_gtest: | - apt-get install -y libgtest-dev libgmock-dev - cd /usr/src/gtest - cmake . - make - cp lib/libgtest* /usr/lib/ #-------- RHEL-based Dependencies (all versions) ---------------- - cfg: { arch: rhel } @@ -211,6 +206,8 @@ jobs: diffutils gcc gcc-c++ + gtest-devel + gmock-devel java-21-openjdk-devel libxml2-devel llvm-devel @@ -227,67 +224,50 @@ jobs: zlib-devel python3-devel - #-------- RHEL 8-only Dependencies ---------------- + #-------- RHEL 8: gtest lives in powertools ---------------- - cfg: { arch: rhel, tag: 8 } - install_gtest: | - dnf config-manager --enable powertools - dnf install -y gtest-devel gmock-devel + enable_repo: dnf config-manager --enable powertools - #-------- RHEL 9-only Dependencies ---------------- + #-------- RHEL 9/10: gtest lives in crb ---------------- - cfg: { arch: rhel, tag: 9 } - conf_pkg: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - dnf config-manager --enable crb - install_gtest: | - dnf install -y gtest-devel gmock-devel + enable_repo: dnf config-manager --enable crb - #-------- RHEL 10-only Dependencies ---------------- - cfg: { arch: rhel, tag: 10 } - conf_pkg: | - dnf -y install epel-release - dnf -y update - dnf install -y 'dnf-command(config-manager)' - dnf config-manager --enable crb - install_gtest: | - dnf install -y gtest-devel gmock-devel + enable_repo: dnf config-manager --enable crb - #-------- OL 8 Dependencies ---------------- + #-------- OL 8: gtest lives in codeready_builder ---------------- - cfg: { os: oraclelinux, tag: 8 } - install_gtest: | - dnf config-manager --enable ol8_codeready_builder - dnf install -y gtest-devel gmock-devel + enable_repo: dnf config-manager --enable ol8_codeready_builder steps: - name: Set noninteractive mode run: echo "DEBIAN_FRONTEND=noninteractive" >> "$GITHUB_ENV" if: matrix.cfg.arch == 'debian' - name: Update Package Manager - run: ${{ matrix.conf_pkg }} + run: | + ${{ matrix.conf_pkg }} + ${{ matrix.enable_repo }} - name: Install Dependencies run: > ${{ matrix.pkg_mgr }} ${{ matrix.install_cmd }} ${{ matrix.deps }} ${{ matrix.arch_deps }} - - name: Install GTest - run: ${{ matrix.install_gtest }} - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick run: | echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" + export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) ./configure - name: Build Trick + run: make + - name: Test Trick run: | - export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - make - - name: Test - run: | - cd share/trick/trickops/ - python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt - cd ../../../; make test + python3 -m venv share/trick/trickops/.venv + source share/trick/trickops/.venv/bin/activate + pip3 install -r share/trick/trickops/requirements.txt + make test - name: Upload Tests uses: actions/upload-artifact@v7 if: ${{ !cancelled() }} @@ -332,9 +312,10 @@ jobs: make - name: Test run: | - cd share/trick/trickops/ - python3 -m venv .venv && source .venv/bin/activate && pip3 install -r requirements.txt - cd ../../../; make test + python3 -m venv share/trick/trickops/.venv + source share/trick/trickops/.venv/bin/activate + pip3 install -r share/trick/trickops/requirements.txt + make test - name: Upload Tests uses: actions/upload-artifact@v7 if: ${{ !cancelled() }} @@ -375,18 +356,18 @@ jobs: run: ${{ matrix.install }} - name: Create virtual environment run: | - cd share/trick/trickops/ - python3 -m venv .venv && source .venv/bin/activate && pip3 install --upgrade pip && pip3 install -r requirements.txt + python3 -m venv share/trick/trickops/.venv + source share/trick/trickops/.venv/bin/activate + pip3 install --upgrade pip && pip3 install -r share/trick/trickops/requirements.txt - name: Build koviz run: | - cd /tmp/ && wget -q https://github.com/nasa/koviz/archive/refs/heads/master.zip && unzip master.zip - cd /tmp/koviz-master/ && ${{ matrix.qmake }} && make + git clone --depth 1 https://github.com/nasa/koviz.git /tmp/koviz + cd /tmp/koviz && ${{ matrix.qmake }} && make - name: Run unit and doc tests run: | - cd share/trick/trickops/tests/ - source ../.venv/bin/activate - export PATH="/tmp/koviz-master/bin:${PATH}" - ./run_tests.py + source share/trick/trickops/.venv/bin/activate + export PATH="/tmp/koviz/bin:${PATH}" + share/trick/trickops/tests/run_tests.py - name: Upload test logs uses: actions/upload-artifact@v7 if: always() @@ -401,7 +382,6 @@ jobs: needs: [style] runs-on: ubuntu-latest env: - MAKEFLAGS: -j4 CFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" CXXFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" LDFLAGS: "-fprofile-arcs -ftest-coverage -O0" @@ -424,20 +404,21 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick - run: ./configure - - name: Build Trick run: | + echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - make + ./configure + - name: Build Trick + run: make - name: Generate Code Coverage run: | - cd share/trick/trickops/ - python3 -m venv .venv && . .venv/bin/activate && pip3 install -r requirements.txt - cd ../../../ + python3 -m venv share/trick/trickops/.venv + source share/trick/trickops/.venv/bin/activate + pip3 install -r share/trick/trickops/requirements.txt make code-coverage - name: Upload to Coveralls uses: coverallsapp/github-action@v2 continue-on-error: true with: - github-token: ${{ secrets.GITHUB_TOKEN }} - path-to-lcov: "./coverage.info" + file: coverage.info + format: lcov From 7b2e43ab244c2b19a664af309fedd977a87166e7 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 13:39:04 -0500 Subject: [PATCH 19/38] Update Makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 046fec1c8..73bbe8a61 100644 --- a/Makefile +++ b/Makefile @@ -336,7 +336,7 @@ extra-coverage-builds: code-coverage: test extra-coverage-builds lcov --capture --ignore-errors mismatch,negative $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info - lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info + lcov --remove coverage_large.info '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From 85e553ac9df5c595c3f8929a8268f0e188c76171 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 13:53:30 -0500 Subject: [PATCH 20/38] Fix curl deps on rhel and flag setting --- .github/workflows/ci.yml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 97864e5d5..6fd9f3869 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -158,7 +158,6 @@ jobs: deps: >- bison clang - curl flex git llvm @@ -177,6 +176,7 @@ jobs: pkg_mgr: apt-get conf_pkg: apt-get update arch_deps: >- + curl g++ libx11-dev libxml2-dev @@ -217,7 +217,6 @@ jobs: openmotif-devel perl perl-Digest-MD5 - swig udunits2 udunits2-devel which @@ -256,12 +255,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick + run: ./configure + - name: Build Trick run: | echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" - export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - ./configure - - name: Build Trick - run: make + echo "JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))" >> "$GITHUB_ENV" + make - name: Test Trick run: | python3 -m venv share/trick/trickops/.venv @@ -367,7 +366,7 @@ jobs: run: | source share/trick/trickops/.venv/bin/activate export PATH="/tmp/koviz/bin:${PATH}" - share/trick/trickops/tests/run_tests.py + cd share/trick/trickops/tests && ./run_tests.py - name: Upload test logs uses: actions/upload-artifact@v7 if: always() @@ -404,12 +403,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick + run: ./configure + - name: Build Trick run: | echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" - export JAVA_HOME=$(dirname $(dirname $(readlink -f `which java`))) - ./configure - - name: Build Trick - run: make + echo "JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))" >> "$GITHUB_ENV" + make - name: Generate Code Coverage run: | python3 -m venv share/trick/trickops/.venv From e7b085eff4ee61935b207b4a6b7cbcb1fdf2d6fe Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 14:15:45 -0500 Subject: [PATCH 21/38] Update ci.yml --- .github/workflows/ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6fd9f3869..e7086cd0e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -264,7 +264,7 @@ jobs: - name: Test Trick run: | python3 -m venv share/trick/trickops/.venv - source share/trick/trickops/.venv/bin/activate + . share/trick/trickops/.venv/bin/activate pip3 install -r share/trick/trickops/requirements.txt make test - name: Upload Tests @@ -312,7 +312,7 @@ jobs: - name: Test run: | python3 -m venv share/trick/trickops/.venv - source share/trick/trickops/.venv/bin/activate + . share/trick/trickops/.venv/bin/activate pip3 install -r share/trick/trickops/requirements.txt make test - name: Upload Tests @@ -356,7 +356,7 @@ jobs: - name: Create virtual environment run: | python3 -m venv share/trick/trickops/.venv - source share/trick/trickops/.venv/bin/activate + . share/trick/trickops/.venv/bin/activate pip3 install --upgrade pip && pip3 install -r share/trick/trickops/requirements.txt - name: Build koviz run: | @@ -364,7 +364,7 @@ jobs: cd /tmp/koviz && ${{ matrix.qmake }} && make - name: Run unit and doc tests run: | - source share/trick/trickops/.venv/bin/activate + . share/trick/trickops/.venv/bin/activate export PATH="/tmp/koviz/bin:${PATH}" cd share/trick/trickops/tests && ./run_tests.py - name: Upload test logs @@ -412,7 +412,7 @@ jobs: - name: Generate Code Coverage run: | python3 -m venv share/trick/trickops/.venv - source share/trick/trickops/.venv/bin/activate + . share/trick/trickops/.venv/bin/activate pip3 install -r share/trick/trickops/requirements.txt make code-coverage - name: Upload to Coveralls From a8cfdec78887af3d189ffcbf2a7d07e74cc0e138 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 14:19:23 -0500 Subject: [PATCH 22/38] Update ci.yml --- .github/workflows/ci.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e7086cd0e..671f10071 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -255,12 +255,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick - run: ./configure - - name: Build Trick run: | echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" echo "JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))" >> "$GITHUB_ENV" - make + ./configure + - name: Build Trick + run: make - name: Test Trick run: | python3 -m venv share/trick/trickops/.venv @@ -403,12 +403,12 @@ jobs: - name: Checkout repository uses: actions/checkout@v6 - name: Configure Trick - run: ./configure - - name: Build Trick run: | echo "MAKEFLAGS=-j$(nproc)" >> "$GITHUB_ENV" echo "JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))" >> "$GITHUB_ENV" - make + ./configure + - name: Build Trick + run: make - name: Generate Code Coverage run: | python3 -m venv share/trick/trickops/.venv From c2399c27af5255c4c1acd5515af9bdcce731e0f6 Mon Sep 17 00:00:00 2001 From: brendan fattig Date: Thu, 23 Apr 2026 14:56:27 -0500 Subject: [PATCH 23/38] Revert makefile changes --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 73bbe8a61..69423f6a4 100644 --- a/Makefile +++ b/Makefile @@ -335,8 +335,8 @@ extra-coverage-builds: @ $(MAKE) test -C trick_source/trick_utils/SAIntegrator code-coverage: test extra-coverage-builds - lcov --capture --ignore-errors mismatch,negative $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info - lcov --remove coverage_large.info '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info + lcov --capture $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info + lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From 6419c36f2e1b105baf7963744f285cea5af9941b Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 15:25:43 -0500 Subject: [PATCH 24/38] Update Makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 69423f6a4..b46933f90 100644 --- a/Makefile +++ b/Makefile @@ -335,7 +335,7 @@ extra-coverage-builds: @ $(MAKE) test -C trick_source/trick_utils/SAIntegrator code-coverage: test extra-coverage-builds - lcov --capture $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info + lcov --capture --ignore-errors mismatch $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From f17f5f3a95e45b2fafad232075078029efc23394 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 15:38:35 -0500 Subject: [PATCH 25/38] update .gitignores --- .gitignore | 3 +++ test/SIM_exclusion_mechanisms/models/trickified/.gitignore | 1 + test/SIM_mtv/models/test_client/.gitignore | 1 + test/SIM_trickified/trickified_project/trickified/.gitignore | 1 + trick_sims/SIM_balloon/models/graphics/.gitignore | 3 +++ trick_source/sim_services/CommandLineArguments/test/.gitignore | 3 ++- trick_source/trick_utils/math/test/.gitignore | 1 + trick_source/trick_utils/optimization/test/.gitignore | 2 ++ 8 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 test/SIM_mtv/models/test_client/.gitignore create mode 100644 trick_source/trick_utils/optimization/test/.gitignore diff --git a/.gitignore b/.gitignore index 31bb38862..20c89ae1d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ +compile_commands.json +*~ config.status* config.log share/trick/makefiles/config_user.mk @@ -44,3 +46,4 @@ coverage.info *.dSYM *.log .cache/ +share/trick/trickops/makefile diff --git a/test/SIM_exclusion_mechanisms/models/trickified/.gitignore b/test/SIM_exclusion_mechanisms/models/trickified/.gitignore index 11033b5d6..53064b3fe 100644 --- a/test/SIM_exclusion_mechanisms/models/trickified/.gitignore +++ b/test/SIM_exclusion_mechanisms/models/trickified/.gitignore @@ -1,2 +1,3 @@ python trickified.o +full_file diff --git a/test/SIM_mtv/models/test_client/.gitignore b/test/SIM_mtv/models/test_client/.gitignore new file mode 100644 index 000000000..b603356bf --- /dev/null +++ b/test/SIM_mtv/models/test_client/.gitignore @@ -0,0 +1 @@ +test_client diff --git a/test/SIM_trickified/trickified_project/trickified/.gitignore b/test/SIM_trickified/trickified_project/trickified/.gitignore index 0259157ce..7f5440dcd 100644 --- a/test/SIM_trickified/trickified_project/trickified/.gitignore +++ b/test/SIM_trickified/trickified_project/trickified/.gitignore @@ -1,4 +1,5 @@ build python trick +full_file *.o diff --git a/trick_sims/SIM_balloon/models/graphics/.gitignore b/trick_sims/SIM_balloon/models/graphics/.gitignore index 0a76dd934..fb2fce41a 100644 --- a/trick_sims/SIM_balloon/models/graphics/.gitignore +++ b/trick_sims/SIM_balloon/models/graphics/.gitignore @@ -1 +1,4 @@ !\makefile +.classpath +.project +.settings/ diff --git a/trick_source/sim_services/CommandLineArguments/test/.gitignore b/trick_source/sim_services/CommandLineArguments/test/.gitignore index d80d85863..c9567dcfc 100644 --- a/trick_source/sim_services/CommandLineArguments/test/.gitignore +++ b/trick_source/sim_services/CommandLineArguments/test/.gitignore @@ -1,2 +1,3 @@ create_path_test -*.o \ No newline at end of file +CommandLineArguments_test +*.o diff --git a/trick_source/trick_utils/math/test/.gitignore b/trick_source/trick_utils/math/test/.gitignore index 948bbb91a..f7b4fe9cf 100644 --- a/trick_source/trick_utils/math/test/.gitignore +++ b/trick_source/trick_utils/math/test/.gitignore @@ -1,2 +1,3 @@ UnitTestEulerQuat +UnitTestLDLtFactorization *.o diff --git a/trick_source/trick_utils/optimization/test/.gitignore b/trick_source/trick_utils/optimization/test/.gitignore new file mode 100644 index 000000000..409295011 --- /dev/null +++ b/trick_source/trick_utils/optimization/test/.gitignore @@ -0,0 +1,2 @@ +UnitTestPDIPOptimization +*.o From 3d17b848b116e6b9268bc9b4c415d37f03b3a8c1 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 15:43:22 -0500 Subject: [PATCH 26/38] Use rockylinux/rockylinux:8 image in CI --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 671f10071..67a3b9635 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -341,7 +341,7 @@ jobs: apt-get install -y git python3 python3-venv perl perl-modules-5.38 qtbase5-dev wget unzip g++ make flex bison qmake: qmake - name: RockyLinux 8 - image: rockylinux:8 + image: rockylinux/rockylinux:8 install: | dnf install -y git python3-devel which perl perl-Digest-MD5 qt5-qtbase-devel bison clang flex make gcc gcc-c++ wget qmake: qmake-qt5 From 745244cab68cfe550827e5591eeb56e4fbc364c6 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 16:35:30 -0500 Subject: [PATCH 27/38] Update Makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index b46933f90..5a20cfe8b 100644 --- a/Makefile +++ b/Makefile @@ -336,7 +336,7 @@ extra-coverage-builds: code-coverage: test extra-coverage-builds lcov --capture --ignore-errors mismatch $(addprefix --directory , $(COVERAGE_DIRS)) --output-file coverage_large.info - lcov --remove coverage_large.info '/Library/*' '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info + lcov --remove coverage_large.info '/usr/*' '*/io_src/*' '*/test/*' '*/unittest/*' -o coverage.info rm coverage_large.info lcov --list coverage.info From 3721fc87140e212ca4c917a6f2d31ecb43250128 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 17:00:22 -0500 Subject: [PATCH 28/38] Update Makefile.common --- share/trick/makefiles/Makefile.common | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/trick/makefiles/Makefile.common b/share/trick/makefiles/Makefile.common index 4db13de63..cc58e63b4 100644 --- a/share/trick/makefiles/Makefile.common +++ b/share/trick/makefiles/Makefile.common @@ -196,7 +196,7 @@ export TRICK_SYSTEM_CFLAGS := $(TRICK_SYSTEM_CXXFLAGS) -fexceptions TRICK_SYSTEM_CFLAGS += $(TRICK_ADDITIONAL_CFLAGS) TRICK_SYSTEM_CXXFLAGS += $(TRICK_ADDITIONAL_CXXFLAGS) -TRICK_TEST_FLAGS += -Wall -Wextra $(GTEST_CXXSTD) +TRICK_TEST_FLAGS := -Wall -Wextra $(GTEST_CXXSTD) TRICK_INCLUDE = $(shell $(PERL) -e '@inc_paths = "${TRICK_CFLAGS}" =~ /-(?:I|isystem)\s*(\S+)/g ; foreach $$i (@inc_paths) { print "-I$$i " if (-e $$i and $$i ne "/usr/include")}') \ $(shell $(PERL) -e '@inc_paths = "${TRICK_SYSTEM_CFLAGS}" =~ /-(?:I|isystem)\s*(\S+)/g ; foreach $$i (@inc_paths) { print "-I$$i " if (-e $$i)}') From 2b1ad83ed29af718ccfa08ada97920f29604b9ee Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 17:03:07 -0500 Subject: [PATCH 29/38] Revert changes made to deal with flaky gh runners --- .../SIM_mtv/models/test_client/test_client.hh | 28 +++++++------------ 1 file changed, 10 insertions(+), 18 deletions(-) diff --git a/test/SIM_mtv/models/test_client/test_client.hh b/test/SIM_mtv/models/test_client/test_client.hh index 647e2175f..7f66e1afa 100644 --- a/test/SIM_mtv/models/test_client/test_client.hh +++ b/test/SIM_mtv/models/test_client/test_client.hh @@ -2,7 +2,6 @@ #include #include -#include #include #include #include @@ -29,8 +28,12 @@ public: { } - int init(const std::string& host, int port, int timeout_sec = 10) + int init(const std::string& host, int port) { + _fd = socket(AF_INET, SOCK_STREAM, 0); + if (_fd < 0) + return -1; + struct sockaddr_in addr; memset(&addr, 0, sizeof(addr)); addr.sin_family = AF_INET; @@ -38,22 +41,11 @@ public: if (inet_pton(AF_INET, "127.0.0.1", &addr.sin_addr) <= 0) return -1; - time_t deadline = time(nullptr) + timeout_sec; - while (time(nullptr) < deadline) - { - _fd = socket(AF_INET, SOCK_STREAM, 0); - if (_fd < 0) - return -1; - if (connect(_fd, (struct sockaddr*)&addr, sizeof(addr)) == 0) - { - _ok = true; - return 0; - } - ::close(_fd); - _fd = -1; - usleep(100000); // 100 ms between retries - } - return -1; + if (connect(_fd, (struct sockaddr*)&addr, sizeof(addr)) < 0) + return -1; + + _ok = true; + return 0; } void close() From 57a8b2d1357c6e3161b647ad9aa1b371d57bce2b Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Thu, 23 Apr 2026 17:07:18 -0500 Subject: [PATCH 30/38] Always set GTEST_CXXSTD to c++17 --- autoconf/m4/tr_gtest.m4 | 17 +- configure | 9101 ++++++++++++++++++++++++--------------- 2 files changed, 5614 insertions(+), 3504 deletions(-) diff --git a/autoconf/m4/tr_gtest.m4 b/autoconf/m4/tr_gtest.m4 index 41461ad75..b1fc46233 100644 --- a/autoconf/m4/tr_gtest.m4 +++ b/autoconf/m4/tr_gtest.m4 @@ -15,28 +15,13 @@ AC_DEFUN([TR_GTEST],[ ) dnl Check gtest version using pkg-config if available - GTEST_CXXSTD="" + GTEST_CXXSTD="-std=c++17" AS_IF([test -n "$GTEST_HOME"], [ PKG_CHECK_EXISTS([gtest], [ GTEST_VERSION=`$PKG_CONFIG --modversion gtest 2>/dev/null` AS_IF([test -n "$GTEST_VERSION"], [ AC_MSG_CHECKING([gtest version]) AC_MSG_RESULT([$GTEST_VERSION]) - - dnl Extract major and minor version numbers - GTEST_MAJOR=`echo $GTEST_VERSION | cut -d. -f1` - GTEST_MINOR=`echo $GTEST_VERSION | cut -d. -f2` - - dnl Set C++ standard based on gtest version - dnl gtest >= 1.17 requires C++17 - AS_IF([test "$GTEST_MAJOR" -gt 1 -o \( "$GTEST_MAJOR" -eq 1 -a "$GTEST_MINOR" -ge 17 \)], [ - GTEST_CXXSTD="-std=c++17" - AC_MSG_NOTICE([gtest >= 1.17.0 detected, setting C++ standard to C++17]) - ], [ - dnl gtest < 1.17 uses C++14 - GTEST_CXXSTD="-std=c++14" - AC_MSG_NOTICE([gtest < 1.17.0 detected, setting C++ standard to C++14]) - ]) ], [ AC_MSG_WARN([Could not determine gtest version via pkg-config]) ]) diff --git a/configure b/configure index f86a5fbc5..960b214b9 100755 --- a/configure +++ b/configure @@ -1,9 +1,10 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for Trick 19.6+. +# Generated by GNU Autoconf 2.73 for Trick 19.6+. # # -# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. +# Copyright (C) 1992-1996, 1998-2017, 2020-2026 Free Software Foundation, +# Inc. # # # This configure script is free software; the Free Software Foundation @@ -14,63 +15,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. + # contradicts POSIX and common usage. Disable this. 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&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 || @@ -79,13 +82,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 #(( @@ -94,43 +90,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. @@ -149,28 +129,33 @@ case $- in # (((( *x* ) as_opts=-x ;; * ) as_opts= ;; esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +case $# in # (( + 0) exec $CONFIG_SHELL $as_opts "$as_myself" ;; + *) exec $CONFIG_SHELL $as_opts "$as_myself" "$@" ;; +esac # 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. + # contradicts POSIX and common usage. Disable this. 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 " @@ -185,42 +170,55 @@ 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 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test \$(( 1 + 1 )) = 2 || 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 @@ -228,14 +226,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 @@ -250,27 +256,32 @@ case $- in # (((( *x* ) as_opts=-x ;; * ) as_opts= ;; esac -exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} +case $# in # (( + 0) exec $CONFIG_SHELL $as_opts "$as_myself" ;; + *) exec $CONFIG_SHELL $as_opts "$as_myself" "$@" ;; +esac # 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 about your system, + printf '%s\n' "$0: Please tell bug-autoconf@gnu.org about your system, $0: 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} @@ -291,6 +302,7 @@ as_fn_unset () } as_unset=as_fn_unset + # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. @@ -322,7 +334,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" @@ -331,7 +343,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 @@ -370,16 +382,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... @@ -387,16 +401,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 @@ -410,9 +426,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 @@ -439,7 +455,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 @@ -472,6 +488,8 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits /[$]LINENO/= ' <$as_myself | sed ' + t clear + :clear s/[$]LINENO.*/&-/ t lineno b @@ -483,7 +501,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 @@ -497,19 +515,6 @@ as_cr_alnum=$as_cr_Letters$as_cr_digits exit } -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file @@ -521,9 +526,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 @@ -548,10 +553,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 test -n "$DJDIR" || exec 7<&0 /dev/null | sed 1q` # Initializations. # ac_default_prefix=/usr/local +ac_clean_CONFIG_STATUS= ac_clean_files= ac_config_libobj_dir=. LIBOBJS= @@ -584,40 +592,36 @@ PACKAGE_URL='' # Factoring default headers for most tests. ac_includes_default="\ -#include -#ifdef HAVE_SYS_TYPES_H -# include -#endif -#ifdef HAVE_SYS_STAT_H -# include +#include +#ifdef HAVE_STDIO_H +# include #endif -#ifdef STDC_HEADERS +#ifdef HAVE_STDLIB_H # include -# include -#else -# ifdef HAVE_STDLIB_H -# include -# endif #endif #ifdef HAVE_STRING_H -# if !defined STDC_HEADERS && defined HAVE_MEMORY_H -# include -# endif # include #endif -#ifdef HAVE_STRINGS_H -# include -#endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif +#ifdef HAVE_STRINGS_H +# include +#endif +#ifdef HAVE_SYS_TYPES_H +# include +#endif +#ifdef HAVE_SYS_STAT_H +# include +#endif #ifdef HAVE_UNISTD_H # include #endif" +ac_header_cxx_list= ac_subst_vars='LTLIBOBJS LIBOBJS USE_ER7_UTILS @@ -642,6 +646,7 @@ CLANG LLVM_CONFIG PTHREAD_CFLAGS PTHREAD_LIBS +PTHREAD_CXX PTHREAD_CC ax_pthread_config CPP @@ -663,6 +668,7 @@ PYTHON PYTHON_VERSION ZIP PERL_VERSION +GREP SED PERL CURL @@ -673,9 +679,6 @@ LEX LD TEE GCC_VERSION -ac_ct_CC -CFLAGS -CC AWK TRICK_OFFLINE TRICK_FORCE_32BIT @@ -683,17 +686,18 @@ LIBXML X_LIB_DIR USE_X_WINDOWS MOTIF_HOME -EGREP -GREP CXXCPP +XMKMF +ac_ct_CXX +CXXFLAGS +CXX OBJEXT EXEEXT -ac_ct_CXX +ac_ct_CC CPPFLAGS LDFLAGS -CXXFLAGS -CXX -XMKMF +CFLAGS +CC XCRUN host_os host_vendor @@ -703,13 +707,13 @@ build_os build_vendor build_cpu build +ECHO_T +ECHO_N +ECHO_C target_alias host_alias build_alias LIBS -ECHO_T -ECHO_N -ECHO_C DEFS mandir localedir @@ -722,6 +726,7 @@ infodir docdir oldincludedir includedir +runstatedir localstatedir sharedstatedir sysconfdir @@ -763,16 +768,16 @@ enable_er7utils ac_precious_vars='build_alias host_alias target_alias -XMKMF -CXX -CXXFLAGS +CC +CFLAGS LDFLAGS LIBS CPPFLAGS +CXX +CXXFLAGS CCC +XMKMF CXXCPP -CC -CFLAGS PYTHON_VERSION JAVA_CC JAVA_CC_FLAGS @@ -818,6 +823,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}' @@ -847,8 +853,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 ;; @@ -889,9 +893,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" @@ -915,9 +919,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" @@ -1070,6 +1074,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=* \ @@ -1119,9 +1132,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" @@ -1135,9 +1148,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" @@ -1165,8 +1178,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" ;; *=*) @@ -1174,16 +1187,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}" ;; @@ -1191,7 +1204,7 @@ Try \`$0 --help' for more information" done if test -n "$ac_prev"; then - ac_option=--`echo $ac_prev | sed 's/_/-/g'` + ac_option=--`printf '%s\n' $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi @@ -1199,7 +1212,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 @@ -1207,7 +1220,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. @@ -1224,7 +1237,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 @@ -1263,7 +1276,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 @@ -1292,7 +1305,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)` @@ -1320,7 +1333,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 Trick 19.6+ to adapt to many kinds of systems. +'configure' configures Trick 19.6+ to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1334,11 +1347,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 @@ -1346,10 +1359,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. @@ -1360,6 +1373,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] @@ -1425,17 +1439,17 @@ Optional Packages: --with-civetweb[=DIR] CIVETWEB root directory Some influential environment variables: - XMKMF Path to xmkmf, Makefile generator for X Window System - CXX C++ compiler command - CXXFLAGS C++ compiler flags + CC C compiler command + CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory + CXX C++ compiler command + CXXFLAGS C++ compiler flags + XMKMF Path to xmkmf, Makefile generator for X Window System CXXCPP C++ preprocessor - CC C compiler command - CFLAGS C compiler flags PYTHON_VERSION Adds suffix to python search e.g. PYTHON_VERSION=3 will look for python3 @@ -1449,7 +1463,7 @@ Some influential environment variables: PKG_CONFIG_LIBDIR path overriding pkg-config's built-in search path -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 the package provider. @@ -1468,9 +1482,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/ ;; @@ -1498,7 +1512,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 @@ -1506,7 +1521,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 @@ -1516,9 +1531,9 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF Trick configure 19.6+ -generated by GNU Autoconf 2.69 +generated by GNU Autoconf 2.73 -Copyright (C) 2012 Free Software Foundation, Inc. +Copyright (C) 2026 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF @@ -1529,20 +1544,20 @@ fi ## Autoconf initialization. ## ## ------------------------ ## -# ac_fn_cxx_try_compile LINENO -# ---------------------------- +# ac_fn_c_try_compile LINENO +# -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_compile () +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 @@ -1550,59 +1565,64 @@ $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_cxx_werror_flag" || + 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_cxx_try_compile +} # ac_fn_c_try_compile -# ac_fn_cxx_try_cpp LINENO -# ------------------------ -# Try to preprocess conftest.$ac_ext, and return whether this succeeded. -ac_fn_cxx_try_cpp () +# ac_fn_cxx_try_compile LINENO +# ---------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_cpp conftest.$ac_ext" + 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 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } > conftest.i && { - test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_cxx_werror_flag" || test ! -s conftest.err - }; 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_cxx_try_cpp +} # ac_fn_cxx_try_compile # ac_fn_cxx_try_link LINENO # ------------------------- @@ -1610,14 +1630,14 @@ fi ac_fn_cxx_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 @@ -1625,20 +1645,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_cxx_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 @@ -1650,134 +1672,44 @@ fi } # ac_fn_cxx_try_link -# ac_fn_cxx_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_cxx_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_cxx_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_cxx_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_cxx_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;} - ;; -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_cxx_check_header_mongrel - -# ac_fn_cxx_try_run LINENO +# ac_fn_cxx_try_cpp LINENO # ------------------------ -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_cxx_try_run () +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_cxx_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" + if { { ac_try="$ac_cpp conftest.$ac_ext" 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 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$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 - (eval "$ac_try") 2>&5 +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || + test ! -s conftest.err + } +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: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 - ac_retval=$ac_status + ac_retval=1 ;; +esac fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval -} # ac_fn_cxx_try_run +} # ac_fn_cxx_try_cpp # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES # --------------------------------------------------------- @@ -1786,113 +1718,81 @@ fi ac_fn_cxx_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 + { 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_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$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_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_cxx_check_header_compile -# ac_fn_c_try_compile LINENO -# -------------------------- -# Try to compile conftest.$ac_ext, and return whether this succeeded. -ac_fn_c_try_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 - if { { ac_try="$ac_compile" + 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 - (eval "$ac_compile") 2>conftest.err +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 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_exeext && { + test "$cross_compiling" = yes || + test -x conftest$ac_exeext + } +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 + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval -} # ac_fn_c_try_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 - 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 - (eval "$ac_link") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - grep -v '^ *+' conftest.err >conftest.er1 - cat conftest.er1 >&5 - mv -f conftest.er1 conftest.err - fi - $as_echo "$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 : - ac_retval=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=1 -fi - # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information - # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would - # interfere with the next link command; also delete a directory that is - # left behind by Apple's compiler. We do this before executing the actions. - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno - as_fn_set_status $ac_retval - -} # ac_fn_c_try_link +} # ac_fn_c_try_link # ac_fn_c_try_cpp LINENO # ---------------------- @@ -1906,7 +1806,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 @@ -1914,117 +1814,87 @@ $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 +# ac_fn_c_check_header_compile 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 () +# 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 - 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 + { 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 : - 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 +if ac_fn_c_try_compile "$LINENO" +then : + eval "$3=yes" +else case e in #( + e) eval "$3=no" ;; +esac 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;} - ;; +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;; 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 + { 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_mongrel +} # ac_fn_c_check_header_compile +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 Trick $as_me 19.6+, which was -generated by GNU Autoconf 2.69. Invocation command line was +generated by GNU Autoconf 2.73. Invocation command line was - $ $0 $@ + $ $0$ac_configure_args_raw _ACEOF exec 5>>config.log @@ -2057,8 +1927,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 @@ -2093,7 +1967,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'" ;; @@ -2122,29 +1996,22 @@ done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} -# When interrupted or exit'd, cleanup temporary files, and complete -# config.log. We remove comments because anyway the quotes in there -# would cause problems or look ugly. -# 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=$? - # Save into config.log some information that might help in debugging. - { - echo - - $as_echo "## ---------------- ## -## Cache variables. ## -## ---------------- ##" - echo - # The following way of writing the cache mishandles newlines in values, +# Dump the cache to stdout. It can be in a pipe (this is a requirement). +ac_cache_dump () +{ + # The following way of writing the cache mishandles newlines in values, +# but we know of no workaround that is simple, portable, and efficient. +# So, we kill variables containing newlines. +# Ultrix sh set writes to stderr and can't be redirected directly, +# and sets the high bit in the cache file unless we assign to the vars. ( - for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do + for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var 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) ;; #( @@ -2153,67 +2020,95 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac ;; esac done + (set) 2>&1 | - case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( + case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) + # '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" + "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. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) - echo +} + +# Print debugging info to stdout. +ac_dump_debugging_info () +{ + echo + + printf '%s\n' "## ---------------- ## +## Cache variables. ## +## ---------------- ##" + echo + ac_cache_dump + echo - $as_echo "## ----------------- ## + printf '%s\n' "## ----------------- ## ## Output variables. ## ## ----------------- ##" + echo + for ac_var in $ac_subst_vars + do + eval ac_val=\$$ac_var + case $ac_val in + *\'*) ac_val=`printf '%s\n' "$ac_val" | sed "s/'/'\\\\\\\\''/g"`;; + esac + printf '%s\n' "$ac_var='$ac_val'" + done | sort + echo + + if test -n "$ac_subst_files"; then + printf '%s\n' "## ------------------- ## +## File substitutions. ## +## ------------------- ##" echo - for ac_var in $ac_subst_vars + for ac_var in $ac_subst_files 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 -n "$ac_subst_files"; then - $as_echo "## ------------------- ## -## File substitutions. ## -## ------------------- ##" - echo - for ac_var in $ac_subst_files - do - eval ac_val=\$$ac_var - case $ac_val in - *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; - esac - $as_echo "$ac_var='\''$ac_val'\''" - done | sort - echo - fi - - if test -s confdefs.h; then - $as_echo "## ----------- ## + if test -s confdefs.h; then + printf '%s\n' "## ----------- ## ## confdefs.h. ## ## ----------- ##" - echo - cat confdefs.h - echo - fi - test "$ac_signal" != 0 && - $as_echo "$as_me: caught signal $ac_signal" - $as_echo "$as_me: exit $exit_status" - } >&5 - rm -f core *.core core.conftest.* && + echo + cat confdefs.h + echo + fi + test "$ac_signal" != 0 && + printf '%s\n' "$as_me: caught signal $ac_signal" + printf '%s\n' "$as_me: exit $exit_status" +} + +# When interrupted or exit'd, cleanup temporary files, and complete +# config.log. +ac_exit_trap () +{ + exit_status= + # Sanitize IFS. + IFS=" "" $as_nl" + # Save into config.log some information that might help in debugging. + ac_dump_debugging_info >&5 + eval "rm -f $ac_clean_CONFIG_STATUS core *.core core.conftest.*" && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status -' 0 +} + +trap 'ac_exit_trap $?' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done @@ -2222,65 +2117,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 @@ -2288,194 +2168,723 @@ 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 - # 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=$ac_new_val ;; - esac - case " $ac_configure_args " in - *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) as_fn_append ac_configure_args " '$ac_arg'" ;; - esac - 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 -fi -## -------------------- ## -## Main body of script. ## -## -------------------- ## - -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 - - -ac_ext=cpp -ac_cpp='$CXXCPP $CPPFLAGS' -ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' -ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' -ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +# Test code for whether the C compiler supports C23 (global declarations) +ac_c_conftest_c23_globals=' +/* Does the compiler advertise conformance to C17 or earlier? + Although GCC 14 does not do that, even with -std=gnu23, + it is close enough, and defines __STDC_VERSION == 202000L. */ +#if !defined __STDC_VERSION__ || __STDC_VERSION__ <= 201710L +# error "Compiler advertises conformance to C17 or earlier" +#endif +// Check alignas. +char alignas (double) c23_aligned_as_double; +char alignas (0) c23_no_special_alignment; +extern char c23_aligned_as_int; +char alignas (0) alignas (int) c23_aligned_as_int; -ac_aux_dir= -for ac_dir in autoconf "$srcdir"/autoconf; 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 autoconf \"$srcdir\"/autoconf" "$LINENO" 5 -fi +// Check alignof. +enum +{ + c23_int_alignment = alignof (int), + c23_int_array_alignment = alignof (int[100]), + c23_char_alignment = alignof (char) +}; +static_assert (0 < -alignof (int), "alignof is signed"); -# 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. +int function_with_unnamed_parameter (int) { return 0; } +void c23_noreturn (); +/* Test parsing of string and char UTF-8 literals (including hex escapes). + The parens pacify GCC 15. */ +bool use_u8 = (!sizeof u8"\xFF") == (!u8'\''x'\''); +bool check_that_bool_works = true | false | !nullptr; +#if !true +# error "true does not work in #if" +#endif +#if false +#elifdef __STDC_VERSION__ +#else +# error "#elifdef does not work" +#endif -# 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 +#ifndef __has_c_attribute +# error "__has_c_attribute not defined" +#endif -{ $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 -test "x$ac_build_alias" = x && - 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 +#ifndef __has_include +# error "__has_include not defined" +#endif -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 -$as_echo "$ac_cv_build" >&6; } -case $ac_cv_build in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; -esac -build=$ac_cv_build -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_build -shift -build_cpu=$1 -build_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -build_os=$* -IFS=$ac_save_IFS -case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac +#define LPAREN() ( +#define FORTY_TWO(x) 42 +#define VA_OPT_TEST(r, x, ...) __VA_OPT__ (FORTY_TWO r x)) +static_assert (VA_OPT_TEST (LPAREN (), 0, <:-) == 42); +static_assert (0b101010 == 42); +static_assert (0B101010 == 42); +static_assert (0xDEAD'\''BEEF == 3'\''735'\''928'\''559); +static_assert (0.500'\''000'\''000 == 0.5); -{ $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 - 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 -fi +enum unsignedish : unsigned int { uione = 1 }; +static_assert (0 < -uione); -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 -$as_echo "$ac_cv_host" >&6; } -case $ac_cv_host in -*-*-*) ;; -*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; -esac -host=$ac_cv_host -ac_save_IFS=$IFS; IFS='-' -set x $ac_cv_host -shift -host_cpu=$1 -host_vendor=$2 -shift; shift -# Remember, the first character of IFS is used to create $*, -# except with old shells: -host_os=$* -IFS=$ac_save_IFS -case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac +#include +constexpr nullptr_t null_pointer = nullptr; + +static typeof (1 + 1L) two () { return 2; } +static long int three () { return 3; } +' + +# Test code for whether the C compiler supports C23 (body of main). +ac_c_conftest_c23_main=' + { + label_before_declaration: + int arr[10] = {}; + if (arr[0]) + goto label_before_declaration; + if (!arr[0]) + goto label_at_end_of_block; + label_at_end_of_block: + } + ok |= !null_pointer; + ok |= two != three; +' + +# Test code for whether the C compiler supports C23 (complete). +ac_c_conftest_c23_program="${ac_c_conftest_c23_globals} + +int +main (int, char **) +{ + int ok = 0; + ${ac_c_conftest_c23_main} + return ok; +} +" + +# Test code for whether the C compiler supports C89 (global declarations) +ac_c_conftest_c89_globals=' +/* Do not test the value of __STDC__, because some compilers define it to 0 + or do not define it, while otherwise adequately conforming. */ + +#include +#include +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 +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, and "aND" is used instead of "and" to work around +// GCC bug 40564 which is irrelevant here. +#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; + const char *restrict newvar = "Another string"; + + // Check varargs. + success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234); + test_varargs_macros (); + + // Check flexible array members. + static struct incomplete_array *volatile incomplete_array_pointer; + struct incomplete_array *ia = incomplete_array_pointer; + 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; + + // Do not test for VLAs, as some otherwise-conforming compilers lack them. + // C code should instead use __STDC_NO_VLA__; see Autoconf manual. + + // work around unused variable warnings + ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\'' + || ni.number != 58); +' + +# 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_cxx_list " stdio.h stdio_h HAVE_STDIO_H" +as_fn_append ac_header_cxx_list " stdlib.h stdlib_h HAVE_STDLIB_H" +as_fn_append ac_header_cxx_list " string.h string_h HAVE_STRING_H" +as_fn_append ac_header_cxx_list " inttypes.h inttypes_h HAVE_INTTYPES_H" +as_fn_append ac_header_cxx_list " stdint.h stdint_h HAVE_STDINT_H" +as_fn_append ac_header_cxx_list " strings.h strings_h HAVE_STRINGS_H" +as_fn_append ac_header_cxx_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H" +as_fn_append ac_header_cxx_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H" +as_fn_append ac_header_cxx_list " unistd.h unistd_h HAVE_UNISTD_H" + +# Auxiliary files required by this configure script. +ac_aux_files="config.guess config.sub" + +# Locations in which to look for auxiliary files. +ac_aux_dir_candidates="${srcdir}/autoconf" + +# 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= + for ac_val in x $ac_old_val; do + ac_old_val_w="$ac_old_val_w $ac_val" + done + ac_new_val_w= + for ac_val in x $ac_new_val; do + ac_new_val_w="$ac_new_val_w $ac_val" + done + 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=`printf '%s\n' "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; + *) ac_arg=$ac_var=$ac_new_val ;; + esac + case " $ac_configure_args " in + *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. + *) as_fn_append ac_configure_args " '$ac_arg'" ;; + esac + fi +done +if $ac_cache_corrupted; then + { 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. ## +## -------------------- ## + + +# 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*) + case `echo 'xy\c'` in + *c*) ECHO_T=' ';; # ECHO_T is single tab character. + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; + esac;; +*) + ECHO_N='-n';; +esac + +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 + + +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + + + + + + + + # 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"` +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 + ;; +esac +fi +{ 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;; +esac +build=$ac_cv_build +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_build +shift +build_cpu=$1 +build_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +build_os=$* +IFS=$ac_save_IFS +case $build_os in *\ *) build_os=`printf '%s\n' "$build_os" | sed 's/ /-/g'`;; esac + + +{ 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 +fi + ;; +esac +fi +{ 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;; +esac +host=$ac_cv_host +ac_save_IFS=$IFS; IFS='-' +set x $ac_cv_host +shift +host_cpu=$1 +host_vendor=$2 +shift; shift +# Remember, the first character of IFS is used to create $*, +# except with old shells: +host_os=$* +IFS=$ac_save_IFS +case $host_os in *\ *) host_os=`printf '%s\n' "$host_os" | sed 's/ /-/g'`;; esac @@ -2491,16 +2900,18 @@ case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac esac - if test "$ON_MAC" = "yes"; then : + if test "$ON_MAC" = "yes" +then : # Extract the first word of "xcrun", so it can be a program name with args. set dummy xcrun; 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_path_XCRUN+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $XCRUN in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_XCRUN+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $XCRUN in [\\/]* | ?:[\\/]*) ac_cv_path_XCRUN="$XCRUN" # Let the user override the test with a path. ;; @@ -2509,45 +2920,1129 @@ else 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_path_XCRUN="$as_dir/$ac_word$ac_exec_ext" - $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_path_XCRUN="$as_dir$ac_word$ac_exec_ext" + 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 + done +IFS=$as_save_IFS + + test -z "$ac_cv_path_XCRUN" && ac_cv_path_XCRUN="noxcrun" + ;; +esac ;; +esac +fi +XCRUN=$ac_cv_path_XCRUN +if test -n "$XCRUN"; then + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $XCRUN" >&5 +printf '%s\n' "$XCRUN" >&6; } +else + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf '%s\n' "no" >&6; } +fi + + + if test "$ac_cv_path_XCRUN" = "norun" +then : + as_fn_error $? "could not find xcrun - install Xcode command line tools" "$LINENO" 5 +fi + XCODE_SDK_PATH=`$XCRUN --show-sdk-path` + XTRAINCPATHS="-I/usr/X11/include -I${XCODE_SDK_PATH}/usr/include -I${XCODE_SDK_PATH}/usr/include/libxml2" + +else case e in #( + e) + XTRAINCPATHS="-I/usr/include/libxml2/" + ;; +esac +fi + CFLAGS="$CFLAGS $XTRAINCPATHS" + CPPFLAGS="$CPPFLAGS $XTRAINCPATHS" + + + + + + + + + + + + + + +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 +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 +{ 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}gcc" + 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 "gcc", so it can be a program name with args. +set dummy gcc; 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="gcc" + 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 + +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 +{ 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}cc" + 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 +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 +{ 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 +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 + if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then + ac_prog_rejected=yes + continue + fi + ac_cv_prog_CC="cc" + 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 + +if test $ac_prog_rejected = yes; then + # We found a bogon in the path, so make sure we never use it. + set dummy $ac_cv_prog_CC + shift + if test $# != 0; then + # We chose a different compiler from the bogus one. + # 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+' '}$@" + fi +fi +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 "$CC"; then + if test -n "$ac_tool_prefix"; then + for ac_prog in cl.exe + 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_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$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 +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 + + + test -n "$CC" && break + done +fi +if test -z "$CC"; then + ac_ct_CC=$CC + for ac_prog in cl.exe +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_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="$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 +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 + + + test -n "$ac_ct_CC" && break +done + + 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 +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" && { { 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; } + +# Provide some information about the compiler. +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 -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\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done + +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main (void) +{ + + ; + return 0; +} +_ACEOF +ac_clean_files_save=$ac_clean_files +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. +{ 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.*" + +ac_rmfiles= +for ac_file in $ac_files +do + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + * ) ac_rmfiles="$ac_rmfiles $ac_file";; + esac +done +rm -f $ac_rmfiles + +if { { ac_try="$ac_link_default" +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\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_link_default") 2>&5 + ac_status=$? + 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. +for ac_file in $ac_files '' +do + test -f "$ac_file" || continue + case $ac_file in + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) + ;; + [ab].out ) + # We found the default executable, but exeext='' is most + # certainly right. + break;; + *.* ) + 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' + # 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. + break;; + * ) + break;; + esac +done +test "$ac_cv_exeext" = no && ac_cv_exeext= + +else case e in #( + e) ac_file='' ;; +esac +fi +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 + +{ { 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 case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf '%s\n' "yes" >&6; } ;; +esac +fi +{ 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 +{ 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\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + 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 + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; + *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` + break;; + * ) break;; + esac +done +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; } ;; +esac +fi +rm -f conftest conftest$ac_cv_exeext +{ 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 +ac_exeext=$EXEEXT +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main (void) +{ +FILE *f = fopen ("conftest.out", "w"); + if (!f) + return 1; + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_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. +{ 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 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + 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 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + 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 + { { 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 +{ 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.o conftest.obj conftest.out +ac_clean_files=$ac_clean_files_save +{ 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 (void) +{ + + ; + return 0; +} +_ACEOF +rm -f conftest.o conftest.obj +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\"" +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>&5 + ac_status=$? + 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 + *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; + *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` + break;; + esac +done +else case e in #( + e) printf '%s\n' "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&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 $? "cannot compute suffix of object files: cannot compile +See 'config.log' for more details" "$LINENO" 5; } ;; +esac +fi +rm -f conftest.$ac_cv_objext conftest.$ac_ext ;; +esac +fi +{ 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 +{ 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 (void) +{ +#ifndef __GNUC__ + choke me +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_compiler_gnu=yes +else case e in #( + e) ac_compiler_gnu=no ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext +ac_cv_c_compiler_gnu=$ac_compiler_gnu + ;; +esac +fi +{ 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+y} +ac_save_CFLAGS=$CFLAGS +{ 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" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main (void) +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_g=yes +else case e in #( + e) CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main (void) +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + +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 (void) +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_g=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 ;; +esac +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ac_c_werror_flag=$ac_save_c_werror_flag ;; +esac +fi +{ 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 + CFLAGS="-g -O2" + else + CFLAGS="-g" + fi +else + if test "$GCC" = yes; then + CFLAGS="-O2" + else + CFLAGS= + fi +fi +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 C23 features" >&5 +printf %s "checking for $CC option to enable C23 features... " >&6; } +if test ${ac_cv_prog_cc_c23+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_prog_cc_c23=no +ac_save_CC=$CC +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_c_conftest_c23_program +_ACEOF +for ac_arg in '' -std=gnu23 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_c23=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam + test "x$ac_cv_prog_cc_c23" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC ;; +esac +fi - test -z "$ac_cv_path_XCRUN" && ac_cv_path_XCRUN="noxcrun" - ;; +if test "x$ac_cv_prog_cc_c23" = 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_c23" = 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_c23" >&5 +printf '%s\n' "$ac_cv_prog_cc_c23" >&6; } + CC="$CC $ac_cv_prog_cc_c23" ;; esac fi -XCRUN=$ac_cv_path_XCRUN -if test -n "$XCRUN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCRUN" >&5 -$as_echo "$XCRUN" >&6; } -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 -$as_echo "no" >&6; } + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c23 + ac_prog_cc_stdc=c23 ;; +esac fi - - - if test "$ac_cv_path_XCRUN" = "norun"; then : - as_fn_error $? "could not find xcrun - install Xcode command line tools" "$LINENO" 5 fi - XCODE_SDK_PATH=`$XCRUN --show-sdk-path` - XTRAINCPATHS="-I/usr/X11/include -I${XCODE_SDK_PATH}/usr/include -I${XCODE_SDK_PATH}/usr/include/libxml2" +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. */ +$ac_c_conftest_c11_program +_ACEOF +for ac_arg in '' -std=gnu11 -std:c11 +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 -else +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 - XTRAINCPATHS="-I/usr/include/libxml2/" +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__" +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_c89=$ac_arg +fi +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 ;; +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_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 + ac_prog_cc_stdc=c89 ;; +esac +fi fi - CFLAGS="$CFLAGS $XTRAINCPATHS" - CPPFLAGS="$CPPFLAGS $XTRAINCPATHS" +ac_ext=cpp +ac_cpp='$CXXCPP $CPPFLAGS' +ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' @@ -2559,42 +4054,48 @@ if test -z "$CXX"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ 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_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CXX"; 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_CXX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CXX"; then ac_cv_prog_CXX="$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 - 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_CXX="$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 CXX=$ac_cv_prog_CXX if test -n "$CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 -$as_echo "$CXX" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +printf '%s\n' "$CXX" >&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 @@ -2603,42 +4104,48 @@ fi fi if test -z "$CXX"; then ac_ct_CXX=$CXX - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ 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_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CXX"; 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_CXX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_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 - 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_CXX="$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_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 -$as_echo "$ac_ct_CXX" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +printf '%s\n' "$ac_ct_CXX" >&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 @@ -2650,8 +4157,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 CXX=$ac_ct_CXX @@ -2660,291 +4167,42 @@ fi fi fi -# Provide some information about the compiler. -$as_echo "$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 - { { 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 - (eval "$ac_compiler $ac_option >&5") 2>conftest.err - ac_status=$? - if test -s conftest.err; then - sed '10a\ -... rest of stderr output deleted ... - 10q' conftest.err >conftest.er1 - cat conftest.er1 >&5 - fi - rm -f conftest.er1 conftest.err - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -done - -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -ac_clean_files_save=$ac_clean_files -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[^ ]*//'` - -# The possible output files: -ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" - -ac_rmfiles= -for ac_file in $ac_files -do - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - * ) ac_rmfiles="$ac_rmfiles $ac_file";; - esac -done -rm -f $ac_rmfiles - -if { { ac_try="$ac_link_default" -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 - (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' -# 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. -for ac_file in $ac_files '' -do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) - ;; - [ab].out ) - # We found the default executable, but exeext='' is most - # certainly right. - break;; - *.* ) - if test "${ac_cv_exeext+set}" = set && 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' - # 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. - break;; - * ) - break;; - esac -done -test "$ac_cv_exeext" = no && ac_cv_exeext= - -else - ac_file='' -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 -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;} -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; } -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; } -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; } -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 - (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'. -for ac_file in conftest.exe conftest conftest.*; do - test -f "$ac_file" || continue - case $ac_file in - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; - *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` - break;; - * ) 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;} -as_fn_error $? "cannot compute suffix of executables: cannot compile and link -See \`config.log' for more details" "$LINENO" 5; } -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; } - -rm -f conftest.$ac_ext -EXEEXT=$ac_cv_exeext -ac_exeext=$EXEEXT -cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -int -main () -{ -FILE *f = fopen ("conftest.out", "w"); - return ferror (f) || fclose (f) != 0; - - ; - return 0; -} -_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; } -if test "$cross_compiling" != yes; then - { { 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 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } - if { ac_try='./conftest$ac_cv_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 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$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; } - fi - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 -$as_echo "$cross_compiling" >&6; } - -rm -f conftest.$ac_ext conftest$ac_cv_exeext 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 -/* end confdefs.h. */ - -int -main () -{ - - ; - return 0; -} -_ACEOF -rm -f conftest.o conftest.obj -if { { ac_try="$ac_compile" +# Provide some information about the compiler. +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 + { { 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 - (eval "$ac_compile") 2>&5 +printf '%s\n' "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? - $as_echo "$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 - *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; - *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` - break;; - esac + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } done -else - $as_echo "$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;} -as_fn_error $? "cannot compute suffix of object files: cannot compile -See \`config.log' for more details" "$LINENO" 5; } -fi -rm -f conftest.$ac_cv_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 -$as_echo "$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_cxx_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_cxx_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 @@ -2954,30 +4212,36 @@ main () return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_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_cxx_compiler_gnu=$ac_compiler_gnu - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 -$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +printf '%s\n' "$ac_cv_cxx_compiler_gnu" >&6; } +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + if test $ac_compiler_gnu = yes; then GXX=yes else GXX= fi -ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_test_CXXFLAGS=${CXXFLAGS+y} ac_save_CXXFLAGS=$CXXFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 -$as_echo_n "checking whether $CXX accepts -g... " >&6; } -if ${ac_cv_prog_cxx_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_cxx_werror_flag=$ac_cxx_werror_flag +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +printf %s "checking whether $CXX accepts -g... " >&6; } +if test ${ac_cv_prog_cxx_g+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" @@ -2985,57 +4249,63 @@ else /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : ac_cv_prog_cxx_g=yes -else - CXXFLAGS="" +else case e in #( + e) CXXFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : -else - ac_cxx_werror_flag=$ac_save_cxx_werror_flag +else case e in #( + e) ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : ac_cv_prog_cxx_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_cxx_werror_flag=$ac_save_cxx_werror_flag +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 -$as_echo "$ac_cv_prog_cxx_g" >&6; } -if test "$ac_test_CXXFLAGS" = set; then +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +printf '%s\n' "$ac_cv_prog_cxx_g" >&6; } +if test $ac_test_CXXFLAGS; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then @@ -3062,38 +4332,35 @@ ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_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; } +{ 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; } if test -z "$CXXCPP"; then - if ${ac_cv_prog_CXXCPP+:} false; then : - $as_echo_n "(cached) " >&6 -else - # Double quotes because CXXCPP needs to be expanded - for CXXCPP in "$CXX -E" "/lib/cpp" + if test ${ac_cv_prog_CXXCPP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # Double quotes because $CXX needs to be expanded + for CXXCPP in "$CXX -E" cpp /lib/cpp do ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # 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 -#else -# include -#endif +#include Syntax error _ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : +if ac_fn_cxx_try_cpp "$LINENO" +then : -else - # Broken: fails on valid input. -continue +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext @@ -3103,56 +4370,56 @@ rm -f conftest.err conftest.i conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : +if ac_fn_cxx_try_cpp "$LINENO" +then : # Broken: success on invalid input. continue -else - # Passes both tests. +else case e in #( + e) # Passes both tests. ac_preproc_ok=: -break +break ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +# 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 : +if $ac_preproc_ok +then : break fi done ac_cv_prog_CXXCPP=$CXXCPP - + ;; +esac fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 -$as_echo "$CXXCPP" >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 +printf '%s\n' "$CXXCPP" >&6; } ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. - # Prefer to if __STDC__ is defined, since - # 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 -#else -# include -#endif +#include Syntax error _ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : +if ac_fn_cxx_try_cpp "$LINENO" +then : -else - # Broken: fails on valid input. -continue +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext @@ -3162,26 +4429,30 @@ rm -f conftest.err conftest.i conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : +if ac_fn_cxx_try_cpp "$LINENO" +then : # Broken: success on invalid input. continue -else - # Passes both tests. +else case e in #( + e) # Passes both tests. ac_preproc_ok=: -break +break ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +# 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 : +if $ac_preproc_ok +then : -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 $? "C++ preprocessor \"$CXXCPP\" fails sanity check -See \`config.log' for more details" "$LINENO" 5; } +See 'config.log' for more details" "$LINENO" 5; } ;; +esac fi ac_ext=cpp @@ -3191,297 +4462,97 @@ ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ex ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -{ $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 -else - 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 grep ggrep; 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 -*GNU*) - ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_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 '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_GREP_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 - 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_GREP_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 - fi -else - ac_cv_path_GREP=$GREP -fi - -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" - - -{ $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 -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 - # 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 +ac_header= ac_cache= +for ac_item in $ac_header_cxx_list do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - 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 - $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 '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 + if test $ac_cache; then + ac_fn_cxx_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 - # 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 + ac_header= ac_cache= + elif test $ac_header; then + ac_cache=$ac_item + else + ac_header=$ac_item fi -else - ac_cv_path_EGREP=$EGREP -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" - - -{ $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 -/* end confdefs.h. */ -#include -#include -#include -#include - -int -main () -{ - - ; - return 0; -} -_ACEOF -if ac_fn_cxx_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. - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - -_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 - -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 - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then : +done -else - ac_cv_header_stdc=no -fi -rm -f conftest* -fi -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 - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include -#include -#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))) -int -main () -{ - int i; - for (i = 0; i < 256; i++) - if (XOR (islower (i), ISLOWER (i)) - || toupper (i) != TOUPPER (i)) - return 2; - return 0; -} -_ACEOF -if ac_fn_cxx_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 -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 -fi +if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes +then : -# 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_cxx_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' "#define STDC_HEADERS 1" >>confdefs.h fi -done - - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 -$as_echo_n "checking for X... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for X" >&5 +printf %s "checking for X... " >&6; } # Check whether --with-x was given. -if test "${with_x+set}" = set; then : +if test ${with_x+y} +then : withval=$with_x; fi -# $have_x is `yes', `no', `disabled', or empty when we do not yet know. +# $have_x is 'yes', 'no', 'disabled', or empty when we do not yet know. if test "x$with_x" = xno; then # The user explicitly disabled X. have_x=disabled else case $x_includes,$x_libraries in #( *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( - *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : - $as_echo_n "(cached) " >&6 -else - # One or both of the vars are not set, and there is no cached value. -ac_x_includes=no ac_x_libraries=no -rm -f -r conftest.dir + *,NONE | NONE,*) if test ${ac_cv_have_x+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # One or both of the vars are not set, and there is no cached value. +ac_x_includes=no +ac_x_libraries=no +# Do we need to do anything special at all? +ac_save_LIBS=$LIBS +LIBS="-lX11 $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main (void) +{ +XrmInitialize () + ; + return 0; +} +_ACEOF +if ac_fn_cxx_try_link "$LINENO" +then : + # We can compile and link X programs with no special options. + ac_x_includes= + ac_x_libraries= +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam \ + conftest$ac_exeext conftest.$ac_ext +LIBS="$ac_save_LIBS" +# If that didn't work, only try xmkmf and file system searches +# for native compilation. +if test x"$ac_x_includes" = xno && test "$cross_compiling" = no +then : + rm -f -r conftest.dir if mkdir conftest.dir; then cd conftest.dir cat >Imakefile <<'_ACEOF' incroot: - @echo incroot='${INCROOT}' + @printf '%s\n' incroot='${INCROOT}' usrlibdir: - @echo usrlibdir='${USRLIBDIR}' + @printf '%s\n' usrlibdir='${USRLIBDIR}' libdir: - @echo libdir='${LIBDIR}' + @printf '%s\n' libdir='${LIBDIR}' _ACEOF if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. @@ -3511,7 +4582,7 @@ _ACEOF rm -f -r conftest.dir fi -# Standard set of common directories for X headers. + # Standard set of common directories for X headers. # Check X11 before X11Rn because it is often a symlink to the current release. ac_x_header_dirs=' /usr/X11/include @@ -3538,6 +4609,8 @@ ac_x_header_dirs=' /usr/local/include/X11R5 /usr/local/include/X11R4 +/opt/X11/include + /usr/X386/include /usr/x386/include /usr/XFree86/include/X11 @@ -3559,16 +4632,18 @@ if test "$ac_x_includes" = no; then /* end confdefs.h. */ #include _ACEOF -if ac_fn_cxx_try_cpp "$LINENO"; then : +if ac_fn_cxx_try_cpp "$LINENO" +then : # We can compile using X headers with no special include directory. ac_x_includes= -else - for ac_dir in $ac_x_header_dirs; do +else case e in #( + e) for ac_dir in $ac_x_header_dirs; do if test -r "$ac_dir/X11/Xlib.h"; then ac_x_includes=$ac_dir break fi -done +done ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext fi # $ac_x_includes = no @@ -3583,20 +4658,21 @@ if test "$ac_x_libraries" = no; then /* end confdefs.h. */ #include int -main () +main (void) { XrmInitialize () ; return 0; } _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_link "$LINENO" +then : LIBS=$ac_save_LIBS # We can link X programs with no special library path. ac_x_libraries= -else - LIBS=$ac_save_LIBS -for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` +else case e in #( + e) LIBS=$ac_save_LIBS +for ac_dir in `printf '%s\n' "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` do # Don't even attempt the hair of trying to link an X program! for ac_extension in a so sl dylib la dll; do @@ -3605,21 +4681,25 @@ do break 2 fi done -done +done ;; +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 fi # $ac_x_libraries = no +fi +# Record the results. case $ac_x_includes,$ac_x_libraries in #( - no,* | *,no | *\'*) + no,* | *,no | *\'*) : # Didn't find X, or a directory has "'" in its name. - ac_cv_have_x="have_x=no";; #( - *) + ac_cv_have_x="have_x=no" ;; #( + *) : # Record where we found X for the cache. ac_cv_have_x="have_x=yes\ ac_x_includes='$ac_x_includes'\ - ac_x_libraries='$ac_x_libraries'" + ac_x_libraries='$ac_x_libraries'" ;; +esac ;; esac fi ;; #( @@ -3629,8 +4709,8 @@ fi fi # $with_x != no if test "$have_x" != yes; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 -$as_echo "$have_x" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 +printf '%s\n' "$have_x" >&6; } no_x=yes else # If each of the values was on the command line, it overrides each guess. @@ -3640,167 +4720,197 @@ else ac_cv_have_x="have_x=yes\ ac_x_includes='$x_includes'\ ac_x_libraries='$x_libraries'" - { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 -$as_echo "libraries $x_libraries, headers $x_includes" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 +printf '%s\n' "libraries $x_libraries, headers $x_includes" >&6; } fi - if test "$no_x" = "yes"; then : + if test "$no_x" = "yes" +then : USE_X_WINDOWS=0 -else - +else case e in #( + e) USE_X_WINDOWS=1 - if test "x$x_includes" = "x"; then : + if test "x$x_includes" = "x" +then : -else - X_INCLUDE_DIR=-I$x_includes +else case e in #( + e) X_INCLUDE_DIR=-I$x_includes ;; +esac fi - if test "x$x_libraries" = "x"; then : + if test "x$x_libraries" = "x" +then : -else - X_LIB_DIR=-L$x_libraries +else case e in #( + e) X_LIB_DIR=-L$x_libraries ;; +esac fi - ac_fn_cxx_check_header_mongrel "$LINENO" "X11/Intrinsic.h" "ac_cv_header_X11_Intrinsic_h" "$ac_includes_default" -if test "x$ac_cv_header_X11_Intrinsic_h" = xyes; then : + ac_fn_cxx_check_header_compile "$LINENO" "X11/Intrinsic.h" "ac_cv_header_X11_Intrinsic_h" "$ac_includes_default" +if test "x$ac_cv_header_X11_Intrinsic_h" = xyes +then : -else - as_fn_error $? "could not find libxt development headers" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find libxt development headers" "$LINENO" 5 ;; +esac fi - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for trick_source/data_products/fermi-ware" >&5 -$as_echo_n "checking for trick_source/data_products/fermi-ware... " >&6; } -if ${ac_cv_file_trick_source_data_products_fermi_ware+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for trick_source/data_products/fermi-ware" >&5 +printf %s "checking for trick_source/data_products/fermi-ware... " >&6; } +if test ${ac_cv_file_trick_source_data_products_fermi_ware+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "trick_source/data_products/fermi-ware"; then ac_cv_file_trick_source_data_products_fermi_ware=yes else ac_cv_file_trick_source_data_products_fermi_ware=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file_trick_source_data_products_fermi_ware" >&5 -$as_echo "$ac_cv_file_trick_source_data_products_fermi_ware" >&6; } -if test "x$ac_cv_file_trick_source_data_products_fermi_ware" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file_trick_source_data_products_fermi_ware" >&5 +printf '%s\n' "$ac_cv_file_trick_source_data_products_fermi_ware" >&6; } +if test "x$ac_cv_file_trick_source_data_products_fermi_ware" = xyes +then : - ac_fn_cxx_check_header_mongrel "$LINENO" "Xm/Xm.h" "ac_cv_header_Xm_Xm_h" "$ac_includes_default" -if test "x$ac_cv_header_Xm_Xm_h" = xyes; then : + ac_fn_cxx_check_header_compile "$LINENO" "Xm/Xm.h" "ac_cv_header_Xm_Xm_h" "$ac_includes_default" +if test "x$ac_cv_header_Xm_Xm_h" = xyes +then : MOTIF_HOME="/usr" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/local/include/Xm/Xm.h" >&5 -$as_echo_n "checking for /usr/local/include/Xm/Xm.h... " >&6; } -if ${ac_cv_file__usr_local_include_Xm_Xm_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /usr/local/include/Xm/Xm.h" >&5 +printf %s "checking for /usr/local/include/Xm/Xm.h... " >&6; } +if test ${ac_cv_file__usr_local_include_Xm_Xm_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/usr/local/include/Xm/Xm.h"; then ac_cv_file__usr_local_include_Xm_Xm_h=yes else ac_cv_file__usr_local_include_Xm_Xm_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_local_include_Xm_Xm_h" >&5 -$as_echo "$ac_cv_file__usr_local_include_Xm_Xm_h" >&6; } -if test "x$ac_cv_file__usr_local_include_Xm_Xm_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_local_include_Xm_Xm_h" >&5 +printf '%s\n' "$ac_cv_file__usr_local_include_Xm_Xm_h" >&6; } +if test "x$ac_cv_file__usr_local_include_Xm_Xm_h" = xyes +then : MOTIF_HOME="/usr/local" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/Xm/Xm.h" >&5 -$as_echo_n "checking for /opt/homebrew/include/Xm/Xm.h... " >&6; } -if ${ac_cv_file__opt_homebrew_include_Xm_Xm_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/Xm/Xm.h" >&5 +printf %s "checking for /opt/homebrew/include/Xm/Xm.h... " >&6; } +if test ${ac_cv_file__opt_homebrew_include_Xm_Xm_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/opt/homebrew/include/Xm/Xm.h"; then ac_cv_file__opt_homebrew_include_Xm_Xm_h=yes else ac_cv_file__opt_homebrew_include_Xm_Xm_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_Xm_Xm_h" >&5 -$as_echo "$ac_cv_file__opt_homebrew_include_Xm_Xm_h" >&6; } -if test "x$ac_cv_file__opt_homebrew_include_Xm_Xm_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_Xm_Xm_h" >&5 +printf '%s\n' "$ac_cv_file__opt_homebrew_include_Xm_Xm_h" >&6; } +if test "x$ac_cv_file__opt_homebrew_include_Xm_Xm_h" = xyes +then : MOTIF_HOME="/opt/homebrew" -else - as_fn_error $? "could not find Xm/Xm.h" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find Xm/Xm.h" "$LINENO" 5 ;; +esac fi - + ;; +esac fi - + ;; +esac fi - -else - +else case e in #( + e) MOTIF_HOME="" - + ;; +esac fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lxml2" >&5 -$as_echo_n "checking for main in -lxml2... " >&6; } -if ${ac_cv_lib_xml2_main+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for main in -lxml2" >&5 +printf %s "checking for main in -lxml2... " >&6; } +if test ${ac_cv_lib_xml2_main+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lxml2 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +namespace conftest { + extern "C" int main (); +} int -main () +main (void) { -return main (); +return conftest::main (); ; return 0; } _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_link "$LINENO" +then : ac_cv_lib_xml2_main=yes -else - ac_cv_lib_xml2_main=no +else case e in #( + e) ac_cv_lib_xml2_main=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_xml2_main" >&5 -$as_echo "$ac_cv_lib_xml2_main" >&6; } -if test "x$ac_cv_lib_xml2_main" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_main" >&5 +printf '%s\n' "$ac_cv_lib_xml2_main" >&6; } +if test "x$ac_cv_lib_xml2_main" = xyes +then : LIBXML=-lxml2 fi -ac_fn_cxx_check_header_mongrel "$LINENO" "libxml/tree.h" "ac_cv_header_libxml_tree_h" "$ac_includes_default" -if test "x$ac_cv_header_libxml_tree_h" = xyes; then : +ac_fn_cxx_check_header_compile "$LINENO" "libxml/tree.h" "ac_cv_header_libxml_tree_h" "$ac_includes_default" +if test "x$ac_cv_header_libxml_tree_h" = xyes +then : -else - as_fn_error $? "could not find libxml development headers" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find libxml development headers" "$LINENO" 5 ;; +esac fi - # If 32bit is specified, set some compilation flags. # Check whether --enable-32bit was given. -if test "${enable_32bit+set}" = set; then : - enableval=$enable_32bit; if test "x$enable_32bit" = xyes; then : +if test ${enable_32bit+y} +then : + enableval=$enable_32bit; if test "x$enable_32bit" = xyes +then : TRICK_FORCE_32BIT=1 CFLAGS="${CFLAGS} -m32" @@ -3808,67 +4918,81 @@ if test "${enable_32bit+set}" = set; then : LDFLAGS="${LDFLAGS} -m32" ARCH="i686" -else - TRICK_FORCE_32BIT=0 +else case e in #( + e) TRICK_FORCE_32BIT=0 ;; +esac fi -else - TRICK_FORCE_32BIT=0 - +else case e in #( + e) TRICK_FORCE_32BIT=0 + ;; +esac fi # If offline is specified, set some compilation flags # Check whether --enable-offline was given. -if test "${enable_offline+set}" = set; then : - enableval=$enable_offline; if test "x$enable_offline" = xyes; then : +if test ${enable_offline+y} +then : + enableval=$enable_offline; if test "x$enable_offline" = xyes +then : TRICK_OFFLINE="1" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for trick-offline" >&5 -$as_echo_n "checking for trick-offline... " >&6; } -if ${ac_cv_file_trick_offline+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for trick-offline" >&5 +printf %s "checking for trick-offline... " >&6; } +if test ${ac_cv_file_trick_offline+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "trick-offline"; then ac_cv_file_trick_offline=yes else ac_cv_file_trick_offline=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file_trick_offline" >&5 -$as_echo "$ac_cv_file_trick_offline" >&6; } -if test "x$ac_cv_file_trick_offline" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file_trick_offline" >&5 +printf '%s\n' "$ac_cv_file_trick_offline" >&6; } +if test "x$ac_cv_file_trick_offline" = xyes +then : -else - as_fn_error $? "Offline mode requires an uncompressed directory named \"trick-offline\" in TRICK_HOME" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "Offline mode requires an uncompressed directory named \"trick-offline\" in TRICK_HOME" "$LINENO" 5 ;; +esac fi -else - TRICK_OFFLINE="0" - +else case e in #( + e) TRICK_OFFLINE="0" + ;; +esac fi -else - TRICK_OFFLINE="0" - +else case e in #( + e) TRICK_OFFLINE="0" + ;; +esac fi # If offline is specified, set some compilation flags # Check whether --enable-offline was given. -if test "${enable_offline+set}" = set; then : - enableval=$enable_offline; if test "x$enable_offline" = xyes; then : +if test ${enable_offline+y} +then : + enableval=$enable_offline; if test "x$enable_offline" = xyes +then : TRICK_OFFLINE="1" -else - TRICK_OFFLINE="0" - +else case e in #( + e) TRICK_OFFLINE="0" + ;; +esac fi -else - TRICK_OFFLINE="0" - +else case e in #( + e) TRICK_OFFLINE="0" + ;; +esac fi @@ -3894,42 +5018,48 @@ fi # ) # AC_SUBST([TRICK_OFFLINE]) -for ac_prog in gawk mawk nawk awk +for ac_prog in gawk mawk nawk awk 'busybox 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 @@ -3944,38 +5074,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 @@ -3984,38 +5120,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 @@ -4023,8 +5165,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 @@ -4037,38 +5179,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 @@ -4077,12 +5225,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 @@ -4090,15 +5239,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 @@ -4114,18 +5267,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 @@ -4136,38 +5290,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 @@ -4180,38 +5340,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 @@ -4223,34 +5389,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 @@ -4260,20 +5532,21 @@ $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 -{ $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 @@ -4283,30 +5556,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" @@ -4314,57 +5593,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 @@ -4379,94 +5664,202 @@ 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 C23 features" >&5 +printf %s "checking for $CC option to enable C23 features... " >&6; } +if test ${ac_cv_prog_cc_c23+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_cv_prog_cc_c23=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -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; -} +$ac_c_conftest_c23_program +_ACEOF +for ac_arg in '' -std=gnu23 +do + CC="$ac_save_CC $ac_arg" + if ac_fn_c_try_compile "$LINENO" +then : + ac_cv_prog_cc_c23=$ac_arg +fi +rm -f core conftest.err conftest.$ac_objext conftest.beam + test "x$ac_cv_prog_cc_c23" != "xno" && break +done +rm -f conftest.$ac_ext +CC=$ac_save_CC ;; +esac +fi -/* 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]; +if test "x$ac_cv_prog_cc_c23" = 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_c23" = 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_c23" >&5 +printf '%s\n' "$ac_cv_prog_cc_c23" >&6; } + CC="$CC $ac_cv_prog_cc_c23" ;; +esac +fi + ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c23 + ac_prog_cc_stdc=c23 ;; +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 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. */ +$ac_c_conftest_c11_program +_ACEOF +for ac_arg in '' -std=gnu11 -std:c11 +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=cpp @@ -4485,42 +5878,48 @@ if test -z "$CXX"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ 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_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$CXX"; 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_CXX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$CXX"; then ac_cv_prog_CXX="$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 - 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_CXX="$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 CXX=$ac_cv_prog_CXX if test -n "$CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 -$as_echo "$CXX" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 +printf '%s\n' "$CXX" >&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 @@ -4529,42 +5928,48 @@ fi fi if test -z "$CXX"; then ac_ct_CXX=$CXX - for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC + for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC clang++ 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_CXX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_CXX"; 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_CXX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_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 - 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_CXX="$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_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 -$as_echo "$ac_ct_CXX" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 +printf '%s\n' "$ac_ct_CXX" >&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 @@ -4576,8 +5981,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 CXX=$ac_ct_CXX @@ -4587,7 +5992,7 @@ fi fi fi # 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 @@ -4597,7 +6002,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_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then @@ -4607,20 +6012,21 @@ $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 -{ $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_cxx_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_cxx_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 @@ -4630,30 +6036,36 @@ main () return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_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_cxx_compiler_gnu=$ac_compiler_gnu - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 -$as_echo "$ac_cv_cxx_compiler_gnu" >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 +printf '%s\n' "$ac_cv_cxx_compiler_gnu" >&6; } +ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + if test $ac_compiler_gnu = yes; then GXX=yes else GXX= fi -ac_test_CXXFLAGS=${CXXFLAGS+set} +ac_test_CXXFLAGS=${CXXFLAGS+y} ac_save_CXXFLAGS=$CXXFLAGS -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 -$as_echo_n "checking whether $CXX accepts -g... " >&6; } -if ${ac_cv_prog_cxx_g+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_save_cxx_werror_flag=$ac_cxx_werror_flag +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 +printf %s "checking whether $CXX accepts -g... " >&6; } +if test ${ac_cv_prog_cxx_g+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" @@ -4661,57 +6073,63 @@ else /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : ac_cv_prog_cxx_g=yes -else - CXXFLAGS="" +else case e in #( + e) CXXFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : -else - ac_cxx_werror_flag=$ac_save_cxx_werror_flag +else case e in #( + e) ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int -main () +main (void) { ; return 0; } _ACEOF -if ac_fn_cxx_try_compile "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : ac_cv_prog_cxx_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_cxx_werror_flag=$ac_save_cxx_werror_flag +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ac_cxx_werror_flag=$ac_save_cxx_werror_flag ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 -$as_echo "$ac_cv_prog_cxx_g" >&6; } -if test "$ac_test_CXXFLAGS" = set; then +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 +printf '%s\n' "$ac_cv_prog_cxx_g" >&6; } +if test $ac_test_CXXFLAGS; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then @@ -4733,29 +6151,35 @@ ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ex ac_compiler_gnu=$ac_cv_cxx_compiler_gnu -if test "$ON_MAC" = "no"; then : +if test "$ON_MAC" = "no" +then : GCC_VERSION="" - if test "x$GCC" = "xyes"; then : - - if test "x$ax_gcc_version_option" != "xno"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking gcc version" >&5 -$as_echo_n "checking gcc version... " >&6; } -if ${ax_cv_gcc_version+:} false; then : - $as_echo_n "(cached) " >&6 -else - + if test "x$GCC" = "xyes" +then : + + if test "x$ax_gcc_version_option" != "xno" +then : + + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking gcc version" >&5 +printf %s "checking gcc version... " >&6; } +if test ${ax_cv_gcc_version+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ax_cv_gcc_version="`$CC -dumpfullversion -dumpversion`" - if test "x$ax_cv_gcc_version" = "x"; then : + if test "x$ax_cv_gcc_version" = "x" +then : ax_cv_gcc_version="" fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_gcc_version" >&5 -$as_echo "$ax_cv_gcc_version" >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ax_cv_gcc_version" >&5 +printf '%s\n' "$ax_cv_gcc_version" >&6; } GCC_VERSION=$ax_cv_gcc_version fi @@ -4764,11 +6188,12 @@ fi fi -if test "x$GCC_VERSION" = "x"; then : +if test "x$GCC_VERSION" = "x" +then : -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking gcc version >= 4.8" >&5 -$as_echo_n "checking gcc version >= 4.8... " >&6; } +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking gcc version >= 4.8" >&5 +printf %s "checking gcc version >= 4.8... " >&6; } @@ -4801,27 +6226,29 @@ x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version if test "$ax_compare_version" = "true" ; 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; } + { 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; } as_fn_error $? "Trick requires gcc version >= 4.8" "$LINENO" 5 fi - + ;; +esac fi CC=`which $CC` CXX=`which $CXX` # Extract the first word of "tee", so it can be a program name with args. set dummy tee; 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_path_TEE+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $TEE in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_TEE+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $TEE in [\\/]* | ?:[\\/]*) ac_cv_path_TEE="$TEE" # Let the user override the test with a path. ;; @@ -4830,11 +6257,15 @@ else 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_path_TEE="$as_dir/$ac_word$ac_exec_ext" - $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_path_TEE="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -4843,29 +6274,32 @@ IFS=$as_save_IFS test -z "$ac_cv_path_TEE" && ac_cv_path_TEE="notee" ;; +esac ;; esac fi TEE=$ac_cv_path_TEE if test -n "$TEE"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 -$as_echo "$TEE" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 +printf '%s\n' "$TEE" >&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 "$ac_cv_path_TEE" = "notee"; then : +if test "$ac_cv_path_TEE" = "notee" +then : as_fn_error $? "could not find tee" "$LINENO" 5 fi # Extract the first word of "ld", so it can be a program name with args. set dummy ld; 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_path_LD+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $LD in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_LD+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $LD in [\\/]* | ?:[\\/]*) ac_cv_path_LD="$LD" # Let the user override the test with a path. ;; @@ -4874,11 +6308,15 @@ else 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_path_LD="$as_dir/$ac_word$ac_exec_ext" - $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_path_LD="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -4887,57 +6325,65 @@ IFS=$as_save_IFS test -z "$ac_cv_path_LD" && ac_cv_path_LD="nold" ;; +esac ;; esac fi LD=$ac_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 -if test "$ac_cv_path_LD" = "nold"; then : +if test "$ac_cv_path_LD" = "nold" +then : as_fn_error $? "could not find ld" "$LINENO" 5 fi for ac_prog in flex lex 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_LEX+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$LEX"; 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_LEX+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$LEX"; then ac_cv_prog_LEX="$LEX" # 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_LEX="$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 LEX=$ac_cv_prog_LEX if test -n "$LEX"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5 -$as_echo "$LEX" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5 +printf '%s\n' "$LEX" >&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 @@ -4945,15 +6391,26 @@ fi done test -n "$LEX" || LEX=":" -if test "x$LEX" != "x:"; then - cat >conftest.l <<_ACEOF + if test "x$LEX" != "x:"; then + cat >conftest.l <<_ACEOF +%{ +#ifdef __cplusplus +extern "C" +#endif +int yywrap(void); +%} %% a { ECHO; } b { REJECT; } c { yymore (); } d { yyless (1); } e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */ - yyless ((input () != 0)); } +#ifdef __cplusplus + yyless ((yyinput () != 0)); +#else + yyless ((input () != 0)); +#endif + } f { unput (yytext[0]); } . { BEGIN INITIAL; } %% @@ -4961,117 +6418,176 @@ f { unput (yytext[0]); } extern char *yytext; #endif int +yywrap (void) +{ + return 1; +} +int main (void) { - return ! yylex () + ! yywrap (); + return ! yylex (); } _ACEOF +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for lex output file root" >&5 +printf %s "checking for lex output file root... " >&6; } +if test ${ac_cv_prog_lex_root+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) +ac_cv_prog_lex_root=unknown { { ac_try="$LEX conftest.l" 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 "$LEX conftest.l") 2>&5 ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5 -$as_echo_n "checking lex output file root... " >&6; } -if ${ac_cv_prog_lex_root+:} false; then : - $as_echo_n "(cached) " >&6 -else - + printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && if test -f lex.yy.c; then ac_cv_prog_lex_root=lex.yy elif test -f lexyy.c; then ac_cv_prog_lex_root=lexyy -else - as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5 +fi ;; +esac fi +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5 +printf '%s\n' "$ac_cv_prog_lex_root" >&6; } +if test "$ac_cv_prog_lex_root" = unknown +then : + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: cannot find output from $LEX; giving up on $LEX" >&5 +printf '%s\n' "$as_me: WARNING: cannot find output from $LEX; giving up on $LEX" >&2;} + LEX=: LEXLIB= fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5 -$as_echo "$ac_cv_prog_lex_root" >&6; } LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root -if test -z "${LEXLIB+set}"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5 -$as_echo_n "checking lex library... " >&6; } -if ${ac_cv_lib_lex+:} false; then : - $as_echo_n "(cached) " >&6 -else +# When compiled as C++, the test lexer declares yywrap with extern "C". +# Solaris 10 lex (Software Generation Utilities (SGU) Solaris-ELF (4.0))'s +# scanner skeleton will provide a conflicting declaration of yywrap, +# *without* extern "C", unless we define this macro on the command line. +# The %{ %} block is not early enough for the definition to be effective. +ac_save_CPPFLAGS="$CPPFLAGS" +CPPFLAGS="$CPPFLAGS -D__EXTERN_C__=1" + +if test ${LEXLIB+y} +then : + +else case e in #( + e) + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for lex library" >&5 +printf %s "checking for lex library... " >&6; } +if test ${ac_cv_lib_lex+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) + ac_save_LIBS="$LIBS" + ac_found=false + for ac_cv_lib_lex in 'none needed' -lfl -ll 'not found'; do + case $ac_cv_lib_lex in #( + 'none needed') : + ;; #( + 'not found') : + break ;; #( + *) : + LIBS="$ac_cv_lib_lex $ac_save_LIBS" ;; #( + *) : + ;; +esac - ac_save_LIBS=$LIBS - ac_cv_lib_lex='none needed' - for ac_lib in '' -lfl -ll; do - LIBS="$ac_lib $ac_save_LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ `cat $LEX_OUTPUT_ROOT.c` _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : - ac_cv_lib_lex=$ac_lib +if ac_fn_cxx_try_link "$LINENO" +then : + ac_found=: 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 - test "$ac_cv_lib_lex" != 'none needed' && break + if $ac_found; then + break + fi done - LIBS=$ac_save_LIBS - + LIBS="$ac_save_LIBS" + ;; +esac +fi +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5 +printf '%s\n' "$ac_cv_lib_lex" >&6; } + if test "$ac_cv_lib_lex" = 'not found' +then : + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: required lex library not found; giving up on $LEX" >&5 +printf '%s\n' "$as_me: WARNING: required lex library not found; giving up on $LEX" >&2;} + LEX=: LEXLIB= +elif test "$ac_cv_lib_lex" = 'none needed' +then : + LEXLIB='' +else case e in #( + e) LEXLIB=$ac_cv_lib_lex ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5 -$as_echo "$ac_cv_lib_lex" >&6; } - test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5 -$as_echo_n "checking whether yytext is a pointer... " >&6; } -if ${ac_cv_prog_lex_yytext_pointer+:} false; then : - $as_echo_n "(cached) " >&6 -else - # POSIX says lex can declare yytext either as a pointer or an array; the +if test "$LEX" != : +then : + +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5 +printf %s "checking whether yytext is a pointer... " >&6; } +if test ${ac_cv_prog_lex_yytext_pointer+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) # POSIX says lex can declare yytext either as a pointer or an array; the # default is implementation-dependent. Figure out which it is, since # not all implementations provide the %pointer and %array declarations. ac_cv_prog_lex_yytext_pointer=no -ac_save_LIBS=$LIBS -LIBS="$LEXLIB $ac_save_LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define YYTEXT_POINTER 1 `cat $LEX_OUTPUT_ROOT.c` _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_compile "$LINENO" +then : ac_cv_prog_lex_yytext_pointer=yes fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_save_LIBS - +rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5 -$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5 +printf '%s\n' "$ac_cv_prog_lex_yytext_pointer" >&6; } if test $ac_cv_prog_lex_yytext_pointer = yes; then -$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h +printf '%s\n' "#define YYTEXT_POINTER 1" >>confdefs.h fi + +fi +CPPFLAGS="$ac_save_CPPFLAGS" rm -f conftest.l $LEX_OUTPUT_ROOT.c fi -if test "x$LEX" = "x:"; then : +if test "x$LEX" = "x:" +then : as_fn_error $? "could not find flex" "$LINENO" 5 fi # Extract the first word of "bison", so it can be a program name with args. set dummy bison; 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_path_BISON+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $BISON in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_BISON+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $BISON in [\\/]* | ?:[\\/]*) ac_cv_path_BISON="$BISON" # Let the user override the test with a path. ;; @@ -5080,11 +6596,15 @@ else 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_path_BISON="$as_dir/$ac_word$ac_exec_ext" - $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_path_BISON="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5093,29 +6613,32 @@ IFS=$as_save_IFS test -z "$ac_cv_path_BISON" && ac_cv_path_BISON="nobison" ;; +esac ;; esac fi BISON=$ac_cv_path_BISON if test -n "$BISON"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5 -$as_echo "$BISON" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5 +printf '%s\n' "$BISON" >&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 "$ac_cv_path_BISON" = "nobison"; then : +if test "$ac_cv_path_BISON" = "nobison" +then : as_fn_error $? "could not find bison" "$LINENO" 5 fi # Extract the first word of "curl", so it can be a program name with args. set dummy curl; 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_path_CURL+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $CURL in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_CURL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $CURL in [\\/]* | ?:[\\/]*) ac_cv_path_CURL="$CURL" # Let the user override the test with a path. ;; @@ -5124,11 +6647,15 @@ else 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_path_CURL="$as_dir/$ac_word$ac_exec_ext" - $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_path_CURL="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5137,29 +6664,32 @@ IFS=$as_save_IFS test -z "$ac_cv_path_CURL" && ac_cv_path_CURL="nocurl" ;; +esac ;; esac fi CURL=$ac_cv_path_CURL if test -n "$CURL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURL" >&5 -$as_echo "$CURL" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $CURL" >&5 +printf '%s\n' "$CURL" >&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 "$ac_cv_path_CURL" = "nocurl"; then : +if test "$ac_cv_path_CURL" = "nocurl" +then : as_fn_error $? "could not find curl" "$LINENO" 5 fi # Extract the first word of "perl", so it can be a program name with args. set dummy perl; 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_path_PERL+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PERL in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PERL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PERL in [\\/]* | ?:[\\/]*) ac_cv_path_PERL="$PERL" # Let the user override the test with a path. ;; @@ -5168,11 +6698,15 @@ else 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_path_PERL="$as_dir/$ac_word$ac_exec_ext" - $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_path_PERL="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5180,24 +6714,26 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PERL=$ac_cv_path_PERL if test -n "$PERL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 -$as_echo "$PERL" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +printf '%s\n' "$PERL" >&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 -{ $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 @@ -5210,25 +6746,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 @@ -5254,23 +6796,96 @@ 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 +{ 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 + 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_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_GREP="$ac_path_GREP" ac_path_GREP_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' '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_GREP_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 + 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_GREP_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 + fi +else + ac_cv_path_GREP=$GREP +fi + ;; +esac +fi +{ 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" + + - if test -n "$PERL"; then : + if test -n "$PERL" +then : ax_perl_version="5.14.0" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl version" >&5 -$as_echo_n "checking for perl version... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for perl version" >&5 +printf %s "checking for perl version... " >&6; } perl_version=`$PERL --version 2>&1 \ | $SED -n -e '/This is perl/b inspect @@ -5278,8 +6893,8 @@ b : inspect s/.* (\{0,1\}v\([0-9]*\.[0-9]*\.[0-9]*\))\{0,1\} .*/\1/;p'` - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $perl_version" >&5 -$as_echo "$perl_version" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $perl_version" >&5 +printf '%s\n' "$perl_version" >&6; } PERL_VERSION=$perl_version @@ -5327,22 +6942,24 @@ x$ax_compare_version_B" | sed 's/^ *//' | sort | sed "s/x${ax_compare_version_A} fi -else - - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find the perl interpreter" >&5 -$as_echo "$as_me: WARNING: could not find the perl interpreter" >&2;} +else case e in #( + e) + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: could not find the perl interpreter" >&5 +printf '%s\n' "$as_me: WARNING: could not find the perl interpreter" >&2;} as_fn_error $? "Trick requires perl version >= 5.14.0" "$LINENO" 5 - + ;; +esac fi # Extract the first word of "zip", so it can be a program name with args. set dummy zip; 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_path_ZIP+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $ZIP in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_ZIP+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $ZIP in [\\/]* | ?:[\\/]*) ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. ;; @@ -5351,11 +6968,15 @@ else 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_path_ZIP="$as_dir/$ac_word$ac_exec_ext" - $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_path_ZIP="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5364,19 +6985,21 @@ IFS=$as_save_IFS test -z "$ac_cv_path_ZIP" && ac_cv_path_ZIP="nozip" ;; +esac ;; esac fi ZIP=$ac_cv_path_ZIP if test -n "$ZIP"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 -$as_echo "$ZIP" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 +printf '%s\n' "$ZIP" >&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 "$ac_cv_path_ZIP" = "nozip"; then : +if test "$ac_cv_path_ZIP" = "nozip" +then : as_fn_error $? "Trick now requires zip but it could not be found. Please install zip. We recommend you use your OS package manager" "$LINENO" 5 fi @@ -5385,19 +7008,21 @@ fi # Check whether --with-python was given. -if test "${with_python+set}" = set; then : +if test ${with_python+y} +then : withval=$with_python; PYTHON_HOME="$withval" for ac_prog in python${PYTHON_VERSION} python python3 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_path_PYTHON+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PYTHON in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PYTHON+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PYTHON in [\\/]* | ?:[\\/]*) ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path. ;; @@ -5406,11 +7031,15 @@ else for as_dir in "$PYTHON_HOME" 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_path_PYTHON="$as_dir/$ac_word$ac_exec_ext" - $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_path_PYTHON="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5418,15 +7047,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PYTHON=$ac_cv_path_PYTHON if test -n "$PYTHON"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 -$as_echo "$PYTHON" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 +printf '%s\n' "$PYTHON" >&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 @@ -5434,7 +7064,8 @@ fi done test -n "$PYTHON" || PYTHON="nopython" - if test "$ac_cv_path_PYTHON" = "" || test "$ac_cv_path_PYTHON" = "nopython"; then : + if test "$ac_cv_path_PYTHON" = "" || test "$ac_cv_path_PYTHON" = "nopython" +then : as_fn_error $? "could not find python python or python3 in the specefied path. Please install the python development package" "$LINENO" 5 fi PYTHON_MAJORMINOR=`${PYTHON} -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))'` @@ -5443,12 +7074,13 @@ fi 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_path_PYTHON_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PYTHON_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PYTHON_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PYTHON_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PYTHON_CONFIG="$PYTHON_CONFIG" # Let the user override the test with a path. ;; @@ -5457,11 +7089,15 @@ else for as_dir in "$PYTHON_HOME" 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_path_PYTHON_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_PYTHON_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5469,15 +7105,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PYTHON_CONFIG=$ac_cv_path_PYTHON_CONFIG if test -n "$PYTHON_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CONFIG" >&5 -$as_echo "$PYTHON_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CONFIG" >&5 +printf '%s\n' "$PYTHON_CONFIG" >&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 @@ -5485,22 +7122,24 @@ fi done test -n "$PYTHON_CONFIG" || PYTHON_CONFIG="nopython-config" - if test "$ac_cv_path_PYTHON_CONFIG" = "" || test "$ac_cv_path_PYTHON_CONFIG" = "nopython-config"; then : + if test "$ac_cv_path_PYTHON_CONFIG" = "" || test "$ac_cv_path_PYTHON_CONFIG" = "nopython-config" +then : as_fn_error $? "could not find python-config python-config or python-config in the specified path. Please install the python development package" "$LINENO" 5 fi -else - +else case e in #( + e) for ac_prog in python${PYTHON_VERSION} python python3 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_path_PYTHON+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PYTHON in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PYTHON+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PYTHON in [\\/]* | ?:[\\/]*) ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path. ;; @@ -5509,11 +7148,15 @@ else 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_path_PYTHON="$as_dir/$ac_word$ac_exec_ext" - $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_path_PYTHON="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5521,15 +7164,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PYTHON=$ac_cv_path_PYTHON if test -n "$PYTHON"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 -$as_echo "$PYTHON" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5 +printf '%s\n' "$PYTHON" >&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 @@ -5537,7 +7181,8 @@ fi done test -n "$PYTHON" || PYTHON="nopython" - if test {"$ac_cv_path_PYTHON" = "" || test "${ac_cv_path_PYTHON}" = "nopython"}; then : + if test {"$ac_cv_path_PYTHON" = "" || test "${ac_cv_path_PYTHON}" = "nopython"} +then : as_fn_error $? "could not find python python or python3. Please install the python development package" "$LINENO" 5 fi PYTHON_MAJORMINOR=`${PYTHON} -c 'import sys; print(str(sys.version_info[0])+"."+str(sys.version_info[1]))'` @@ -5546,12 +7191,13 @@ fi 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_path_PYTHON_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PYTHON_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PYTHON_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PYTHON_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PYTHON_CONFIG="$PYTHON_CONFIG" # Let the user override the test with a path. ;; @@ -5560,11 +7206,15 @@ else 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_path_PYTHON_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_PYTHON_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5572,15 +7222,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PYTHON_CONFIG=$ac_cv_path_PYTHON_CONFIG if test -n "$PYTHON_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CONFIG" >&5 -$as_echo "$PYTHON_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PYTHON_CONFIG" >&5 +printf '%s\n' "$PYTHON_CONFIG" >&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 @@ -5588,11 +7239,13 @@ fi done test -n "$PYTHON_CONFIG" || PYTHON_CONFIG="nopython-config" - if test "$ac_cv_path_PYTHON_CONFIG" = "" || test "$ac_cv_path_PYTHON_CONFIG" = "nopython-config"; then : + if test "$ac_cv_path_PYTHON_CONFIG" = "" || test "$ac_cv_path_PYTHON_CONFIG" = "nopython-config" +then : as_fn_error $? "could not find python-config python-config or python-config. Please install the python development package" "$LINENO" 5 fi - + ;; +esac fi @@ -5644,26 +7297,31 @@ PYTHON_LIBS=`${PYTHON_LIBS_COMMAND} | tr '\r\n' ' '` # Check whether --with-prepend-path was given. -if test "${with_prepend_path+set}" = set; then : - withval=$with_prepend_path; if test "x${with_prepend_path}" = xyes; then : +if test ${with_prepend_path+y} +then : + withval=$with_prepend_path; if test "x${with_prepend_path}" = xyes +then : PATH="/usr/local/bin:${PATH}" -else - if test "x${with_prepend_path}" != xno; then : +else case e in #( + e) if test "x${with_prepend_path}" != xno +then : PATH="${withval}:${PATH}" fi - + ;; +esac fi fi # Extract the first word of "gnuplot", so it can be a program name with args. set dummy gnuplot; 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_path_GNUPLOT+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $GNUPLOT in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_GNUPLOT+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $GNUPLOT in [\\/]* | ?:[\\/]*) ac_cv_path_GNUPLOT="$GNUPLOT" # Let the user override the test with a path. ;; @@ -5672,11 +7330,15 @@ else 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_path_GNUPLOT="$as_dir/$ac_word$ac_exec_ext" - $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_path_GNUPLOT="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5685,26 +7347,29 @@ IFS=$as_save_IFS test -z "$ac_cv_path_GNUPLOT" && ac_cv_path_GNUPLOT="nognuplot" ;; +esac ;; esac fi GNUPLOT=$ac_cv_path_GNUPLOT if test -n "$GNUPLOT"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNUPLOT" >&5 -$as_echo "$GNUPLOT" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $GNUPLOT" >&5 +printf '%s\n' "$GNUPLOT" >&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 "$ac_cv_path_GNUPLOT" = "nognuplot"; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: could not find gnuplot" >&5 -$as_echo "$as_me: could not find gnuplot" >&6;} +if test "$ac_cv_path_GNUPLOT" = "nognuplot" +then : + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: could not find gnuplot" >&5 +printf '%s\n' "$as_me: could not find gnuplot" >&6;} fi # Check whether --with-swig was given. -if test "${with_swig+set}" = set; then : +if test ${with_swig+y} +then : withval=$with_swig; TEMP_PATH="${PATH}" PATH="$withval:${PATH}" @@ -5714,12 +7379,13 @@ if test "${with_swig+set}" = set; 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_path_SWIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $SWIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_SWIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $SWIG in [\\/]* | ?:[\\/]*) ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. ;; @@ -5728,11 +7394,15 @@ else 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_path_SWIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_SWIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5740,15 +7410,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi SWIG=$ac_cv_path_SWIG if test -n "$SWIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +printf '%s\n' "$SWIG" >&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 @@ -5757,12 +7428,14 @@ done if test -z "$SWIG" ; then as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 - elif test -n "3.0" ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG version" >&5 -$as_echo_n "checking SWIG version... " >&6; } + elif test -z "3.0" ; then + : + else + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking SWIG version" >&5 +printf %s "checking SWIG version... " >&6; } swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 -$as_echo "$swig_version" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 +printf '%s\n' "$swig_version" >&6; } if test -n "$swig_version" ; then # Calculate the required version number components required=3.0 @@ -5770,12 +7443,12 @@ $as_echo "$swig_version" >&6; } if test -z "$required_major" ; then required_major=0 fi - required=`echo $required | sed 's/[0-9]*[^0-9]//'` + required=`echo $required. | sed 's/[0-9]*[^0-9]//'` required_minor=`echo $required | sed 's/[^0-9].*//'` if test -z "$required_minor" ; then required_minor=0 fi - required=`echo $required | sed 's/[0-9]*[^0-9]//'` + required=`echo $required. | sed 's/[0-9]*[^0-9]//'` required_patch=`echo $required | sed 's/[^0-9].*//'` if test -z "$required_patch" ; then required_patch=0 @@ -5805,21 +7478,21 @@ $as_echo "$swig_version" >&6; } \+ $available_minor \* 100 \+ $available_patch` if test $available_swig_vernum -lt $required_swig_vernum; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&5 -$as_echo "$as_me: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&5 +printf '%s\n' "$as_me: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&2;} SWIG='' as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG library" >&5 -$as_echo_n "checking for SWIG library... " >&6; } - SWIG_LIB=`$SWIG -swiglib` - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG_LIB" >&5 -$as_echo "$SWIG_LIB" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for SWIG library" >&5 +printf %s "checking for SWIG library... " >&6; } + SWIG_LIB=`$SWIG -swiglib | tr '\r\n' ' '` + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $SWIG_LIB" >&5 +printf '%s\n' "$SWIG_LIB" >&6; } fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5 -$as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5 +printf '%s\n' "$as_me: WARNING: cannot determine SWIG version" >&2;} SWIG='' as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 fi @@ -5828,19 +7501,20 @@ $as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;} PATH="${TEMP_PATH}" -else - +else case e in #( + e) # Find path to the "swig" executable. for ac_prog in swig swig3.0 swig2.0 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_path_SWIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $SWIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_SWIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $SWIG in [\\/]* | ?:[\\/]*) ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. ;; @@ -5849,11 +7523,15 @@ else 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_path_SWIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_SWIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -5861,15 +7539,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi SWIG=$ac_cv_path_SWIG if test -n "$SWIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +printf '%s\n' "$SWIG" >&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 @@ -5878,12 +7557,14 @@ done if test -z "$SWIG" ; then as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 - elif test -n "3.0" ; then - { $as_echo "$as_me:${as_lineno-$LINENO}: checking SWIG version" >&5 -$as_echo_n "checking SWIG version... " >&6; } + elif test -z "3.0" ; then + : + else + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking SWIG version" >&5 +printf %s "checking SWIG version... " >&6; } swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 -$as_echo "$swig_version" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 +printf '%s\n' "$swig_version" >&6; } if test -n "$swig_version" ; then # Calculate the required version number components required=3.0 @@ -5891,12 +7572,12 @@ $as_echo "$swig_version" >&6; } if test -z "$required_major" ; then required_major=0 fi - required=`echo $required | sed 's/[0-9]*[^0-9]//'` + required=`echo $required. | sed 's/[0-9]*[^0-9]//'` required_minor=`echo $required | sed 's/[^0-9].*//'` if test -z "$required_minor" ; then required_minor=0 fi - required=`echo $required | sed 's/[0-9]*[^0-9]//'` + required=`echo $required. | sed 's/[0-9]*[^0-9]//'` required_patch=`echo $required | sed 's/[^0-9].*//'` if test -z "$required_patch" ; then required_patch=0 @@ -5926,83 +7607,95 @@ $as_echo "$swig_version" >&6; } \+ $available_minor \* 100 \+ $available_patch` if test $available_swig_vernum -lt $required_swig_vernum; then - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&5 -$as_echo "$as_me: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&5 +printf '%s\n' "$as_me: WARNING: SWIG version >= 3.0 is required. You have $swig_version." >&2;} SWIG='' as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG library" >&5 -$as_echo_n "checking for SWIG library... " >&6; } - SWIG_LIB=`$SWIG -swiglib` - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG_LIB" >&5 -$as_echo "$SWIG_LIB" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for SWIG library" >&5 +printf %s "checking for SWIG library... " >&6; } + SWIG_LIB=`$SWIG -swiglib | tr '\r\n' ' '` + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $SWIG_LIB" >&5 +printf '%s\n' "$SWIG_LIB" >&6; } fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5 -$as_echo "$as_me: WARNING: cannot determine SWIG version" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine SWIG version" >&5 +printf '%s\n' "$as_me: WARNING: cannot determine SWIG version" >&2;} SWIG='' as_fn_error $? "Trick requires SWIG version >= 3.0" "$LINENO" 5 fi fi - + ;; +esac fi # Check whether --enable-java was given. -if test "${enable_java+set}" = set; then : - enableval=$enable_java; if test "x$enable_java" = xyes; then : +if test ${enable_java+y} +then : + enableval=$enable_java; if test "x$enable_java" = xyes +then : USE_JAVA="1" -else - USE_JAVA="0" +else case e in #( + e) USE_JAVA="0" ;; +esac fi -else - USE_JAVA="1" - +else case e in #( + e) USE_JAVA="1" + ;; +esac fi - if test "$USE_JAVA" = "1"; then : + if test "$USE_JAVA" = "1" +then : - for ac_prog in gawk mawk nawk awk + for ac_prog in gawk mawk nawk awk 'busybox 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 @@ -6014,38 +7707,44 @@ done 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_JAVA_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$JAVA_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_JAVA_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$JAVA_CC"; then ac_cv_prog_JAVA_CC="$JAVA_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_JAVA_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 JAVA_CC=$ac_cv_prog_JAVA_CC if test -n "$JAVA_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CC" >&5 -$as_echo "$JAVA_CC" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $JAVA_CC" >&5 +printf '%s\n' "$JAVA_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 @@ -6058,38 +7757,44 @@ if test -z "$JAVA_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_JAVA_CC+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$ac_ct_JAVA_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_JAVA_CC+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$ac_ct_JAVA_CC"; then ac_cv_prog_ac_ct_JAVA_CC="$ac_ct_JAVA_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_JAVA_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_JAVA_CC=$ac_cv_prog_ac_ct_JAVA_CC if test -n "$ac_ct_JAVA_CC"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_JAVA_CC" >&5 -$as_echo "$ac_ct_JAVA_CC" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_ct_JAVA_CC" >&5 +printf '%s\n' "$ac_ct_JAVA_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 @@ -6101,8 +7806,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 JAVA_CC=$ac_ct_JAVA_CC @@ -6121,8 +7826,8 @@ fi test -z "$JAVA_CC" && as_fn_error $? "no acceptable java compiler found in \$PATH" "$LINENO" 5 JAVA_VER=`$JAVA_CC -version 2>&1 | $ac_cv_path_PERL -ne 'print $& if /\d+(\.\d+)?/'` - { $as_echo "$as_me:${as_lineno-$LINENO}: checking $JAVA_CC version >= 1.8" >&5 -$as_echo_n "checking $JAVA_CC version >= 1.8... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking $JAVA_CC version >= 1.8" >&5 +printf %s "checking $JAVA_CC version >= 1.8... " >&6; } @@ -6155,24 +7860,26 @@ x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version if test "$ax_compare_version" = "true" ; 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; } + { 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; } as_fn_error $? "Trick requires javac version >= 1.8" "$LINENO" 5 fi - if test "$TRICK_OFFLINE" = "0"; then : + if test "$TRICK_OFFLINE" = "0" +then : # Extract the first word of "mvn", so it can be a program name with args. set dummy mvn; 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_path_MVN+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $MVN in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_MVN+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $MVN in [\\/]* | ?:[\\/]*) ac_cv_path_MVN="$MVN" # Let the user override the test with a path. ;; @@ -6181,11 +7888,15 @@ else 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_path_MVN="$as_dir/$ac_word$ac_exec_ext" - $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_path_MVN="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -6194,19 +7905,21 @@ IFS=$as_save_IFS test -z "$ac_cv_path_MVN" && ac_cv_path_MVN="nomvn" ;; +esac ;; esac fi MVN=$ac_cv_path_MVN if test -n "$MVN"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MVN" >&5 -$as_echo "$MVN" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $MVN" >&5 +printf '%s\n' "$MVN" >&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 "$ac_cv_path_MVN" = "nomvn"; then : + if test "$ac_cv_path_MVN" = "nomvn" +then : as_fn_error $? "could not find maven" "$LINENO" 5 fi @@ -6221,42 +7934,39 @@ 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; } +{ 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 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" + 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. - # Prefer to if __STDC__ is defined, since - # 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 -#else -# include -#endif +#include Syntax error _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_cpp "$LINENO" +then : -else - # Broken: fails on valid input. -continue +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext @@ -6266,56 +7976,56 @@ rm -f conftest.err conftest.i conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_cpp "$LINENO" +then : # Broken: success on invalid input. continue -else - # Passes both tests. +else case e in #( + e) # Passes both tests. ac_preproc_ok=: -break +break ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext done -# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. +# 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 : +if $ac_preproc_ok +then : break fi done ac_cv_prog_CPP=$CPP - + ;; +esac fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 -$as_echo "$CPP" >&6; } +{ 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. - # Prefer to if __STDC__ is defined, since - # 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 -#else -# include -#endif +#include Syntax error _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +if ac_fn_c_try_cpp "$LINENO" +then : -else - # Broken: fails on valid input. -continue +else case e in #( + e) # Broken: fails on valid input. +continue ;; +esac fi rm -f conftest.err conftest.i conftest.$ac_ext @@ -6325,34 +8035,172 @@ rm -f conftest.err conftest.i conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF -if ac_fn_c_try_cpp "$LINENO"; then : +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 + 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_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" -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_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 + : + fi else - # Passes both tests. -ac_preproc_ok=: -break + ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL 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 : + 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 - { { $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; } + ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL 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 - + ;; +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 @@ -6377,38 +8225,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="" @@ -6423,10 +8280,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" @@ -6484,11 +8343,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* ;; @@ -6502,47 +8362,19 @@ 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" - ;; -esac - -# 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" -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 - -case $host_os in - darwin* | hpux* | linux* | osf* | solaris*) - ax_pthread_check_macro="_REENTRANT" - ;; - - aix*) - ax_pthread_check_macro="_THREAD_SAFE" - ;; - - *) - ax_pthread_check_macro="--" + ax_pthread_flags="-mt,-lpthread pthread $ax_pthread_flags" ;; esac -if test "x$ax_pthread_check_macro" = "x--"; then : - ax_pthread_check_cond=0 -else - ax_pthread_check_cond="!defined($ax_pthread_check_macro)" -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 +{ 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 @@ -6554,162 +8386,117 @@ else _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then : + $EGREP_TRADITIONAL "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1 +then : ax_cv_PTHREAD_CLANG=yes fi -rm -f conftest* +rm -rf conftest* fi - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5 -$as_echo "$ax_cv_PTHREAD_CLANG" >&6; } +{ 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" -ax_pthread_clang_warning=no - -# Clang needs special handling, because older versions handle the -pthread -# option in a rather... idiosyncratic way -if test "x$ax_pthread_clang" = "xyes"; then +# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC) - # Clang takes -pthread; it has never supported any other flag +# 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 - # (Note 1: This will need to be revisited if a system that Clang - # supports has POSIX threads in a separate library. This tends not - # to be the way of modern systems, but it's conceivable.) +if test "x$GCC" = "xyes" +then : + ax_pthread_flags="-pthread,-lpthread -pthread -pthreads $ax_pthread_flags" +fi - # (Note 2: On some systems, notably Darwin, -pthread is not needed - # to get POSIX threads support; the API is always present and - # active. We could reasonably leave PTHREAD_CFLAGS empty. But - # -pthread does define _REENTRANT, and while the Darwin headers - # ignore this macro, third-party headers might not.) +# Clang takes -pthread (never supported any other flag), but we'll try with -lpthread first - PTHREAD_CFLAGS="-pthread" - PTHREAD_LIBS= +if test "x$ax_pthread_clang" = "xyes" +then : + ax_pthread_flags="-pthread,-lpthread -pthread" +fi - 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 - # during compilation"). They expect -pthread to be passed in only - # when source code is being compiled. - # - # Problem is, this is at odds with the way Automake and most other - # C build frameworks function, which is that the same flags used in - # compilation (CFLAGS) are also used in linking. Many systems - # supported by AX_PTHREAD require exactly this for POSIX threads - # support, and in fact it is often not straightforward to specify a - # flag that is used only in the compilation phase and not in - # linking. Such a scenario is extremely rare in practice. - # - # Even though use of the -pthread flag in linking would only print - # a warning, this can be a nuisance for well-run software projects - # that build with -Werror. So if the active version of Clang has - # this misfeature, we search for an option to squash it. +# 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 - { $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 - # 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_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 : - break -fi - CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS" - ac_link="$ax_pthread_save_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 : - 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 : - break -fi -rm -f core conftest.err conftest.$ac_objext \ - conftest$ac_exeext conftest.$ac_ext +case $host_os in + darwin* | hpux* | linux* | osf* | solaris*) + ax_pthread_check_macro="_REENTRANT" + ;; -fi -rm -f core conftest.err conftest.$ac_objext \ - 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 : - ax_pthread_try=no -fi - ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try" + aix*) + ax_pthread_check_macro="_THREAD_SAFE" + ;; + *) + ax_pthread_check_macro="--" + ;; +esac +if test "x$ax_pthread_check_macro" = "x--" +then : + ax_pthread_check_cond=0 +else case e in #( + e) ax_pthread_check_cond="!defined($ax_pthread_check_macro)" ;; +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; } - - case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in - no | unknown) ;; - *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;; - esac -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; } + { 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; } ;; - -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" + *,*) + 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; } ;; -*) - { $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; } + { 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" ;; 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 +{ 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 - 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_ax_pthread_config="yes" - $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 @@ -6717,19 +8504,21 @@ done IFS=$as_save_IFS test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no" -fi +fi ;; +esac 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; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5 +printf '%s\n' "$ax_pthread_config" >&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$ax_pthread_config" = "xno"; then : + if test "x$ax_pthread_config" = "xno" +then : continue fi PTHREAD_CFLAGS="`pthread-config --cflags`" @@ -6737,8 +8526,8 @@ fi ;; *) - { $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; } + { 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 @@ -6760,44 +8549,156 @@ $as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -# 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; -} +#include +# 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 + # to be the way of modern systems, but it's conceivable.) + + # (Note 2: On some systems, notably Darwin, -pthread is not needed + # to get POSIX threads support; the API is always present and + # active. We could reasonably leave PTHREAD_CFLAGS empty. But + # -pthread does define _REENTRANT, and while the Darwin headers + # ignore this macro, third-party headers might not.) + + # 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 + # during compilation"). They expect -pthread to be passed in only + # when source code is being compiled. + # + # Problem is, this is at odds with the way Automake and most other + # C build frameworks function, which is that the same flags used in + # compilation (CFLAGS) are also used in linking. Many systems + # supported by AX_PTHREAD require exactly this for POSIX threads + # support, and in fact it is often not straightforward to specify a + # flag that is used only in the compilation phase and not in + # linking. Such a scenario is extremely rare in practice. + # + # Even though use of the -pthread flag in linking would only print + # a warning, this can be a nuisance for well-run software projects + # that build with -Werror. So if the active version of Clang has + # this misfeature, we search for an option to squash it. + + { 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=`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 : + break +fi + CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS" + ac_link="$ax_pthread_save_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 : - ax_pthread_ok=yes +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 : + 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 - 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 +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 : + ax_pthread_try=no +fi + ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try" + ;; +esac fi +{ 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) ;; + *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;; + esac + +fi # $ax_pthread_clang = yes + + # Various other checks: if test "x$ax_pthread_ok" = "xyes"; then @@ -6807,98 +8708,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 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 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 @@ -6916,54 +8828,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 @@ -6973,6 +8957,8 @@ esac fi test -n "$PTHREAD_CC" || PTHREAD_CC="$CC" +test -n "$PTHREAD_CXX" || PTHREAD_CXX="$CXX" + @@ -6981,7 +8967,7 @@ test -n "$PTHREAD_CC" || PTHREAD_CC="$CC" # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND: if test "x$ax_pthread_ok" = "xyes"; then -$as_echo "#define HAVE_PTHREAD 1" >>confdefs.h +printf '%s\n' "#define HAVE_PTHREAD 1" >>confdefs.h : else @@ -7005,38 +8991,44 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -z "$PERL"; then # Extract the first word of "perl", so it can be a program name with args. set dummy perl; 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_PERL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; 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_PERL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$PERL"; then ac_cv_prog_PERL="$PERL" # 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_PERL="perl" - $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 PERL=$ac_cv_prog_PERL if test -n "$PERL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 -$as_echo "$PERL" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +printf '%s\n' "$PERL" >&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 @@ -7045,18 +9037,18 @@ fi if test "x$PERL" != x; then ax_perl_modules_failed=0 for ax_perl_module in 'Text::Balanced' ; do - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5 -$as_echo_n "checking for perl module $ax_perl_module... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5 +printf %s "checking for perl module $ax_perl_module... " >&6; } # Would be nice to log result here, but can't rely on autoconf internals $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1 if test $? -ne 0; then - { $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; }; ax_perl_modules_failed=1 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 done @@ -7069,8 +9061,8 @@ $as_echo "ok" >&6; }; as_fn_error $? "could not find perl modules Text::Balanced" "$LINENO" 5 fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 -$as_echo "$as_me: WARNING: could not find perl" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 +printf '%s\n' "$as_me: WARNING: could not find perl" >&2;} fi @@ -7082,38 +9074,44 @@ fi if test -z "$PERL"; then # Extract the first word of "perl", so it can be a program name with args. set dummy perl; 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_PERL+:} false; then : - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; 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_PERL+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) if test -n "$PERL"; then ac_cv_prog_PERL="$PERL" # 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_PERL="perl" - $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 PERL=$ac_cv_prog_PERL if test -n "$PERL"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 -$as_echo "$PERL" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +printf '%s\n' "$PERL" >&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 @@ -7122,18 +9120,18 @@ fi if test "x$PERL" != x; then ax_perl_modules_failed=0 for ax_perl_module in 'Digest::MD5' ; do - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5 -$as_echo_n "checking for perl module $ax_perl_module... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for perl module $ax_perl_module" >&5 +printf %s "checking for perl module $ax_perl_module... " >&6; } # Would be nice to log result here, but can't rely on autoconf internals $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1 if test $? -ne 0; then - { $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; }; ax_perl_modules_failed=1 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 done @@ -7146,23 +9144,25 @@ $as_echo "ok" >&6; }; as_fn_error $? "could not find perl module Digest::MD5" "$LINENO" 5 fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 -$as_echo "$as_me: WARNING: could not find perl" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 +printf '%s\n' "$as_me: WARNING: could not find perl" >&2;} fi # Check whether --with-llvm was given. -if test "${with_llvm+set}" = set; then : +if test ${with_llvm+y} +then : withval=$with_llvm; LLVM_HOME="$withval" # Extract the first word of "llvm-config", so it can be a program name with args. set dummy llvm-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_path_LLVM_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $LLVM_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_LLVM_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $LLVM_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test with a path. ;; @@ -7171,11 +9171,15 @@ else for as_dir in "$LLVM_HOME/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_exec_ext in '' $ac_executable_extensions; do - if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_path_LLVM_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_LLVM_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -7184,34 +9188,37 @@ IFS=$as_save_IFS test -z "$ac_cv_path_LLVM_CONFIG" && ac_cv_path_LLVM_CONFIG="no-llvm-config" ;; +esac ;; esac fi LLVM_CONFIG=$ac_cv_path_LLVM_CONFIG if test -n "$LLVM_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 -$as_echo "$LLVM_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 +printf '%s\n' "$LLVM_CONFIG" >&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 "$ac_cv_path_LLVM_CONFIG" = "no-llvm-config"; then : + if test "$ac_cv_path_LLVM_CONFIG" = "no-llvm-config" +then : as_fn_error $? "could not find llvm-config" "$LINENO" 5 fi -else - +else case e in #( + e) for ac_prog in llvm-config 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_path_LLVM_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $LLVM_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_LLVM_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $LLVM_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test with a path. ;; @@ -7221,11 +9228,15 @@ as_dummy=""/usr/lib64/llvm20/bin:/usr/lib64/llvm/bin:/bin:/usr/bin:/usr/local/bi for as_dir in $as_dummy 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_path_LLVM_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_LLVM_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -7233,15 +9244,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi LLVM_CONFIG=$ac_cv_path_LLVM_CONFIG if test -n "$LLVM_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 -$as_echo "$LLVM_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 +printf '%s\n' "$LLVM_CONFIG" >&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 @@ -7249,73 +9261,84 @@ fi done test -n "$LLVM_CONFIG" || LLVM_CONFIG="no-llvm-config" - if test "$ac_cv_path_LLVM_CONFIG" = "no-llvm-config"; then : + if test "$ac_cv_path_LLVM_CONFIG" = "no-llvm-config" +then : as_fn_error $? "could not find llvm-config" "$LINENO" 5 fi LLVM_HOME=`$LLVM_CONFIG --prefix` - + ;; +esac fi LLVM_LIB_DIR=`$LLVM_CONFIG --libdir` LLVM_BIN_DIR=`$LLVM_CONFIG --bindir` LLVM_INCLUDE_DIR=`$LLVM_CONFIG --includedir` -as_ac_File=`$as_echo "ac_cv_file_$LLVM_INCLUDE_DIR/clang/Basic/LLVM.h" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_INCLUDE_DIR/clang/Basic/LLVM.h" >&5 -$as_echo_n "checking for $LLVM_INCLUDE_DIR/clang/Basic/LLVM.h... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_INCLUDE_DIR/clang/Basic/LLVM.h" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_INCLUDE_DIR/clang/Basic/LLVM.h" >&5 +printf %s "checking for $LLVM_INCLUDE_DIR/clang/Basic/LLVM.h... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_INCLUDE_DIR/clang/Basic/LLVM.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : -else - as_fn_error $? "could not find clang development headers" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find clang development headers" "$LINENO" 5 ;; +esac fi -as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libLLVMSupport.a" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libLLVMSupport.a" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libLLVMSupport.a... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libLLVMSupport.a" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libLLVMSupport.a" >&5 +printf %s "checking for $LLVM_LIB_DIR/libLLVMSupport.a... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libLLVMSupport.a"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = x"yes"; then : - -else - as_fn_error $? "could not find clang library files in $LLVM_LIB_DIR" "$LINENO" 5 + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf '%s\n' "$ac_res" >&6; } +if eval test \"x\$"$as_ac_File"\" = x"yes" +then : +else case e in #( + e) as_fn_error $? "could not find clang library files in $LLVM_LIB_DIR" "$LINENO" 5 + ;; +esac fi # Extract the first word of "clang", so it can be a program name with args. set dummy clang; 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_path_CLANG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $CLANG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_CLANG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $CLANG in [\\/]* | ?:[\\/]*) ac_cv_path_CLANG="$CLANG" # Let the user override the test with a path. ;; @@ -7325,11 +9348,15 @@ as_dummy=""$LLVM_BIN_DIR:/bin:/usr/bin:/usr/local/bin:/sw/bin"" for as_dir in $as_dummy 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_path_CLANG="$as_dir/$ac_word$ac_exec_ext" - $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_path_CLANG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -7338,19 +9365,21 @@ IFS=$as_save_IFS test -z "$ac_cv_path_CLANG" && ac_cv_path_CLANG="noclang" ;; +esac ;; esac fi CLANG=$ac_cv_path_CLANG if test -n "$CLANG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5 -$as_echo "$CLANG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $CLANG" >&5 +printf '%s\n' "$CLANG" >&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 "$ac_cv_path_CLANG" = "noclang"; then : +if test "$ac_cv_path_CLANG" = "noclang" +then : as_fn_error $? "could not find clang" "$LINENO" 5 fi @@ -7358,7 +9387,8 @@ fi CLANG_VERSION="" ax_cv_clang_version="`$CLANG --version | grep "version" | sed "s/.*version \(0-9*\.0-9*\.0-9*\).*/\1/"`" - if test "x$ax_cv_clang_version" = "x"; then : + if test "x$ax_cv_clang_version" = "x" +then : ax_cv_clang_version="" @@ -7366,11 +9396,12 @@ fi CLANG_VERSION=$ax_cv_clang_version -if test "x$CLANG_VERSION" = "x"; then : +if test "x$CLANG_VERSION" = "x" +then : -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking clang version >= 3.4.2" >&5 -$as_echo_n "checking clang version >= 3.4.2... " >&6; } +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking clang version >= 3.4.2" >&5 +printf %s "checking clang version >= 3.4.2... " >&6; } @@ -7403,21 +9434,23 @@ x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version if test "$ax_compare_version" = "true" ; 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; } + { 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; } as_fn_error $? "Trick requires llvm/clang version >= 3.4.2" "$LINENO" 5 fi - + ;; +esac fi -if test "x$CLANG_VERSION" = "x"; then : - -else +if test "x$CLANG_VERSION" = "x" +then : +else case e in #( + e) # Used to indicate true or false condition @@ -7454,130 +9487,150 @@ x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version fi - + ;; +esac fi NEW_CLANG_LIBS="-lclang-cpp" -as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libclangFrontend.a" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangFrontend.a" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libclangFrontend.a... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libclangFrontend.a" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangFrontend.a" >&5 +printf %s "checking for $LLVM_LIB_DIR/libclangFrontend.a... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libclangFrontend.a"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : ICG_CLANGLIBS="$OLD_CLANG_LIBS" -else - as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libclangFrontend.so" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangFrontend.so" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libclangFrontend.so... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libclangFrontend.so" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangFrontend.so" >&5 +printf %s "checking for $LLVM_LIB_DIR/libclangFrontend.so... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libclangFrontend.so"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : ICG_CLANGLIBS="$OLD_CLANG_LIBS" -else - as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libclang-cpp.a" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclang-cpp.a" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libclang-cpp.a... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libclang-cpp.a" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclang-cpp.a" >&5 +printf %s "checking for $LLVM_LIB_DIR/libclang-cpp.a... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libclang-cpp.a"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : ICG_CLANGLIBS="$NEW_CLANG_LIBS" -else - as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libclang-cpp.so" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclang-cpp.so" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libclang-cpp.so... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libclang-cpp.so" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclang-cpp.so" >&5 +printf %s "checking for $LLVM_LIB_DIR/libclang-cpp.so... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libclang-cpp.so"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : ICG_CLANGLIBS="$NEW_CLANG_LIBS" -else - as_fn_error $? "could not find clang libs in LLVM library: \"$LLVM_LIB_DIR\"" "$LINENO" 5 - +else case e in #( + e) as_fn_error $? "could not find clang libs in LLVM library: \"$LLVM_LIB_DIR\"" "$LINENO" 5 + ;; +esac fi - + ;; +esac fi - + ;; +esac fi - + ;; +esac fi -as_ac_File=`$as_echo "ac_cv_file_$LLVM_LIB_DIR/libclangSupport.a" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangSupport.a" >&5 -$as_echo_n "checking for $LLVM_LIB_DIR/libclangSupport.a... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +as_ac_File=`printf '%s\n' "ac_cv_file_$LLVM_LIB_DIR/libclangSupport.a" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $LLVM_LIB_DIR/libclangSupport.a" >&5 +printf %s "checking for $LLVM_LIB_DIR/libclangSupport.a... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$LLVM_LIB_DIR/libclangSupport.a"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : ICG_CLANGLIBS="$ICG_CLANGLIBS -lclangSupport" fi @@ -7587,30 +9640,32 @@ fi # # Handle user hints # -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if zlib is wanted" >&5 -$as_echo_n "checking if zlib is wanted... " >&6; } +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking if zlib is wanted" >&5 +printf %s "checking if zlib is wanted... " >&6; } zlib_places="/usr/local /usr /opt/local /sw" # Check whether --with-zlib was given. -if test "${with_zlib+set}" = set; then : +if test ${with_zlib+y} +then : withval=$with_zlib; if test "$withval" != no ; 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; } if test -d "$withval" then zlib_places="$withval $zlib_places" else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Sorry, $withval does not exist, checking usual places" >&5 -$as_echo "$as_me: WARNING: Sorry, $withval does not exist, checking usual places" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: Sorry, $withval does not exist, checking usual places" >&5 +printf '%s\n' "$as_me: WARNING: Sorry, $withval does not exist, checking usual places" >&2;} fi else zlib_places= - { $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 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 -$as_echo "yes" >&6; } +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +printf '%s\n' "yes" >&6; } ;; +esac fi @@ -7633,63 +9688,72 @@ then LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" 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 - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5 -$as_echo_n "checking for inflateEnd in -lz... " >&6; } -if ${ac_cv_lib_z_inflateEnd+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5 +printf %s "checking for inflateEnd in -lz... " >&6; } +if test ${ac_cv_lib_z_inflateEnd+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lz $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 inflateEnd (); +char inflateEnd (void); int -main () +main (void) { return inflateEnd (); ; return 0; } _ACEOF -if ac_fn_c_try_link "$LINENO"; then : +if ac_fn_c_try_link "$LINENO" +then : ac_cv_lib_z_inflateEnd=yes -else - ac_cv_lib_z_inflateEnd=no +else case e in #( + e) ac_cv_lib_z_inflateEnd=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_z_inflateEnd" >&5 -$as_echo "$ac_cv_lib_z_inflateEnd" >&6; } -if test "x$ac_cv_lib_z_inflateEnd" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateEnd" >&5 +printf '%s\n' "$ac_cv_lib_z_inflateEnd" >&6; } +if test "x$ac_cv_lib_z_inflateEnd" = xyes +then : zlib_cv_libz=yes -else - zlib_cv_libz=no +else case e in #( + e) zlib_cv_libz=no ;; +esac fi - ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" -if test "x$ac_cv_header_zlib_h" = xyes; then : + ac_fn_c_check_header_compile "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" +if test "x$ac_cv_header_zlib_h" = xyes +then : zlib_cv_zlib_h=yes -else - zlib_cv_zlib_h=no +else case e in #( + e) zlib_cv_zlib_h=no ;; +esac fi - ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' @@ -7702,11 +9766,9 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu # If both library and header were found, action-if-found # - CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" - LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" LIBS="-lz $LIBS" -$as_echo "#define HAVE_LIBZ 1" >>confdefs.h +printf '%s\n' "#define HAVE_LIBZ 1" >>confdefs.h else @@ -7721,161 +9783,185 @@ fi # Check whether --with-udunits was given. -if test "${with_udunits+set}" = set; then : +if test ${with_udunits+y} +then : withval=$with_udunits; UDUNITS_HOME="$withval" -else - UDUNITS_HOME="" - +else case e in #( + e) UDUNITS_HOME="" + ;; +esac fi -if test "$UDUNITS_HOME" = ""; then : +if test "$UDUNITS_HOME" = "" +then : - ac_fn_cxx_check_header_mongrel "$LINENO" "udunits2.h" "ac_cv_header_udunits2_h" "$ac_includes_default" -if test "x$ac_cv_header_udunits2_h" = xyes; then : + ac_fn_cxx_check_header_compile "$LINENO" "udunits2.h" "ac_cv_header_udunits2_h" "$ac_includes_default" +if test "x$ac_cv_header_udunits2_h" = xyes +then : UDUNITS_INCLUDES= UDUNITS_LDFLAGS=-ludunits2 -else - ac_fn_cxx_check_header_mongrel "$LINENO" "udunits2/udunits2.h" "ac_cv_header_udunits2_udunits2_h" "$ac_includes_default" -if test "x$ac_cv_header_udunits2_udunits2_h" = xyes; then : +else case e in #( + e) ac_fn_cxx_check_header_compile "$LINENO" "udunits2/udunits2.h" "ac_cv_header_udunits2_udunits2_h" "$ac_includes_default" +if test "x$ac_cv_header_udunits2_udunits2_h" = xyes +then : UDUNITS_INCLUDES=-I/usr/include/udunits2 UDUNITS_LDFLAGS=-ludunits2 -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/udunits2.h" >&5 -$as_echo_n "checking for /opt/homebrew/include/udunits2.h... " >&6; } -if ${ac_cv_file__opt_homebrew_include_udunits2_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/udunits2.h" >&5 +printf %s "checking for /opt/homebrew/include/udunits2.h... " >&6; } +if test ${ac_cv_file__opt_homebrew_include_udunits2_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/opt/homebrew/include/udunits2.h"; then ac_cv_file__opt_homebrew_include_udunits2_h=yes else ac_cv_file__opt_homebrew_include_udunits2_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_udunits2_h" >&5 -$as_echo "$ac_cv_file__opt_homebrew_include_udunits2_h" >&6; } -if test "x$ac_cv_file__opt_homebrew_include_udunits2_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_udunits2_h" >&5 +printf '%s\n' "$ac_cv_file__opt_homebrew_include_udunits2_h" >&6; } +if test "x$ac_cv_file__opt_homebrew_include_udunits2_h" = xyes +then : UDUNITS_HOME="/opt/homebrew" UDUNITS_INCLUDES=-I$UDUNITS_HOME/include UDUNITS_LDFLAGS="-L$UDUNITS_HOME/lib -ludunits2" UDUNITS_EXCLUDE=$UDUNITS_HOME LDFLAGS="${LDFLAGS} ${UDUNITS_LDFLAGS}" -else - as_fn_error $? "could not find udunits2.h" "$LINENO" 5 - +else case e in #( + e) as_fn_error $? "could not find udunits2.h" "$LINENO" 5 + ;; +esac fi - + ;; +esac fi - - + ;; +esac fi - -else - +else case e in #( + e) UDUNITS_EXCLUDE=$UDUNITS_HOME - as_ac_File=`$as_echo "ac_cv_file_$UDUNITS_HOME/include/udunits2.h" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $UDUNITS_HOME/include/udunits2.h" >&5 -$as_echo_n "checking for $UDUNITS_HOME/include/udunits2.h... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && + as_ac_File=`printf '%s\n' "ac_cv_file_$UDUNITS_HOME/include/udunits2.h" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $UDUNITS_HOME/include/udunits2.h" >&5 +printf %s "checking for $UDUNITS_HOME/include/udunits2.h... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$UDUNITS_HOME/include/udunits2.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : UDUNITS_INCLUDES=-I$UDUNITS_HOME/include UDUNITS_LDFLAGS="-Wl,-rpath,$UDUNITS_HOME/lib -L$UDUNITS_HOME/lib -ludunits2" -else - as_ac_File=`$as_echo "ac_cv_file_$UDUNITS_HOME/lib/udunits2.h" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $UDUNITS_HOME/lib/udunits2.h" >&5 -$as_echo_n "checking for $UDUNITS_HOME/lib/udunits2.h... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$UDUNITS_HOME/lib/udunits2.h" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $UDUNITS_HOME/lib/udunits2.h" >&5 +printf %s "checking for $UDUNITS_HOME/lib/udunits2.h... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$UDUNITS_HOME/lib/udunits2.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : UDUNITS_INCLUDES=-I$UDUNITS_HOME/lib UDUNITS_LDFLAGS="-Wl,-rpath,$UDUNITS_HOME/lib -L$UDUNITS_HOME/lib -ludunits2" -else - as_fn_error $? "could not find udunits2" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find udunits2" "$LINENO" 5 ;; +esac fi - + ;; +esac fi CFLAGS="${CFLAGS} ${UDUNITS_INCLUDES}" LDFLAGS="${LDFLAGS} ${UDUNITS_LDFLAGS}" - + ;; +esac fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -ludunits2" >&5 -$as_echo_n "checking for main in -ludunits2... " >&6; } -if ${ac_cv_lib_udunits2_main+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for main in -ludunits2" >&5 +printf %s "checking for main in -ludunits2... " >&6; } +if test ${ac_cv_lib_udunits2_main+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-ludunits2 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +namespace conftest { + extern "C" int main (); +} int -main () +main (void) { -return main (); +return conftest::main (); ; return 0; } _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_link "$LINENO" +then : ac_cv_lib_udunits2_main=yes -else - ac_cv_lib_udunits2_main=no +else case e in #( + e) ac_cv_lib_udunits2_main=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_udunits2_main" >&5 -$as_echo "$ac_cv_lib_udunits2_main" >&6; } -if test "x$ac_cv_lib_udunits2_main" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBUDUNITS2 1 -_ACEOF +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_udunits2_main" >&5 +printf '%s\n' "$ac_cv_lib_udunits2_main" >&6; } +if test "x$ac_cv_lib_udunits2_main" = xyes +then : + printf '%s\n' "#define HAVE_LIBUDUNITS2 1" >>confdefs.h LIBS="-ludunits2 $LIBS" -else - as_fn_error $? "could not find libudunits" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find libudunits" "$LINENO" 5 ;; +esac fi @@ -7885,125 +9971,148 @@ fi # Check whether --with-hdf5 was given. -if test "${with_hdf5+set}" = set; then : +if test ${with_hdf5+y} +then : withval=$with_hdf5; HDF5_HOME="$withval" - if test "$HDF5_HOME" = "yes"; then : - ac_fn_cxx_check_header_mongrel "$LINENO" "hdf5.h" "ac_cv_header_hdf5_h" "$ac_includes_default" -if test "x$ac_cv_header_hdf5_h" = xyes; then : + if test "$HDF5_HOME" = "yes" +then : + ac_fn_cxx_check_header_compile "$LINENO" "hdf5.h" "ac_cv_header_hdf5_h" "$ac_includes_default" +if test "x$ac_cv_header_hdf5_h" = xyes +then : HDF5_HOME="/usr" -else - as_fn_error $? "could not find hdf5.h" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find hdf5.h" "$LINENO" 5 ;; +esac fi - -else - if test "$HDF5_HOME" = "no"; then : - HDF5_HOME="" -else - as_ac_File=`$as_echo "ac_cv_file_$HDF5_HOME/include/hdf5.h" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $HDF5_HOME/include/hdf5.h" >&5 -$as_echo_n "checking for $HDF5_HOME/include/hdf5.h... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) if test "$HDF5_HOME" = "no" +then : + HDF5_HOME="" +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$HDF5_HOME/include/hdf5.h" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $HDF5_HOME/include/hdf5.h" >&5 +printf %s "checking for $HDF5_HOME/include/hdf5.h... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$HDF5_HOME/include/hdf5.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = x"yes"; then : - -else - as_fn_error $? "could not find $HDF5_HOME/include/hdf5.h" "$LINENO" 5 - + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf '%s\n' "$ac_res" >&6; } +if eval test \"x\$"$as_ac_File"\" = x"yes" +then : + +else case e in #( + e) as_fn_error $? "could not find $HDF5_HOME/include/hdf5.h" "$LINENO" 5 + ;; +esac fi - + ;; +esac fi - + ;; +esac fi -else - - ac_fn_cxx_check_header_mongrel "$LINENO" "hdf5.h" "ac_cv_header_hdf5_h" "$ac_includes_default" -if test "x$ac_cv_header_hdf5_h" = xyes; then : +else case e in #( + e) + ac_fn_cxx_check_header_compile "$LINENO" "hdf5.h" "ac_cv_header_hdf5_h" "$ac_includes_default" +if test "x$ac_cv_header_hdf5_h" = xyes +then : HDF5_HOME="/usr" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/hdf5.h" >&5 -$as_echo_n "checking for /opt/homebrew/include/hdf5.h... " >&6; } -if ${ac_cv_file__opt_homebrew_include_hdf5_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/hdf5.h" >&5 +printf %s "checking for /opt/homebrew/include/hdf5.h... " >&6; } +if test ${ac_cv_file__opt_homebrew_include_hdf5_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/opt/homebrew/include/hdf5.h"; then ac_cv_file__opt_homebrew_include_hdf5_h=yes else ac_cv_file__opt_homebrew_include_hdf5_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_hdf5_h" >&5 -$as_echo "$ac_cv_file__opt_homebrew_include_hdf5_h" >&6; } -if test "x$ac_cv_file__opt_homebrew_include_hdf5_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_hdf5_h" >&5 +printf '%s\n' "$ac_cv_file__opt_homebrew_include_hdf5_h" >&6; } +if test "x$ac_cv_file__opt_homebrew_include_hdf5_h" = xyes +then : HDF5_HOME="/opt/homebrew" -else - HDF5_HOME="" +else case e in #( + e) HDF5_HOME="" ;; +esac fi - + ;; +esac fi - - + ;; +esac fi - if test "$HDF5_HOME" != ""; then : + if test "$HDF5_HOME" != "" +then : LDFLAGS="${LDFLAGS} -L${HDF5_HOME}/lib" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lhdf5" >&5 -$as_echo_n "checking for main in -lhdf5... " >&6; } -if ${ac_cv_lib_hdf5_main+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for main in -lhdf5" >&5 +printf %s "checking for main in -lhdf5... " >&6; } +if test ${ac_cv_lib_hdf5_main+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lhdf5 $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +namespace conftest { + extern "C" int main (); +} int -main () +main (void) { -return main (); +return conftest::main (); ; return 0; } _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_link "$LINENO" +then : ac_cv_lib_hdf5_main=yes -else - ac_cv_lib_hdf5_main=no +else case e in #( + e) ac_cv_lib_hdf5_main=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_hdf5_main" >&5 -$as_echo "$ac_cv_lib_hdf5_main" >&6; } -if test "x$ac_cv_lib_hdf5_main" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBHDF5 1 -_ACEOF +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hdf5_main" >&5 +printf '%s\n' "$ac_cv_lib_hdf5_main" >&6; } +if test "x$ac_cv_lib_hdf5_main" = xyes +then : + printf '%s\n' "#define HAVE_LIBHDF5 1" >>confdefs.h LIBS="-lhdf5 $LIBS" -else - as_fn_error $? "could not find libhdf5" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find libhdf5" "$LINENO" 5 ;; +esac fi @@ -8015,123 +10124,146 @@ fi # Check whether --with-gsl was given. -if test "${with_gsl+set}" = set; then : +if test ${with_gsl+y} +then : withval=$with_gsl; GSL_HOME="$withval" - if test "$GSL_HOME" = "yes"; then : - ac_fn_cxx_check_header_mongrel "$LINENO" "gsl/gsl_rng.h" "ac_cv_header_gsl_gsl_rng_h" "$ac_includes_default" -if test "x$ac_cv_header_gsl_gsl_rng_h" = xyes; then : + if test "$GSL_HOME" = "yes" +then : + ac_fn_cxx_check_header_compile "$LINENO" "gsl/gsl_rng.h" "ac_cv_header_gsl_gsl_rng_h" "$ac_includes_default" +if test "x$ac_cv_header_gsl_gsl_rng_h" = xyes +then : GSL_HOME="/usr" -else - as_fn_error $? "could not find gsl/gsl_rng.h" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find gsl/gsl_rng.h" "$LINENO" 5 ;; +esac fi - -else - if test "$GSL_HOME" = "no"; then : +else case e in #( + e) if test "$GSL_HOME" = "no" +then : GSL_HOME="" -else - as_ac_File=`$as_echo "ac_cv_file_$GSL_HOME/include/gsl" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GSL_HOME/include/gsl" >&5 -$as_echo_n "checking for $GSL_HOME/include/gsl... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$GSL_HOME/include/gsl" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $GSL_HOME/include/gsl" >&5 +printf %s "checking for $GSL_HOME/include/gsl... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$GSL_HOME/include/gsl"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = x"yes"; then : - -else - as_fn_error $? "could not find $GSL_HOME/include/gsl" "$LINENO" 5 - + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf '%s\n' "$ac_res" >&6; } +if eval test \"x\$"$as_ac_File"\" = x"yes" +then : + +else case e in #( + e) as_fn_error $? "could not find $GSL_HOME/include/gsl" "$LINENO" 5 + ;; +esac fi - + ;; +esac fi - + ;; +esac fi -else - ac_fn_cxx_check_header_mongrel "$LINENO" "gsl/gsl_rng.h" "ac_cv_header_gsl_gsl_rng_h" "$ac_includes_default" -if test "x$ac_cv_header_gsl_gsl_rng_h" = xyes; then : +else case e in #( + e) ac_fn_cxx_check_header_compile "$LINENO" "gsl/gsl_rng.h" "ac_cv_header_gsl_gsl_rng_h" "$ac_includes_default" +if test "x$ac_cv_header_gsl_gsl_rng_h" = xyes +then : GSL_HOME="/usr" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/gsl/gsl_rng.h" >&5 -$as_echo_n "checking for /opt/homebrew/include/gsl/gsl_rng.h... " >&6; } -if ${ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/gsl/gsl_rng.h" >&5 +printf %s "checking for /opt/homebrew/include/gsl/gsl_rng.h... " >&6; } +if test ${ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/opt/homebrew/include/gsl/gsl_rng.h"; then ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h=yes else ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" >&5 -$as_echo "$ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" >&6; } -if test "x$ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" >&5 +printf '%s\n' "$ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" >&6; } +if test "x$ac_cv_file__opt_homebrew_include_gsl_gsl_rng_h" = xyes +then : GSL_HOME="/opt/homebrew" -else - GSL_HOME="" +else case e in #( + e) GSL_HOME="" ;; +esac fi - + ;; +esac fi - - + ;; +esac fi - if test "$GSL_HOME" != ""; then : + if test "$GSL_HOME" != "" +then : LDFLAGS="${LDFLAGS} -L${GSL_HOME}/lib" - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lgsl" >&5 -$as_echo_n "checking for main in -lgsl... " >&6; } -if ${ac_cv_lib_gsl_main+:} false; then : - $as_echo_n "(cached) " >&6 -else - ac_check_lib_save_LIBS=$LIBS + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for main in -lgsl" >&5 +printf %s "checking for main in -lgsl... " >&6; } +if test ${ac_cv_lib_gsl_main+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) ac_check_lib_save_LIBS=$LIBS LIBS="-lgsl -lgslcblas $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - +namespace conftest { + extern "C" int main (); +} int -main () +main (void) { -return main (); +return conftest::main (); ; return 0; } _ACEOF -if ac_fn_cxx_try_link "$LINENO"; then : +if ac_fn_cxx_try_link "$LINENO" +then : ac_cv_lib_gsl_main=yes -else - ac_cv_lib_gsl_main=no +else case e in #( + e) ac_cv_lib_gsl_main=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_gsl_main" >&5 -$as_echo "$ac_cv_lib_gsl_main" >&6; } -if test "x$ac_cv_lib_gsl_main" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBGSL 1 -_ACEOF +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gsl_main" >&5 +printf '%s\n' "$ac_cv_lib_gsl_main" >&6; } +if test "x$ac_cv_lib_gsl_main" = xyes +then : + printf '%s\n' "#define HAVE_LIBGSL 1" >>confdefs.h LIBS="-lgsl $LIBS" -else - as_fn_error $? "could not find libgsl" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find libgsl" "$LINENO" 5 ;; +esac fi @@ -8149,12 +10281,13 @@ if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-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_path_PKG_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $PKG_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_PKG_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; @@ -8163,11 +10296,15 @@ else 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_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -8175,15 +10312,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 -$as_echo "$PKG_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 +printf '%s\n' "$PKG_CONFIG" >&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 @@ -8192,12 +10330,13 @@ if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-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_path_ac_pt_PKG_CONFIG+:} false; then : - $as_echo_n "(cached) " >&6 -else - case $ac_pt_PKG_CONFIG in +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +printf %s "checking for $ac_word... " >&6; } +if test ${ac_cv_path_ac_pt_PKG_CONFIG+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; @@ -8206,11 +10345,15 @@ else 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_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $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_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext" + printf '%s\n' "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2 fi done @@ -8218,15 +10361,16 @@ done IFS=$as_save_IFS ;; +esac ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 -$as_echo "$ac_pt_PKG_CONFIG" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 +printf '%s\n' "$ac_pt_PKG_CONFIG" >&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_pt_PKG_CONFIG" = x; then @@ -8234,8 +10378,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 PKG_CONFIG=$ac_pt_PKG_CONFIG @@ -8247,142 +10391,147 @@ fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 - { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 -$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 +printf %s "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; 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" >&5 -$as_echo "no" >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: no" >&5 +printf '%s\n' "no" >&6; } PKG_CONFIG="" fi fi +if test -z "$PKG_CONFIG"; then + as_fn_error $? "pkg-config not found" "$LINENO" 5 +fi # Check whether --with-gtest was given. -if test "${with_gtest+set}" = set; then : +if test ${with_gtest+y} +then : withval=$with_gtest; GTEST_HOME="$withval" - if test "$GTEST_HOME" = "yes"; then : - ac_fn_cxx_check_header_mongrel "$LINENO" "gtest/gtest.h" "ac_cv_header_gtest_gtest_h" "$ac_includes_default" -if test "x$ac_cv_header_gtest_gtest_h" = xyes; then : + if test "$GTEST_HOME" = "yes" +then : + ac_fn_cxx_check_header_compile "$LINENO" "gtest/gtest.h" "ac_cv_header_gtest_gtest_h" "$ac_includes_default" +if test "x$ac_cv_header_gtest_gtest_h" = xyes +then : GTEST_HOME="/usr" -else - as_fn_error $? "could not find gtest/gtest.h" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find gtest/gtest.h" "$LINENO" 5 ;; +esac fi - -else - if test "$GTEST_HOME" = "no"; then : +else case e in #( + e) if test "$GTEST_HOME" = "no" +then : GTEST_HOME="" -else - as_ac_File=`$as_echo "ac_cv_file_$GTEST_HOME/include/gtest" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTEST_HOME/include/gtest" >&5 -$as_echo_n "checking for $GTEST_HOME/include/gtest... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) as_ac_File=`printf '%s\n' "ac_cv_file_$GTEST_HOME/include/gtest" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $GTEST_HOME/include/gtest" >&5 +printf %s "checking for $GTEST_HOME/include/gtest... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$GTEST_HOME/include/gtest"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = x"yes"; then : - -else - as_fn_error $? "could not find $GTEST_HOME/include/gtest" "$LINENO" 5 - + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +printf '%s\n' "$ac_res" >&6; } +if eval test \"x\$"$as_ac_File"\" = x"yes" +then : + +else case e in #( + e) as_fn_error $? "could not find $GTEST_HOME/include/gtest" "$LINENO" 5 + ;; +esac fi - + ;; +esac fi - + ;; +esac fi -else - ac_fn_cxx_check_header_mongrel "$LINENO" "gtest/gtest.h" "ac_cv_header_gtest_gtest_h" "$ac_includes_default" -if test "x$ac_cv_header_gtest_gtest_h" = xyes; then : +else case e in #( + e) ac_fn_cxx_check_header_compile "$LINENO" "gtest/gtest.h" "ac_cv_header_gtest_gtest_h" "$ac_includes_default" +if test "x$ac_cv_header_gtest_gtest_h" = xyes +then : GTEST_HOME="/usr" -else - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/gtest/gtest.h" >&5 -$as_echo_n "checking for /opt/homebrew/include/gtest/gtest.h... " >&6; } -if ${ac_cv_file__opt_homebrew_include_gtest_gtest_h+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for /opt/homebrew/include/gtest/gtest.h" >&5 +printf %s "checking for /opt/homebrew/include/gtest/gtest.h... " >&6; } +if test ${ac_cv_file__opt_homebrew_include_gtest_gtest_h+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "/opt/homebrew/include/gtest/gtest.h"; then ac_cv_file__opt_homebrew_include_gtest_gtest_h=yes else ac_cv_file__opt_homebrew_include_gtest_gtest_h=no +fi ;; +esac fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_gtest_gtest_h" >&5 -$as_echo "$ac_cv_file__opt_homebrew_include_gtest_gtest_h" >&6; } -if test "x$ac_cv_file__opt_homebrew_include_gtest_gtest_h" = xyes; then : +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_homebrew_include_gtest_gtest_h" >&5 +printf '%s\n' "$ac_cv_file__opt_homebrew_include_gtest_gtest_h" >&6; } +if test "x$ac_cv_file__opt_homebrew_include_gtest_gtest_h" = xyes +then : GTEST_HOME="/opt/homebrew" -else - GTEST_HOME="" +else case e in #( + e) GTEST_HOME="" ;; +esac fi - + ;; +esac fi - - + ;; +esac fi - GTEST_CXXSTD="" - if test -n "$GTEST_HOME"; then : + GTEST_CXXSTD="-std=c++17" + if test -n "$GTEST_HOME" +then : if test -n "$PKG_CONFIG" && \ - { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtest\""; } >&5 + { { printf '%s\n' "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtest\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtest") 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 GTEST_VERSION=`$PKG_CONFIG --modversion gtest 2>/dev/null` - if test -n "$GTEST_VERSION"; then : - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5 -$as_echo_n "checking gtest version... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTEST_VERSION" >&5 -$as_echo "$GTEST_VERSION" >&6; } - - GTEST_MAJOR=`echo $GTEST_VERSION | cut -d. -f1` - GTEST_MINOR=`echo $GTEST_VERSION | cut -d. -f2` - - if test "$GTEST_MAJOR" -gt 1 -o \( "$GTEST_MAJOR" -eq 1 -a "$GTEST_MINOR" -ge 17 \); then : - - GTEST_CXXSTD="-std=c++17" - { $as_echo "$as_me:${as_lineno-$LINENO}: gtest >= 1.17.0 detected, setting C++ standard to C++17" >&5 -$as_echo "$as_me: gtest >= 1.17.0 detected, setting C++ standard to C++17" >&6;} - -else - - GTEST_CXXSTD="-std=c++14" - { $as_echo "$as_me:${as_lineno-$LINENO}: gtest < 1.17.0 detected, setting C++ standard to C++14" >&5 -$as_echo "$as_me: gtest < 1.17.0 detected, setting C++ standard to C++14" >&6;} - -fi - -else - - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not determine gtest version via pkg-config" >&5 -$as_echo "$as_me: WARNING: Could not determine gtest version via pkg-config" >&2;} - + if test -n "$GTEST_VERSION" +then : + + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5 +printf %s "checking gtest version... " >&6; } + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: result: $GTEST_VERSION" >&5 +printf '%s\n' "$GTEST_VERSION" >&6; } + +else case e in #( + e) + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: Could not determine gtest version via pkg-config" >&5 +printf '%s\n' "$as_me: WARNING: Could not determine gtest version via pkg-config" >&2;} + ;; +esac fi else - { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config gtest not found, version detection skipped" >&5 -$as_echo "$as_me: WARNING: pkg-config gtest not found, version detection skipped" >&2;} + { printf '%s\n' "$as_me:${as_lineno-$LINENO}: WARNING: pkg-config gtest not found, version detection skipped" >&5 +printf '%s\n' "$as_me: WARNING: pkg-config gtest not found, version detection skipped" >&2;} fi @@ -8395,95 +10544,111 @@ fi # Check whether --with-civetweb was given. -if test "${with_civetweb+set}" = set; then : +if test ${with_civetweb+y} +then : withval=$with_civetweb; # --with option was provided. CIVETWEB_HOME="$withval" USE_CIVETWEB="0" # check whether directory arg was also provided. - if test "$CIVETWEB_HOME" = "yes"; then : - ac_fn_cxx_check_header_mongrel "$LINENO" "civetweb.h" "ac_cv_header_civetweb_h" "$ac_includes_default" -if test "x$ac_cv_header_civetweb_h" = xyes; then : + if test "$CIVETWEB_HOME" = "yes" +then : + ac_fn_cxx_check_header_compile "$LINENO" "civetweb.h" "ac_cv_header_civetweb_h" "$ac_includes_default" +if test "x$ac_cv_header_civetweb_h" = xyes +then : CIVETWEB_HOME="/usr"; USE_CIVETWEB="1" -else - as_fn_error $? "could not find civetweb.h" "$LINENO" 5 +else case e in #( + e) as_fn_error $? "could not find civetweb.h" "$LINENO" 5 ;; +esac fi - -else - # else check whether --without-civet or --with-civet=no specified. - if test "$CIVETWEB_HOME" = "no"; then : +else case e in #( + e) # else check whether --without-civet or --with-civet=no specified. + if test "$CIVETWEB_HOME" = "no" +then : CIVETWEB_HOME="" -else - # else --with-civet was provided with a directory path. - as_ac_File=`$as_echo "ac_cv_file_$CIVETWEB_HOME/include/civetweb.h" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CIVETWEB_HOME/include/civetweb.h" >&5 -$as_echo_n "checking for $CIVETWEB_HOME/include/civetweb.h... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +else case e in #( + e) # else --with-civet was provided with a directory path. + as_ac_File=`printf '%s\n' "ac_cv_file_$CIVETWEB_HOME/include/civetweb.h" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $CIVETWEB_HOME/include/civetweb.h" >&5 +printf %s "checking for $CIVETWEB_HOME/include/civetweb.h... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$CIVETWEB_HOME/include/civetweb.h"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$CIVETWEB_HOME/include/civetweb.h" | $as_tr_cpp` 1 +#define `printf '%s\n' "HAVE_$CIVETWEB_HOME/include/civetweb.h" | sed "$as_sed_cpp"` 1 _ACEOF USE_CIVETWEB="1" -else - as_fn_error $? "Could not find all of the civetweb files." "$LINENO" 5 +else case e in #( + e) as_fn_error $? "Could not find all of the civetweb files." "$LINENO" 5 ;; +esac fi -as_ac_File=`$as_echo "ac_cv_file_$CIVETWEB_HOME/lib/libcivetweb.a" | $as_tr_sh` -{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CIVETWEB_HOME/lib/libcivetweb.a" >&5 -$as_echo_n "checking for $CIVETWEB_HOME/lib/libcivetweb.a... " >&6; } -if eval \${$as_ac_File+:} false; then : - $as_echo_n "(cached) " >&6 -else - test "$cross_compiling" = yes && +as_ac_File=`printf '%s\n' "ac_cv_file_$CIVETWEB_HOME/lib/libcivetweb.a" | sed "$as_sed_sh"` +{ printf '%s\n' "$as_me:${as_lineno-$LINENO}: checking for $CIVETWEB_HOME/lib/libcivetweb.a" >&5 +printf %s "checking for $CIVETWEB_HOME/lib/libcivetweb.a... " >&6; } +if eval test \${$as_ac_File+y} +then : + printf %s "(cached) " >&6 +else case e in #( + e) test "$cross_compiling" = yes && as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 if test -r "$CIVETWEB_HOME/lib/libcivetweb.a"; then eval "$as_ac_File=yes" else eval "$as_ac_File=no" -fi +fi ;; +esac fi eval ac_res=\$$as_ac_File - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -if eval test \"x\$"$as_ac_File"\" = 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_ac_File"\" = x"yes" +then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$CIVETWEB_HOME/lib/libcivetweb.a" | $as_tr_cpp` 1 +#define `printf '%s\n' "HAVE_$CIVETWEB_HOME/lib/libcivetweb.a" | sed "$as_sed_cpp"` 1 _ACEOF USE_CIVETWEB="1" -else - as_fn_error $? "Could not find all of the civetweb files." "$LINENO" 5 +else case e in #( + e) as_fn_error $? "Could not find all of the civetweb files." "$LINENO" 5 ;; +esac fi - -fi + ;; +esac +fi ;; +esac fi -else - # --with option not provided. - ac_fn_cxx_check_header_mongrel "$LINENO" "civetweb.h" "ac_cv_header_civetweb_h" "$ac_includes_default" -if test "x$ac_cv_header_civetweb_h" = xyes; then : +else case e in #( + e) # --with option not provided. + ac_fn_cxx_check_header_compile "$LINENO" "civetweb.h" "ac_cv_header_civetweb_h" "$ac_includes_default" +if test "x$ac_cv_header_civetweb_h" = xyes +then : CIVETWEB_HOME="/usr"; USE_CIVETWEB="1" -else - CIVETWEB_HOME=""; USE_CIVETWEB="0" +else case e in #( + e) CIVETWEB_HOME=""; USE_CIVETWEB="0" ;; +esac fi - - + ;; +esac fi @@ -8491,15 +10656,19 @@ fi # Check whether --enable-er7utils was given. -if test "${enable_er7utils+set}" = set; then : - enableval=$enable_er7utils; if test "x$enable_er7utils" = xyes; then : +if test ${enable_er7utils+y} +then : + enableval=$enable_er7utils; if test "x$enable_er7utils" = xyes +then : USE_ER7_UTILS="1" -else - USE_ER7_UTILS="0" +else case e in #( + e) USE_ER7_UTILS="0" ;; +esac fi -else - USE_ER7_UTILS="1" - +else case e in #( + e) USE_ER7_UTILS="1" + ;; +esac fi @@ -8517,63 +10686,26 @@ 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 -# The following way of writing the cache mishandles newlines in values, -# but we know of no workaround that is simple, portable, and efficient. -# So, we kill variables containing newlines. -# Ultrix sh set writes to stderr and can't be redirected directly, -# and sets the high bit in the cache file unless we assign to the vars. -( - for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do - eval ac_val=\$$ac_var - 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;} ;; - esac - case $ac_var in #( - _ | IFS | as_nl) ;; #( - BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( - *) { eval $ac_var=; unset $ac_var;} ;; - esac ;; - esac - done - - (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 - # 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. - sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" - ;; - esac | - sort -) | +ac_cache_dump | sed ' /^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 @@ -8587,8 +10719,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 @@ -8619,9 +10751,7 @@ s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g t quote b any :quote -s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g -s/\[/\\&/g -s/\]/\\&/g +s/[][ `~#$^&*(){}\\|;'\''"<>?]/\\&/g s/\$/$$/g H :any @@ -8641,7 +10771,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" @@ -8654,13 +10784,21 @@ LTLIBOBJS=$ac_ltlibobjs : "${CONFIG_STATUS=./config.status}" +case $CONFIG_STATUS in #( + -*) : + CONFIG_STATUS=./$CONFIG_STATUS ;; #( + */*) : + ;; #( + *) : + CONFIG_STATUS=./$CONFIG_STATUS ;; +esac + 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;} +ac_clean_CONFIG_STATUS='"$CONFIG_STATUS"' +{ 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 +cat >"$CONFIG_STATUS" <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. @@ -8674,70 +10812,72 @@ ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF -cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # 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. + # contradicts POSIX and common usage. Disable this. 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&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 || @@ -8746,13 +10886,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 #(( @@ -8761,43 +10894,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] @@ -8810,9 +10927,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 @@ -8843,22 +10960,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... @@ -8866,16 +10986,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 @@ -8902,7 +11024,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 @@ -8924,19 +11046,6 @@ as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits -ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in #((((( --n*) - case `echo 'xy\c'` in - *c*) ECHO_T=' ';; # ECHO_T is single tab character. - xy) ECHO_C='\c';; - *) echo `echo ksh88 bug on AIX 6.1` > /dev/null - ECHO_T=' ';; - esac;; -*) - ECHO_N='-n';; -esac - rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file @@ -8948,9 +11057,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 @@ -8978,7 +11087,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" @@ -8987,7 +11096,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 @@ -9031,26 +11140,28 @@ 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 -## ----------------------------------- ## -## Main body of $CONFIG_STATUS script. ## -## ----------------------------------- ## +## ------------------------------------- ## +## Main body of "$CONFIG_STATUS" script. ## +## ------------------------------------- ## _ASEOF -test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 +test $as_write_fail = 0 && chmod +x "$CONFIG_STATUS" || ac_write_fail=1 -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by Trick $as_me 19.6+, which was -generated by GNU Autoconf 2.69. Invocation command line was +generated by GNU Autoconf 2.73. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -9069,15 +11180,15 @@ esac -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +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. @@ -9099,24 +11210,30 @@ $config_files Report bugs to the package provider." _ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" +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='$ac_cs_config_escaped' ac_cs_version="\\ Trick config.status 19.6+ -configured by $0, generated by GNU Autoconf 2.69, +configured by $0, generated by GNU Autoconf 2.73, with options \\"\$ac_cs_config\\" -Copyright (C) 2012 Free Software Foundation, Inc. +Copyright (C) 2026 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' AWK='$AWK' -test -n "\$AWK" || AWK=awk +test -n "\$AWK" || { + awk '' >$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 @@ -9144,28 +11261,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 ;; @@ -9182,32 +11299,32 @@ if $ac_cs_silent; then fi _ACEOF -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +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 "\$@" fi _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo 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 -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets @@ -9215,7 +11332,7 @@ do case $ac_config_target in "share/trick/makefiles/config_user.mk") CONFIG_FILES="$CONFIG_FILES share/trick/makefiles/config_user.mk" ;; - *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + *) as_fn_error $? "invalid argument: '$ac_config_target'" "$LINENO" 5;; esac done @@ -9225,7 +11342,7 @@ 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_FILES+y} || CONFIG_FILES=$config_files fi # Have a temporary directory for convenience. Make it in the build tree @@ -9233,7 +11350,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= @@ -9257,7 +11374,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 @@ -9285,13 +11402,13 @@ _ACEOF echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 -ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` +ac_delim_num=`echo "$ac_subst_vars" | sed -n '$='` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 - ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` + ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | sed -n '$='` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then @@ -9302,7 +11419,7 @@ for ac_last_try in false false false false false :; do done rm -f conf$$subs.sh -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' @@ -9347,9 +11464,9 @@ t delim N s/\n// } -' >>$CONFIG_STATUS || ac_write_fail=1 +' >>"$CONFIG_STATUS" || ac_write_fail=1 rm -f conf$$subs.awk -cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 @@ -9378,7 +11495,7 @@ cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && _ACAWK _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else @@ -9410,7 +11527,7 @@ s/^[^=]*=[ ]*$// }' fi -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" @@ -9423,7 +11540,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 @@ -9445,33 +11562,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 @@ -9488,7 +11605,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 @@ -9512,9 +11629,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/ ;; @@ -9550,7 +11667,7 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= @@ -9567,10 +11684,10 @@ 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 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g @@ -9581,14 +11698,14 @@ 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 +cat >>"$CONFIG_STATUS" <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF -cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 +cat >>"$CONFIG_STATUS" <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t @@ -9610,9 +11727,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" @@ -9632,7 +11749,7 @@ done # for ac_tag as_fn_exit 0 _ACEOF -ac_clean_files=$ac_clean_files_save +ac_clean_CONFIG_STATUS= test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 @@ -9648,20 +11765,28 @@ test $ac_write_fail = 0 || # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: + case $CONFIG_STATUS in #( + -*) : + ac_no_opts=-- ;; #( + *) : + ac_no_opts= ;; +esac ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null - $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false + $SHELL $ac_no_opts "$CONFIG_STATUS" $ac_config_status_args || + ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $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 printf "\033[32mconfigure script successfully completed\033[0m\n" + From c8adc4a8f19175f823feb47bccd5e9bd3eecc8a8 Mon Sep 17 00:00:00 2001 From: brendan fattig Date: Tue, 5 May 2026 17:08:05 -0500 Subject: [PATCH 31/38] Update clang-format configuration options --- .clang-format | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.clang-format b/.clang-format index eaecc7ed6..4726d699a 100644 --- a/.clang-format +++ b/.clang-format @@ -1,5 +1,6 @@ --- BasedOnStyle: WebKit +AccessModifierOffset: -2 AlignConsecutiveAssignments: AcrossEmptyLines AlignTrailingComments: Kind: Always @@ -17,4 +18,6 @@ IncludeCategories: Priority: 4 - Regex: ".*" Priority: 1 +KeepEmptyLinesAtEOF: false +KeepEmptyLinesAtTheStartOfBlocks: false ... From 027867e3ef887436b6d687925d7a52d9415f7490 Mon Sep 17 00:00:00 2001 From: brendan fattig Date: Wed, 6 May 2026 14:22:24 -0500 Subject: [PATCH 32/38] Update clang-format for alignment settings --- .clang-format | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.clang-format b/.clang-format index 4726d699a..702b0f11f 100644 --- a/.clang-format +++ b/.clang-format @@ -1,7 +1,7 @@ --- BasedOnStyle: WebKit AccessModifierOffset: -2 -AlignConsecutiveAssignments: AcrossEmptyLines +AlignConsecutiveAssignments: Consecutive AlignTrailingComments: Kind: Always BreakBeforeBraces: Allman From dd916030bc6c7b62d15ddbe5ccf0b7048c20d0b6 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 6 May 2026 15:12:32 -0500 Subject: [PATCH 33/38] Add python format check --- .github/workflows/ci.yml | 65 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 63 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 67a3b9635..5abcc1828 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,9 +37,12 @@ jobs: - name: Install tools run: | sudo apt-get update -qq - sudo apt-get install -y clang-format perltidy + sudo apt-get install -y clang-format perltidy python3-pip + pip3 install --break-system-packages ruff - - name: Check formatting of changed lines + - name: Check clang-format on changed C/C++ lines + id: clang_format + continue-on-error: true run: | set -euo pipefail @@ -62,6 +65,8 @@ jobs: echo "All changed C/C++ lines are correctly formatted." - name: Check perltidy on changed Perl files + id: perltidy + continue-on-error: true run: | set -euo pipefail @@ -104,9 +109,65 @@ jobs: fi echo "All changed Perl files are correctly formatted." + - name: Check ruff formatting on changed Python files + id: ruff + continue-on-error: true + run: | + set -euo pipefail + + if [ "${{ github.event_name }}" = "pull_request" ]; then + BASE=${{ github.event.pull_request.base.sha }} + else + git fetch origin master + BASE=$(git merge-base origin/master HEAD) + fi + + # Collect changed Python files: by extension and by shebang + PYTHON_FILES=() + while IFS= read -r f; do + [ -z "$f" ] && continue + case "$f" in + *.py) PYTHON_FILES+=("$f") ;; + *) if head -1 "$f" 2>/dev/null | grep -q '^#!.*python'; then + PYTHON_FILES+=("$f") + fi ;; + esac + done < <(git diff --diff-filter=ACMR --name-only "$BASE") + + if [ ${#PYTHON_FILES[@]} -eq 0 ]; then + echo "No changed Python files to check." + exit 0 + fi + + FAILED=0 + for f in "${PYTHON_FILES[@]}"; do + if ! ruff format --check --diff "$f"; then + echo "::error file=$f::$f is not ruff-formatted." + FAILED=1 + fi + if ! ruff check --select I --diff "$f"; then + echo "::error file=$f::$f has unsorted imports." + FAILED=1 + fi + done + + if [ $FAILED -ne 0 ]; then + echo "" + echo "::error::Changed Python files have formatting or import issues." + echo "::error::To fix, run: ruff check --select I --fix && ruff format " + exit 1 + fi + echo "All changed Python files are correctly formatted." + + - name: Fail if any style check failed + if: steps.clang_format.outcome == 'failure' || steps.perltidy.outcome == 'failure' || steps.ruff.outcome == 'failure' + run: exit 1 + # TODO: Once the codebase is fully formatted, switch to whole-file checking: # # - name: Check formatting of changed files + # id: clang_format + # continue-on-error: true # run: | # set -euo pipefail # From 2cfbbec16a54eebfcfa6d78b5770f6b497de74ad Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 6 May 2026 15:14:33 -0500 Subject: [PATCH 34/38] Don't fail if changed files found --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5abcc1828..aed856ac1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,7 +53,7 @@ jobs: BASE=$(git merge-base origin/master HEAD) fi - DIFF=$(git clang-format --diff "$BASE" --extensions c,h,cpp,hpp,cc,hh) + DIFF=$(git clang-format --diff "$BASE" --extensions c,h,cpp,hpp,cc,hh) || true if echo "$DIFF" | grep -q '^diff'; then echo "$DIFF" From 4875b4873006bfe467beb86f8d3c46f9983864e0 Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 6 May 2026 15:14:54 -0500 Subject: [PATCH 35/38] Build and test even if style check fails --- .github/workflows/ci.yml | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aed856ac1..1e46e456c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -202,6 +202,8 @@ jobs: test-linux: name: Linux (${{ matrix.cfg.os }} ${{ matrix.cfg.tag }}) needs: [style] + # TODO: Remove always() once style enforcement is stable — ideally builds only run on clean style. + if: always() runs-on: ubuntu-latest container: docker://${{ matrix.cfg.image }}:${{ matrix.cfg.tag }} strategy: @@ -340,7 +342,9 @@ jobs: test-macos: name: macOS needs: [style] - runs-on: macos-15 + # TODO: Remove always() once style enforcement is stable — ideally builds only run on clean style. + if: always() + runs-on: macos-26 env: MAKEFLAGS: -j4 steps: @@ -388,6 +392,8 @@ jobs: trickops: name: TrickOps (${{ matrix.name }}) needs: [style] + # TODO: Remove always() once style enforcement is stable — ideally builds only run on clean style. + if: always() runs-on: ubuntu-latest container: ${{ matrix.image }} strategy: @@ -440,6 +446,8 @@ jobs: code-coverage: name: Code Coverage needs: [style] + # TODO: Remove always() once style enforcement is stable — ideally builds only run on clean style. + if: always() runs-on: ubuntu-latest env: CFLAGS: "-fprofile-arcs -ftest-coverage -fprofile-update=atomic -O0" From f11412d5f52d533a92fd67cbcb9ed9b6a3100c7a Mon Sep 17 00:00:00 2001 From: Brendan Fattig Date: Wed, 6 May 2026 15:41:44 -0500 Subject: [PATCH 36/38] Use ruff preview switch --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1e46e456c..6cdc88d27 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -141,11 +141,11 @@ jobs: FAILED=0 for f in "${PYTHON_FILES[@]}"; do - if ! ruff format --check --diff "$f"; then + if ! ruff format --preview --check --diff "$f"; then echo "::error file=$f::$f is not ruff-formatted." FAILED=1 fi - if ! ruff check --select I --diff "$f"; then + if ! ruff check --preview --select I --diff "$f"; then echo "::error file=$f::$f has unsorted imports." FAILED=1 fi @@ -154,7 +154,7 @@ jobs: if [ $FAILED -ne 0 ]; then echo "" echo "::error::Changed Python files have formatting or import issues." - echo "::error::To fix, run: ruff check --select I --fix && ruff format " + echo "::error::To fix, run: ruff check --preview --select I --fix && ruff format --preview " exit 1 fi echo "All changed Python files are correctly formatted." From 67ccf9fb4ffa8ff3bbc080ee0e0cc155eb414005 Mon Sep 17 00:00:00 2001 From: brendan fattig Date: Wed, 6 May 2026 16:20:48 -0500 Subject: [PATCH 37/38] move trickops makefile gitignore from top level to directory level --- .gitignore | 1 - share/trick/trickops/.gitignore | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 share/trick/trickops/.gitignore diff --git a/.gitignore b/.gitignore index 20c89ae1d..27ffd84ac 100644 --- a/.gitignore +++ b/.gitignore @@ -46,4 +46,3 @@ coverage.info *.dSYM *.log .cache/ -share/trick/trickops/makefile diff --git a/share/trick/trickops/.gitignore b/share/trick/trickops/.gitignore new file mode 100644 index 000000000..f0be4dd53 --- /dev/null +++ b/share/trick/trickops/.gitignore @@ -0,0 +1 @@ +makefile From cbea26dccae63bc77c51dbe83f965865a9d68d79 Mon Sep 17 00:00:00 2001 From: brendan fattig Date: Thu, 7 May 2026 17:12:05 -0500 Subject: [PATCH 38/38] Update .clang-format --- .clang-format | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.clang-format b/.clang-format index 702b0f11f..64bc5ee4d 100644 --- a/.clang-format +++ b/.clang-format @@ -1,6 +1,8 @@ --- BasedOnStyle: WebKit AccessModifierOffset: -2 +AlignAfterOpenBracket: Align +AlignArrayOfStructures: Left AlignConsecutiveAssignments: Consecutive AlignTrailingComments: Kind: Always