Uploaded image for project: 'Guacamole'
  1. Guacamole
  2. GUACAMOLE-638

Compile error: 'avcodec_register_all' is deprecated

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.0.0
    • 1.1.0
    • guacamole-server
    • None
    • Fedora 28

    Description

      Compile error with Fedora 28:

      guacenc.c: In function 'main':
      guacenc.c:79:5: error: 'avcodec_register_all' is deprecated [-Werror=deprecated-declarations]
       avcodec_register_all();
       ^~~~~~~~~~~~~~~~~~~~
      In file included from guacenc.c:27:
      /usr/include/ffmpeg/libavcodec/avcodec.h:4086:6: note: declared here
       void avcodec_register_all(void);
       ^~~~~~~~~~~~~~~~~~~~
      cc1: all warnings being treated as errors
      

      Here's a patch:

      --- guacenc.c	2018-09-28 02:25:30.000000000 +0100
      +++ guacenc.c	2018-09-28 15:30:26.849265324 +0100
      @@ -76,7 +76,9 @@
                   "version " VERSION);
       
           /* Prepare libavcodec */
      +#if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(58, 9, 100)
           avcodec_register_all();
      +#endif
       
           /* Track number of overall failures */
           int total_files = argc - optind;
      

      Attachments

        Issue Links

          Activity

            People

              mjumper Mike Jumper
              TonyGeeUK T Gale
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: