BUILD.Windows: Some details on the proposed build system.
[sliver-openvswitch.git] / BUILD.Windows
1 Open vSwitch support on Windows is a work in progress.  This file describes
2 the planned build system to compile Open vSwitch on Windows.  Once the work
3 is complete, this file will be replaced by a INSTALL.Windows file.
4
5 Autoconf, Automake and Visual C++:
6 ---------------------------------
7 Open vSwitch on Linux uses autoconf and automake for generating Makefiles.
8 It will be useful to maintain the same build system while compiling on Windows
9 too.  One approach is to compile Open vSwitch in a MinGW environment that
10 contains autoconf and automake utilities and then use Visual C++ as a compiler
11 and linker.
12
13 The following explains the steps in some detail.
14 * Install Mingw on a Windows machine by following the instructions at:
15 http://www.mingw.org/wiki/Getting_Started
16
17 This should install mingw at C:\Mingw and msys at C:\Mingw\msys.
18 Add "C:\MinGW\bin" and "C:\Mingw\msys\1.0\bin" to PATH environment variable
19 of Windows.
20
21 You can either use the MinGW installer or the command line utility 'mingw-get'
22 to install both the base packages and additional packages like automake and
23 autoconf(version 2.68).
24
25 * Install the latest Python 2.x from python.org and verify that its path is
26 part of Windows' PATH environment variable.
27
28 * It is important to get the Visual Studio related environment variables and
29 to have the $PATH inside the bash to point to the proper compiler and linker.
30 One easy way to achieve this is to get into the "Developer Command prompt for
31 visual studio" and through it enter into the bash shell available from msys.
32
33 * Get the Open vSwitch sources from either cloning the repo using git
34 or from a distribution tar ball.
35
36 * Run ./boot.sh; ./configure CC=./build-aux/cccl; make
37 (cccl is a wrapper script that provides the right options to Visual c++
38 'cl' compiler.)