From 491fffe12f2e8be85d726008684c0adbcdae10a8 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Nov 24 2022 12:10:29 +0000 Subject: Fixes for C99 compatibility Related to: --- diff --git a/fvwm-configure-c99.patch b/fvwm-configure-c99.patch new file mode 100644 index 0000000..728c873 --- /dev/null +++ b/fvwm-configure-c99.patch @@ -0,0 +1,41 @@ +Do not check that the compiler supports implicit ints without errors. +Add a missing #include . + +Submitted upstream: + +diff --git a/acinclude.m4 b/acinclude.m4 +index 8b74ff1e5be21f6d..4dee2abebc678358 100644 +--- a/acinclude.m4 ++++ b/acinclude.m4 +@@ -30,7 +30,7 @@ if test "$ac_cv_func_select" = yes; then + #ifdef HAVE_SYS_SOCKET_H + #include + #endif], +-[extern select ($ac_cv_type_fd_set_size_t, ++[extern int select ($ac_cv_type_fd_set_size_t, + $ac_cv_type_fd_set *, $ac_cv_type_fd_set *, $ac_cv_type_fd_set *, + $ac_type_timeval *);], + [ac_found=yes ; break 3],ac_found=no) +@@ -1154,6 +1154,9 @@ AC_DEFUN([AM_SAFETY_CHECK_MKSTEMP],[ + #include + #include + #include ++#ifdef HAVE_UNISTD_H ++#include ++#endif + int main(void) + { + char template[128]; +diff --git a/configure.ac b/configure.ac +index 1389d5643653aa8e..cd73b925dc077141 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -220,7 +220,7 @@ AC_MINIX + + # catch -Werror and similar options when running configure + AC_TRY_COMPILE([#include ], +-[int i; static j; int *p; char *c; ++[int i; int *p; char *c; + switch (*p = p = *c) { case 0: printf("%Q", c, p); } + *c = &i; c = p; + while (1 || (unsigned int)3 >= 0 || ((int)-1) == ((unsigned int)1)); diff --git a/fvwm.spec b/fvwm.spec index 0ba20e9..6f1ac87 100644 --- a/fvwm.spec +++ b/fvwm.spec @@ -1,6 +1,6 @@ Name: fvwm Version: 2.7.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Highly configurable multiple virtual desktop window manager License: GPLv2+ URL: https://www.fvwm.org/ @@ -12,6 +12,7 @@ Patch2: fvwm-0002-Use-mimeopen-instead-of-EDITOR.patch Patch3: fvwm-0003-FvwmPager-be-more-careful-with-window-labels.patch # Fedora-specific Patch4: fvwm-0004-Skip-install-data-hook-for-default-configs.patch +Patch5: fvwm-configure-c99.patch BuildRequires: autoconf BuildRequires: automake BuildRequires: fribidi-devel @@ -81,6 +82,9 @@ install -D -m0644 -p %{SOURCE1} \ %changelog +* Thu Nov 24 2022 Florian Weimer - 2.7.0-2 +- Fixes for C99 compatibility + * Wed Nov 9 2022 Peter Lemenkov - 2.7.0-1 - Ver. 2.7.0