From 9e3fb832a3ccd3c830dd30d5304888be95db76fa Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Thu, 5 Nov 2009 23:47:06 +0100 Subject: [PATCH] Update the cross-compilation example. The mingw script is only necessary when the ./configure script of a project does not support the --host option that enables cross-compilation. --- examples/cross-compiling-windows-binary.mdwn | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/examples/cross-compiling-windows-binary.mdwn b/examples/cross-compiling-windows-binary.mdwn index 2af6c57..2e850c1 100644 --- a/examples/cross-compiling-windows-binary.mdwn +++ b/examples/cross-compiling-windows-binary.mdwn @@ -57,7 +57,8 @@ If `$HOME/bin` is not already part of your `$PATH`, you need to add it: > export PATH="$HOME/bin:$PATH" We use this script to call `./configure` and `make` with the right environment -variables. You can also run the export commands from the `mingw` script by +variables, but only when the `./configure` script doesn't support cross-compilation itself. +You can also run the export commands from the `mingw` script by hand instead of calling the mingw script for every `./configure` or `make` command, or execute `$HOME/bin/mingw $SHELL` to get a shell with these environment variables set, but in this howto we will call it explicitly every @@ -67,10 +68,10 @@ time it is needed. Cross-compiling LZO is easy: -> cd $HOME/lzo2-2.03 -> mingw ./configure --host=mingw32 -> mingw make -> DESTDIR=$HOME/mingw mingw make install +> cd $HOME/mingw/lzo2-2.03 +> ./configure --host=i586-mingw32msvc +> make +> DESTDIR=$HOME/mingw make install ### Compiling Zlib @@ -106,8 +107,8 @@ this is not necessary. > cd $HOME/mingw/tinc > autoreconf -fsi -> mingw ./configure --host=mingw32 --with-openssl=$HOME/mingw/usr/local -> mingw make +> ./configure --host=i586-mingw32msvc --with-openssl=$HOME/mingw/usr/local +> make ### Testing tinc -- 2.20.1