Windows package: statically link MatIO and GSL in Octave MEX files

Closes: #1750
time-shift
Sébastien Villemot 2020-11-18 15:31:06 +01:00
parent 426e52e2d9
commit f104b9d517
No known key found for this signature in database
GPG Key ID: 2CECE9350ECEBE4A
1 changed files with 9 additions and 0 deletions

View File

@ -94,6 +94,15 @@ fi
AC_CHECK_LIB([umfpack], [umfpack_dl_defaults], [LIBADD_UMFPACK="-lumfpack"], [AC_MSG_ERROR([Can't find UMFPACK])])
AC_SUBST([LIBADD_UMFPACK])
# On Windows, we want static linking of the external libraries
case ${host_os} in
*mingw32*)
GSL_LIBS="-Wl,-Bstatic $GSL_LIBS -Wl,-Bdynamic"
LIBADD_MATIO="-Wl,-Bstatic $LIBADD_MATIO -Wl,-Bdynamic"
LIBADD_SLICOT="-Wl,-Bstatic $LIBADD_SLICOT -Wl,-Bdynamic"
;;
esac
# Construct final output message
if test "$enable_mex_dynareplusplus" = yes; then
BUILD_GENSYLV_KORDER_DYNSIMUL_MEX_OCTAVE="yes"