summaryrefslogtreecommitdiff
path: root/doc/README.WIN32
blob: 3a722897e8e3c048cbca5178d0abe86d7ed12ea8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
Introduction
------------

This document describes how to build xine library under Windows.


Download
--------
Checkout source code from CVS (under Windows can be used CygWin or another tool). You will need 'xine-lib' (the library) and 'xine-win32' (testing Windows frontend).


Build
-----

There are three different ports on Windows:
 1) MinGW (the simplest and recommended)
 1) CygWin
 3) M$ Visual C, or maybe .NET (recommended for debugging)


1. MinGW port
-------------
This is the best way. Final library is 100% native Windows with all optimizations.

Also you can use cross-build from comfortable unix-like system. See README.MINGWCROSS for more information.

Requirements for compilation under Windows:
  a) MinGW installed on Windows
  b) LIB.EXE, LINK.EXE and MSPDB60.DLL from M$ Visual C 
     (necessary only for usability created xine library by M$ compilers)

How to build:
    #
    # configure for building in MinGW under Windows
    #
    ./configure --with-dxheaders=DIRECTORY

    #
    # compile
    #
    make

    #
    # install and manually remove the static plugins
    #
    make install DESTDIR=/tmp/xine-lib
    rm /tmp/xine-lib/bin/plugins/*.a
    rm /tmp/xine-lib/bin/plugins/post/*.a

Prepare xine library for using in M$ compilers too:
    # run terminal window (MinGW for example)
    ...
    # creating libxine-1.lib file
    cd <path_where_libxine_is_installed_>/lib
    cp ../bin/libxine-1.dll .
    <path_to_M$VC>/VC98/BIN/LIB.EXE /machine:i386 /def:libxine-1.def
    rm libxine-1.dll


2. CygWin port
--------------
This is the second way. Created library won't be 100% windows native: it will contains some additional emulation code and I'm not sure, if can be used with M$ compilers.

It's possible to use CygWin for cross-compiling with MinGW.

How to build:
    #
    # configure
    #
    ./configure --with-dxheaders=DIRECTORY

    #
    # compile
    #
    make

    #
    # install
    #
    make install DESTDIR=/tmp/xine-lib


3. M$ Visual C port
-------------------
This build system is different from the one, used for all other platforms, but we partially keep it up to date - just for experimental reasons, but only if we have access to some M$ computer.

Reasons, why not to use this port:
 - can't compile included ffmpeg (important multi-decoder in xine)
 - can't compile new assembler code (it means degradation of power)
 - never 100% up to date
 - somebody must buy the OS and compiler

Reasons, why to use this port:
 - obtaining backtrace after crash, debugging

How to build xine in M$ Visual C:
  - Set up MSVC to look for DirectX headers.

  - Open up the xine.dsw workspace/project in MSVC.

  - Unless you have a project file to build css you must select Cancel when prompted for the libdvdcss.dsp file.

  - Click on the FileView tab.

  - Build the following projects in this order:
    libxinesuppt
    libxine
    libdvdnav

  - Next build any desired plugins (decoders/demuxers ...). The ao_out_directx and vo_out_directx are required for Win32. There is an option to use the vo_out_sdl but a sdl.dll must be present for that to take place. There have also been some issues observed with the directX video driver on some machines.

  - If you want ffmpeg decoder plugin, you must use precompiled version. If you want to compile it, you should have the files LIB.EXE, LINK.EXE and MSPDB60.DLL from the Visual C++.
    Under MinGW you can compile ffmpeg for xine by this way:

    #
    # for cross-compiling add "--cross-prefix=i386-mingw32-" and "--disable-mmx"
    #
    ./configure \
       --enable-gpl \
       --enable-pp \
       --enable-shared \
       --disable-zlib \
       --enable-mingw32
    make
    make install prefix=/tmp/ffmpeg
    cp avcodec/avcodec.def /tmp/ffmpeg
    #
    # for cross-compiling finalize linking by running this command 
    #
    wine LIB.EXE /machine:i386 /def:avcodec.def

Status
------

There remains many of work yet on Windows port.

Limitations:
 - doesn't work under Win95/98 (DirectX? win32-pthreads?)
 - file > 1GB doesn't work (MinGW problem?)
 - missing full Win32 frontend
 - build system isn't fully tuned for cross-compiling

Bugs:
 - use GetCurrentDirectory(SIZE, STR) because of changing volume drive!
 - random crashes
 - seeking doesn't work with testing frontend
 - non-seekable input plugins crash