In the following I again rescued a helpful blog entry from markstoehr.com, which I think needs to be rescued for the future world:
HTK is an important speech recognition tool maintained and founded by the Cambridge University Engineering Department. Once one registers, downloads the code, and unpacks it, the standard recipe for compiling the source on Linux is
However, on a 64-bit architecture this will fail because of a bug on line 5507 of
configure we see that the generated Makefiles will set the call to the C compiler to have the
-m32 flag (line 3):
case "$host" in *x86_64*linux*) CFLAGS="-m64 -ansi -D_SVID_SOURCE -DOSS_AUDIO -D'ARCH=\"$host_cpu\"' $CFLAGS" LDFLAGS="-L/usr/X11R6/lib $LDFLAGS" ARCH=linux trad_bin_dir=linux ;;
-m32 flag is meant for an i386 system since it sets “int”, “long”, and pointer types to 32 bits. For x86-64 architectures we want the
-m64 flag so we need to change Line 3 above to
After making this change I was able to compile HTK without any further problems.
This note is for HTK version
3.4.1 and hopefully future versions will include this bug fix.