diff --git a/docs/packages/cvc5.yaml b/docs/packages/cvc5.yaml index dd67fbef0ac9..5846ea07bd18 100644 --- a/docs/packages/cvc5.yaml +++ b/docs/packages/cvc5.yaml @@ -35,3 +35,4 @@ versions: sha256: ac838cf194b49ddd41d6c4d168e5c2b7010a10ef42af694dafaf4507dd068586 - filename: cvc5-1.4.1-cp314-cp314-manylinux_2_39_riscv64.whl sha256: 8ce9e963ad3e603a110a7b188999984eaeae3d21fffe6635e6dc2ffe9fb26962 +- version: 1.4.2 diff --git a/patches/cvc5/1.4.2/0001-Map-riscv64-to-a-Linux-build-triplet-for-GMP.patch b/patches/cvc5/1.4.2/0001-Map-riscv64-to-a-Linux-build-triplet-for-GMP.patch new file mode 100644 index 000000000000..3a8e33e73e58 --- /dev/null +++ b/patches/cvc5/1.4.2/0001-Map-riscv64-to-a-Linux-build-triplet-for-GMP.patch @@ -0,0 +1,35 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: Ludovic Henry +Date: Fri, 25 Sep 2026 00:00:00 +0000 +Subject: [PATCH] Map riscv64 to a Linux build triplet for GMP + +BUILD_TRIPLET is handed to GMP's configure as --build, and only x86_64 +and aarch64 get a full "-linux-gnu" triplet. On riscv64 it falls +back to the bare CMAKE_HOST_SYSTEM_PROCESSOR, which GMP's config.sub +canonicalises to "riscv64-unknown-none". libtool knows no dynamic linker +for host_os "none", so GMP's configure answers "whether to build shared +libraries... no" and produces only libgmp.a, while the default +BUILD_SHARED_LIBS build links against deps/lib/libgmp.so. + +Give riscv64 the same treatment as aarch64. With riscv64-linux-gnu GMP +still selects its mpn/riscv/64 assembly and builds libgmp.so. + +Upstream-Status: To upstream [not yet submitted; cmake/Helpers.cmake on cvc5 main still has no riscv64 branch] + +Signed-off-by: Ludovic Henry +--- +diff --git a/cmake/Helpers.cmake b/cmake/Helpers.cmake +index 25c86dc3a..c0156862c 100644 +--- a/cmake/Helpers.cmake ++++ b/cmake/Helpers.cmake +@@ -34,6 +34,8 @@ if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Linux") + set(BUILD_TRIPLET "x86_64-linux-gnu") + elseif(CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL "aarch64") + set(BUILD_TRIPLET "aarch64-linux-gnu") ++ elseif(CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL "riscv64") ++ set(BUILD_TRIPLET "riscv64-linux-gnu") + endif() + elseif(CMAKE_HOST_SYSTEM_NAME STREQUAL "Darwin") + if(CMAKE_HOST_SYSTEM_PROCESSOR STREQUAL "x86_64") +-- +2.43.0