Xpra: Ticket #1772: Deprecated declarations

Hello.

xpra/codecs/dec_avcodec2/decoder.c is not compiled for a "deprecated declaration" error:

building 'xpra.codecs.dec_avcodec2.decoder' extension
creating build/temp.linux-x86_64-2.7/xpra/codecs/dec_avcodec2
gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -mcet -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -mcet -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -mcet -fcf-protection -fPIC -I/usr/include/ffmpeg -I/usr/include/python2.7 -c xpra/codecs/dec_avcodec2/decoder.c -o build/temp.linux-x86_64-2.7/xpra/codecs/dec_avcodec2/decoder.o -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -Wall -Werror -fPIC
xpra/codecs/dec_avcodec2/decoder.c: In function '__pyx_pf_4xpra_6codecs_12dec_avcodec2_7decoder_7Decoder_init_context':
xpra/codecs/dec_avcodec2/decoder.c:5218:3: error: 'avcodec_register_all' is deprecated [-Werror=deprecated-declarations]
   avcodec_register_all();
   ^~~~~~~~~~~~~~~~~~~~
In file included from xpra/codecs/dec_avcodec2/decoder.c:579:
/usr/include/ffmpeg/libavcodec/avcodec.h:4044:6: note: declared here
 void avcodec_register_all(void);
      ^~~~~~~~~~~~~~~~~~~~
xpra/codecs/dec_avcodec2/decoder.c: In function 'initdecoder':
xpra/codecs/dec_avcodec2/decoder.c:13996:3: error: 'avcodec_register_all' is deprecated [-Werror=deprecated-declarations]
   avcodec_register_all();
   ^~~~~~~~~~~~~~~~~~~~
In file included from xpra/codecs/dec_avcodec2/decoder.c:579:
/usr/include/ffmpeg/libavcodec/avcodec.h:4044:6: note: declared here
 void avcodec_register_all(void);
      ^~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
error: command 'gcc' failed with exit status 1


xpra-2.2.4 ffmpeg-3.5 gcc-8.0.1



Fri, 23 Feb 2018 09:28:22 GMT - Antoine Martin: priority, status changed; milestone set; keywords deleted

As far as I can tell, there is no replacement for this function. We'll deal with it when ffmpeg 4.0 comes out, hopefully they will have fixed their own code and provided an alternative by then. Until then, you can silence the warnings with --without-strict.


Sat, 21 Apr 2018 04:49:32 GMT - Antoine Martin: status changed; resolution set

Fixes:

For platform packaging of ffmpeg 4, see r19039 and #1751


Sun, 22 Apr 2018 05:59:33 GMT - Antoine Martin: milestone changed


Sat, 01 Dec 2018 08:08:01 GMT - Dennis Schridde: cc set


Sat, 01 Dec 2018 09:28:52 GMT - Antoine Martin:

@devurandom: this ticket is closed as fixed, it will not receive further updates.


Wed, 06 May 2020 08:37:52 GMT - Antoine Martin:

Workaround removed in r26267 as xpra v4 no longer supports older versions of ffmpeg.


Sat, 23 Jan 2021 05:33:23 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1772