# # # patch "INSTALL" # from [b4c9369d29b0696a516303c55f39c9c1ec8b5fb6] # to [22044b4342c997c8caa90ec4759ccb0b4e6b8342] # ============================================================ --- INSTALL b4c9369d29b0696a516303c55f39c9c1ec8b5fb6 +++ INSTALL 22044b4342c997c8caa90ec4759ccb0b4e6b8342 @@ -83,6 +83,176 @@ 1. prerequisites: download and extract it manually and let CXXFLAGS point to the include/ directory of the extracted version. + on Windows (using MinGW): + + tools and packages needed: + + Package | Version | URL + -------------------------- + MingGW | 5.1.3 | http://prdownloads.sf.net/mingw/MinGW-5.1.3.exe?download + MSYS | 1.0.10 | http://prdownloads.sf.net/mingw/MSYS-1.0.10.exe?download + msysDTK | 1.0.1 | http://prdownloads.sf.net/mingw/msysDTK-1.0.1.exe?download + wget | 1.9.1 | http://prdownloads.sf.net/mingw/wget-1.9.1-mingwPORT.tar.bz2?download + libiconv | 1.11 | http://prdownloads.sf.net/mingw/libiconv-1.11-mingwPORT-20070423-1.tar.bz2?download + autoconf | 2.59 | http://prdownloads.sf.net/mingw/autoconf-2.59-mingwPORT.tar.bz2?download + automake | 1.9.5 | http://prdownloads.sf.net/mingw/automake-1.9.5-mingwPORT.tar.bz2?download + zlib | 1.2.3 | http://prdownloads.sf.net/mingw/zlib-1.2.3-mingwPORT.tar.bz2?download + gettext | 0.16.1 | ftp://aeneas.mit.edu/pub/gnu/gettext/gettext-0.16.1.tar.gz + boost | 1.34.1 | http://prdownloads.sf.net/boost/boost_1_34_1.tar.bz2?download + Lua | 5.1 | http://www.lua.org/ + pcre | 7.8 | http://www.pcre.org/ + botan | 1.8 | http://botan.randombit.net/news/ + sqlite3 | 3.6.10 | http://www.sqlite.org/download.html - sqlite-amalgamation-3_6_10.tar.gz, with makefile + libidn | 1.9 | ftp://ftp.gnu.org/gnu/libidn + + The installer defaults put MinGW in `c:\MinGW` and MSYS in + `c:\Msys`. However, later steps sometimes install new items + in `c:\MinGW\bin`, and sometimes in `c:\Msys\bin`. So it is + difficult to ensure that the new items are always first in + path. Installing MinGW and MSYS both to `c:\MinGW` avoids + this issue. However, in this case the MSYS installer + mistakenly renames 'make' to 'mingw32-make', so we need to + change it back. + + msysDTK installs Perl, CVS, crypt, and other tools needed + by the autoconf tools. The installed autoconf scripts are a + little broken, so we need to manually fix them. + + 1. MinGW - install, accept defaults but add g++ on the package selection page + 2. MSYS - install to same directory as MinGW (`c:\MinGW`), otherwise accept defaults + 3. msysDTK - install into MinGW directory + 4. Rename `make`: + $ mv /bin/mingw32-make.exe /bin/make.exe + + 5. wget + $ mkdir -p /usr/src + $ cd /usr/src + $ tar jxf wget-1.9.1-mingwPORT.tar.bz2 + $ cd wget-1.9.1/mingwPORT + $ cp -a wget.exe /mingw/bin + $ ./mingwPORT.sh + + 6. Accept all defaults by hitting the enter key. The following steps also always accept all defaults. + 7. libiconv + $ cd /usr/src + $ export SRCROOT=/usr/src + $ tar jxf libiconv-1.11-mingwPORT.tar.bz2 + $ cd libiconv-1.11/mingwPORT + $ ./mingwPORT.sh + + 8. autoconf + $ cd /usr/src + $ tar jxf autoconf-2.59-mingwPORT.tar.bz2 + $ cd autoconf-2.59/mingwPORT + $ ./mingwPORT.sh + + 9. Open `/mingw/bin/autoconf` in an editor and change the following line from something like + + : ${AUTOM4TE='c:/mingw/bin/autom4te'} + + to + + : ${AUTOM4TE='/mingw/bin/autom4te'} + + 10. automake + $ cd /usr/src + $ tar jxf automake-1.9.5-mingwPORT.tar.bz2 + $ cd automake-1.9.5/mingwPORT + $ ./mingwPORT.sh + + 11. Open the files `/mingw/bin/aclocal`, + `/mingw/bin/aclocal-1.9`, and all files matching + `auto*` in an editor and delete `c:/` from all paths, + as was done above for `autoconf`. + + 12. zlib + $ cd /usr/src + $ tar jxf zlib-1.2.3-mingwPORT.tar.bz2 + $ cd zlib-1.2.3/mingwPORT + $ ./mingwPORT.sh + + 13. gettext + $ cd /usr/src + $ tar zxf gettext-0.16.1.tar.gz + $ cd gettext-0.16.1 + $ wget 'http://cvs.savannah.gnu.org/viewvc/gettext/gettext/gettext-runtime/intl/\ + localename.c?r1=1.15&r2=1.16&view=patch' -O localename_1.15-1.16.patch + $ cd gettext-runtime/intl + $ patch -p0 < ../../localename_1.15-1.16.patch + $ cd ../.. + $ ./configure --prefix=/mingw + $ make install + + 14. If the wget command here fails, get the patch manually + from + ,
+ on *version 1.15*, click "select for diffs"
on + *version 1.16*, click "diff to previous 1.15"
near + top of page, click on "patch"
save file as + `c:/Downloads/mingw/localename_1.15-1.16.patch` + + 15. boost; only need headers + $ cd /usr/src + $ tar jxf boost_1_34_1.tar.bz2 + $ cd boost_1_34_1 + $ cp -a boost /mingw/include + + 16. Lua + $ cd /usr/src + $ tar zxf lua-5.1.4.tar.gz + $ cd lua-5.1.4 + $ make mingw + $ make install + + 17. pcre + $ cd /usr/src + $ tar zxf pcre-7.8.tar.gz + $ cd pcre-7.8 + $ ./configure + $ make install + + 18. botan + $ cd /usr/src + $ tar zxf Botan-1.8.0.tgz + $ cd Botan-1.8 + $ ./configure.pl --with-tr1=none + $ make install + + 19. sqlite3 + $ cd /usrsrc + $ tar zxf sqlite-amalgamation-3_6_10.tar.gz + $ cd sqlite-amalgamation-3.6.10 + $ ./configure + $ make install + + 20. libidn + $ cd /usr/src + $ tar zxf libidn-1.9.tar.gz + $ cd libidn-1.9 + $ ./configure + $ make install + + cd monotone + ./configure LUA_CFLAGS=-I/usr/local/include LUA_LIBS="-L/usr/local/lib -llua" \ + SQLITE3_CFLAGS=-I/usr/local/include SQLITE3_LIBS="-L/usr/local/lib -lsqlite3" \ + LIBIDN_CFLAGS=-I/usr/local/include LIBIDN_LIBS="-L/usr/local/lib -lidn" + + # Notes + + * If the `./configure` step of the monotone build fails + claiming your system is unrecognized while checking the + build system type, it may be caused by `uname -s` + returning a string containing MSYS rather than MINGW. + This indicates that your build environment is in a + special mode for producing MSYS binaries, which is not + what you want when building monotone. See + [MsysBuildEnvironment](http://www.mingw.org/MinGWiki/index.php/MsysBuildEnvironment) + for a detailed explanation. + + * If you get strange errors from perl when running + `autoreconf -i`, check that you edited the paths + correctly in `aclocal-*` and `auto*`. + on Windows (using Cygwin): FIXME: add exact name of needed packages