Skip to content

Commit ce22cc0

Browse files
authored
[SuiteSparse] Fix build for 64-bit BLAS (#10215)
* Properly pass build option into the script section * Remove hard-coded CMake version to let it get the newest
1 parent 39a1ecf commit ce22cc0

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

S/SuiteSparse/SuiteSparse@7/build_tarballs.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ PROJECTS_TO_BUILD="suitesparse_config;amd;btf;camd;ccolamd;colamd;cholmod;klu;ld
1414
build_tarballs(ARGS, name, version, sources, script, platforms, products, dependencies;
1515
julia_compat="1.11")
1616

17-
# Build trigger: 1
17+
# Build trigger: 2

S/SuiteSparse/common.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ dependencies = [
9191
compat="5.8.0"),
9292
BuildDependency("LLVMCompilerRT_jll",platforms=[Platform("x86_64", "linux"; sanitize="memory")]),
9393
# Need the most recent 3.29.3+1 version (or later) to get libblastrampoline support
94-
HostBuildDependency(PackageSpec(; name="CMake_jll", version = v"3.29.3"))
94+
HostBuildDependency(PackageSpec(; name="CMake_jll"))
9595
]
9696

9797
# Generate a common build script for most SuiteSparse packages.
@@ -103,7 +103,7 @@ dependencies = [
103103
# certain packages.
104104
# Use PROJECTS_TO_BUILD to specify which projects to build.
105105
function build_script(; use_omp::Bool = false, use_cuda::Bool = false, build_32bit_blas::Bool = false)
106-
return "USEOMP=$(use_omp)\nUSECUDA=$(use_cuda)\n" * raw"""
106+
return "USE_OMP=$(use_omp)\nUSE_CUDA=$(use_cuda)\nUSE_32BIT_BLAS=$(build_32bit_blas)\n" * raw"""
107107
cd $WORKSPACE/srcdir/SuiteSparse
108108
109109
# Needs cmake >= 3.29 provided by jll
@@ -116,7 +116,7 @@ if [[ ${bb_full_target} == *-sanitize+memory* ]]; then
116116
cp -rL ${libdir}/linux/* /opt/x86_64-linux-musl/lib/clang/*/lib/linux/
117117
fi
118118
119-
if [[ ${nbits} == 64 ]] && [[ ${build_32bit_blas} == false ]]; then
119+
if [[ ${nbits} == 64 ]] && [[ ${USE_32BIT_BLAS} == false ]]; then
120120
CMAKE_OPTIONS+=(
121121
-DBLAS64_SUFFIX="_64"
122122
-DSUITESPARSE_USE_64BIT_BLAS=YES
@@ -142,8 +142,8 @@ cmake -DCMAKE_BUILD_TYPE=Release \
142142
-DSUITESPARSE_DEMOS=OFF \
143143
-DSUITESPARSE_USE_STRICT=ON \
144144
-DSUITESPARSE_USE_FORTRAN=OFF \
145-
-DSUITESPARSE_USE_OPENMP=${USEOMP} \
146-
-DSUITESPARSE_USE_CUDA=${USECUDA} \
145+
-DSUITESPARSE_USE_OPENMP=${USE_OMP} \
146+
-DSUITESPARSE_USE_CUDA=${USE_CUDA} \
147147
-DCHOLMOD_PARTITION=ON \
148148
"${CMAKE_OPTIONS[@]}" \
149149
..

0 commit comments

Comments
 (0)