Windows build » History » Version 22
« Previous -
Version 22/98
(diff) -
Next » -
Current version
pospelov, 05 Sep 2013 14:28
Windows build¶
Experimental compilation under Windows using Mingw or Microsoft Visual Studio.
To be updated.
Install packages for happier life¶
- Atlassian SourceTree (v0.9.2.3)
- Kate from KDE
http://download.kde.org/stable/kdewin/installer/kdewin-installer-gui-latest.exe.mirrorlist
- far manager
- WinSCP
First assure compilation of MinGW, then switch to Visual Studio recipe
Mingw build¶
Install Qt, cmake¶
- Install Qt 5.1.0, MinGW is part of this installer
http://qt-project.org/downloads
Add to PATH C:\Qt\Tools\mingw48_32\bin;C:\Qt\Tools\mingw48_32\lib;C:\Qt\5.1.0\mingw48_32\bin;C:\Qt\Tools\QtCreator\binthis will allow usage of mingw from any command line
- install cmake
http://www.cmake.org/cmake/resources/software.html by running cmake-2.8.11.2-win32-x86.exe
Install Python and Co¶
- Install Python
install through http://www.python.org/ftp/python/2.7.5/python-2.7.5.msi into C:/Python27
- install numpy
from unofficial http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy by running numpy-unoptimized-1.7.1.win32-py2.7.exe
- install matplotlib
from http://matplotlib.org/downloads.html by running matplotlib-1.2.1.win32-py2.7.exe
(alternative install Anaconda pack (python + mingw + numpy) from http://continuum.io/downloads ) Not checked!
Comment about installation of additional libraries¶
All further installations should end up in C:\opt\local
Install gsl, fftw3¶
- Install gsl
using corresponding gnuwin32 setup file from http://gnuwin32.sourceforge.net/packages.html
install in the default location
copy "C:\Program Files (x86)\GnuWin32\include\gsl" to "C:\opt\local\include\gsl"
copy libgsl.dll and libgslcblas.dll from "C:\Program Files (x86)\GnuWin32\bin" to "C:\opt\local\lib"
- Install fftw3
from http://www.fftw.org/install/windows.html download fftw-3.3.3-dll32.zip
unpack archive somewhere
copy fftw3.h to C:\opt\local\include
copy libfftw3-3.dll and libfftw3-3.def to C:\opt\local\lib
install BOOST¶
- install zlib and bzip2
from http://www.zlib.net/ into C:/opt/local/source/zlib-1.2.8
from http://www.bzip.org/downloads.html into C:/opt/local/source/bzip2-1.0.6Patch bzip2 installation (necessary for MSVC build later)
Namely delete first line ("LIBRARY LIBBZ2") from file libbz2.def
This will remove unnecessary dependency from external bzip2 during MSVC boost compilation
- Download and compile boost_1_54_0
from http://sourceforge.net/projects/boost/files/boost/1.54.0/ and unpack
cd <BOOSTDIR>
bootstrap.bat mingw
b2 install --prefix=c:/opt/local toolset=gcc -sBZIP2_SOURCE="C:\opt\local\source\bzip2-1.0.6" -sZLIB_SOURCE="C:\opt\local\source\zlib-1.2.8" address-model=32 variant=release link=static,shared threading=single,multi
Move c:/opt/local/include/boost_1.54/boost directory into c:/opt/local/include/boost
PATH¶
- Add c:\home\pospelov\development\git\BornAgain\lib;c:\opt\local\lib to PATH
Where we are?¶
- At this point Qt creator should work (except App and GUI)
- At this point cmake should work too
cmake -G "MinGW Makefiles" ../BornAgain
mingw32-make -j4
mingw32-make check
MS Visual Studio build¶
Install VS.NET2012¶
Install En language pack
install "stop build on error" plugin http://visualstudiogallery.msdn.microsoft.com/91aaa139-5d3c-43a7-b39f-369196a84fa5
Comment about installation of additional libraries¶
All further installations should end up in C:\opt\local_vc110
- Install gsl
Download source gsl-1.8-src.zip from http://gnuwin32.sourceforge.net/downlinks/gsl-src-zip.php
Copy gsl-1.8 source dir into C:/opt/local_vc110/source
Open VC8/libgsl.sln in Visual Studio and compile project
Copy libgsl.dll and libgsl_dll.lib from VC8/libgsl/Release-DLL/ to C:/opt/local_vc110/lib
Copy libgslcblas.dll and libgslcblas_dll.lib from VC8/libgslcblas/Release-DLL/ to C:/opt/local_vc110/lib
Copy C:/opt/local/include/gsl to C:/opt/local_vc110/include/gsl
- Install fftw3
from http://www.fftw.org/install/windows.html download fftw-3.3.3-dll32.zip
unpack archive somewhere
copy fftw3.h to C:\opt\local_vc110\include
copy libfftw3-3.dll and libfftw3-3.def to C:\opt\local_vc110\lib
generate corresponding lib filerun "VS2012 x86 native tools command prompt"
run there "lib /def:libfftw3-3.def" to generate lib file