moonchi
(moonchi)
May 4, 2021, 8:55pm
1
I used
CMAKE 3.19.8
Visual Studio 2019 x64 tool v142
And refer to
I hope I might find some help here. I recently started working on the PkModeling extension an I am trying to get it to build on various continuous integration platforms (Appveyor for Win and Travis CI for Linux and Mac).
https://github.com/michaelschwier/PkModeling/tree/CI
I got the build working on Appveyor but it copies some of the generated files to the wrong output. So the expected output would be “[pkmodeling-build]/bin/Release” (expected files there are: PkModeling.exe, PkModelingLib.dll…
I first installed and compiled
ITK DCMTK SlicerExecutionModel ZLIB
And join them in CMAKE-GUI
The following is my CMAKE interface
I used the Release mode to build
Then here is my error list
errorlist-Release
errorlog-Release
I want to know what I should do to successfully build Slicer
Thank you for your patience to read this
You previously posted on the following thread. Did the solution provided there solve the issue?
Probably the issue is that your system code page is set to 950 (Traditional Chinese) and c:\S4R\LibArchive\libarchive\archive_read_support_format_rar5.c contains characters that cannot be interpreted in this code page.
The simplest is to remove the offending characters (remove entire line 74, it is just a comment):
* "Rar!→•☺·\x00"
If you will keep running into similar errors then you may consider switching to Latin1 code page for the build.
I do see in one of the logs you posted that it warns the following:
warning C4819: The file contains a character that cannot be represented in the current code page (950)
moonchi
(moonchi)
May 4, 2021, 11:56pm
3
Sorry this is my fault. I emptied the old folder before this construction, which caused the same error to reappear. I have fixed it, thank you
This is the file I rebuilt, and the error is reduced to 9
Below is the new list
errorlist-Release
errorlog-Release
lassoan
(Andras Lasso)
May 7, 2021, 1:41pm
4
Most probably you have run into this issue:
opened 04:01PM - 01 Mar 21 UTC
domain:vtk9
type:bug
When building latest master version on Windows, using Visual Studio, in debug mo… de, then build fails with this error:
```
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at C:/Program Files/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
Could NOT find Python3 (missing: Python3_EXECUTABLE Interpreter) (found
suitable version "3.7", minimum required is "3.6")
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE)
C:/D/S4D/VTK-build/lib/cmake/vtk-9.0/patches/3.18/FindPython/Support.cmake:2578 (find_package_handle_standard_args)
C:/D/S4D/VTK-build/lib/cmake/vtk-9.0/patches/3.18/FindPython3.cmake:348 (include)
C:/D/S4D/VTK-build/lib/cmake/vtk-9.0/VTK-vtk-module-find-packages.cmake:303 (find_package)
C:/D/S4D/VTK-build/lib/cmake/vtk-9.0/vtk-config.cmake:138 (include)
C:/D/S4D/VTK-build/vtk-config.cmake:1 (include)
C:/D/S4D/ITK-build/lib/cmake/ITK-5.1/Modules/ITKVtkGlue.cmake:30 (find_package)
C:/D/S4D/ITK/CMake/ITKModuleAPI.cmake:76 (include)
C:/D/S4D/ITK/CMake/ITKModuleAPI.cmake:31 (itk_module_load)
C:/D/S4D/ITK/CMake/ITKModuleAPI.cmake:129 (_itk_module_config_recurse)
C:/D/S4D/ITK-build/ITKConfig.cmake:77 (itk_module_config)
SuperBuild.cmake:386 (find_package)
CMakeLists.txt:38 (include)
-- Configuring incomplete, errors occurred!
See also "C:/D/S4D/SimpleITK-build/CMakeFiles/CMakeOutput.log".
See also "C:/D/S4D/SimpleITK-build/CMakeFiles/CMakeError.log".
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppCommon.targets(238
,5): error MSB8066: Custom build for 'C:\D\S4D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleITK-mkdir.rule;C:\D\S4
D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleITK-download.rule;C:\D\S4D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde629
1e1\SimpleITK-update.rule;C:\D\S4D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleITK-patch.rule;C:\D\S4D\CMakeFiles
\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleITK-configure.rule;C:\D\S4D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleI
TK-build.rule;C:\D\S4D\CMakeFiles\76a3bb6e84cfb300f8ba64bbde6291e1\SimpleITK-install.rule;C:\D\S4D\CMakeFiles\55773c0e5
810be009a8f38bd18c05739\SimpleITK-complete.rule;C:\D\S4D\CMakeFiles\f5993a3ec64cf58c5707908b20f354e5\SimpleITK.rule;C:\
D\S4\CMakeLists.txt' exited with code 1. [C:\D\S4D\SimpleITK.vcxproj]
```
I don't know if it is related, but SimpleITK CMake cache (c:\D\S4D\SimpleITK-build\CMakeCache.txt) picks up pieces of anaconda, which is strange because my environment variables are clean (there is absolutely no mention of anaconda or python in any of the variables):
```
//Path to a program.
_Python3_CONFIG:INTERNAL=_Python3_CONFIG-NOTFOUND
_Python3_DEVELOPMENT_EMBED_SIGNATURE:INTERNAL=0993e8f7af6d2f88f03f3f71fd289925
_Python3_DEVELOPMENT_MODULE_SIGNATURE:INTERNAL=0993e8f7af6d2f88f03f3f71fd289925
//Path to a program.
_Python3_EXECUTABLE:INTERNAL=_Python3_EXECUTABLE-NOTFOUND
//Path to a file.
_Python3_INCLUDE_DIR:INTERNAL=C:/Users/andra/anaconda3/include
//Path to a library.
_Python3_LIBRARY_DEBUG:INTERNAL=_Python3_LIBRARY_DEBUG-NOTFOUND
//Path to a library.
_Python3_LIBRARY_RELEASE:INTERNAL=C:/Users/andra/anaconda3/libs/python37.lib
//Path to a library.
_Python3_RUNTIME_LIBRARY_RELEASE:INTERNAL=C:/Users/andra/anaconda3/python37.dll
//Result of TRY_COMPILE
project_compiles:INTERNAL=FALSE
```
You can find the full logs here: https://1drv.ms/u/s!Arm_AFxB9yqHxaN2aILYudYPjN5xdA?e=Fhpgcf
A workaround is to temporarily rename your other Python installation folder (anaconda, etc.). You can rename it back to the original name after Slicer build is complete.
moonchi
(moonchi)
May 8, 2021, 12:36pm
5
I tried the method you recommended, and successfully built the Release and Debug of Slicer. Thank you for your answers!
1 Like