Solve the error of compiling automake project in cygwin

Solve the error of compiling automake project in cygwin
Photo by Emmanuel Edward / Unsplash

Compiling open source project on cygwin platform, running configure script encounters the following error:

configure: error: cannot guess build type; you must specify one

Solution:

  1. Check the current automake version
$ automake --version
automake (GNU automake) 1.16.5

Show the current version is 1.16.5

  1. Enter /usr/share to find the automake directory with version 1.16.5
  2. Copy the config.guess and config.sub files in the automake directory to the source directory

cp /usr/share/automake-1.16/config.guess /src

cp /usr/share/automake-1.16/config.sub /src

  1. Enter the source directory and run config.guess to get the platform
$ ./config.guess
x86_64-pc-cygwin
  1. Run configure

./configure --build=x86_64-pc-cygwin

  1. Run make

Read more