diff --git a/.github/actions/build_bindings_python/action.yml b/.github/actions/build_bindings_python/action.yml index 07162483689b..e7cc4b4a0bd3 100644 --- a/.github/actions/build_bindings_python/action.yml +++ b/.github/actions/build_bindings_python/action.yml @@ -51,7 +51,7 @@ runs: rust-toolchain: ${{ steps.toolchain.outputs.RUST_TOOLCHAIN }} working-directory: src/bendpy target: ${{ inputs.target }} - manylinux: auto + manylinux: "2_28" # Keep them in one line due to https://github.com/PyO3/maturin-action/issues/153 rustup-components: rust-std rustfmt args: ${{ steps.opts.outputs.BUILD_ARGS }} @@ -62,7 +62,7 @@ runs: - name: Run tests working-directory: src/bendpy - if: startsWith(inputs.target, 'x86_64-') + if: endsWith(inputs.target, '-gnu') shell: bash run: | pip install dist/*.whl diff --git a/.github/actions/build_linux/action.yml b/.github/actions/build_linux/action.yml index 502dfdedc47b..1878382a85d4 100644 --- a/.github/actions/build_linux/action.yml +++ b/.github/actions/build_linux/action.yml @@ -46,13 +46,13 @@ runs: flags="-C target-feature=+sse4.2" ;; x86_64-unknown-linux-musl) - flags="-C target-feature=+sse4.2 -C link-arg=--max-memory=4294967296" + flags="-C target-feature=+sse4.2" ;; aarch64-unknown-linux-gnu) flags="" ;; aarch64-unknown-linux-musl) - flags="-C link-arg=--max-memory=4294967296" + flags="" ;; *) flags="" diff --git a/.github/actions/build_linux_sanitizer/action.yml b/.github/actions/build_linux_sanitizer/action.yml index a13868d2d056..615b59104b8b 100644 --- a/.github/actions/build_linux_sanitizer/action.yml +++ b/.github/actions/build_linux_sanitizer/action.yml @@ -50,7 +50,7 @@ runs: if: env.BUILD_PROFILE == 'debug' && endsWith(inputs.target, '-gnu') shell: bash run: | - artifacts="meta,metactl,query" + artifacts="${{ inputs.artifacts }}" for artifact in ${artifacts//,/ }; do echo "==> building databend-$artifact with sanitizer ..." cargo -Zbuild-std -Zgitoxide=fetch -Zgit=shallow-index,shallow-deps build --target ${{ inputs.target }} --features ${{ inputs.features }} --manifest-path src/binaries/Cargo.toml --bin databend-$artifact diff --git a/.github/workflows/bindings.python.yml b/.github/workflows/bindings.python.yml index dcedfa123c07..3e74b9bbc3ba 100644 --- a/.github/workflows/bindings.python.yml +++ b/.github/workflows/bindings.python.yml @@ -20,18 +20,19 @@ concurrency: jobs: linux: - runs-on: [self-hosted, X64, Linux, 8c16g, gcp] + runs-on: [self-hosted, "${{ matrix.runner }}", Linux, 8c16g, gcp] strategy: matrix: - target: - - x86_64-unknown-linux-gnu + include: + - { arch: x86_64, runner: X64 } + # - { arch: aarch64, runner: ARM64 } steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: ./.github/actions/build_bindings_python with: - target: ${{ matrix.target }} + target: ${{ matrix.arch }}-unknown-linux-gnu version: ${{ inputs.tag }} - name: upload if: inputs.tag @@ -45,15 +46,15 @@ jobs: runs-on: macos-latest strategy: matrix: - target: - - aarch64-apple-darwin + arch: + - aarch64 steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - uses: ./.github/actions/build_bindings_python with: - target: ${{ matrix.target }} + target: ${{ matrix.arch }}-apple-darwin version: ${{ inputs.tag }} - name: upload if: inputs.tag diff --git a/.github/workflows/build_tool.yml b/.github/workflows/build_tool.yml index 3d438c900d3e..1b7b963da3ea 100644 --- a/.github/workflows/build_tool.yml +++ b/.github/workflows/build_tool.yml @@ -13,16 +13,10 @@ permissions: contents: read jobs: - build: + debian: runs-on: ubuntu-latest - strategy: - matrix: - os: - - debian - - alpine steps: - uses: actions/checkout@v4 - - uses: ./.github/actions/setup_docker id: login with: @@ -30,31 +24,32 @@ jobs: ecr_role_arn: ${{ secrets.ECR_ROLE_ARN }} dockerhub_user: ${{ secrets.DOCKERHUB_USERNAME }} dockerhub_token: ${{ secrets.DOCKERHUB_TOKEN }} - - name: Get rust toolchain version id: toolchain run: | version=$(awk -F'[ ="]+' '$1 == "channel" { print $2 }' scripts/setup/rust-toolchain.toml) echo "TOOLCHAIN=${version}" >> $GITHUB_OUTPUT - - name: Build and publish databend build image uses: docker/build-push-action@v5 with: pull: true push: true tags: | - ${{ steps.login.outputs.dockerhub_repo }}:${{ matrix.os }} - ${{ steps.login.outputs.dockerhub_repo }}:${{ matrix.os }}-${{ steps.toolchain.outputs.TOOLCHAIN }} + ${{ steps.login.outputs.dockerhub_repo }}:debian + ${{ steps.login.outputs.dockerhub_repo }}:debian-${{ steps.toolchain.outputs.TOOLCHAIN }} context: ./scripts/setup - file: ./docker/build-tool/${{ matrix.os }}/Dockerfile + file: ./docker/build-tool/debian/Dockerfile platforms: linux/amd64,linux/arm64 - dev: + musl: runs-on: ubuntu-latest - needs: build + strategy: + matrix: + arch: + - aarch64 + - x86_64 steps: - uses: actions/checkout@v4 - - uses: ./.github/actions/setup_docker id: login with: @@ -62,14 +57,43 @@ jobs: ecr_role_arn: ${{ secrets.ECR_ROLE_ARN }} dockerhub_user: ${{ secrets.DOCKERHUB_USERNAME }} dockerhub_token: ${{ secrets.DOCKERHUB_TOKEN }} - - name: Get rust toolchain version id: toolchain run: | version=$(awk -F'[ ="]+' '$1 == "channel" { print $2 }' scripts/setup/rust-toolchain.toml) echo "TOOLCHAIN=${version}" >> $GITHUB_OUTPUT + - name: Build and publish databend build image + uses: docker/build-push-action@v5 + with: + pull: true + push: true + tags: | + ${{ steps.login.outputs.dockerhub_repo }}:${{ matrix.arch }}-unknown-linux-musl + ${{ steps.login.outputs.dockerhub_repo }}:${{ matrix.arch }}-unknown-linux-musl-${{ steps.toolchain.outputs.TOOLCHAIN }} + context: ./docker/build-tool/musl + file: ./docker/build-tool/musl/Dockerfile + build-args: | + ARCH=${{ matrix.arch }} + RUST_TOOLCHAIN=${{ steps.toolchain.outputs.TOOLCHAIN }} - - name: Build and publish databend build base image + dev: + runs-on: ubuntu-latest + needs: debian + steps: + - uses: actions/checkout@v4 + - uses: ./.github/actions/setup_docker + id: login + with: + repo: build-tool + ecr_role_arn: ${{ secrets.ECR_ROLE_ARN }} + dockerhub_user: ${{ secrets.DOCKERHUB_USERNAME }} + dockerhub_token: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Get rust toolchain version + id: toolchain + run: | + version=$(awk -F'[ ="]+' '$1 == "channel" { print $2 }' scripts/setup/rust-toolchain.toml) + echo "TOOLCHAIN=${version}" >> $GITHUB_OUTPUT + - name: Build and publish databend build image uses: docker/build-push-action@v5 with: pull: true @@ -77,8 +101,6 @@ jobs: tags: | ${{ steps.login.outputs.dockerhub_repo }}:dev ${{ steps.login.outputs.dockerhub_repo }}:dev-${{ steps.toolchain.outputs.TOOLCHAIN }} - ${{ steps.login.outputs.ecr_repo }}:dev - ${{ steps.login.outputs.ecr_repo }}:dev-${{ steps.toolchain.outputs.TOOLCHAIN }} context: ./scripts/setup file: ./docker/build-tool/dev/Dockerfile build-args: | diff --git a/.github/workflows/cloud.yml b/.github/workflows/cloud.yml index fa5529faae63..9769e5c41cca 100644 --- a/.github/workflows/cloud.yml +++ b/.github/workflows/cloud.yml @@ -47,8 +47,8 @@ jobs: strategy: matrix: include: - - {target: x86_64-unknown-linux-gnu, runner: X64} - - {target: aarch64-unknown-linux-gnu, runner: ARM64} + - {arch: x86_64, runner: X64} + - {arch: aarch64, runner: ARM64} steps: - uses: actions/checkout@v4 with: @@ -59,7 +59,7 @@ jobs: timeout-minutes: 60 with: sha: ${{ needs.info.outputs.sha }} - target: ${{ matrix.target }} + target: ${{ matrix.arch }}-unknown-linux-gnu artifacts: meta,query docker: diff --git a/.github/workflows/reuse.linux.yml b/.github/workflows/reuse.linux.yml index 6cc82304f80a..4d88da4de3d5 100644 --- a/.github/workflows/reuse.linux.yml +++ b/.github/workflows/reuse.linux.yml @@ -59,7 +59,7 @@ jobs: fail-fast: false matrix: include: - - { target: x86_64-unknown-linux-gnu, runner: X64 } + - { arch: x86_64, runner: X64 } steps: - uses: actions/checkout@v4 with: @@ -69,7 +69,7 @@ jobs: timeout-minutes: 60 with: sha: ${{ github.sha }} - target: ${{ matrix.target }} + target: ${{ matrix.arch }}-unknown-linux-gnu artifacts: all build_address_sanitizer: @@ -78,7 +78,7 @@ jobs: fail-fast: false matrix: include: - - { target: aarch64-unknown-linux-gnu, runner: ARM64 } + - { arch: aarch64, runner: ARM64 } steps: - uses: actions/checkout@v4 with: @@ -87,27 +87,28 @@ jobs: - uses: ./.github/actions/build_linux_sanitizer timeout-minutes: 60 with: - target: ${{ matrix.target }} + target: ${{ matrix.arch }}-unknown-linux-gnu artifacts: query - # build_other: - # runs-on: [self-hosted, "${{ matrix.runner }}", Linux, 16c32g, "${{ inputs.runner_provider }}"] - # strategy: - # fail-fast: false - # matrix: - # include: - # - { target: aarch64-unknown-linux-musl, runner: ARM64 } - # steps: - # - uses: actions/checkout@v4 - # with: - # # fetch all tags, metasrv and metaclient need tag as its version. - # fetch-depth: 0 - # - uses: ./.github/actions/build_linux - # timeout-minutes: 60 - # with: - # sha: ${{ github.sha }} - # target: ${{ matrix.target }} - # artifacts: query + build_musl: + runs-on: [self-hosted, X64, Linux, 16c32g, "${{ inputs.runner_provider }}"] + strategy: + fail-fast: false + matrix: + arch: + - x86_64 + - aarch64 + steps: + - uses: actions/checkout@v4 + with: + # fetch all tags, metasrv and metaclient need tag as its version. + fetch-depth: 0 + - uses: ./.github/actions/build_linux + timeout-minutes: 60 + with: + sha: ${{ github.sha }} + target: ${{ matrix.arch }}-unknown-linux-musl + artifacts: query test_unit: runs-on: [self-hosted, X64, Linux, 16c32g, "${{ inputs.runner_provider }}"] diff --git a/Cargo.lock b/Cargo.lock index f8de86ae8ba3..3a7fa6353553 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -878,7 +878,7 @@ dependencies = [ "cc", "cfg-if", "libc", - "miniz_oxide 0.7.1", + "miniz_oxide", "object", "rustc-demangle", ] @@ -892,7 +892,7 @@ dependencies = [ "cc", "cfg-if", "libc", - "miniz_oxide 0.7.1", + "miniz_oxide", "object", "rustc-demangle", ] @@ -1007,36 +1007,16 @@ dependencies = [ [[package]] name = "bindgen" -version = "0.66.1" +version = "0.69.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2b84e06fc203107bfbad243f4aba2af864eb7db3b1cf46ea0a023b0b433d2a7" -dependencies = [ - "bitflags 2.4.0", - "cexpr", - "clang-sys", - "lazy_static", - "lazycell", - "peeking_take_while", - "proc-macro2", - "quote", - "regex", - "rustc-hash", - "shlex", - "syn 2.0.46", -] - -[[package]] -name = "bindgen" -version = "0.68.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "726e4313eb6ec35d2730258ad4e15b547ee75d6afaa1361a922e78e59b7d8078" +checksum = "a00dc851838a2120612785d195287475a3ac45514741da670b735818822129a0" dependencies = [ "bitflags 2.4.0", "cexpr", "clang-sys", + "itertools 0.11.0", "lazy_static", "lazycell", - "peeking_take_while", "proc-macro2", "quote", "regex", @@ -5336,13 +5316,13 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.25" +version = "1.0.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" +checksum = "46303f565772937ffe1d394a4fac6f411c6013172fadde9dcdb1e147a086940e" dependencies = [ "crc32fast", "libz-sys", - "miniz_oxide 0.6.2", + "miniz_oxide", ] [[package]] @@ -8671,15 +8651,6 @@ dependencies = [ "opentelemetry_sdk", ] -[[package]] -name = "miniz_oxide" -version = "0.6.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" -dependencies = [ - "adler", -] - [[package]] name = "miniz_oxide" version = "0.7.1" @@ -8886,7 +8857,7 @@ checksum = "06f19e4cfa0ab5a76b627cec2d81331c49b034988eaf302c3bafeada684eadef" dependencies = [ "base64 0.21.0", "bigdecimal", - "bindgen 0.68.1", + "bindgen", "bitflags 2.4.0", "bitvec", "btoi", @@ -9700,12 +9671,6 @@ dependencies = [ "hmac", ] -[[package]] -name = "peeking_take_while" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" - [[package]] name = "pem" version = "3.0.2" @@ -9949,9 +9914,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.26" +version = "0.3.30" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" +checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" [[package]] name = "planus" @@ -10543,7 +10508,7 @@ dependencies = [ "indoc", "libc", "memoffset 0.9.0", - "parking_lot 0.11.2", + "parking_lot 0.12.1", "pyo3-build-config 0.19.1", "pyo3-ffi", "pyo3-macros", @@ -11610,8 +11575,9 @@ dependencies = [ [[package]] name = "sentry" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "766448f12e44d68e675d5789a261515c46ac6ccd240abdd451a9c46c84a49523" dependencies = [ "httpdate", "reqwest", @@ -11623,13 +11589,14 @@ dependencies = [ "sentry-tracing", "tokio", "ureq", - "webpki-roots 0.23.1", + "webpki-roots 0.25.2", ] [[package]] name = "sentry-backtrace" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32701cad8b3c78101e1cd33039303154791b0ff22e7802ed8cc23212ef478b45" dependencies = [ "backtrace 0.3.69 (registry+https://github.com/rust-lang/crates.io-index)", "once_cell", @@ -11639,8 +11606,9 @@ dependencies = [ [[package]] name = "sentry-contexts" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17ddd2a91a13805bd8dab4ebf47323426f758c35f7bf24eacc1aded9668f3824" dependencies = [ "hostname", "libc", @@ -11652,8 +11620,9 @@ dependencies = [ [[package]] name = "sentry-core" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1189f68d7e7e102ef7171adf75f83a59607fafd1a5eecc9dc06c026ff3bdec4" dependencies = [ "once_cell", "rand 0.8.5", @@ -11664,8 +11633,9 @@ dependencies = [ [[package]] name = "sentry-panic" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1c18d0b5fba195a4950f2f4c31023725c76f00aabb5840b7950479ece21b5ca" dependencies = [ "sentry-backtrace", "sentry-core", @@ -11673,8 +11643,9 @@ dependencies = [ [[package]] name = "sentry-tracing" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3012699a9957d7f97047fd75d116e22d120668327db6e7c59824582e16e791b2" dependencies = [ "sentry-backtrace", "sentry-core", @@ -11684,12 +11655,13 @@ dependencies = [ [[package]] name = "sentry-types" -version = "0.31.5" -source = "git+https://github.com/getsentry/sentry-rust?rev=6ef6d97#6ef6d976225f029b6d58541eb267879b40778f0b" +version = "0.32.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7173fd594569091f68a7c37a886e202f4d0c1db1e1fa1d18a051ba695b2e2ec" dependencies = [ "debugid", - "getrandom 0.2.11", "hex", + "rand 0.8.5", "serde", "serde_json", "thiserror", @@ -13142,7 +13114,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "97fee6b57c6a41524a810daee9286c02d7752c4253064d0b05472833a438f675" dependencies = [ "cfg-if", - "rand 0.7.3", + "rand 0.8.5", "static_assertions", ] @@ -14098,21 +14070,21 @@ checksum = "09041cd90cf85f7f8b2df60c646f853b7f535ce68f85244eb6731cf89fa498ec" [[package]] name = "z3" version = "0.12.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a7ff5718c079e7b813378d67a5bed32ccc2086f151d6185074a7e24f4a565e8" +source = "git+https://github.com/prove-rs/z3.rs?rev=247d308#247d308f27d8b59152ad402e2d8b13d617a1a6a1" dependencies = [ "log", + "num", "z3-sys", ] [[package]] name = "z3-sys" version = "0.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7cf70fdbc0de3f42b404f49b0d4686a82562254ea29ff0a155eef2f5430f4b0" +source = "git+https://github.com/prove-rs/z3.rs?rev=247d308#247d308f27d8b59152ad402e2d8b13d617a1a6a1" dependencies = [ - "bindgen 0.66.1", + "bindgen", "cmake", + "pkg-config", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index 29d519eae965..ba3106c9a2e4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -257,8 +257,9 @@ arrow-format = { git = "https://github.com/everpcpc/arrow-format", rev = "ad8f2d parquet2 = { git = "https://github.com/jorgecarleitao/parquet2", rev = "b0e6545" } metrics = { git = "https://github.com/datafuse-extras/metrics.git", rev = "fc2ecd1" } icelake = { git = "https://github.com/icelake-io/icelake", rev = "f06cdf3" } -sentry = { git = "https://github.com/getsentry/sentry-rust", rev = "6ef6d97" } micromarshal = { git = "https://github.com/ariesdevil/opensrv", rev = "6c96813" } async-backtrace = { git = "https://github.com/zhang2014/async-backtrace.git", rev = "dea4553" } +z3 = { git = "https://github.com/prove-rs/z3.rs", rev = "247d308" } +z3-sys = { git = "https://github.com/prove-rs/z3.rs", rev = "247d308" } geozero = { git = "https://github.com/georust/geozero", rev = "1d78b36" } # proj = { git = "https://github.com/ariesdevil/proj", rev = "51e1c60" } diff --git a/docker/build-tool/musl/Dockerfile b/docker/build-tool/musl/Dockerfile new file mode 100644 index 000000000000..cb3b8a276645 --- /dev/null +++ b/docker/build-tool/musl/Dockerfile @@ -0,0 +1,34 @@ +ARG RUST_TOOLCHAIN +FROM datafuselabs/build-tool:debian-${RUST_TOOLCHAIN} + +ARG ARCH +ENV MUSL_TARGET ${ARCH}-linux-musl +ENV MUSL_RUST_TARGET ${ARCH}-unknown-linux-musl + +RUN curl -sSfLo /tmp/musl-cross-make.tar.gz https://github.com/richfelker/musl-cross-make/archive/v0.9.10.tar.gz && \ + tar -xzf /tmp/musl-cross-make.tar.gz -d /tmp && \ + cd /tmp/musl-cross-make-* && \ + make install "-j$(nproc)" \ + OUTPUT=/usr/local/ \ + TARGET=${MUSL_TARGET} \ + DL_CMD='curl --retry 3 -sSfL -C - -o' && \ + rm -rf /tmp/musl-cross-make-* && \ + rm -f /tmp/musl-cross-make.tar.gz + +ENV C_INCLUDE_PATH /usr/local/${MUSL_TARGET}/include/ +RUN ln -s ${MUSL_TARGET}-gcc /usr/local/bin/musl-gcc + +RUN rustup target add ${MUSL_RUST_TARGET} + +# needed by z3 +RUN ln -s ${MUSL_TARGET}-g++ /usr/local/bin/musl-g++ +RUN ln -s ${MUSL_TARGET}-ar /usr/local/bin/musl-ar + +# HACK: something wrong with python detection in cmake for z3 +RUN ln -s python3.9 /usr/bin/python3.10 + +# HACK: to link with libstdc++ statically +# ref: https://github.com/rust-lang/rust/issues/36710#issuecomment-364623950 +COPY linker.sh /usr/local/bin/linker +RUN chmod +x /usr/local/bin/linker +RUN printf "[target.${MUSL_RUST_TARGET}]\nlinker = \"linker\"\n" >${CARGO_HOME}/config diff --git a/docker/build-tool/musl/linker.sh b/docker/build-tool/musl/linker.sh new file mode 100644 index 000000000000..a8ee80d9f326 --- /dev/null +++ b/docker/build-tool/musl/linker.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +args=() + +for arg in "$@"; do + if [[ $arg = *"Bdynamic"* ]]; then + args+=() # we do not want this arg + elif [[ $arg = *"crti.o"* ]]; then + args+=("$arg" "-Bstatic") + elif [[ $arg = *"crtn.o"* ]]; then + args+=("-lgcc" "-lgcc_eh" "-lc" "/usr/local/lib/gcc/${MUSL_TARGET}/9.4.0/crtendS.o" "$arg") + else + args+=("$arg") + fi +done + +echo "RUNNING WITH ARGS: ${args[@]}" +mold -run /usr/local/bin/${MUSL_TARGET}-g++ "${args[@]}" diff --git a/scripts/setup/run_build_tool.sh b/scripts/setup/run_build_tool.sh index 9c9aee8852a3..c1bdec59e560 100755 --- a/scripts/setup/run_build_tool.sh +++ b/scripts/setup/run_build_tool.sh @@ -24,16 +24,13 @@ USER=${USER:-$(whoami)} case $TARGET in x86_64-unknown-linux-gnu | aarch64-unknown-linux-gnu) RUNNER_BASE="debian" - USER_CMD="useradd -u ${_UID} -M -s /bin/bash ${USER}" ;; x86_64-unknown-linux-musl | aarch64-unknown-linux-musl) - RUNNER_BASE="alpine" - USER_CMD="adduser -u ${_UID} -D -H -s /bin/bash ${USER}" + RUNNER_BASE=${TARGET} ;; *) RUNNER_BASE="dev" TARGET=x86_64-unknown-linux-gnu - USER_CMD="useradd -u ${_UID} -M -s /bin/bash ${USER}" ;; esac @@ -50,7 +47,7 @@ else tmpdir=$(mktemp -d) cat >"${tmpdir}/Dockerfile" < /etc/sudoers.d/databend EOF diff --git a/src/binaries/Cargo.toml b/src/binaries/Cargo.toml index e1ec37ec6567..3384b38e51a9 100644 --- a/src/binaries/Cargo.toml +++ b/src/binaries/Cargo.toml @@ -66,7 +66,7 @@ log = { workspace = true } minitrace = { workspace = true } opendal = { workspace = true } poem = { workspace = true } -sentry = { version = "0.31.5", default-features = false, features = [ +sentry = { version = "0.32.2", default-features = false, features = [ "backtrace", "contexts", "panic", diff --git a/src/common/arrow/Cargo.toml b/src/common/arrow/Cargo.toml index ac9a69afb8ea..b29d97742171 100644 --- a/src/common/arrow/Cargo.toml +++ b/src/common/arrow/Cargo.toml @@ -157,6 +157,6 @@ tokio-util = { version = "0.7", features = ["compat"] } # used to run formal property testing async-std = "1.12" env_logger = "0.10" -flate2 = "1" +flate2 = "1.0.28" proptest = { version = "1", default_features = false, features = ["std"] } quanta = "0.11.1" diff --git a/src/query/constraint/Cargo.toml b/src/query/constraint/Cargo.toml index 2718507d10f4..7cc6357b85bb 100644 --- a/src/query/constraint/Cargo.toml +++ b/src/query/constraint/Cargo.toml @@ -13,7 +13,7 @@ test = false # Workspace dependencies # Crates.io dependencies -z3 = { version = "0.12.1", features = ["static-link-z3"] } +z3 = { version = "0.12.1", features = ["bundled"] } [dev-dependencies] criterion = "0.4"