1Installation on Woe32 (WinNT/2000/XP, Win95/98/ME): 2 3This file explains how to create binaries for the mingw execution environment. 4For how to create binaries for the cygwin environment, please see the normal 5INSTALL file. MS Visual C/C++ with "nmake" is no longer supported. 6 7I recommend to use the cygwin environment as the development environment 8and mingw only as the target (runtime, deployment) environment. 9For this, you need to install 10 - cygwin, 11 - the mingw runtime package, also from the cygwin site. 12 13You must not install cygwin programs directly under /usr/local - 14because the mingw compiler and linker would pick up the include files 15and libraries from there, thus introducing an undesired dependency to 16cygwin. You can for example achieve this by using the 17configure option --prefix=/usr/local/cygwin each time you build a 18program for cygwin. 19 20Building for mingw is then achieved through the following preparation 21and configure commands: 22 23 PATH=/usr/local/mingw/bin:$PATH 24 export PATH 25 ./configure --host=i586-pc-mingw32 --prefix=/usr/local/mingw \ 26 CPPFLAGS="-mno-cygwin -Wall -I/usr/local/mingw/include" \ 27 CFLAGS="-mno-cygwin -O2 -g" \ 28 CXXFLAGS="-mno-cygwin -O2 -g" \ 29 LDFLAGS="-mno-cygwin -L/usr/local/mingw/lib" 30 31The -mno-cygwin tells the cygwin compiler and linker to build for mingw. 32The -I and -L option are so that packages previously built for the 33same environment are found. The --host option tells the various 34tools that you are building for mingw, not cygwin. 35