-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Installation issue: ffmpeg fails in configure with +X (xlib not found), possibly libxv issue? #16820
Description
I have included the standard requested information below, but from what I could unravel,
- Spack package libxv installs .../include/X11/extensions/Xvlib.h
which includes a line "#include X11/extensions/Xv.h" - Xv.h appears to be part of the videoproto package, which libxv has as a
build dependency. - If I manually add the include dir for the videoproto package to the SPACK_INCLUDE_DIRS env variable in spack-build-env.txt in the stage directory, the configure will succeed.
I believe I can write a patch for ffmpeg to get the videoproto package's include directory added to the
include path, however I suspect that the underlying issue might really be in the libxv package.
Since libxv is a library, and it's Xvlib.h header file refers to a header file in videoproto package,
shouldn't videoproto be a run-time dependency of libxv, not just a build-time dependency? ---
since anyone using libxv will presumably need to include Xvlib.h which need the videoproto package.
What is best way to pass dependency on package A in package B to package C which depends on B?
Steps to reproduce the issue
spack install [email protected]%[email protected] +X +avresample +bzlib +drawtext +gpl +libaom +libmp3lame +libopenjpeg +libopus +libsnappy +libspeex ~libssh +libvorbis ~libwebp +libzmq ~lzma +nonfree +openssl +sdl2 +shared +version3 arch=linux-rhel8-x86_64
==> 9934: ffmpeg: Executing phase: 'configure'
==> Error: ProcessError: Command exited with status 1:
'/tmp/spackswinst/spack-stage/spack-stage-ffmpeg-4.2.2-ugf7spdypubkuqeubh7hnxunlp2vclwa/spack-src/configure' '--prefix=/software/spack-software/2020.05.14/linux-rhel8-x86_64/gcc-8.4.0/ffmpeg-4.2.2-ugf7spdypubkuqeubh7hnxunlp2vclwa' '--enable-pic' '--enable-libxcb' '--enable-libxcb-shape' '--enable-libxcb-shm' '--enable-libxcb-xfixes' '--enable-xlib' '--enable-libfontconfig' '--enable-libfreetype' '--enable-libfribidi' '--enable-bzlib' '--enable-libmp3lame' '--enable-libopenjpeg' '--enable-libopus' '--enable-libspeex' '--enable-libvorbis' '--enable-avresample' '--enable-openssl' '--enable-shared' '--enable-libzmq' '--disable-libssh' '--disable-libwebp' '--disable-lzma' '--enable-libsnappy' '--enable-sdl2' '--enable-libaom'
ERROR: xlib requested but not found
In $STAGE_DIR/spack-src/ffbuild/config.log, it gives an error
check_lib xlib X11/Xlib.h X11/extensions/Xvlib.h XvGetPortAttribute -lXv -lX11 -lXext
check_func_headers X11/Xlib.h X11/extensions/Xvlib.h XvGetPortAttribute -lXv -lX11 -lXext
test_ld cc -lXv -lX11 -lXext
test_cc
BEGIN /tmp/ffconf.n8kqe5te/test.c
1 #include <X11/Xlib.h>
2 #include <X11/extensions/Xvlib.h>
3 #include <stdint.h>
4 long check_XvGetPortAttribute(void) { return (long) XvGetPortAttribute; }
5 int main(void) { int ret = 0;
6 ret |= ((intptr_t)check_XvGetPortAttribute) & 0xFFFF;
7 return ret; }
END /tmp/ffconf.n8kqe5te/test.c
gcc -D_ISOC99_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_POSIX_C_SOURCE=200112 -D_XOPEN_SOURCE=600 -DPIC -std=c11 -fomit-frame-pointer -fPIC -c -o /tmp/ffconf.n8kqe5te/test.o /tmp/ffconf.n8kqe5te/test.c
In file included from /tmp/ffconf.n8kqe5te/test.c:2:
/software/spack-software/2020.05.14/linux-rhel8-x86_64/gcc-8.4.0/libxv-1.0.10-a6t63vy7i6znr4h7ksjbnwv2mkkavjny/include/X11/extensions/Xvlib.h:56:10: fatal error: X11/extensions/Xv.h: No such file or directory
#include <X11/extensions/Xv.h>
Information on your system
- Spack: 0.14.2-1112-445cae5c8
- Python: 3.6.8
- Platform: linux-rhel8-x86_64
Additional information
Attaching spack-build-out.txt, spack-build-env.txt, and spack-src/ffbuild/config.log
No maintainers listed for either ffmpeg or libxv.
General information
- I have run
spack debug reportand reported the version of Spack/Python/Platform - I have run
spack maintainers <name-of-the-package>and @mentioned any maintainers - I have uploaded the build log and environment files
- I have searched the issues of this repo and believe this is not a duplicate