gentoo-ebuilds/app-misc/ddcutil/files/ddcutil-1.4.1-no-werror.patch
Z. Liu 60c04bf9dc
app-misc/ddcutil: fix build error with clang 19
1. 'test STRING' equivalent to '-n STRING' which is True if the length of
   string is non-zero, so 'test 0' always success. Both 'test ""' and
   'test 1 -eq 0' are ok, but the later is more intuitive.
2. too many errors on Wcompound-token-split-by-macro, so disable this
   warning as a workaround.
3. fix two errors reported by clang 19, patch submitted to upstream.

Closes: https://bugs.gentoo.org/928969
Closes: https://bugs.gentoo.org/929096
Signed-off-by: Z. Liu <zhixu.liu@gmail.com>
Closes: https://github.com/gentoo/gentoo/pull/40762
Signed-off-by: Sam James <sam@gentoo.org>
2025-02-26 06:13:34 +00:00

25 lines
773 B
Diff

diff --git a/src/test/Makefile.am b/src/test/Makefile.am
index c12f15c..27d2124 100644
--- a/src/test/Makefile.am
+++ b/src/test/Makefile.am
@@ -4,7 +4,7 @@ $(GLIB_CFLAGS) \
-I$(top_srcdir)/src \
-I$(top_srcdir)/src/public
-AM_CFLAGS = -Wall -Werror
+AM_CFLAGS = -Wall
CLEANFILES = \
*expand
--- ddcutil-1.4.1/configure.ac.orig 2023-07-02 22:11:20.601695946 -0700
+++ ddcutil-1.4.1/configure.ac 2023-07-02 22:11:41.306685606 -0700
@@ -63,7 +63,7 @@
AC_ARG_VAR(DBG, [Turn on script debugging messages(0/1)])
dnl AC_MSG_NOTICE([DBG = |$DBG|])
-AM_CONDITIONAL(WARNINGS_ARE_ERRORS_COND, [test "x$ddcutil_version_suffix" != "x"] )
+AM_CONDITIONAL(WARNINGS_ARE_ERRORS_COND, [test 1 -eq 0])
AS_IF( [test 0$DBG -ne 0],
AC_MSG_NOTICE([debug messages enabled]),