diff --git a/ci/vcpkg/riscv64-linux-static-debug.cmake b/ci/vcpkg/riscv64-linux-static-debug.cmake new file mode 100644 index 000000000000..16f64e6173c2 --- /dev/null +++ b/ci/vcpkg/riscv64-linux-static-debug.cmake @@ -0,0 +1,28 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +set(VCPKG_TARGET_ARCHITECTURE riscv64) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Linux) +set(VCPKG_BUILD_TYPE debug) + +if(NOT CMAKE_HOST_SYSTEM_PROCESSOR) + execute_process(COMMAND "uname" "-m" + OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR + OUTPUT_STRIP_TRAILING_WHITESPACE) +endif() diff --git a/ci/vcpkg/riscv64-linux-static-release.cmake b/ci/vcpkg/riscv64-linux-static-release.cmake new file mode 100644 index 000000000000..968ddfde9f78 --- /dev/null +++ b/ci/vcpkg/riscv64-linux-static-release.cmake @@ -0,0 +1,28 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +set(VCPKG_TARGET_ARCHITECTURE riscv64) +set(VCPKG_CRT_LINKAGE dynamic) +set(VCPKG_LIBRARY_LINKAGE static) +set(VCPKG_CMAKE_SYSTEM_NAME Linux) +set(VCPKG_BUILD_TYPE release) + +if(NOT CMAKE_HOST_SYSTEM_PROCESSOR) + execute_process(COMMAND "uname" "-m" + OUTPUT_VARIABLE CMAKE_HOST_SYSTEM_PROCESSOR + OUTPUT_STRIP_TRAILING_WHITESPACE) +endif() diff --git a/compose.yaml b/compose.yaml index c799059fe254..37bdb28f1584 100644 --- a/compose.yaml +++ b/compose.yaml @@ -199,6 +199,8 @@ volumes: name: maven-cache python-wheel-manylinux-2-28-ccache: name: python-wheel-manylinux-2-28-ccache + python-wheel-manylinux-2-39-ccache: + name: python-wheel-manylinux-2-39-ccache python-wheel-musllinux-1-2-ccache: name: python-wheel-musllinux-1-2-ccache ubuntu-ccache: @@ -1182,6 +1184,31 @@ services: - ${DOCKER_VOLUME_PREFIX}python-wheel-manylinux-2-28-ccache:/ccache:delegated command: /arrow/ci/scripts/python_wheel_xlinux_build.sh + # See available versions at: + # https://quay.io/repository/pypa/manylinux_2_39_riscv64?tab=tags + python-wheel-manylinux-2-39: + image: ${REPO}:${ARCH}-python-${PYTHON}-wheel-manylinux-2-39-vcpkg-${VCPKG} + build: + args: + arch: ${ARCH} + arch_short: ${ARCH_SHORT} + base: quay.io/pypa/manylinux_2_39_riscv64:2026.03.01-1 + manylinux: 2_39 + python: ${PYTHON} + python_abi_tag: ${PYTHON_ABI_TAG} + vcpkg: ${VCPKG} + context: . + dockerfile: ci/docker/python-wheel-manylinux.dockerfile + cache_from: + - ${REPO}:${ARCH}-python-${PYTHON}-wheel-manylinux-2-39-vcpkg-${VCPKG} + secrets: *vcpkg-build-secrets + environment: + <<: [*common, *ccache] + volumes: + - .:/arrow:delegated + - ${DOCKER_VOLUME_PREFIX}python-wheel-manylinux-2-39-ccache:/ccache:delegated + command: /arrow/ci/scripts/python_wheel_xlinux_build.sh + # See available versions at: # https://quay.io/repository/pypa/musllinux_1_2_x86_64?tab=tags python-wheel-musllinux-1-2: diff --git a/dev/tasks/python-wheels/github.linux.yml b/dev/tasks/python-wheels/github.linux.yml index df5648f9e9ef..2fc8b268548c 100644 --- a/dev/tasks/python-wheels/github.linux.yml +++ b/dev/tasks/python-wheels/github.linux.yml @@ -27,6 +27,8 @@ jobs: name: "Build wheel for {{ linux_wheel_kind }} {{ linux_wheel_version }}" {% if arch == "amd64" %} runs-on: ubuntu-latest + {% elif arch == "riscv64" %} + runs-on: ubuntu-24.04-riscv {% else %} runs-on: ubuntu-24.04-arm {% endif %} @@ -37,6 +39,8 @@ jobs: # archery uses these environment variables {% if arch == "amd64" %} ARCH: amd64 + {% elif arch == "riscv64" %} + ARCH: riscv64 {% else %} ARCH: arm64v8 {% endif %} diff --git a/dev/tasks/tasks.yml b/dev/tasks/tasks.yml index 97843d2ef0cb..4799042a2925 100644 --- a/dev/tasks/tasks.yml +++ b/dev/tasks/tasks.yml @@ -183,6 +183,7 @@ tasks: {% for wheel_kind, arch, version, platform_tag in [("manylinux", "amd64", "2-28", "manylinux_2_28_x86_64"), ("manylinux", "arm64", "2-28", "manylinux_2_28_aarch64"), + ("manylinux", "riscv64", "2-39", "manylinux_2_39_riscv64"), ("musllinux", "amd64", "1-2", "musllinux_1_2_x86_64"), ("musllinux", "arm64", "1-2", "musllinux_1_2_aarch64")] %} wheel-{{ wheel_kind }}-{{ version }}-{{ python_tag }}-{{ abi_tag }}-{{ arch }}: