emerge of media-gfx/blender-3.4.1-r3 fails during compilation with: FAILED: source/blender/imbuf/CMakeFiles/bf_imbuf.dir/intern/anim_movie.c.o /usr/bin/x86_64-pc-linux-gnu-gcc -DNDEBUG -DWITH_AVI -DWITH_CINEON -DWITH_DDS -DWITH_FFMPEG -DWITH_HDR -DWITH_OPENEXR -DWITH_OPENGL -DWITH_OPENIMAGEIO -DWITH_OPENJPEG -DWITH_TIFF -DWITH_WEBP -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D__LITTLE_ENDIAN__ -D__MMX__ -D__SSE2__ -D__SSE__ -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/imbuf -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/blenkernel -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/blenlib -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/blenloader -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/gpu -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/makesdna -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/makesrna -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/sequencer -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/intern/guardedalloc -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/intern/memutil -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/io/avi -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/intern/ffmpeg -I/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/intern/opencolorio -isystem /usr/include/openjpeg-2.5 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -Wall -Werror=implicit-function-declaration -Werror=return-type -Werror=vla -Wstrict-prototypes -Wmissing-prototypes -Wno-char-subscripts -Wno-unknown-pragmas -Wpointer-arith -Wunused-parameter -Wwrite-strings -Wlogical-op -Wundef -Winit-self -Wmissing-include-dirs -Wno-div-by-zero -Wtype-limits -Wformat-signedness -Wrestrict -Wnonnull -Wabsolute-value -Wuninitialized -Wredundant-decls -Wshadow -Wno-error=unused-but-set-variable -Wimplicit-fallthrough=5 -march=native -mtune=native -Os -fomit-frame-pointer -pipe -fstack-protector-strong -DNDEBUG -fopenmp -std=gnu11 -msse -pipe -fPIC -funsigned-char -fno-strict-aliasing -ffp-contract=off -msse2 -fmacro-prefix-map="/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/"="" -fmacro-prefix-map="/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1_build/"="" -Wno-maybe-uninitialized -MD -MT source/blender/imbuf/CMakeFiles/bf_imbuf.dir/intern/anim_movie.c.o -MF source/blender/imbuf/CMakeFiles/bf_imbuf.dir/intern/anim_movie.c.o.d -o source/blender/imbuf/CMakeFiles/bf_imbuf.dir/intern/anim_movie.c.o -c /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/imbuf/intern/anim_movie.c /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/imbuf/intern/anim_movie.c: In function ‘startffmpeg’: /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/imbuf/intern/anim_movie.c:557:30: error: ‘AV_CODEC_CAP_AUTO_THREADS’ undeclared (first use in this function); did you mean ‘AV_CODEC_CAP_SLICE_THREADS’? 557 | if (pCodec->capabilities & AV_CODEC_CAP_AUTO_THREADS) { | ^~~~~~~~~~~~~~~~~~~~~~~~~ | AV_CODEC_CAP_SLICE_THREADS /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1/source/blender/imbuf/intern/anim_movie.c:557:30: note: each undeclared identifier is reported only once for each function it appears in ninja: build stopped: subcommand failed. * ERROR: media-gfx/blender-3.4.1-r3::gentoo failed (compile phase): * ninja -v -j7 -l0 failed * * Call stack: * ebuild.sh, line 136: Called src_compile * environment, line 3573: Called cmake_src_compile * environment, line 1716: Called cmake_build * environment, line 1682: Called eninja * environment, line 2144: Called die * The specific snippet of code: * "$@" || die -n "${*} failed" The ebuild environment file is attached. This on an AMD x86_64 system. Let me know if any further details needed. Best regards, Martin Reproducible: Always Steps to Reproduce: 1. emerge -vDNUu media-gfx/blender 2. ninja attempts to compile media-gfx/blender-3.4.1-r3 3. emerge expected to complete Actual Results: emerge fails with the above ninja error message of an undeclared name in anim_movie.c Expected Results: emerge/ninja expected to complete the compile and install emerge --info: Portage 3.0.49 (python 3.11.4-final-0, default/linux/amd64/17.1/desktop, gcc-12, glibc-2.37-r3, 6.4.7-gentoo_BA x86_64) ================================================================= System uname: Linux-6.4.7-gentoo_BA-x86_64-AMD_Phenom-tm-_II_X6_1090T_Processor-with-glibc2.37 KiB Mem: 8151196 total, 421388 free KiB Swap: 100662260 total, 95875648 free Timestamp of repository gentoo: Tue, 01 Aug 2023 12:30:01 +0000 Head commit of repository gentoo: ea879e1064c10494339aa0a526f836c06d479596 sh bash 5.1_p16-r6 ld GNU ld (Gentoo 2.39 p6) 2.39.0 app-misc/pax-utils: 1.3.5::gentoo app-shells/bash: 5.1_p16-r6::gentoo dev-lang/perl: 5.36.1-r3::gentoo dev-lang/python: 3.10.12::gentoo, 3.11.4::gentoo dev-lang/rust: 1.69.0-r1::gentoo dev-util/cmake: 3.26.4-r1::gentoo dev-util/meson: 1.1.1::gentoo sys-apps/baselayout: 2.13-r1::gentoo sys-apps/openrc: 0.47.1::gentoo sys-apps/sandbox: 2.37::gentoo sys-devel/autoconf: 2.13-r7::gentoo, 2.71-r6::gentoo sys-devel/automake: 1.16.5-r1::gentoo sys-devel/binutils: 2.39-r5::gentoo, 2.40-r5::gentoo sys-devel/binutils-config: 5.5::gentoo sys-devel/clang: 15.0.7-r3::gentoo, 16.0.6::gentoo sys-devel/gcc: 12.3.1_p20230526::gentoo sys-devel/gcc-config: 2.11::gentoo sys-devel/libtool: 2.4.7-r1::gentoo sys-devel/lld: 15.0.7::gentoo, 16.0.6::gentoo sys-devel/llvm: 15.0.7-r3::gentoo, 16.0.6::gentoo sys-devel/make: 4.4.1-r1::gentoo sys-kernel/linux-headers: 6.1::gentoo (virtual/os-headers) sys-libs/glibc: 2.37-r3::gentoo Repositories: gentoo location: /usr/portage sync-type: rsync sync-uri: rsync://rsync.gentoo.org/gentoo-portage priority: -1000 volatile: True sync-rsync-verify-jobs: 1 sync-rsync-verify-max-age: 24 sync-rsync-extra-opts: sync-rsync-verify-metamanifest: yes edgets location: /var/lib/layman/edgets masters: gentoo priority: 50 volatile: True rocm location: /var/lib/layman/rocm masters: gentoo priority: 50 volatile: True ACCEPT_KEYWORDS="amd64" ACCEPT_LICENSE="@FREE" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=native -mtune=native -Os -fomit-frame-pointer -pipe -fstack-protector-strong" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/sddm/scripts/Xsetup /usr/share/themes/oxygen-gtk/gtk-2.0" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c" CXXFLAGS="-march=native -mtune=native -Os -fomit-frame-pointer -pipe -fstack-protector-strong" DISTDIR="/usr/portage/distfiles" ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="rsync://rsync.mirrorservice.org/distfiles.gentoo.org/ rsync://ftp.snt.utwente.nl/gentoo rsync://mirror.leaseweb.com/gentoo/ rsync://ftp.fau.de/gentoo" LANG="en_GB.utf8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" LEX="flex" LINGUAS="en_GB en" MAKEOPTS="-j7" PKGDIR="/usr/portage/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git" PORTAGE_TMPDIR="/var/tmp" SHELL="/bin/bash" USE="X a52 aac acpi alsa alsa-plugin amd64 branding brotli bzip2 cairo caps cdda cdr cli compiler-rt crypt cups dav1d dbus dri dts dvd dvdr elogind encode exif faad fam ffmpeg fftw flac gallium gdbm gfx803 gif gimp gmp gpm gtk gui hddtemp http2 iconv icu imagemagick introspection ipv6 jemalloc jpeg jpeg2k jpegxl lcms leaps_timezone libnotify libplacebo libsamplerate libtirpc lm-sensors lm_sensors mad mesa mng mp3 mp4 mpd mpeg mtp multilib ncurses nls nptl nsplugin ntp ogg opengl openmp opus osmesa pam pango parcheck pcre pdf pie plotutils png policykit ppapi ppds pulseaudio qml qt5 rar readline sddm sdl seccomp sensord sensors sound spell split-usr ssl startup-notification svg test-rust theora threads tiff truetype udev udisks unicode upower usb uuid vaapi vala vdpau vim-syntax vorbis vpx vulkan wavpack webkit webp webrtc-aec wxwidgets x264 xa xattr xcb xft xml xscreensaver xv xvid xvmc zink zlib" ABI_X86="64" ADA_TARGET="gnat_2021" ALSA_CARDS="emu10k1x ice1712" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="3dnow 3dnowext mmx mmxext popcnt sse sse2 sse3 sse4a" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" GRUB_PLATFORMS="pc" INPUT_DEVICES="libinput wacom" KERNEL="linux" L10N="en-GB en" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LLVM_TARGETS="AMDGPU BPF WebAssembly X86" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11" RUBY_TARGETS="ruby31" SANE_BACKENDS="agfafocus net snapscan" VIDEO_CARDS="amdgpu vesa" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Created attachment 866817 [details] ebuild environment '/var/tmp/portage/media-gfx/blender-3.4.1-r3/temp/environment'
This looks ffmpeg related to me. What version of media-video/ffmpeg have you got installed?
Adding a ~amd64 to the packages accept for blender-3.6.0 and compiling again gave success: >>> media-gfx/blender-3.6.0 merged. The only other change made was to add "-openpgl" to the blender flags to avoid for my old CPU: !!! The ebuild selected to satisfy "media-libs/openpgl" has unmet requirements. - media-libs/openpgl-0.5.0::gentoo USE="-debug" ABI_X86="(64)" CPU_FLAGS_X86="-avx2 -avx512dq -sse4_2" The following REQUIRED_USE flag constraints are unsatisfied: any-of ( cpu_flags_arm_neon cpu_flags_x86_sse4_2 cpu_flags_x86_avx2 cpu_flags_x86_avx512dq ) (dependency required by "media-gfx/blender-3.6.0::gentoo[openpgl]" [ebuild]) fyi on this system: media-video/ffmpeg-6.0-r5 And the successful emerge was for: [ebuild NS ~] media-gfx/blender-3.6.0:3.6::gentoo [3.3.8:3.3::gentoo] USE="X%* alembic bullet color-management cycles dds embree ffmpeg fftw fluid gmp jemalloc jpeg2k man nanovdb nls oidn openexr openmp opensubdiv openvdb pdf potrace pugixml pulseaudio sdl sndfile tbb tiff -collada -cuda -cycles-bin-kernels% -debug -doc -jack -ndof -openal -openpgl% -optix -osl -test -valgrind -wayland% (-headless%) (-openimageio%*)" PYTHON_SINGLE_TARGET="python3_11 -python3_10" 68,779 KiB Sorry for the noise. Thanks, Martin
please attach the full build.log as described on https://wiki.gentoo.org/wiki/Attach_the_logs_to_the_bug_ticket
Created attachment 866849 [details, diff] Patch from arch linux Arch and Fedora were carrying this patch for ffmpeg-6 up until version 3.5.0 of blender. https://gitlab.archlinux.org/archlinux/packaging/packages/blender/-/blob/995d0d699fca76ea03dc50588bee5018ce3add6d/blender-ffmpeg6.patch https://src.fedoraproject.org/rpms/blender/blob/1731e01768a738fdc2c48652f249a1222d50402a/f/blender-3.4.1-ffmpeg6.patch
Created attachment 866850 [details] blender-3.4.1-r3 build log Build log for failed compile for blender-3.4.1-r3
(In reply to Kostadin Shishmanov from comment #5) > Created attachment 866849 [details, diff] [details, diff] > Patch from arch linux > > Arch and Fedora were carrying this patch for ffmpeg-6 up until version 3.5.0 > of blender. > > https://gitlab.archlinux.org/archlinux/packaging/packages/blender/-/blob/ > 995d0d699fca76ea03dc50588bee5018ce3add6d/blender-ffmpeg6.patch > > https://src.fedoraproject.org/rpms/blender/blob/ > 1731e01768a738fdc2c48652f249a1222d50402a/f/blender-3.4.1-ffmpeg6.patch From the comments from the fedora patch: +/* AV_CODEC_CAP_AUTO_THREADS was renamed to AV_CODEC_CAP_OTHER_THREADS with + * upstream commit + * github.com/FFmpeg/FFmpeg/commit/7d09579190def3ef7562399489e628f3b65714ce + * (lavc 58.132.100) and removed with commit + * github.com/FFmpeg/FFmpeg/commit/10c9a0874cb361336237557391d306d26d43f137 + * for ffmpeg 6.0. + */ From my glib glance, that gives a good explanation. Thanks, Martin
To close this one: Recompiling blender with the Arch Linux blender-3.4.1-ffmpeg6.patch... [ebuild NS ~] media-gfx/blender-3.4.1-r3:3.4::gentoo [3.6.0:3.6::gentoo] USE="X alembic bullet color-management cycles dds embree ffmpeg fftw fluid gmp jemalloc jpeg2k man nanovdb nls oidn openexr openimageio%* openmp opensubdiv openvdb pdf potrace pugixml pulseaudio sdl sndfile tbb tiff -collada -cuda -debug -doc -jack -ndof -openal -optix -osl -test -valgrind -wayland (-cycles-bin-kernels%) (-openpgl%)" PYTHON_SINGLE_TARGET="python3_11 -python3_10" 52,409 KiB ... * blender-3.4.1.tar.xz BLAKE2B SHA512 size ;-) ... [ ok ] * Using python3.11 to build >>> Unpacking source... >>> Unpacking blender-3.4.1.tar.xz to /var/tmp/portage/media-gfx/blender-3.4.1-r3/work >>> Source unpacked in /var/tmp/portage/media-gfx/blender-3.4.1-r3/work >>> Preparing source in /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1 ... * Source directory (CMAKE_USE_DIR): "/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1" * Build directory (BUILD_DIR): "/var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1_build" * Applying blender-3.3.0-fix-build-with-boost-1.81.patch ... [ ok ] * ============================================================================= * Applying user patches from /etc/portage/patches ... * Applying blender-3.4.1-ffmpeg6.patch ... [ ok ] * User patches applied. * ============================================================================= * Hardcoded definition(s) removed in extern/quadriflow/3rd/lemon-1.3.1/CMakeLists.txt: * SET(CMAKE_BUILD_TYPE "Release") * Hardcoded definition(s) removed in CMakeLists.txt: * set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE P * set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH}/\${BUILD_TYPE} CACHE P * set(CMAKE_INSTALL_PREFIX ${EXECUTABLE_OUTPUT_PATH} CACHE PATH "default >>> Source prepared. >>> Configuring source in /var/tmp/portage/media-gfx/blender-3.4.1-r3/work/blender-3.4.1 ... ... >>> media-gfx/blender-3.4.1-r3 merged. All good. Thanks, Martin
Sorry for not getting back to you earlier, I was on vacation. Is there any particular reason why you are using 3.4? I'm asking as I intended to remove this version when I 3.6 was released, but I forgot to do so. I'm intending to do so in a upcoming 3.6.x bump.
(In reply to Sebastian Parborg from comment #9) > Sorry for not getting back to you earlier, I was on vacation. > > Is there any particular reason why you are using 3.4? > I'm asking as I intended to remove this version when I 3.6 was released, but > I forgot to do so. > > I'm intending to do so in a upcoming 3.6.x bump. At the time, only to avoid a jump at an inconvenient point. ... No concerns to move upwards now. Thanks, Martin
Since media-video/ffmpeg-6 has been stabilized, this is hitting all users of stable media-gfx/blender (last stable version there is still 3.3.6-r1) by now. It might be best to either block >=media-video/ffmpeg-6 with current media-gfx/blender stable or introduce the patch until a more recent blender version can be stabilized?
(In reply to Oliver Freyermuth from comment #11) > Since media-video/ffmpeg-6 has been stabilized, this is hitting all users of > stable media-gfx/blender (last stable version there is still 3.3.6-r1) by > now. > > It might be best to either block >=media-video/ffmpeg-6 with current > media-gfx/blender stable or introduce the patch until a more recent blender > version can be stabilized? ffmpeg 6 should be supported in the later 3.3 versions as the ffmpeg 6 support should have been backported to this LTS release. Are you saying that it works with 3.3.8 but not 3.3.6?
The point is that ffmpeg-6 just got stabilized, but stable blender does not support it yet. If newer blender supports ffmpeg-6 then we need a newer blender stable!
AFAICT blender-3.3.8 has the patches from DarkDefender upstream so should be fine. I've just stabled it in bug 915118.