Origin: http://iverilog.wikia.com/wiki/Installation_using_MinGW
更新:编译git时出现找不到langinfo.h的错误。(http://comments.gmane.org/gmane.comp.gnu.mingw.user/16568)
使用msysgit替代:
$ cd /c/Pro*86*/git
$ cp bin/git* /mingw/bin
$ cp -r libexec/git* /mingw/libexec
$ cp -r share/git* /mingw//share
The following instructions assume you have none of the necessary build tools installed. If you have already installed MinGW and/or Git on your machine, you can of course skip the appropriate steps.
NOTE: Some steps are optional, depending on whether or not you also wish to build Git. Building Git allows you to execute Git commands in a MinGW shell, and allows the Icarus Verilog tools to report more detailed version information when called with the -V option.
Incidentally, besides MinGW, none of the packages installed in the following steps are needed after installation of Icarus Verilog is complete. They are only needed to build the compiler. The MinGW package can be used to compile VPI modules if you choose.
From the MinGW project, download and run the MinGW graphical installer (mingw-get-inst). Select the following components to be installed:
NOTE: If the download site is responding slowly, the installer may time out. If this happens it will skip the package it is currently trying to download and continue. If this happens, you can install the skipped packages later using the mingw-get command in a MinGW shell.
The default installation path is C:\MinGW, but you can change this to anything you like (but make sure there are no spaces in the path names). This path is referred to as <mingw>in subsequent instructions.
The installation will leave a "MinGW Shell" icon in the MinGW sub-menu of your Start menu. This icon brings up a shell window (a command line) that has paths all set up for executing MSYS and MinGW commands.
Start a MinGW shell. In the shell window, execute the following commands:
mingw-get install libz mingw-get install bzip2 mingw-get install pthreads-w32 mingw-get install msys-man
If you wish to build Git, execute the following commands as well:
mingw-get install libiconv mingw-get install msys-perl
The GnuWin32 project is a collection of open source programs and libraries ported to Windows. These also work well with the MinGW compiler, and Icarus Verilog uses a few pieces from this collection.
From the GnuWin project, download the following packages:
NOTE: You need the binaries and the developer files, but you do not need the source to these packages.
From the downloaded gperf-3.0.1-bin zip archive:
From the downloaded readline-5.0.1-bin zip archive:
where <mingw> is the location you chose to install MinGW.
NOTE: readline is only required to enable command line editing when in the vvp interactive mode.
NOTE: Skip this step if you only wish to build from snapshots.
From the msysgit project, download and install the Git for Windows binary package.
NOTE: When installing, you must select the option of "Checkout as-is, commit Unix-style line endings".
The installation will leave a "Git Shell" icon on the desktop and in the Git sub-menu of your Start menu. This icon brings up a shell window (a command line) that has paths all set up for executing Git commands.
NOTE: Skip this step if you don't want to build Git.
Start a Git shell. In the Git shell window, change directory to the location where you wish to store the source code and execute the following command:
git clone git://repo.or.cz/git/mingw.git git
This will create a directory "git" that contains all the source code for git.
The path to the directory containing the source code is referred to as <git-source>in subsequent instructions.
NOTE: Make sure there are no spaces in the <git-source> path names. Use forward slashes in place of back slashes when using <git-source> in a MinGW shell.
NOTE: Skip this step if you don't want to build Git.
In the MinGW shell window, execute the following commands:
cd <git-source> make NO_OPENSSL=YesPlease NO_TCLTK=YesPlease INSTALL=/bin/install prefix=/usr/local install
You can now uninstall the Git for Windows binary package if you wish, as Git commands can now be executed in the MinGW shell.