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

[mingw64] [ffmpeg] fribidi not found using pkg-config #1735

Closed dsent closed 4 years ago

dsent commented 4 years ago

I get this error on configure, but fribidi is installed, I can see it in /local64/bin-video, /local64/lib. There is an \local64\lib\pkgconfig\fribidi.pc file. Tried to remove it and rebuild with the same result.

ffmpeg_extra is for the issue #1725

┌ ffmpeg git  ............................................ [Updates found]
├ Until an upstream fix is issued, libaom must be disabled when compiling with libsvtav1....
├ Until an upstream fix is issued, libopencore-amrwb must be disabled when compiling with libsvtav1....
├ Changing options to comply to nonfree...
CUDA_PATH environment variable not set or directory does not exist.
├ Compiling static FFmpeg...
├ Running pre configure from ffmpeg_extra.sh...
├ Running configure...
Likely error (tail of the failed operation logfile):
CXXFLAGS: -mthreads -mtune=generic -O2 -pipe
LDFLAGS: -pipe -static-libgcc -static-libstdc++ -L/local64/lib -L/mingw64/lib
../configure --prefix=/local64 --bindir=/local64/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 --disable-debug --enable-fontconfig --enable-libass --enable-libbluray --enable-libfreetype --enable-libmfx --enable-libmysofa --enable-libopencore-amrnb --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-chromaprint --enable-decklink --enable-frei0r --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libfdk-aac --enable-libflite --enable-libfribidi --enable-libgme --enable-libgsm --enable-libilbc --enable-libsvthevc --enable-libsvtav1 --enable-libkvazaar --enable-libmodplug --enable-librtmp --enable-librubberband --enable-libtesseract --enable-libxavs --enable-libzmq --enable-libzvbi --enable-openal --enable-libvmaf --enable-libcodec2 --enable-libsrt --enable-ladspa --enable-librav1e --enable-libglslang --enable-vulkan --enable-opencl --enable-opengl --enable-libopenh264 --enable-openssl --extra-cflags=-fopenmp --extra-libs=-lgomp --extra-cflags=-DLIBTWOLAME_STATIC --extra-libs=-lstdc++ --extra-cflags=-DCACA_STATIC --extra-cflags=-DMODPLUG_STATIC --extra-cflags=-DCHROMAPRINT_NODLL --extra-libs=-lstdc++ --extra-cflags=-DZMQ_STATIC --extra-libs=-lpsapi --extra-cflags=-DLIBXML_STATIC --extra-libs=-liconv --disable-w32threads --extra-cflags=-DKVZ_STATIC_LIB --enable-nonfree --extra-version=g2c21955f52+3
ERROR: fribidi not found using pkg-config

logs.zip

dsent commented 4 years ago

Should I close the issue if I personally don't need the fribidi package? Recompiled with fribidi disabled, and it works for my workflow.

1480c1 commented 4 years ago

No, it's reproducible, and I can trace it to being an issue in fribidi's since although fribidi's pkg-config template https://github.com/fribidi/fribidi/blob/master/fribidi.pc.in#L13 contains -DFRIBIDI_LIB_STATIC, that line somehow gets removed when meson generates it, resulting in the broken compilation.

1480c1 commented 4 years ago

I have a guess that it's because meson's pkgconfig import doesn't have requires_private

1480c1 commented 4 years ago

nope, wrong field

1480c1 commented 4 years ago

seems that meson's pkgconfig doesn't have cflags.private, shame.

1480c1 commented 4 years ago

Closed in https://github.com/m-ab-s/media-autobuild_suite/commit/7cd247e3c8ad1a9792f941f6c7817116fbdf34ec