Skip to content

Commit

Permalink
use quotes on windows, fix lib name on posix
Browse files Browse the repository at this point in the history
  • Loading branch information
mattip committed Oct 29, 2023
1 parent 5758b60 commit d2c52da
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions tools/build_openblas.sh
Original file line number Diff line number Diff line change
Expand Up @@ -95,17 +95,17 @@ make BINARY=$build_bits DYNAMIC_ARCH=1 USE_THREAD=1 USE_OPENMP=0 \
COMMON_OPT="$cflags" \
FCOMMON_OPT="$fflags" \
MAX_STACK_ALLOC=2048 \
SYMBOLPREFIX=scipy_ \
SYMBOLPREFIX="scipy_" \
$interface64_flags
make PREFIX=$openblas_root/$build_bits $interface64_flags \
. SYMBOLPREFIX=scipy_ install
. SYMBOLPREFIX="scipy_" install
DLL_BASENAME=libopenblas${SYMBOLSUFFIX}_${LIBNAMESUFFIX}
if [ "$if_bits" == "64" ]; then
# OpenBLAS does not build a symbol-suffixed static library on Windows:
# do it ourselves
set -x # echo commands
static_libname=$(find . -maxdepth 1 -type f -name '*.a' \! -name '*.dll.a' | tail -1)
make -C exports SYMBOLPREFIX=scipy_ $interface64_flags objcopy.def
make -C exports SYMBOLPREFIX="scipy_" $interface64_flags objcopy.def
objcopy --redefine-syms exports/objcopy.def "${static_libname}" "${static_libname}.renamed"
cp -f "${static_libname}.renamed" "$openblas_root/$build_bits/lib/${static_libname}"
cp -f "${static_libname}.renamed" "$openblas_root/$build_bits/lib/${DLL_BASENAME}.a"
Expand Down
2 changes: 1 addition & 1 deletion tools/build_steps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ function do_build_lib {
tar zcvf libs/$out_name \
$BUILD_PREFIX/include/*blas* \
$BUILD_PREFIX/include/*lapack* \
$BUILD_PREFIX/lib/libscipyopenblas* \
$BUILD_PREFIX/lib/libscipy_openblas* \
$BUILD_PREFIX/lib/pkgconfig/openblas* \
$BUILD_PREFIX/lib/cmake/openblas
}
Expand Down

0 comments on commit d2c52da

Please sign in to comment.