m-ab-s / media-autobuild_suite

This Windows Batchscript helps setup a Mingw-w64 compiler environment for building ffmpeg and other media tools under Windows.
GNU General Public License v3.0
1.53k stars 263 forks source link

ffmpeg configure: libmfx not found #1684

Closed LigH-de closed 4 years ago

LigH-de commented 4 years ago

I forced a re-download and re-building of both libmfx and ffmpeg, did not help.

local32/lib/libmfx.[l]a and package info do exist.

ab-suite.configure.log

CPPFLAGS: -D_FORTIFY_SOURCE=0 -D__USE_MINGW_ANSI_STDIO=1
CFLAGS: -mthreads -mtune=generic -O2 -pipe
CXXFLAGS: -mthreads -mtune=generic -O2 -pipe
LDFLAGS: -pipe -static-libgcc -static-libstdc++ -L/local32/lib -L/mingw32/lib
../configure --prefix=/local32 --bindir=/local32/bin-video --pkg-config-flags=--static --cc=ccache gcc --cxx=ccache g++ --disable-autodetect --enable-amf --enable-bzlib --enable-cuda --enable-cuvid --enable-d3d11va --enable-dxva2 --enable-iconv --enable-lzma --enable-nvenc --enable-zlib --enable-sdl2 --enable-ffnvcodec --enable-nvdec --enable-cuda-llvm --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libdav1d --enable-libaom --disable-debug --enable-fontconfig --enable-libass --enable-libbluray --enable-libfreetype --enable-libmfx --enable-libmysofa --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libwavpack --enable-libwebp --enable-libxml2 --enable-libzimg --enable-libshine --enable-gpl --enable-avisynth --enable-libxvid --enable-libopenmpt --enable-version3 --enable-mbedtls --extra-cflags=-DLIBTWOLAME_STATIC --extra-libs=-lstdc++ --extra-cflags=-DLIBXML_STATIC --extra-libs=-liconv --extra-version=gc0f01eaf12+1
ERROR: libmfx not found

If you think configure made a mistake, make sure you are using the latest
version from Git.  If the latest version fails, report the problem to the
ffmpeg-user@ffmpeg.org mailing list or IRC #ffmpeg on irc.freenode.net.
Include the log file "ffbuild/config.log" produced by configure as this will help
solve the problem.

logs.zip

wiiaboo commented 4 years ago
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/stdio/mingw_pformat.c:797: undefined reference to `__umoddi3'
E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-mbrtowc.o): in function `_mbrtowc_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:60: undefined reference to `_imp__IsDBCSLeadByteEx@8'
E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-wcrtomb.o): in function `_wcrtomb_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/wcrtomb.c:35: undefined reference to `_imp__WideCharToMultiByte@32'
E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: E:/MABS/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-lc_locale_func.o): in function `_mingw_get_msvcrt_handle':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/include/msvcrt.h:9: undefined reference to `_imp__GetModuleHandleW@4'

Same kind of issue in #1685:

C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/lib/../lib/libmsvcrt.a(lib64_libmsvcrt_os_a-mbrtowc.o): in function `__mbrtowc_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:60: undefined reference to `__imp_IsDBCSLeadByteEx'
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:60:(.text+0x5c): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `__imp_IsDBCSLeadByteEx'
C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:50: undefined reference to `__imp_MultiByteToWideChar'
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:50:(.text+0x9c): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `__imp_MultiByteToWideChar'
C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:85: undefined reference to `__imp_MultiByteToWideChar'
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:85:(.text+0x134): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `__imp_MultiByteToWideChar'
C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: C:/MinGW64/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.1.0/../../../../x86_64-w64-mingw32/lib/../lib/libmsvcrt.a(lib64_libmsvcrt_os_a-wcrtomb.o): in function `__wcrtomb_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/wcrtomb.c:35: undefined reference to `__imp_WideCharToMultiByte'
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/wcrtomb.c:35:(.text+0x64): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `__imp_WideCharToMultiByte'
pat357 commented 4 years ago

I get similar errors when building ffmpeg: chromaprint not found After disabling chromaprint in ffmpeg_options and running the suite again, I get: gme not found Again, after disabling gme in ffmpeg_options and running the suite again, I get: libilbc not found:

full logs at https://0x0.st/ifjl.zip

ffmpeg config.log:


require libilbc ilbc.h WebRtcIlbcfix_InitDecode -lilbc
check_lib libilbc ilbc.h WebRtcIlbcfix_InitDecode -lilbc
check_func_headers ilbc.h WebRtcIlbcfix_InitDecode -lilbc
test_ld cc -lilbc
test_cc
BEGIN /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.c
    1   #include <ilbc.h>
    2   #include <stdint.h>
    3   long check_WebRtcIlbcfix_InitDecode(void) { return (long) WebRtcIlbcfix_InitDecode; }
    4   int main(void) { int ret = 0;
    5    ret |= ((intptr_t)check_WebRtcIlbcfix_InitDecode) & 0xFFFF;
    6   return ret; }
END /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.c
ccache gcc -D_FORTIFY_SOURCE=0 -D__USE_MINGW_ANSI_STDIO=1 -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -U__STRICT_ANSI__ -D__USE_MINGW_ANSI_STDIO=1 -D__printf__=__gnu_printf__ -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -mthreads -mtune=generic -O2 -pipe -DLIBTWOLAME_STATIC -DCACA_STATIC -DMODPLUG_STATIC -DLIBXML_STATIC -std=c11 -fomit-frame-pointer -DLIBXML_STATIC -IH:/Mingw645/local32/include/harfbuzz -IH:/Mingw645/local32/include/libxml2 -IH:/Mingw645/local32/include/fribidi -IH:/Mingw645/local32/include/freetype2 -DLIBXML_STATIC -IH:/Mingw645/local32/include/libxml2 -IH:/Mingw645/local32/include/bs2b -DLIBXML_STATIC -IH:/Mingw645/local32/include/libxml2 -IH:/Mingw645/local32/include/freetype2 -IH:/Mingw645/local32/include/freetype2 -IH:/Mingw645/local32/include/fribidi -c -o /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.o /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.c
ccache gcc -pipe -static-libgcc -static-libstdc++ -L/local32/lib -L/mingw32/lib -Wl,--large-address-aware -Wl,--nxcompat,--dynamicbase -Wl,--as-needed -Wl,--pic-executable,-e,_mainCRTStartup -o /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.exe /c/Users/Public/Documents/Wondershare/CreatorTemp/ffconf.tPKQWNst/test.o -lilbc -lpsapi -lstdc++
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmingwex.a(lib32_libmingwex_a-mingw_pformat.o): in function `_pformat_int':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/stdio/mingw_pformat.c:797: undefined reference to `__umoddi3'
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-mbrtowc.o): in function `_mbrtowc_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:60: undefined reference to `_imp__IsDBCSLeadByteEx@8'
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:50: undefined reference to `_imp__MultiByteToWideChar@24'
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/mbrtowc.c:85: undefined reference to `_imp__MultiByteToWideChar@24'
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-wcrtomb.o): in function `_wcrtomb_cp':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/misc/wcrtomb.c:35: undefined reference to `_imp__WideCharToMultiByte@32'
H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/bin/ld.exe: H:/Mingw645/msys64/mingw32/bin/../lib/gcc/i686-w64-mingw32/10.1.0/../../../../i686-w64-mingw32/lib/../lib/libmsvcrt.a(lib32_libmsvcrt_os_a-lc_locale_func.o): in function `_mingw_get_msvcrt_handle':
D:/mingwbuild/mingw-w64-crt-git/src/mingw-w64/mingw-w64-crt/include/msvcrt.h:9: undefined reference to `_imp__GetModuleHandleW@4'
collect2.exe: error: ld returned 1 exit status
ERROR: libilbc not found
1480c1 commented 4 years ago

https://github.com/msys2/MINGW-packages/issues/6530

pat357 commented 4 years ago

Have some good news ! After the update I just got for GCC, winpthreads and some other, the issue seems to be solved. After re-enabling the above mentioned libs in ffmpegoptions{32,64}bit, I got no longer complains about missing libs during ffmpeg configure.

Edit: I use different options for ffmpeg 32bit and for 64bit : ffmpegoptions{32,64}bit, When the logs are uploaded after something fails, the log only contains ffmpeg_options.txt IIRC, while the latter is ignored by the suite if ffmpegoptions{32,64}bit are present. I think to have the correct settings in case of an issue, the log.zip should also include ffmpegoptions{32,64}bit if present.

pat357 commented 4 years ago

@LigH-de : do you still have problems with ffmpeg configure complaining about missing options/libs ?

LigH-de commented 4 years ago

I paused my tests because I have an MSYS2 update problem (pacman 5.2.1-9 vs. depencency 'pacman-contrib'), and there is so much German in the error messages that I hoped you could tell me a solution to turn all the output to English easily... #1692

OK, so I will try again. But at the moment, updates have low bandwidth at this daytime in this area. Will report tomorrow.

LigH-de commented 4 years ago

OK, suite finished.