./configure error: cannot find input file: `tests/Makefile.in’

After cloning and bootstrap, while running ./configure I get a strange error message

./configure: line 17515: sw_vers: command not found
checking for xmlSAXUserParseFile in -lxml2... yes
checking libxml/parser.h usability... yes
checking libxml/parser.h presence... yes
checking for libxml/parser.h... yes
checking for __gmpz_add in -lgmp... yes
checking gmp.h usability... yes
checking gmp.h presence... yes
checking for gmp.h... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: error: cannot find input file: `tests/Makefile.in'

This then leads to a inability to actually compile, curious as to what I’ve missed here.

Edit: The full ./configure, though not sure it does any good to supply just this.

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking how to run the C++ preprocessor... g++ -E
checking for flex... flex
checking lex output file root... lex.yy
checking lex library... -lfl
checking whether yytext is a pointer... yes
checking for bison... bison -y
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking sys/times.h usability... yes
checking sys/times.h presence... yes
checking for sys/times.h... yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking for a sed that does not truncate output... /bin/sed
checking for fgrep... /bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... dlltool
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /bin/dd
checking how to truncate binary pipes... /bin/dd bs=4096 count=1
checking for mt... mt
checking if mt is a manifest tool... no
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking for shl_load... no
checking for shl_load in -ldld... no
checking for dlopen... no
checking for dlopen in -ldl... yes
checking whether a program can dlopen itself... yes
checking whether a statically linked program can dlopen itself... no
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking how to run the C++ preprocessor... g++ -E
checking for ld used by g++... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking for g++ option to produce PIC... -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works... yes
checking if g++ static flag -static works... yes
checking if g++ supports -c -o file.o... yes
checking if g++ supports -c -o file.o... (cached) yes
checking whether the g++ linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking for ANSI C header files... (cached) yes
checking stdarg.h usability... yes
checking stdarg.h presence... yes
checking for stdarg.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking time.h usability... yes
checking time.h presence... yes
checking for time.h... yes
checking for unistd.h... (cached) yes
checking for stdint.h... (cached) yes
checking sys/int_types.h usability... no
checking sys/int_types.h presence... no
checking for sys/int_types.h... no
checking for expm1... yes
checking for rint... yes
checking for rintf... yes
checking for finite... yes
checking for log2... yes
checking for snprintf... yes
checking for log1p... yes
checking for round... yes
checking for fabsl... yes
checking for fmin... yes
checking for strcasecmp... yes
checking for isnan... yes
checking for strdup... yes
checking for _strdup... no
checking for ftruncate... yes
checking for stpcpy... yes
checking whether isfinite is declared... yes
checking whether stpcpy is declared... yes
checking whether compiler supports -ffloat-store... yes
checking whether compiler supports -fstore... no
checking whether compiler accepts -Wall... yes
checking for xml2-config... /usr/bin/xml2-config
./configure: line 17515: sw_vers: command not found
checking for xmlSAXUserParseFile in -lxml2... yes
checking libxml/parser.h usability... yes
checking libxml/parser.h presence... yes
checking for libxml/parser.h... yes
checking for __gmpz_add in -lgmp... yes
checking gmp.h usability... yes
checking gmp.h presence... yes
checking for gmp.h... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: error: cannot find input file: `tests/Makefile.in'

Thank you for the report! Could you also provide the output of running the initial ./bootstrap.sh command?

What is your operating system (including its version)? Are you on macOS?

I think that the error message about sw_vers is unrelated and should not affect the outcome of the configure script. Basically, we try to detect the macOS version that the user is running in order to work around a bug in macOS 10.11. If sw_vers is not found, we simply move on. What is strange, though, is that we should not even attempt to call sw_vers if it is not found; this is from the configure script:

if test -f /usr/bin/sw_vers -a `sw_vers -productVersion | yadda yadda ...

./bootstrap.sh
Finding out version number/string… 0.9.0-pre+31be62d8

  • /usr/bin/libtoolize --force --copy
    libtoolize: putting auxiliary files in ‘.’.
    libtoolize: copying file ‘./ltmain.sh’
    libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, ‘m4’.
    libtoolize: copying file ‘m4/libtool.m4’
    libtoolize: copying file ‘m4/ltoptions.m4’
    libtoolize: copying file ‘m4/ltsugar.m4’
    libtoolize: copying file ‘m4/ltversion.m4’
    libtoolize: copying file ‘m4/lt~obsolete.m4’
  • aclocal -I m4 --install
  • autoheader
  • autoconf
  • automake --foreign --add-missing --force-missing --copy
    configure.ac:27: installing ‘./compile’
    configure.ac:4: installing ‘./missing’
    src/Makefile.am: installing ‘./depcomp’
  • patch -N -p0 -r-
  • true

Although oddly enough, running bootstrap again and configure seems to look less crappy and error-prone. Last lines:

checking gmp.h usability… yes
checking gmp.h presence… yes
checking for gmp.h… yes
checking that generated files are newer than configure… done
configure: creating ./config.status
config.status: creating tests/Makefile
config.status: creating tests/atlocal
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating igraph.pc
config.status: creating igraph_Info.plist
config.status: creating doc/Makefile
config.status: creating include/igraph_version.h
config.status: creating include/igraph_threading.h
config.status: creating config.h
config.status: executing tests/atconfig commands
config.status: executing depfiles commands
config.status: executing libtool commands
igraph successfully configured.
GraphML format support – yes
GMP library support – yes
GLPK library support – yes
Thread-local storage – no
Use internal ARPACK – yes
Use internal LAPACK – yes
Use internal BLAS – yes
Use internal F2C – yes
Use internal GLPK – yes
Debug build – no
Clang AddressSanitizer – no
Profiling – no
Link time optimization – no

Which seems somewhat more functional than before?

Are you on macOS or Linux?

Ubuntu in this case, apologies for the delay in getting back.