Difference between revisions of "User:Inorton/Slicer3SuperBuildWindows7"

From NAMIC Wiki
Jump to: navigation, search
m (Blanked the page)
 
Line 1: Line 1:
'''Doesn't work:''' There is a CMake pseudo-dependency which causes the Slicer3 configure stage to report an error and abort the build. This can be subverted manually but there are dll errors when loading Slicer.
 
  
*install Microsoft Visual C++ Express 2008 from here: http://www.microsoft.com/express/Downloads/#2008-Visual-CPP
 
**Microsoft Visual C++ Express 2010 (http://www.microsoft.com/express/Downloads/#2010-Visual-CPP) has problems compiling Numpy, and the compiler is considerably slower than with 2008 version.
 
 
*install CMake from here: http://www.cmake.org/cmake/resources/software.html
 
*install msysGit from here: http://code.google.com/p/msysgit/
 
*install SlikSVN from here: http://www.sliksvn.com/en/download
 
*install WinCVS from here: http://cvsgui.sourceforge.net/download.html
 
**note: CVSNT component is the only actual requirement, and the :pserver authentication option MUST be installed (just use defaults). Don't worry about the fact that the binaries are a few years old, they work fine (look in "C:\Program Files (x86)" for the install dirs on Win7)
 
 
To start, checkout the Slicer3 source using svn (SlikSVN is added to system path by default).
 
*run cmd (cmd.exe, the windows command line. In Win7 just type "cmd" at the Search bar; in WinXP go to "Run Programs" and then type "cmd")
 
*cd c:\cmn\dev
 
*svn co http://svn.slicer.org/Slicer3/trunk Slicer3
 
 
Now run CMake.
 
 
For "Where is the source code" enter the source\SuperBuild directory, ie: C:/cmn/dev/Slicer3/SuperBuild
 
 
For "Where to build the binaries" enter something OUTSIDE the source tree, ie:  C:\cmn\dev\SlicerBUILD
 
 
*Run "Configure". Provided the steps above are set correctly, it will detect the CMakeLists and populate options.
 
*Select Generator "Visual Studio 10"
 
It should automagically detect git, cvs, and svn. If not, turned Advanced options on and manually select the svn and cvs executables from SlikSVN and CVSNT directories respectively (C:\Program Files (x86))
 
 
*Click Configure again
 
 
*If no errors, click Generate.
 
 
At this point if there are no errors, all of the configuration steps should be complete. To build:
 
*Go to the build directory entered above (C:\cmn\dev\SlicerBUILD)
 
*Open Slicer3.sln    This should open in visual studio or Visual C++ express.
 
*right click on the project "ALL_BUILD" and select "Build"
 
 
=Notes and Problems=
 
* '''DO NOT try to open the ALL_BUILD solution or to build the "Slicer3: 'Solution'" parent project. The dependencies will NOT be handled correctly and the build will fail.
 
 
* Visual Studio will fail to build if the CMake configure step returns an error, even if this error is non-fatal. For example, with the current (10/18/2010) Slicer trunk this error is reported by the configure step (from the VS Buildlog.htm for project 'Slicer3'):
 
<pre>
 
-- Configuring done
 
-- Generating done
 
CMake Error: Unknown Target referenced : EMSegmentCommandLine_GUIVersion
 
CMake Error: Target: EMSegmentBatchMakeModule depends on unknown target: EMSegmentCommandLine_GUIVersion
 
CMake Error: Unknown Target referenced : EMSegmentCommandLine_GUIVersion
 
CMake Error: Target: EMSegmentBatchMakeModule depends on unknown target: EMSegmentCommandLine_GUIVersion
 
CMake Error: Unknown Target referenced : EMSegmentCommandLine_GUIVersion
 
CMake Error: Target: EMSegmentBatchMakeModule depends on unknown target: EMSegmentCommandLine_GUIVersion
 
CMake Error: Unknown Target referenced : EMSegmentCommandLine_GUIVersion
 
CMake Error: Target: EMSegmentBatchMakeModule depends on unknown target: EMSegmentCommandLine_GUIVersion
 
-- Build files have been written to: C:/cmn/dev/Slicer3BUILD/Slicer3-build
 
Project : error PRJ0019: A tool returned an error code from "Performing configure step for 'Slicer3'"
 
</pre>
 
This error is not fatal, but it will raise "error level 1" and cause the VC buildscript to exit. It is possible to make the build finish by manually executing the steps found in Buildlog.htm after the configure step. However, Slicer gives a number of errors upon startup about bad DLL loading.. I think it is missing dll manifest information since the install step was not properly run.
 

Latest revision as of 20:15, 13 July 2018