tmedicci commented on code in PR #1735:
URL: https://github.com/apache/nuttx-apps/pull/1735#discussion_r1182691789


##########
netutils/rtptools/Makefile:
##########
@@ -28,8 +28,21 @@ RTPTOOLS_SRCDIR   = $(RTPTOOLS_UNPACK)
 DEPPATH += --dep-path $(RTPTOOLS_SRCDIR)
 VPATH   += :$(RTPTOOLS_SRCDIR)
 
-CFLAGS += -Wno-maybe-uninitialized -Wno-strict-prototypes
-CFLAGS += -Wno-unused-function -Wno-format -Wno-shadow
+CFLAGS += -Wno-strict-prototypes -Wno-unused-function -Wno-format -Wno-shadow
+
+# Workaround for clang.
+#
+# error: unknown warning option '-Wno-maybe-uninitialized'; did you mean 
'-Wno-uninitialized'? [-Werror,-Wunknown-warning-option]
+# make[3]: *** 
[multimer.c.Users.runner.work.nuttx.nuttx.sources.apps.netutils.rtptools.o] 
Error 1
+#
+# It's possible to use only '-Wno-uninitialized' instead, however, it isn't
+# recommended as it could mask erroneous code.
+#
+ifneq ($(shell $(CC) --version | grep clang),)
+CFLAGS += -Wno-uninitialized

Review Comment:
   Yes, we could. But the original code is quite old and I followed the path to 
build it "as is". Other apps apply the same, so I thought that "as is" was 
acceptable. Definitely, it's something that can be improved in the future, but 
I'm aware that I don't have time to make it for now: it's a demonstration 
project that I'm building for NuttX.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to