annotate DOCS/tech/mingw-crosscompile.txt @ 28846:7e58519eca33

Add a small howto explaining how to cross-compile for MinGW
author reimar
date Sun, 08 Mar 2009 10:01:21 +0000
parents
children 2adc364b3ba3
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
28846
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
1 Due to a lack of Windows developers, it is a good idea to allow Linux
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
2 developers to do at least some basic check of their code.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
3 This HOWTO explains how to set up MinGW cross-compilation under Debian.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
4
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
5 First, you need to install the "mingw32" package and get a MPlayer SVN checkou.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
6
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
7 Next, you need quite a lot of dependencies. Since this is for testing and
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
8 not actually use, the easiest way is to use this package:
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
9 http://natsuki.mplayerhq.hu/~reimar/mpl_mingw32.tar.bz2
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
10 NOTE that this is likely to be quite out-dated and might include packages
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
11 with security issues, so do not use it to build binaries for real use.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
12
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
13 After extracting this package into the MPlayer source-tree,
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
14 you only need to run the included linux-mingw.sh to configure (it just runs
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
15 ./configure --host-cc=cc --target=i686-mingw32msvc --cc=i586-mingw32msvc-cc
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
16 --windres=i586-mingw32msvc-windres --ranlib=i586-mingw32msvc-ranlib
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
17 --with-extraincdir="$PWD/osdep/mingw32"
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
18 --with-extralibdir="$PWD/osdep/mingw32"
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
19 --with-freetype-config="$PWD/osdep/mingw32/ftconf") and then run make.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
20
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
21 You should be able to run the generated binary with Wine, if you want to.
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
22
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
23 The steps as command-lines:
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
24
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
25 sudo apt-get install mingw32
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
26 svn co svn://svn.mplayerhq.hu/mplayer/trunk MPlayer-mingw
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
27 cd MPlayer-mingw
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
28 wget http://natsuki.mplayerhq.hu/~reimar/mpl_mingw32.tar.bz2
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
29 tar -xjf mpl_mingw32.tar.bz2
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
30 sh linux-mingw.sh
7e58519eca33 Add a small howto explaining how to cross-compile for MinGW
reimar
parents:
diff changeset
31 make