Conversation
241c015 to
ef62e01
Compare
|
trying now with my local win, but it seems |
|
as a side note, |
Add support for building and testing on Windows OS in a consistent manner to Linux and macOS. On Windows, this uses RTools to provide the necessary build tools. Testing is performed in CircleCI as it offers a more powerful build machine under the free plan. Co-authored-by: Artur-man <artur-man@hotmail.com>
ef62e01 to
cc78177
Compare
|
i think the issue is with Rtools not seeing the make, there seems to be a quick fix for that, which i check before installing the package. UPDATE: getting close, it seems working with powershell instead of bash is solving the problem. An issue could be to write a separate workflow for windows, I will try unfying mac and win runs afterwards. |
|
It seems windows require a separate cmake setup because i am getting these compilation errors: UPDATE: looked over the web but couldn't find any specific solution, caused by gdcm ? Using |
|
@zivy know any fix to this |
|
The following check looks suspicious for a mingw compiler: I'll have to check to see if ITK has any current build with this compiler. |
|
I have tried the win build on my local win machine too and i am getting the same error, thus I will also try GHA in Getting the same error with the ITK build: |
|
What should be tested is building vanilla ITK with the mingw compiler. I suspect that a the preprocessor logic around this function need adjustment: |
|
Just tried on windows using the same error persists. |
|
Would it work if we turn off ITK IO GDCM module ? https://discourse.itk.org/t/how-to-disable-gdcm-functionality/6330 It seems that the GDCM is sooo deep into the dependancy tree that so many modules have to be manually turned on/off to get GDCM IO off. I turned off a bunch of stuff in ITK build in Thus now the install completes as expected. If you guys have a easy way to disable GDCM without turning off major modules please let me know :D ... or we can do a bug report in GDCM as well. |
|
It seems SimpleITK enforces GDCM: Unfortunately, the build will fail in R windows configure as long as GDCM is not fixed or enforced. |
|
I installed a mingw compiler is a msys2 environment. With just compelling ITK, from either release or main I was able to reproduce this error and there were others too. So there needs to be work done with ITK and it's third party libraries to support the mingw compiler. |
|
Thanks @blowekamp. It is nice that we discovered this issue. In my case, I need a remote win binary to decrease installation time (due to compilation). Thus as a last resort, I will try to point the compiler to an existing GDCM installation in a win machine. If that does not work, I will wait for the developments as you said. We have a nice package that wraps SimpleITK together with OpenCV here: It is better for users to install binaries of dependancies instead of lengthy compilation. |
|
I haven't had a chance to get back to this, but maybe try some older release version to see if they work with mingw. |
|
I have made PR for ITK to address compilation error encountered: ITK/ITK#5774 and ITK/ITK#5773 |
|
Wow @blowekamp, thanks for the quick fix InsightSoftwareConsortium/ITK#5792. I will check the build again when I have the time! |
|
When you configure the SimpleITK Superbuild you should be able to set ITK_GIT_TAG to ea28c4c7ff4041acbe425a302eca5be46e957def to build against those changes. Unfortunately the current ITK main underdevelopment seems to have and issue with HDF5 and mingw. It is similar to the error reported here: HDFGroup/hdf5#5885 This issue is unresolved but that some suggested changes/hacks. |
|
ITK now builds and SimpleITK keeps on going. The only problem with the win build is that it is slow, even with using all default number of cores which is 8, and the circleci puts 1 hour limit to a job on free plan. ITK builds in around 15 mins with 8 cores, but I still wait SimpleITK to finish. UPDATE: Yeap, jobs is terminated before build could complete. |
Yes, it has been tricky getting SimpleITK to build on some free resources. There have even a variety of limitations that have been encountered disk space, total CPU power available, memory for linking, but usually there are some tweaks and tunes to get it working. f I recall correctly @zivy said that the CircleCI builds were faster than GHA, but may GHA by have less CPUs over more time to allow the build to complete. It can be tricky to determine the correct parallel level for different services. Do you have a link to the build so I can see how far it's progressed? Also in the current SimpleITK main underdevelopment for SimpleITK 3.0, the super build is not longer needed. The code generation is now done through python, and support for getting swig from python is also there. So there are potential improvements in the build process also coming. |
|
I think this link is public enough: |
|
That build does not look close at all. I'd double check that the correct parallelism is occurring through make. And there may be a need to switch to GHA for the windows build. The windows builds on for SimpleITK take just over 2hrs in the main repository. https://github.com/SimpleITK/SimpleITK/actions/runs/21766261699 |
|
i might be able to do that, will test on my local win as well |
|
Will check here, lets see if it is gonna finish, running on 8 cores: UPDATE: it was finished in 1.5 hours but there is a problem with R library installation, perhaps I haven't set env variables correctly. |
|
It looks like R symbols were not found. Maybe the library isn't linked correctly? |
|
I will test by building locally and parse the build from the manual location in |
|
I am getting the same linking error during we get a bunch of undefined reference error, mostly (I assume) variables available in I checked ITKR again, and the build/install here happens in https://github.com/ANTsX/ITKR/blob/master/configure.win Have you guys never wrapped R bindings of SimpleITK in any windows machine before? or is this the first time we are doing this ? |
|
Sorry I haven't been participating in the discussion. If you check https://github.com/richardbeare/SimpleITK and look for old branches with names like "RWindowsBattles", you may find some useful but possibly out of date clues to how we got there. I recommend ignoring the installer at the start and focussing on getting a traditional SimpleITK build to work on a local machine over which you have control and with >8GB RAM, using the RTools 4+ and the toolchain that it comes with - I have definitely had success with that in the past. I recall having to contribute patches to the RTools project to bump versions of TBB. Scarily, I checked my old email and the "passing all tests" emails were 2017!
|
|
Thanks @richardbeare, yes I ignored the installer and built the cmake and cmake --build that failed using rtools mingw32 compiler that throw those reference errors as well. I will check the branch now. |
|
We currently do not link R.exe and R.dll, perhaps thats the issue ? ... I do not know about the ninja build though would that work with mingw32 ? |


Add support for building and testing on Windows OS in a consistent manner to Linux and macOS.
Repository URL and tag are specified in a shared
configuration file (SITK_CONFIG) which is used
by both the configure and configure.win scripts.
Testing is performed in CircleCI as it offers a
more powerful build machine under the free plan.