Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ jobs:
command: |
set -x
R -e "Sys.setenv(MAKEJ=3); remotes::install_git(c('.'), lib=c('${R_LIBS}'))"

R -e "library(SimpleITK); Version()"
workflows:
r-build-test:
# Runs on: push to main, pull requests to main, manual trigger, and scheduled runs
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
strategy:
fail-fast: false
matrix:
R: [ '4.3.3', '4.5.3' ]
R: [ '4.4.3', '4.5.3' ]
os: [ 'macos-15-intel', 'ubuntu-latest', 'windows-latest']
runs-on: ${{ matrix.os }}
name: ${{ matrix.R }} ${{ matrix.os }} build
Expand Down Expand Up @@ -44,6 +44,8 @@ jobs:
mkdir -p "$R_LIBS"
cmake --version
if [[ "$RUNNER_OS" == "Windows" ]]; then
ls -d /c/rtools* 2>/dev/null || echo "No rtools found in /c/"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider: `... | ( echo "::error No rtools found in /c/") && exit 1)

which g++ || { echo "No g++ found on PATH"; exit 1; }
g++ --version
else
c++ --version
Expand All @@ -60,3 +62,4 @@ jobs:
ITK_GLOBAL_DEFAULT_NUMBER_OF_THREADS: 2
run: |
R -e "Sys.setenv(MAKEJ=2); remotes::install_git(c('.'), lib=Sys.getenv('R_LIBS'))"
R -e "library(SimpleITK); Version()"
7 changes: 5 additions & 2 deletions configure
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#!/bin/bash
set -e

# configure script that will fetch and build SimpleITK, then move the results
# to somewhere that R can install. It takes a long time and uses
Expand Down Expand Up @@ -67,7 +68,9 @@ mkdir -p SITK
echo "Parallel build using -j${MAKEJ}"
cmake --build . --target SimpleITK-build -- -j${MAKEJ} && \
rm -rf ITK-build &&
# Use R to do the move to avoid system specific issues.
${RCALL} -f ${PKGBASED}/sitkmove.R --args SimpleITK-build/Wrapping/R/Packaging/SimpleITK/ ${PKGBASED} ||
# CMake builds the R package in an isolated directory. Move its contents
# into the package source tree so that R CMD INSTALL can find them.
cp -r SimpleITK-build/Wrapping/R/Packaging/SimpleITK/* "${PKGBASED}" && \
rm -rf SimpleITK-build/Wrapping/R/Packaging/SimpleITK/ ||
exit 1
) || exit 1
13 changes: 6 additions & 7 deletions configure.win
Original file line number Diff line number Diff line change
Expand Up @@ -97,12 +97,11 @@ export MAKEJ
echo "Parallel build using -j${MAKEJ}"
echo $PWD
# Build the specific target with parallel jobs
cmake --build . --target SimpleITK-build -- -j"${MAKEJ}"

# Remove ITK-build to save space (if present)
[ -d ITK-build ] && rm -rf ITK-build

# Use R to do the move to avoid system specific issues.
${RCALL} -f ${PKGBASED}/sitkmove.R --args SimpleITK-build/Wrapping/R/Packaging/SimpleITK/ ${PKGBASED} ||
cmake --build . --target SimpleITK-build -- -j"${MAKEJ}" && \
rm -rf ITK-build &&
# CMake builds the R package in an isolated directory. Move its contents
# into the package source tree so that R CMD INSTALL can find them.
cp -r SimpleITK-build/Wrapping/R/Packaging/SimpleITK/* "${PKGBASED}" && \
rm -rf SimpleITK-build/Wrapping/R/Packaging/SimpleITK/ ||
exit 1
)
36 changes: 0 additions & 36 deletions sitkmove.R

This file was deleted.

Loading