Skip to content

Commit

Permalink
fix configure.win + windows gh-action
Browse files Browse the repository at this point in the history
  • Loading branch information
JorisChau committed Mar 2, 2024
1 parent 8d901f0 commit 0fb85ab
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ jobs:
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes

RTOOLS43_HOME: 'C:\rtools43'

steps:
- name: Configure git
run: git config --global core.autocrlf false
Expand Down
8 changes: 4 additions & 4 deletions configure.win
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ fi
CC=`"${R_HOME}/bin/R" CMD config CC`
CFLAGS=`"${R_HOME}/bin/R" CMD config CFLAGS`
LDFLAGS=`"${R_HOME}/bin/R" CMD config LDFLAGS`
R_VER=`"${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" -e "paste0(version[['major']], as.integer(version[['minor']]))"`
R_VER=`"${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" --vanilla -e "cat(paste0(version[['major']], as.integer(version[['minor']])))"`

# Set LIB_GSL for gh-actions and r-winbuilder
if [ -z "${LIB_GSL}" ] && [ "${R_VER}" == "43" ] && [ -n "${RTOOLS43_HOME}" ] && [ -f "${RTOOLS43_HOME}/x86_64-w64-mingw32.static.posix/lib/libgsl.a" ]; then
echo "LIB_GSL is missing, detected GSL installation in ${RTOOLS43_HOME}"
LIB_GSL="${RTOOLS43_HOME}/x86_64-w64-mingw32.static.posix"
if [ -z "${LIB_GSL}" ] && [ "${R_VER}" = '43' ] && [ -n "${RTOOLS43_HOME}" ] && [ -f "${RTOOLS43_HOME}/x86_64-w64-mingw32.static.posix/lib/libgsl.a" ]; then
echo "** LIB_GSL is missing, detected GSL installation in ${RTOOLS43_HOME}"
LIB_GSL="${RTOOLS43_HOME}/x86_64-w64-mingw32.static.posix'"
fi

if test -n "${LIB_GSL}"; then
Expand Down

0 comments on commit 0fb85ab

Please sign in to comment.