PortAudio / portaudio

PortAudio is a cross-platform, open-source C language library for real-time audio input and output.
Other
1.47k stars 304 forks source link

mingw: configure fails because conftest.c doesn't exist #590

Open amoh-godwin opened 3 years ago

amoh-godwin commented 3 years ago

The entire log in config.log:

This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by configure, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure 

## --------- ##
## Platform. ##
## --------- ##

hostname = DESKTOP-FB12019
uname -m = i686
uname -r = 1.0.19(0.48/3/2)
uname -s = MINGW32_NT-6.2
uname -v = 2016-07-13 17:45

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /mingw/bin
PATH: /usr/bin
PATH: /c/Program Files/Android/Android Studio/jre/bin/spoiler
PATH: /c/WINDOWS/system32
PATH: /c/WINDOWS
PATH: /c/WINDOWS/System32/Wbem
PATH: /c/WINDOWS/System32/WindowsPowerShell/v1.0/
PATH: /c/Program Files (x86)/Common Files/Oracle/Java/javapath/spoiler
PATH: /c/Program Files/dotnet/
PATH: /c/Program Files/Microsoft SQL Server/130/Tools/Binn/
PATH: /c/Program Files/Microsoft SQL Server/Client SDK/ODBC/170/Tools/Binn/
PATH: /c/ProgramData/chocolatey/bin
PATH: /c/Program Files/Java/jdk1.8.0_231/bin
PATH: /c/Program Files/nodejs/
PATH: /c/WINDOWS/System32/OpenSSH/
PATH: /c/Program Files/Git/cmd
PATH: /c/xampp/php
PATH: /c/ProgramData/ComposerSetup/bin
PATH: /c/Program Files/erl-23.2.2/bin
PATH: /c/Program Files (x86)/Elixir/bin
PATH: /c/Users/Ampofo/.mix/escripts
PATH: /c/Program Files (x86)/SMLNJ/bin/
PATH: /c/Users/Ampofo/AppData/Local/Microsoft/WindowsApps
PATH: /c/Program Files/Android/Android Studio/gradle/gradle-5.1.1/bin
PATH: /c/Users/Ampofo/AppData/Roaming/npm
PATH: /c/Users/Ampofo/.deno/bin
PATH: /c/Qt/Qt5.13.0/5.13.0/mingw73_64/bin
PATH: /c/Users/Ampofo/AppData/Local/Programs/Microsoft VS Code/bin
PATH: /c/Users/Ampofo/anaconda3/Scripts
PATH: /c/Users/Ampofo/anaconda3
PATH: /c/Users/Ampofo/AppData/Local/GitHubDesktop/bin
PATH: /c/Users/Ampofo/AppData/Roaming/Composer/vendor/bin
PATH: /c/ProgramData/chocoportable/bin
PATH: /c/Users/Ampofo/anaconda3/Scripts
PATH: /mingw/bin
PATH: /mingw/libexec/gcc/mingw32/6.3.0
PATH: .

## ----------- ##
## Core tests. ##
## ----------- ##

configure:2583: checking build system type
configure:2597: result: i686-pc-mingw32
configure:2617: checking host system type
configure:2630: result: i686-pc-mingw32
configure:2650: checking target system type
configure:2663: result: i686-pc-mingw32
configure:2857: checking for gcc
configure:2884: result: C:\MinGW\bin\gcc.exe
configure:3113: checking for C compiler version
configure:3122: C:\MinGW\bin\gcc.exe --version >&5
gcc.exe (MinGW.org GCC-6.3.0-1) 6.3.0
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:3133: $? = 0
configure:3122: C:\MinGW\bin\gcc.exe -v >&5
Using built-in specs.
COLLECT_GCC=C:\MinGW\bin\gcc.exe
COLLECT_LTO_WRAPPER=c:/mingw/bin/../libexec/gcc/mingw32/6.3.0/lto-wrapper.exe
Target: mingw32
Configured with: ../src/gcc-6.3.0/configure --build=x86_64-pc-linux-gnu --host=mingw32 --target=mingw32 --with-gmp=/mingw --with-mpfr --with-mpc=/mingw --with-isl=/mingw --prefix=/mingw --disable-win32-registry --with-arch=i586 --with-tune=generic --enable-languages=c,c++,objc,obj-c++,fortran,ada --with-pkgversion='MinGW.org GCC-6.3.0-1' --enable-static --enable-shared --enable-threads --with-dwarf2 --disable-sjlj-exceptions --enable-version-specific-runtime-libs --with-libiconv-prefix=/mingw --with-libintl-prefix=/mingw --enable-libstdcxx-debug --enable-libgomp --disable-libvtv --enable-nls
Thread model: win32
gcc version 6.3.0 (MinGW.org GCC-6.3.0-1) 
configure:3133: $? = 0
configure:3122: C:\MinGW\bin\gcc.exe -V >&5
gcc.exe: error: unrecognized command line option '-V'
gcc.exe: fatal error: no input files
compilation terminated.
configure:3133: $? = 1
configure:3122: C:\MinGW\bin\gcc.exe -qversion >&5
gcc.exe: error: unrecognized command line option '-qversion'; did you mean '--version'?
gcc.exe: fatal error: no input files
compilation terminated.
configure:3133: $? = 1
configure:3153: checking whether the C compiler works
configure:3175: C:\MinGW\bin\gcc.exe    conftest.c  >&5
gcc.exe: error: CreateProcess: No such file or directory
configure:3179: $? = 1
configure:3217: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:3222: error: in `/h/CS/build/portaudio/portaudio':
configure:3224: error: C compiler cannot create executables
See `config.log' for more details

## ---------------- ##
## Cache variables. ##
## ---------------- ##

ac_cv_build=i686-pc-mingw32
ac_cv_env_CCC_set=
ac_cv_env_CCC_value=
ac_cv_env_CC_set=set
ac_cv_env_CC_value='C:\MinGW\bin\gcc.exe'
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_CXXCPP_set=
ac_cv_env_CXXCPP_value=
ac_cv_env_CXXFLAGS_set=
ac_cv_env_CXXFLAGS_value=
ac_cv_env_CXX_set=
ac_cv_env_CXX_value=
ac_cv_env_JACK_CFLAGS_set=
ac_cv_env_JACK_CFLAGS_value=
ac_cv_env_JACK_LIBS_set=
ac_cv_env_JACK_LIBS_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_LIBS_set=
ac_cv_env_LIBS_value=
ac_cv_env_PKG_CONFIG_LIBDIR_set=
ac_cv_env_PKG_CONFIG_LIBDIR_value=
ac_cv_env_PKG_CONFIG_PATH_set=
ac_cv_env_PKG_CONFIG_PATH_value=
ac_cv_env_PKG_CONFIG_set=
ac_cv_env_PKG_CONFIG_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_host=i686-pc-mingw32
ac_cv_prog_ac_ct_CC='C:\MinGW\bin\gcc.exe'
ac_cv_target=i686-pc-mingw32

## ----------------- ##
## Output variables. ##
## ----------------- ##

AR=''
AS=''
AWK=''
CC='C:\MinGW\bin\gcc.exe'
CFLAGS=''
CPP=''
CPPFLAGS=''
CXX=''
CXXCPP=''
CXXFLAGS=''
DEFS=''
DLLTOOL=''
DLL_LIBS=''
DSYMUTIL=''
DUMPBIN=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
ENABLE_CXX_FALSE=''
ENABLE_CXX_TRUE=''
EXEEXT=''
FGREP=''
GREP=''
INCLUDES=''
INSTALL_DATA=''
INSTALL_PROGRAM=''
INSTALL_SCRIPT=''
JACK_CFLAGS=''
JACK_LIBS=''
LD=''
LDFLAGS=''
LIBOBJS=''
LIBS=''
LIBTOOL=''
LIPO=''
LN_S=''
LTLIBOBJS=''
LT_AGE=''
LT_CURRENT=''
LT_REVISION=''
MANIFEST_TOOL=''
NASM=''
NASMOPT=''
NM=''
NMEDIT=''
OBJDUMP=''
OBJEXT=''
OTHER_OBJS=''
OTOOL64=''
OTOOL=''
PACKAGE_BUGREPORT=''
PACKAGE_NAME=''
PACKAGE_STRING=''
PACKAGE_TARNAME=''
PACKAGE_URL=''
PACKAGE_VERSION=''
PADLL=''
PATH_SEPARATOR=':'
PKG_CONFIG=''
PKG_CONFIG_LIBDIR=''
PKG_CONFIG_PATH=''
RANLIB=''
SED=''
SHARED_FLAGS=''
SHELL='/bin/sh'
STRIP=''
THREAD_CFLAGS=''
WITH_ASIO_FALSE=''
WITH_ASIO_TRUE=''
ac_ct_AR=''
ac_ct_CC='C:\MinGW\bin\gcc.exe'
ac_ct_CXX=''
ac_ct_DUMPBIN=''
bindir='${exec_prefix}/bin'
build='i686-pc-mingw32'
build_alias=''
build_cpu='i686'
build_os='mingw32'
build_vendor='pc'
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE}'
dvidir='${docdir}'
exec_prefix='NONE'
host='i686-pc-mingw32'
host_alias=''
host_cpu='i686'
host_os='mingw32'
host_vendor='pc'
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='NONE'
program_transform_name='s,x,x,'
psdir='${docdir}'
runstatedir='${localstatedir}/run'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
subdirs=''
sysconfdir='${prefix}/etc'
target='i686-pc-mingw32'
target_alias=''
target_cpu='i686'
target_os='mingw32'
target_vendor='pc'

## ----------- ##
## confdefs.h. ##
## ----------- ##

/* confdefs.h */
#define PACKAGE_NAME ""
#define PACKAGE_TARNAME ""
#define PACKAGE_VERSION ""
#define PACKAGE_STRING ""
#define PACKAGE_BUGREPORT ""
#define PACKAGE_URL ""

configure: exit 77

I checked to see if conftest.c exists, it didn't. So I decided to create one with the code that is above, copied and pasted it and removed the '|'. When I run bash-3.1$ ./configure it deleted the conftest.c and still printed the same error. Also notice the multiple spaces between C:\MinGW\bin\gcc.exe and conftest.c C:\MinGW\bin\gcc.exe conftest.c

Desktop:

RossBencina commented 3 years ago

The configure script should generate the test .c file from the script. It is not missing.

RossBencina commented 3 years ago

C:\MinGW\bin\gcc.exe conftest.c

Ok, but is gcc.exe in your PATH? you need to be able to run gcc.exe without any path qualifer. That's what I think the error is saying: it can't find your compiler. Check config.log for details.

amoh-godwin commented 3 years ago

@RossBencina I did I've added it. You can run gcc at the prompt at both the native cmd and also at the bash prompt. But I get the same error, the same error log.

RossBencina commented 3 years ago

I think this is the problem line:

gcc.exe: error: CreateProcess: No such file or directory

Possibly this fix? https://stackoverflow.com/a/6085411/2013747

amoh-godwin commented 3 years ago

Same error. gcc is the one reporting the error. Check the log, third line from the one I posted. The conftest.c is just not there

npostavs commented 3 years ago

If conftest.c was missing, you would get an error like this:

$ gcc conftest.c
gcc.exe: error: conftest.c: No such file or directory
gcc.exe: fatal error: no input files

The CreateProcess failure suggests some exe is missing.

amoh-godwin commented 3 years ago

configure:3175: C:\MinGW\bin\gcc.exe conftest.c >&5 gcc.exe: error: CreateProcess: No such file or directory

@npostavs well that is the exact same error.

npostavs commented 3 years ago

@amoh-godwin no, one mentions conftest.c by name, where the other just has CreateProcess.

amoh-godwin commented 3 years ago

@npostavs oh okay

RossBencina commented 3 years ago

The CreateProcess failure suggests some exe is missing.

Or a dll that it links to.

philburk commented 3 years ago

@amoh-godwin - Can you clarify what "fails" means. Perhaps MinGW is not installed correctly?

Does ./configure correctly determine that MinGW is broken? Or does ./configure crash and not create a Makefile?

amoh-godwin commented 3 years ago

@philburk I have updated my first comment to include the entire log.

RossBencina commented 2 years ago

We'd be interested to hear whether anyone else is having this issue.