-
Notifications
You must be signed in to change notification settings - Fork 395
Closed
Description
Overview
While installing the PyAV package via. PYPI (pip install av), the build breaks. And it does not install.
Expected behavior
It was expected that the package will install after ffmpeg version > 4 was installed.
Actual behavior
The build/install fails with the following error
Build report:
building 'av.sidedata.motionvectors' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/sidedata/motionvectors.c -o build/temp.linux-x86_64-3.7/src/av/sidedata/motionvectors.o
src/av/sidedata/motionvectors.c: In function ‘__pyx_pf_2av_8sidedata_13motionvectors_14_MotionVectors_2__repr__’:
src/av/sidedata/motionvectors.c:2345:46: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
__pyx_t_4 = __Pyx_PyInt_From_unsigned_int(((unsigned int)__pyx_v_self->__pyx_base.ptr->data)); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 17, __pyx_L1_error)
^
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/sidedata/motionvectors.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/sidedata/motionvectors.cpython-37m-x86_64-linux-gnu.so
building 'av.data.stream' extension
creating build/temp.linux-x86_64-3.7/src/av/data
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/data/stream.c -o build/temp.linux-x86_64-3.7/src/av/data/stream.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/data/stream.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/data/stream.cpython-37m-x86_64-linux-gnu.so
building 'av.filter.filter' extension
creating build/temp.linux-x86_64-3.7/src/av/filter
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/filter/filter.c -o build/temp.linux-x86_64-3.7/src/av/filter/filter.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/filter/filter.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/filter/filter.cpython-37m-x86_64-linux-gnu.so
building 'av.filter.link' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/filter/link.c -o build/temp.linux-x86_64-3.7/src/av/filter/link.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/filter/link.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/filter/link.cpython-37m-x86_64-linux-gnu.so
building 'av.filter.context' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/filter/context.c -o build/temp.linux-x86_64-3.7/src/av/filter/context.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/filter/context.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/filter/context.cpython-37m-x86_64-linux-gnu.so
building 'av.filter.pad' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/filter/pad.c -o build/temp.linux-x86_64-3.7/src/av/filter/pad.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/filter/pad.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/filter/pad.cpython-37m-x86_64-linux-gnu.so
building 'av.filter.graph' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/filter/graph.c -o build/temp.linux-x86_64-3.7/src/av/filter/graph.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/filter/graph.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/filter/graph.cpython-37m-x86_64-linux-gnu.so
building 'av.codec.context' extension
creating build/temp.linux-x86_64-3.7/src/av/codec
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/codec/context.c -o build/temp.linux-x86_64-3.7/src/av/codec/context.o
gcc -pthread -shared -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -L/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,-rpath=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/lib -Wl,--no-as-needed -Wl,--sysroot=/ build/temp.linux-x86_64-3.7/src/av/codec/context.o -lswresample -lavutil -lavcodec -lavformat -lswscale -lavdevice -lavfilter -o build/lib.linux-x86_64-3.7/av/codec/context.cpython-37m-x86_64-linux-gnu.so
building 'av.codec.codec' extension
gcc -pthread -B /home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/compiler_compat -Wl,--sysroot=/ -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -fPIC -Iinclude -Ibuild/temp.linux-x86_64-3.7/include -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -I/usr/include/x86_64-linux-gnu -I/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env/include/python3.7m -Ibuild/temp.linux-x86_64-3.7/include -c src/av/codec/codec.c -o build/temp.linux-x86_64-3.7/src/av/codec/codec.o
src/av/codec/codec.c: In function ‘__pyx_pymod_exec_codec’:
src/av/codec/codec.c:6061:36: error: ‘AV_CODEC_CAP_HARDWARE’ undeclared (first use in this function); did you mean ‘AV_CODEC_CAP_DR1’?
__pyx_t_7 = __Pyx_PyInt_From_int(AV_CODEC_CAP_HARDWARE); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 124, __pyx_L1_error)
^~~~~~~~~~~~~~~~~~~~~
AV_CODEC_CAP_DR1
src/av/codec/codec.c:6061:36: note: each undeclared identifier is reported only once for each function it appears in
src/av/codec/codec.c:6082:36: error: ‘AV_CODEC_CAP_HYBRID’ undeclared (first use in this function); did you mean ‘AV_CODEC_CAP_DR1’?
__pyx_t_7 = __Pyx_PyInt_From_int(AV_CODEC_CAP_HYBRID); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 128, __pyx_L1_error)
^~~~~~~~~~~~~~~~~~~
AV_CODEC_CAP_DR1
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for av
Investigation
I tried to compile download the av package and compile it using setup.py and the --ffmpeg-dir flag pointing to the ffmpeg directory. Installation fails.
Reproduction
Have not tried on any other system.
Versions
- OS: Ubuntu 18.04
- PyAV runtime:
{{ Complete output of `python -m av --version` if you can run it. }}
- PyAV build:
PyAV: 7.0.1 (unknown commit)
Python: 3.7.6 (default, Jan 8 2020, 19:59:22) \n[GCC 7.3.0]
platform: Linux-5.3.0-40-generic-x86_64-with-debian-buster-sid
extension_extra:
include_dirs: [b'include', b'/usr/include/x86_64-linux-gnu']
libraries: [b'avformat', b'avcodec', b'avdevice', b'avutil', b'avfilter', b'swscale', b'swresample']
library_dirs: []
define_macros: []
runtime_library_dirs: []
config_macros:
PYAV_COMMIT_STR="unknown-commit"
PYAV_VERSION=7.0.1
PYAV_VERSION_STR="7.0.1"
- FFmpeg:
ffmpeg version 4.1.3 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 7.3.0 (crosstool-NG 1.23.0.449-a04d0)
configuration: --prefix=/home/dartnixtrix/anaconda3/envs/kyc_webrtc_env --cc=/home/conda/feedstock_root/build_artifacts/ffmpeg_1556785800657/_build_env/bin/x86_64-conda_cos6-linux-gnu-cc --disable-doc --disable-openssl --enable-avresample --enable-gnutls --enable-gpl --enable-hardcoded-tables --enable-libfreetype --enable-libopenh264 --enable-libx264 --enable-pic --enable-pthreads --enable-shared --enable-static --enable-version3 --enable-zlib --enable-libmp3lame
libavutil 56. 22.100 / 56. 22.100
libavcodec 58. 35.100 / 58. 35.100
libavformat 58. 20.100 / 58. 20.100
libavdevice 58. 5.100 / 58. 5.100
libavfilter 7. 40.101 / 7. 40.101
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 3.100 / 5. 3.100
libswresample 3. 3.100 / 3. 3.100
libpostproc 55. 3.100 / 55. 3.100
Research
I have done the following:
- Checked the PyAV documentation
- Searched on Google
- Searched on Stack Overflow
- Looked through old GitHub issues
- Asked on PyAV Gitter
- ... and waited 72 hours for a response.
Additional context
I want to use "aiortc", this is a dependency. I have read an issue on PyAV repo. in which it was said "it is broken since 7.0.0". Tried installing 6.2.0 with success. But 7.0.1 is what is needed.
andyljones, JoshuaCWebDeveloper, igorrendulic and yurinishikawa
Metadata
Metadata
Assignees
Labels
No labels