microsoft / vcpkg

C++ Library Manager for Windows, Linux, and MacOS
MIT License
23.36k stars 6.45k forks source link

[ffmpeg] Build error on arm64-linux #38092

Open pplxlee opened 7 months ago

pplxlee commented 7 months ago

Operating system

Ubuntu 22.04.4 LTS

Compiler

GCC

Steps to reproduce the behavior

`./vcpkg install ffmpeg[x264]:arm64-linux`

Failure logs

install log

Computing installation plan...
The following packages will be built and installed:
    ffmpeg[avcodec,avdevice,avfilter,avformat,core,gpl,swresample,swscale,x264]:arm64-linux@6.1.1#2
Detecting compiler hash for triplet arm64-linux...
Compiler found: /usr/bin/aarch64-linux-gnu-g++
Restored 0 package(s) from /home/lxl/.cache/vcpkg/archives in 7.99 us. Use --debug to see more details.
Installing 1/1 ffmpeg[avcodec,avdevice,avfilter,avformat,core,gpl,swresample,swscale,x264]:arm64-linux@6.1.1#2...
Building ffmpeg[avcodec,avdevice,avfilter,avformat,core,gpl,swresample,swscale,x264]:arm64-linux@6.1.1#2...
/home/lxl/vcpkg_new/vcpkg/triplets/community/arm64-linux.cmake: info: loaded community triplet from here. Community triplets are not built in the curated registry and are thus less likely to succeed.
-- Using cached ffmpeg-ffmpeg-n6.1.1.tar.gz.
-- Cleaning sources at /home/lxl/vcpkg_new/vcpkg/buildtrees/ffmpeg/src/n6.1.1-bf510528a2.clean. Use --editable to skip cleaning for the packages you specify.
-- Extracting source /home/lxl/vcpkg_new/vcpkg/downloads/ffmpeg-ffmpeg-n6.1.1.tar.gz
-- Applying patch 0001-create-lib-libraries.patch
-- Applying patch 0002-fix-msvc-link.patch
-- Applying patch 0003-fix-windowsinclude.patch
-- Applying patch 0004-fix-debug-build.patch
-- Applying patch 0005-fix-nasm.patch
-- Applying patch 0006-fix-StaticFeatures.patch
-- Applying patch 0007-fix-lib-naming.patch
-- Applying patch 0009-Fix-fdk-detection.patch
-- Applying patch 0011-Fix-x265-detection.patch
-- Applying patch 0012-Fix-ssl-110-detection.patch
-- Applying patch 0013-define-WINVER.patch
-- Applying patch 0015-Fix-xml2-detection.patch
-- Applying patch 0020-fix-aarch64-libswscale.patch
-- Applying patch 0022-fix-iconv.patch
-- Using source at /home/lxl/vcpkg_new/vcpkg/buildtrees/ffmpeg/src/n6.1.1-bf510528a2.clean
-- Getting CMake variables for arm64-linux
-- Building Options: --enable-pic --disable-doc --enable-debug --enable-runtime-cpudetect --disable-autodetect --target-os=linux --enable-pthreads --cc=aarch64-linux-gnu-gcc --cxx=aarch64-linux-gnu-g++ --nm=aarch64-linux-gnu-nm --ar='aarch64-linux-gnu-ar' --ranlib=aarch64-linux-gnu-ranlib --enable-gpl --disable-ffmpeg --disable-ffplay --disable-ffprobe --enable-avcodec --enable-avdevice --enable-avformat --enable-avfilter --disable-postproc --enable-swresample --enable-swscale --disable-alsa --disable-amf --disable-libaom --disable-libass --disable-avisynth --disable-bzlib --disable-libdav1d --disable-libfdk-aac --disable-libfontconfig --disable-libfreetype --disable-libfribidi --disable-iconv --disable-libilbc --disable-lzma --disable-libmp3lame --disable-libmodplug --disable-cuda --disable-nvenc --disable-nvdec  --disable-cuvid --disable-ffnvcodec --disable-opencl --disable-opengl --disable-libopenh264 --disable-libopenjpeg --disable-libopenmpt --disable-openssl --disable-libopus --disable-sdl2 --disable-libsnappy --disable-libsoxr --disable-libspeex --disable-libssh --disable-libtensorflow --disable-libtesseract --disable-libtheora --disable-libvorbis --disable-libvpx --disable-libwebp --enable-libx264 --disable-libx265 --disable-libxml2 --disable-zlib --disable-libsrt --disable-libmfx --enable-cross-compile --cross-prefix=aarch64-linux-gnu- --pkg-config-flags=--static
-- Building Release Options: --enable-optimizations --extra-ldflags=-L"/home/lxl/vcpkg_new/vcpkg/installed/arm64-linux/lib"
-- Building ffmpeg for Release
CMake Error at scripts/cmake/vcpkg_execute_required_process.cmake:112 (message):
    Command failed: /usr/bin/bash ./build.sh
    Working Directory: /home/lxl/vcpkg_new/vcpkg/buildtrees/ffmpeg/arm64-linux-rel
    Error code: 1
    See logs for more information:
      /home/lxl/vcpkg_new/vcpkg/buildtrees/ffmpeg/build-arm64-linux-rel-config.log
      /home/lxl/vcpkg_new/vcpkg/buildtrees/ffmpeg/build-arm64-linux-rel-out.log

Call Stack (most recent call first):
  ports/ffmpeg/portfile.cmake:600 (vcpkg_execute_required_process)
  scripts/ports.cmake:175 (include)

error: building ffmpeg:arm64-linux failed with: BUILD_FAILED
Elapsed time to handle ffmpeg:arm64-linux: 11 s
Please ensure you're using the latest port files with `git pull` and `vcpkg update`.
Then check for known issues at:
  https://github.com/microsoft/vcpkg/issues?q=is%3Aissue+is%3Aopen+in%3Atitle+ffmpeg
You can submit a new issue at:
  https://github.com/microsoft/vcpkg/issues/new?title=[ffmpeg]+Build+error+on+arm64-linux&body=Copy+issue+body+from+%2Fhome%2Flxl%2Fvcpkg_new%2Fvcpkg%2Finstalled%2Fvcpkg%2Fissue_body.md

build-arm64-linux-rel-out.log

BUILD_ARCH=arm64
OPTION_VARIABLE=OPTIONS_arm64
=== CONFIGURING ===
ERROR: x264 not found using pkg-config

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.libera.chat.
Include the log file "ffbuild/config.log" produced by configure as this will help
solve the problem.

build-arm64-linux-rel-config.log

Additional context

No response

dg0yt commented 4 months ago

Please test if this issue still exists, after #39460.