User Tools

Site Tools


installation

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
installation [2014/11/29 16:43] – [Windows installation with Visual Studio] link to parallel hints johnnyonthewebinstallation [2016/06/29 16:16] – [Windows installation with Visual Studio] smilauer
Line 132: Line 132:
   * [[http://www.cmake.org|CMake]] is the cross-platform build tool OOFEM uses, and is able to generate build files for Visual Studio. See further instructions on the [[CMake|CMake]] wiki page.   * [[http://www.cmake.org|CMake]] is the cross-platform build tool OOFEM uses, and is able to generate build files for Visual Studio. See further instructions on the [[CMake|CMake]] wiki page.
   * [[https://code.google.com/p/tortoisegit/wiki/Download?tm=2|TortoiseGit]] is the most intuitive Git client for Windows.   * [[https://code.google.com/p/tortoisegit/wiki/Download?tm=2|TortoiseGit]] is the most intuitive Git client for Windows.
-  * [[http://www.paraview.org/|ParaView]] is a good and free replacement for oofeg.+  * [[http://www.paraview.org/|ParaView]] is a good and free replacement for oofeg under Windows.
 ===== Windows installation under MinGW environment ===== ===== Windows installation under MinGW environment =====
   * MinGW uses standard GNU g++ compiler. In a standard MinGW instalation, a few libraries included in oofem are missing (sys/resource.h, execinfo.h). These are not included during cmakeing and compilation for MinGW compilation.   * MinGW uses standard GNU g++ compiler. In a standard MinGW instalation, a few libraries included in oofem are missing (sys/resource.h, execinfo.h). These are not included during cmakeing and compilation for MinGW compilation.
Line 143: Line 143:
   * oofem.exe with static libraries, iml support and optimized version is build via <code>$cmake.exe -G"MinGW Makefiles" -DCMAKE_CXX_FLAGS="-O2" -DUSE_IML="ON" -DUSE_STATIC_LIB="ON" ..   * oofem.exe with static libraries, iml support and optimized version is build via <code>$cmake.exe -G"MinGW Makefiles" -DCMAKE_CXX_FLAGS="-O2" -DUSE_IML="ON" -DUSE_STATIC_LIB="ON" ..
 $mingw32-make.exe $mingw32-make.exe
-</code>If you want smoothless transfer of oofem.exe to another windows computer, you need to put all *.dll from c:\MinGW\bin in the same directory as oofem.exe.+</code>If you want smoothless transfer of oofem.exe to another Windows computer, you need to put all *.dll from c:\MinGW\bin in the same directory as oofem.exe.
  
 ===== Windows installation with Visual Studio ===== ===== Windows installation with Visual Studio =====
-  * Visual Studio 2013 is advised, since it fully supports C++11 specifications, see [[http://msdn.microsoft.com/en-us/library/hh567368.aspx|here]]. You can use the Express for Windows Desktop edition, free available [[http://www.visualstudio.com/en-us/products/visual-studio-express-vs.aspx|here]].+  * Visual Studio 2013 is advised, since it fully supports C++11 specifications, see [[http://msdn.microsoft.com/en-us/library/hh567368.aspx|here]]. You can use the Express for Windows Desktop edition, freely available [[http://www.visualstudio.com/en-us/products/visual-studio-express-vs.aspx|here]].
   * Get oofem code from Git repository as explained previously or, if you're using [[https://code.google.com/p/tortoisegit/wiki/Download?tm=2|TortoiseGit]], simply create a new folder (e.g. ''C:\oofem''), right-click on it and select ''Git clone...'' from the contextual menu. In the window that appears, use the address:<code>http://www.oofem.org/git/oofem.git</code>   * Get oofem code from Git repository as explained previously or, if you're using [[https://code.google.com/p/tortoisegit/wiki/Download?tm=2|TortoiseGit]], simply create a new folder (e.g. ''C:\oofem''), right-click on it and select ''Git clone...'' from the contextual menu. In the window that appears, use the address:<code>http://www.oofem.org/git/oofem.git</code>
 +  * Install [[https://cmake.org/download/|cmake]].
   * Start the VS2013 command prompt (choose x86 if you want a 32-bit compilation), and type ''cmake-gui'' and press enter to load the graphic interface for CMake. The bin folder in CMake installation directory must in system path; if the command does not work, add it and restart the prompt.   * Start the VS2013 command prompt (choose x86 if you want a 32-bit compilation), and type ''cmake-gui'' and press enter to load the graphic interface for CMake. The bin folder in CMake installation directory must in system path; if the command does not work, add it and restart the prompt.
   * In the CMake window, insert the path the previously downloaded oofem.git copy (e.g. ''C:\oofem'') in the fieds ''Where is the source code:'' and ''Where to build the binaries:'' and click ''Configure'' twice. Select in the data line now displayed in the main panel all the packages you want to include in your built (''USE_...'' flags). You can also leave the default checks. Finally press ''Generate'' and choose in the window that would appear ''Visual Studio 12 2013'' and ''Use native compiler''.   * In the CMake window, insert the path the previously downloaded oofem.git copy (e.g. ''C:\oofem'') in the fieds ''Where is the source code:'' and ''Where to build the binaries:'' and click ''Configure'' twice. Select in the data line now displayed in the main panel all the packages you want to include in your built (''USE_...'' flags). You can also leave the default checks. Finally press ''Generate'' and choose in the window that would appear ''Visual Studio 12 2013'' and ''Use native compiler''.
   * Now in the oofem folder (e.g. ''C:\oofem'') double-click on ''oofem.sln'' to start VS; right-click on the ''oofem'' project and click on ''Set as StartUp Project''. Compile the solution. You can find the resulting ''oofem.exe'' inside the ''Debug'', ''Release'', ''MinSizeRel'' or ''RelWithDebInfo'' folder.   * Now in the oofem folder (e.g. ''C:\oofem'') double-click on ''oofem.sln'' to start VS; right-click on the ''oofem'' project and click on ''Set as StartUp Project''. Compile the solution. You can find the resulting ''oofem.exe'' inside the ''Debug'', ''Release'', ''MinSizeRel'' or ''RelWithDebInfo'' folder.
-  * If you want to smoothless transfer oofem.exe to another windows computer, you may have to install [[http://www.microsoft.com/en-us/download/details.aspx?id=40784|VC++ 2012 redistributable package]]. +  * If you want to smoothless transfer oofem.exe to another windows computer, you may have to install [[http://www.microsoft.com/en-us/download/details.aspx?id=40784|VC++ 2013 redistributable package]].  
 +  * For the best debugging experience in VS, please deselect ''USE_SHARED_LIB'' in CMake to generate a monolithic executable. 
 +  * There are different configurations for Debug and Release versions under VS->Configuration manager->Active solution configuration. Debug version is generally slower and contains debugging symbols. Users usually choose Release version which is optimized for speed
  
-If you're interested in parallel version for Windows, go [[installing_optional#[Parallel version for Windows]|here]].+If you plan to redistribute the OOFEM executable to Windows XP machines, you must set the property ''Visual Studio 2013 - Windows XP (v120_xp)'' in ''Configuration Properties\General\Platform Toolset'' from the ''oofem'' project settings. 
 + 
 +If you're interested in **parallel version for Windows**, go [[installing_optional#[Parallel version for Windows]|here]].
installation.txt · Last modified: 2019/09/11 10:54 by bp