]> git.sesse.net Git - vlc/blob - INSTALL.win32
Make clear of what compilation is supported and which one is not for Windows.
[vlc] / INSTALL.win32
1 $Id$
2
3 INSTALL file for the Windows9x/Me/NT4/2k/XP version of the VLC media player
4
5
6 Running VLC
7 ===========
8
9 If you have already built VLC (see below) or are using a binary release,
10 just run 'vlc.exe'.
11
12 You can also run VLC from a dos command box, in which case you'll be able
13 to use the command line arguments. You can obtain a list of these command
14 line arguments by typing 'vlc --help' or 'vlc --help --advanced'.
15
16 To store a debug log of the current VLC session, you can use
17 'vlc -vv --extraintf=logger'. You will end-up with a vlc-log.txt file in
18 your current directory.
19
20 Additional documentation is available at http://www.videolan.org/doc/
21
22
23 Building VLC from the source code
24 =================================
25
26 If you want to build VLC from sources, you can do it in several ways:
27
28 - natively on Windows, using cygwin (www.cygwin.com) with or without the
29   POSIX emulation layer. This is the preferred way to compile vlc if you want
30   to do it on Windows.
31   NOTE: This is the PREFERRED way of building VLC natively (the others
32   are not as much tested so expect more difficulties with them).
33
34   Read http://wiki.videolan.org/Win32CompileCygwinNew to have a complete HOWTO
35
36 - On GNU/Linux, using the mingw32 cross-compiler.
37   This method is  preferred over all the others.
38
39 UNSUPPORTED METHODS
40 -------------------
41 - natively on Windows, using MSYS+MINGW (www.mingw.org)
42   (MSYS is a minimal build environment to compile Unixish projects under
43   windoze. It provides all the common Unix tools like sh, gmake...)
44   Please note that the gettext utilities are not included in the default
45   MSYS/MINGW packages so you won't be able to build VLC with i18n support.
46
47 - natively on Windows, using Microsoft Visual C++. Even though we provide some
48   msvc project files with vlc, this method is advised only if you just want to
49   experiment/play with some basic functionality in vlc. The reason for this
50   is that vlc depends on a lot of 3rd party libraries and building them in
51   MSVC is not convenient and sometimes even impossible.
52   ( NOTE: if you want to run vlc under the msvc debugger, you need to run it
53     with the --fast-mutex --win9x-cv-method=1 options because the debugger
54     usually loses signals sent by PulseEvent() )
55
56 Getting the right compiler tools
57 ================================
58
59 - cross-compiling with mingw32:
60 You first need to download a GNU/Linux cross-compiler version of mingw32.
61
62 For Debian GNU/Linux users, you can use the mingw32, mingw32-binutils and
63 mingw32-runtime packages.
64
65 - compiling natively on Windoze with cygwin:
66 You will need to download and run the setup.exe app from cygwin's web site
67 (www.cygwin.com). You will also need to make sure you install at least the
68 gcc-g++, gcc-mingw, mingw-runtime and win32-api packages.
69
70 - compiling natively on Windoze with MSYS+MINGW:
71 You will need to download and install the latest MSYS, MSYS-DTK and MINGW.
72 The installation is really easy. Begin with the MSYS auto-installer and once
73 this is done, extract MINGW into c:\msys\1.0\mingw. You also have to remember
74 to remove the make utility included with MINGW as it conflicts with the one
75 from MSYS (just rename or remove c:\msys\1.0\mingw\bin\make.exe).
76
77 http://www.mingw.org/download.shtml
78 http://prdownloads.sf.net/mingw/MSYS-1.0.9.exe
79 http://prdownloads.sf.net/mingw/MinGW-3.1.0-1.exe
80 http://prdownloads.sf.net/mingw/msysDTK-1.0.1.exe
81
82 Getting the additional libraries
83 =================================
84
85 VLC depends on other libraries to provide some features like ac3 audio decoding
86 or mpeg4 video decoding, etc...
87
88 Depending on your needs you will have to compile/install some or all of these
89 external libraries.
90
91 * They can be found here (source code):
92   http://download.videolan.org/pub/testing/contrib/
93
94 * We also provide a package with all the libraries already compiled so it is
95   actually really easy to compile a full-featured version of vlc (these compiled
96   libraries will only work with mingw or cygwin):
97   http://download.videolan.org/pub/testing/win32/contrib-20060330-win32-bin-gcc-3.4.5-only.tar.bz2
98   (Check out for more recent versions at the same location). 
99
100   All you need to do is extract it in your root directory (the include files
101   and libraries will be put in /usr/win32). You can do this with the following
102   command: 
103
104     tar xjvf contrib-20060330-win32-bin-gcc-3.4.5-only.tar.bz2 -C /
105
106   Please note the "-C /". 
107
108 * An automated way of building the contrib libraries is provided in 
109   extra/contrib. It will download, configure and build the libraries.
110   See the extras/contrib/README for more info.
111
112 A complete list of the libraries on which we depend can be found here:
113 http://developers.videolan.org/vlc/
114
115 Configuring the build
116 =====================
117
118 Once you've got all the files you need in place, you need to configure the
119 build with the `./configure' script.
120
121 I'll assume that you are using the pre-compiled 3rd party libraries we are
122 providing and that they are in /usr/win32.
123
124 If you are cross-compiling from Debian, you can use something
125 along those lines:
126
127   ./bootstrap && \
128   PATH=/usr/win32/bin:$PATH \
129   PKG_CONFIG_LIBDIR=/usr/win32/lib/pkgconfig \
130   CPPFLAGS="-I/usr/win32/include -I/usr/win32/include/ebml" \
131   LDFLAGS=-L/usr/win32/lib \
132   CC=i586-mingw32msvc-gcc CXX=i586-mingw32msvc-g++ \
133   ./configure --host=i586-mingw32msvc --build=i386-linux \
134       --disable-gtk \
135       --enable-nls --enable-sdl --with-sdl-config-path=/usr/win32/bin \
136       --enable-ffmpeg --with-ffmpeg-mp3lame --with-ffmpeg-faac \
137       --with-ffmpeg-zlib --enable-faad --enable-flac --enable-theora \
138       --with-wx-config-path=/usr/win32/bin \
139       --with-freetype-config-path=/usr/win32/bin \
140       --with-fribidi-config-path=/usr/win32/bin \
141       --enable-live555 --with-live555-tree=/usr/win32/live.com \
142       --enable-caca --with-caca-config-path=/usr/win32/bin \
143       --with-xml2-config-path=/usr/win32/bin \
144       --with-dvdnav-config-path=/usr/win32/bin \
145       --disable-cddax --disable-vcdx --enable-goom \
146       --enable-twolame --enable-dvdread \
147       --enable-debug
148
149 If you are using cygwin, you can build VLC with or without the POSIX
150 emulation layer. Without is usually better and with POSIX emulation
151 hasn't been tested in about a year or so. So to build without the
152 emulation layer, use something like this:
153
154   ./bootstrap && \
155   PATH=/usr/win32/bin:$PATH \
156   PKG_CONFIG_PATH=/usr/win32/lib/pkgconfig \
157   CPPFLAGS="-I/usr/win32/include -I/usr/win32/include/ebml" \
158   LDFLAGS=-L/usr/win32/lib \
159   CC="gcc -mno-cygwin" CXX="g++ -mno-cygwin" \
160   ./configure \
161       --disable-gtk \
162       --enable-nls --enable-sdl --with-sdl-config-path=/usr/win32/bin \
163       --enable-ffmpeg --with-ffmpeg-mp3lame --with-ffmpeg-faac \
164       --with-ffmpeg-zlib --enable-faad --enable-flac --enable-theora \
165       --with-wx-config-path=/usr/win32/bin \
166       --with-freetype-config-path=/usr/win32/bin \
167       --with-fribidi-config-path=/usr/win32/bin \
168       --enable-live555 --with-live555-tree=/usr/win32/live.com \
169       --enable-caca --with-caca-config-path=/usr/win32/bin \
170       --with-xml2-config-path=/usr/win32/bin \
171       --with-dvdnav-config-path=/usr/win32/bin \
172       --disable-cddax --disable-vcdx --enable-goom \
173       --enable-twolame --enable-dvdread \
174       --enable-debug
175
176 If you want to use the emulation layer, then just omit the CC="gcc -mno-cygwin"
177 CXX="g++ -mno-cygwin" line. You're on your own though.
178
179 If you are compiling with MSYS/MINGW, then you can use something along those
180 lines:
181   ./bootstrap && \
182   PKG_CONFIG_PATH=/usr/win32/lib/pkgconfig \
183   PATH=/usr/win32/bin:$PATH \
184   CPPFLAGS="-I/usr/win32/include -I/usr/win32/include/ebml" \
185   LDFLAGS=-L/usr/win32/lib \
186   ./configure \
187       --disable-gtk \
188       --enable-nls --enable-sdl --with-sdl-config-path=/usr/win32/bin \
189       --enable-ffmpeg --with-ffmpeg-mp3lame --with-ffmpeg-faac \
190       --with-ffmpeg-zlib --enable-faad --enable-flac --enable-theora \
191       --with-wx-config-path=/usr/win32/bin \
192       --with-freetype-config-path=/usr/win32/bin \
193       --with-fribidi-config-path=/usr/win32/bin \
194       --enable-caca --with-caca-config-path=/usr/win32/bin \
195       --with-xml2-config-path=/usr/win32/bin \
196       --with-dvdnav-config-path=/usr/win32/bin \
197       --disable-cddax --disable-vcdx --enable-goom \
198       --enable-twolame --enable-dvdread \
199       --disable-mkv \
200       --enable-debug
201
202 If you have used the "extras/contrib" way, you don't need to precise 
203 the CFLAGS, LDFLAGS and --with-foo-config-path=.
204  ./bootstrap && \
205   ./configure \
206       --disable-gtk \
207       --enable-nls --enable-sdl \
208       --enable-ffmpeg --enable-faad --enable-flac --enable-theora \
209       --disable-cddax --disable-vcdx --enable-goom \
210       --enable-twolame --enable-dvdread \
211       --enable-mkv --enable-caca --enable-live555\
212       --enable-debug
213
214
215 See `./configure --help' for more information.
216
217 Actually Compiling the VLC source
218 =================================
219
220 Once configured, to build VLC, just run `make'.
221
222 Once the compilation is done, you can either run VLC directly from the source
223 tree or you can build self-contained VLC packages with the following
224 'make' rules:
225
226   make package-win32-base
227    will create a subdirectory named vlc-x.x.x with all the binaries
228    'stripped' (ie. without any debugging symbols).
229
230   make package-win32-zip
231    Same as above but will package the directory in a zip file.
232
233   make package-win32
234    Same as above but will also create an auto-installer package. You will need
235    to have NSIS installed in its default location for this to work.
236
237 Well done, now you're ready to use VLC!
238 =======================================