title: build vim with MinGW
body: <p>I'm trying to build vim with MinGW by running <code>./configure &amp;&amp; make</code> in the vim repository root, but I'm getting the following error:</p>
  
  <pre><code>checking --with-tlib argument... empty: automatic terminal library selection
  checking for tgetent in -ltinfo... no
  checking for tgetent in -lncurses... no
  checking for tgetent in -ltermlib... no
  checking for tgetent in -ltermcap... no
  checking for tgetent in -lcurses... no
  no terminal library found
  checking for tgetent()... configure: error: NOT FOUND!
        You need to install a terminal library; for example ncurses.
        Or specify the name of the library with --with-tlib.
  C:\pdev\MinGW\bin\sed.exe: -e expression #1, char 1: unknown command: `C'
  </code></pre>
  
  <p>While researching this issue, I came across <a href="https://groups.google.com/forum/?fromgroups=#!topic/vim_use/dhJ2HEz0JGU" rel="nofollow">this post on the vim_use Google Groups</a>,
  which describes the exactly the same problem. It has one reply, suggesting searching for a MinGW curses package.
  I found <a href="http://sourceforge.net/projects/mingwrep/files/?source=navbar" rel="nofollow">a repository of MinGW packages</a>, but there's no ncurses there. Also, they're really old - the newest was
  updated in 2003.</p>
  
  <p>If I change to the <code>src</code> directory and run <code>make</code> from there, the build process
  starts and completes witHout error. It produces a few executables (gvim.exe, vim.exe and a few more)
  and dumps them in <code>src</code>, but does not create a proper distribution.</p>
  
  <p>The targets for complete distributions are in the root Makefile, such as <code>dosbin_gvim</code>,
  but I'm getting errors when trying to build this target:</p>
  
  <pre><code>$ make dosbin_gvim
  rm -rf dist/gvim73.zip
  rm -rf dist/vim
  mkdir dist/vim
  mkdir dist/vim/vim73
  tar cf - \
          README_bindos.txt uninstal.txt  \
          | (cd dist/vim/vim73; tar xf -)
  find dist/vim/vim73 -type f -exec vim -e -X -u no_title.vim -c ":set tx|wq" {} \;
  cp gvim.exe dist/vim/vim73/gvim.exe
  cp: cannot stat `gvim.exe': No such file or directory
  make: *** [dosbin_gvim] Error 1
  </code></pre>
  
  <p>Using the exe's that are built with the stuff in the <code>runtime</code> folder, I could
  probably cobble up a distribution myself, but it would be hackish and fragile.
  I would much rather know what is causing these errors, and how to fix them.</p>