Build Issue on Ubuntu and Linux following instructions on blog post https://www.nginx.com/blog/video-streaming-for-remote-learning-with-nginx/

Sergey Kandaurov pluknet at nginx.com
Tue Nov 24 22:04:51 UTC 2020


> On 24 Nov 2020, at 21:17, j at fuldgroup.com wrote:
> 
> Hi All,
>  
> Found an issue within the build of nginx.
>  
> Following James’ instructions on https://www.nginx.com/blog/video-streaming-for-remote-learning-with-nginx/ :
> mkdir buildnginx
> cd buildnginx
> sudo git clone https://github.com/arut/nginx-rtmp-module.git
> sudo  git clone https://github.com/nginx/nginx.git
> cd nginx
> sudo  ./auto/configure --add-module=../nginx-rtmp-module
> sudo  make
> sudo  sudo make install
>  
> At the make command:  The following error occurs
>  
> -I objs -I src/http -I src/http/modules \
>         -o objs/addon/nginx-rtmp-module/ngx_rtmp_eval.o \
>         ../nginx-rtmp-module/ngx_rtmp_eval.c
> ../nginx-rtmp-module/ngx_rtmp_eval.c: In function ‘ngx_rtmp_eval’:
> ../nginx-rtmp-module/ngx_rtmp_eval.c:160:17: error: this statement may fall through [-Werror=implicit-fallthrough=]
>   160 |                 switch (c) {
>       |                 ^~~~~~
> ../nginx-rtmp-module/ngx_rtmp_eval.c:170:13: note: here
>   170 |             case ESCAPE:
>       |             ^~~~
> cc1: all warnings being treated as errors
> make[1]: *** [objs/Makefile:1339: objs/addon/nginx-rtmp-module/ngx_rtmp_eval.o] Error 1
> make[1]: Leaving directory '/buildnginx/nginx'
> make: *** [Makefile:8: build] Error 2
>  
> Reading through the source code ngx_rtmp_eval at line 160 through 170, the switch statement will most likely fall through, so the build warning call out is a correct action.
>  
> This occurs on both ubuntu and Raspbian versions of Linux.
>  
> Having watched James at https://www.youtube.com/watch?v=Js1OlvRNsdI, there was no problem with his build.
>  
> Questions:
> 	• How do I resolve?
> ·       I could try make -k;
> ·       I remove -Werror flag in the make file (I did not see it in the make file – could be my eyes, though, so if you know where it is please tell me)
> ·       Who owns ngx_rtmp_eval, so that I can contact them to fix the source code?
>  

nginx-rtmp-module is a third-party nginx module.
You may want to report about a build issue to the module author(s).

This is a new error reported in recent gcc versions,
that's why it may not trigger in other environments.

To work around, you can specify -Wno-error=implicit-fallthrough=
in --with-cc-opt= configuration option to ignore that error.

-- 
Sergey Kandaurov



More information about the nginx mailing list