Cygwin (The GNU Awk User’s Guide)
B.3.1.4 Using gawk In The Cygwin Environment
gawk can be built and used “out of the box” under MS-Windows if you are using the Cygwin environment. This environment provides an excellent simulation of GNU/Linux, using Bash, GCC, GNU Make, and other GNU programs. Compilation and installation for Cygwin is the same as for a Unix system:
tar -xvpzf gawk-5.1.0.tar.gz cd gawk-5.1.0 ./configure make && make check
When compared to GNU/Linux on the same system, the ‘
configure’ step on Cygwin takes considerably longer. However, it does finish, and then the ‘
make’ proceeds as usual.
You may also install
gawk using the regular Cygwin installer. In general Cygwin supplies the latest released version.
Recent versions of Cygwin open all files in binary mode. This means that you should use ‘
RS = "\r?\n"’ in order to be able to handle standard MS-Windows text files with carriage-return plus line-feed line endings.
The Cygwin environment supports both the ‘
|&’ operator and TCP/IP networking (see section Using gawk for Network Programming).