It’s kind of fun to put comments like this in your awk code:
// Do C++ comments work? answer: yes! of course
There are a number of other freely available
This section briefly describes where to get them:
Brian Kernighan, one of the original designers of Unix
has made his implementation of
awk freely available.
You can retrieve this version via
his home page.
It is available in several archive formats:
You can also retrieve it from GitHub:
git clone git://github.com/onetrueawk/awk bwkawk
This command creates a copy of the Git
repository in a directory named bwkawk. If you leave that argument
git command line, the repository copy is created in a
directory named awk.
This version requires an ISO C (1990 standard) compiler; the C compiler from GCC (the GNU Compiler Collection) works quite nicely.
See Common Extensions
for a list of extensions in this
awk that are not in POSIX
As a side note, Dan Bornstein has created a Git repository tracking
all the versions of BWK
awk that he could find. It’s
available at git://github.com/danfuzz/one-true-awk.
Michael Brennan wrote an independent implementation of
mawk. It is available under the
GPL (see Copying),
The original distribution site for the
mawk source code
no longer has it. A copy is available at
In 2009, Thomas Dickey took on
Basic information is available on
the project’s web page.
The download URL is
Once you have it,
gunzip may be used to decompress this file. Installation
is similar to
(see Unix Installation).
See Common Extensions
for a list of extensions in
mawk that are not in POSIX
Written by Andrew Sumner,
awk programs into C, compiles them,
and links them with a library of functions that provide the core
It also has a number of extensions.
awk translator is released under the GPL, and the library
is under the LGPL.
awka, go to http://sourceforge.net/projects/awka.
The project seems to be frozen; no new code changes have been made since approximately 2001.
Nelson H.F. Beebe at the University of Utah has modified
awk to provide timing and profiling information.
It is different from
gawk with the --profile option
in that it uses CPU-based profiling, not line-count
profiling. You may find it at either
BusyBox is a GPL-licensed program providing small versions of many
applications within a single executable. It is aimed at embedded systems.
It includes a full implementation of POSIX
awk. When building
it, be careful not to do ‘make install’ as it will overwrite
copies of other applications in your /usr/local/bin. For more
information, see the project’s home page.
The versions of
awk in /usr/xpg4/bin and
/usr/xpg6/bin on Solaris are more or less POSIX-compliant.
They are based on the
awk from Mortice Kern Systems for PCs.
We were able to make this code compile and work under GNU/Linux
with 1–2 hours of work. Making it more generally portable (using
GNU Autoconf and/or Automake) would take more work, and this
has not been done, at least to our knowledge.
The source code used to be available from the OpenSolaris website. However, that project was ended and the website shut down. Fortunately, the Illumos project makes this implementation available. You can view the files one at a time from https://github.com/joyent/illumos-joyent/blob/master/usr/src/cmd/awk_xpg4.
This is an interpreter for
awk written in Java. It claims
to be a full interpreter, although because it uses Java facilities
for I/O and for regexp matching, the language it supports is different
awk. More information is available on the
project’s home page.
This is an embeddable
awk interpreter derived from
mawk. For more information, see
This is a Python module that claims to bring
features to Python. See https://github.com/alecthomas/pawk
for more information. (This is not related to Nelson Beebe’s
modified version of BWK
awk, described earlier.)
This is an embeddable
awk interpreter. For more information,
see http://code.google.com/p/qse/ and http://awk.info/?tools/qse.
This is an independent implementation of
under the GPL. It has a large number of extensions over standard
awk and may not be 100% syntactically compatible with it.
See http://www.quiktrim.org/QTawk.html for more information,
including the manual. The download link there is out of date; see
http://www.quiktrim.org/#AdditionalResources for the latest
The project may also be frozen; no new code changes have been made since approximately 2014.
See also the “Versions and implementations” section of the
Wikipedia article on
awk for information on additional versions.