Compare commits

...
Sign in to create a new pull request.

20 commits

Author SHA1 Message Date
Florian Weimer
fa5dd6e32e Update License tag with build system licenses 2025-11-14 15:32:39 +01:00
Martin Coufal
4387be6cd3 Fix Fedora gating tests.
Remove outdated tests.yml and replace it with FMF/TMT. The upstream
testsuite needed a build path fix and definition of pre-build variables.
2025-11-10 13:00:48 +01:00
Fedora Release Engineering
af97130b57 Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild 2025-07-24 21:10:08 +00:00
Frédéric Bérat
eb4498fb1d Update to m4-1.4.20
The new release fixes the need for -std=gnu17
2025-05-12 15:11:55 +02:00
Frédéric Bérat
e7e00ce157 Set C standard to gnu17
A new m4 release would be needed in order to fix all issues related to
GCC15 setting gnu23 the new standard for C.
While the release has been requested, limit the standard to gnu17.
2025-02-04 15:49:03 +01:00
Fedora Release Engineering
d2aebca464 Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild 2025-01-17 16:39:56 +00:00
Fedora Release Engineering
75eaca3214 Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-18 16:32:39 +00:00
Fedora Release Engineering
c06055e568 Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-25 05:34:39 +00:00
Fedora Release Engineering
2ed6a15836 Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-21 06:43:31 +00:00
Frédéric Bérat
25fbe609d8 Migrate to SPDX licenses
License scanning done on the binary RPM itself, cross-checked with
source RPM for non-text based files.
2023-09-07 15:35:18 +02:00
Fedora Release Engineering
88caa89d09 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-20 13:33:51 +00:00
Fedora Release Engineering
e902be1005 Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-19 18:47:10 +00:00
Fedora Release Engineering
884f8ba72f Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-21 20:20:59 +00:00
Fedora Release Engineering
809099a8cd - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-01-20 18:32:14 +00:00
Fedora Release Engineering
9b1c4a1bda - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-22 13:35:38 +00:00
Vitezslav Crhonek
745918953c Update to m4-1.4.19 2021-06-01 10:50:07 +02:00
Fedora Release Engineering
dec446dc1d - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-26 19:06:16 +00:00
Robert Scheck
693395760c Update URLs to HTTPS 2021-01-18 01:40:29 +00:00
Tom Stellard
abaf7b6606 Add BuildRequires: make
https://fedoraproject.org/wiki/Changes/Remove_make_from_BuildRoot
2021-01-08 03:11:39 +00:00
Vitezslav Crhonek
d9c380b5e8 Drop workaround introduced in previous release 2020-10-13 11:22:19 +02:00
11 changed files with 103 additions and 153 deletions

1
.fmf/version Normal file
View file

@ -0,0 +1 @@
1

4
.gitignore vendored
View file

@ -1,2 +1,2 @@
/m4-1.4.18.tar.xz
/m4-1.4.18.tar.xz.sig
/m4-1.4.20.tar.xz
/m4-1.4.20.tar.xz.sig

7
gating.yaml Normal file
View file

@ -0,0 +1,7 @@
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_stable
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

View file

@ -1,115 +0,0 @@
diff -up m4-1.4.18/lib/fflush.c.orig m4-1.4.18/lib/fflush.c
--- m4-1.4.18/lib/fflush.c.orig 2018-05-02 12:35:59.536851666 +0200
+++ m4-1.4.18/lib/fflush.c 2018-05-02 12:37:02.768958606 +0200
@@ -33,7 +33,7 @@
#undef fflush
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
/* Clear the stream's ungetc buffer, preserving the value of ftello (fp). */
static void
@@ -72,7 +72,7 @@ clear_ungetc_buffer (FILE *fp)
#endif
-#if ! (defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
+#if ! (defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */)
# if (defined __sferror || defined __DragonFly__ || defined __ANDROID__) && defined __SNPT
/* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Android */
@@ -148,7 +148,7 @@ rpl_fflush (FILE *stream)
if (stream == NULL || ! freading (stream))
return fflush (stream);
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
clear_ungetc_buffer_preserving_position (stream);
diff -up m4-1.4.18/lib/fpending.c.orig m4-1.4.18/lib/fpending.c
--- m4-1.4.18/lib/fpending.c.orig 2018-05-02 12:35:32.305806774 +0200
+++ m4-1.4.18/lib/fpending.c 2018-05-02 12:35:44.944827347 +0200
@@ -32,7 +32,7 @@ __fpending (FILE *fp)
/* Most systems provide FILE as a struct and the necessary bitmask in
<stdio.h>, because they need it for implementing getc() and putc() as
fast macros. */
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
return fp->_IO_write_ptr - fp->_IO_write_base;
#elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
/* FreeBSD, NetBSD, OpenBSD, DragonFly, Mac OS X, Cygwin, Android */
diff -up m4-1.4.18/lib/fpurge.c.orig m4-1.4.18/lib/fpurge.c
--- m4-1.4.18/lib/fpurge.c.orig 2018-05-02 12:38:13.586078669 +0200
+++ m4-1.4.18/lib/fpurge.c 2018-05-02 12:38:38.785121867 +0200
@@ -62,7 +62,7 @@ fpurge (FILE *fp)
/* Most systems provide FILE as a struct and the necessary bitmask in
<stdio.h>, because they need it for implementing getc() and putc() as
fast macros. */
-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
fp->_IO_read_end = fp->_IO_read_ptr;
fp->_IO_write_ptr = fp->_IO_write_base;
/* Avoid memory leak when there is an active ungetc buffer. */
diff -up m4-1.4.18/lib/freadahead.c.orig m4-1.4.18/lib/freadahead.c
--- m4-1.4.18/lib/freadahead.c.orig 2016-12-31 14:54:41.000000000 +0100
+++ m4-1.4.18/lib/freadahead.c 2018-05-02 11:43:19.570336724 +0200
@@ -25,7 +25,7 @@
size_t
freadahead (FILE *fp)
{
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
if (fp->_IO_write_ptr > fp->_IO_write_base)
return 0;
return (fp->_IO_read_end - fp->_IO_read_ptr)
diff -up m4-1.4.18/lib/freading.c.orig m4-1.4.18/lib/freading.c
--- m4-1.4.18/lib/freading.c.orig 2018-05-02 12:37:33.970011368 +0200
+++ m4-1.4.18/lib/freading.c 2018-05-02 12:37:59.393054359 +0200
@@ -31,7 +31,7 @@ freading (FILE *fp)
/* Most systems provide FILE as a struct and the necessary bitmask in
<stdio.h>, because they need it for implementing getc() and putc() as
fast macros. */
-# if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+# if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
return ((fp->_flags & _IO_NO_WRITES) != 0
|| ((fp->_flags & (_IO_NO_READS | _IO_CURRENTLY_PUTTING)) == 0
&& fp->_IO_read_base != NULL));
diff -up m4-1.4.18/lib/fseeko.c.orig m4-1.4.18/lib/fseeko.c
--- m4-1.4.18/lib/fseeko.c.orig 2018-05-02 11:44:17.947460233 +0200
+++ m4-1.4.18/lib/fseeko.c 2018-05-02 12:39:49.537216897 +0200
@@ -47,7 +47,7 @@ fseeko (FILE *fp, off_t offset, int when
#endif
/* These tests are based on fpurge.c. */
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
if (fp->_IO_read_end == fp->_IO_read_ptr
&& fp->_IO_write_ptr == fp->_IO_write_base
&& fp->_IO_save_base == NULL)
@@ -123,7 +123,7 @@ fseeko (FILE *fp, off_t offset, int when
return -1;
}
-#if defined _IO_ftrylockfile || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
+#if defined _IO_EOF_SEEN || __GNU_LIBRARY__ == 1 /* GNU libc, BeOS, Haiku, Linux libc5 */
fp->_flags &= ~_IO_EOF_SEEN;
fp->_offset = pos;
#elif defined __sferror || defined __DragonFly__ || defined __ANDROID__
diff -up m4-1.4.18/lib/stdio-impl.h.orig m4-1.4.18/lib/stdio-impl.h
--- m4-1.4.18/lib/stdio-impl.h.orig 2016-12-31 14:54:42.000000000 +0100
+++ m4-1.4.18/lib/stdio-impl.h 2018-05-02 11:43:19.570336724 +0200
@@ -18,6 +18,12 @@
the same implementation of stdio extension API, except that some fields
have different naming conventions, or their access requires some casts. */
+/* Glibc 2.28 made _IO_IN_BACKUP private. For now, work around this
+ problem by defining it ourselves. FIXME: Do not rely on glibc
+ internals. */
+#if !defined _IO_IN_BACKUP && defined _IO_EOF_SEEN
+# define _IO_IN_BACKUP 0x100
+#endif
/* BSD stdio derived implementations. */

78
m4.spec
View file

@ -1,14 +1,14 @@
Summary: The GNU macro processor
Summary: GNU macro processor
Name: m4
Version: 1.4.18
Release: 15%{?dist}
License: GPLv3+
Source0: http://ftp.gnu.org/gnu/m4/m4-%{version}.tar.xz
Source1: http://ftp.gnu.org/gnu/m4/m4-%{version}.tar.xz.sig
# Patch0: update to glibc libio.h removal, rhbz#1573342
Patch0: m4-1.4.18-glibc-change-work-around.patch
URL: http://www.gnu.org/software/m4/
Version: 1.4.20
Release: 3%{?dist}
License: GPL-3.0-or-later AND GFDL-1.3-or-later AND FSFULLR AND GPL-3.0-or-later WITH Autoconf-exception-generic-3.0 AND GPL-3.0-or-later WITH Texinfo-exception AND GPL-2.0-or-later WITH Autoconf-exception-generic AND GPL-3.0-or-later WITH Autoconf-exception-generic-3.0 AND MIT
Source0: https://ftp.gnu.org/gnu/m4/m4-%{version}.tar.xz
Source1: https://ftp.gnu.org/gnu/m4/m4-%{version}.tar.xz.sig
URL: https://www.gnu.org/software/m4/
BuildRequires: make
BuildRequires: gcc autoconf automake
BuildRequires: gettext
%ifarch ppc ppc64
BuildRequires: texinfo
%endif
@ -28,24 +28,21 @@ Install m4 if you need a macro processor.
%prep
%setup -q
%patch0 -p1 -b .glibc-change-work-around
chmod 644 COPYING
%build
autoreconf -ivf
%configure
%make_build
%install
%make_install
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
%find_lang %{name}
%check
%ifnarch ppc64le
make %{?_smp_mflags} check
%endif
%files
%files -f %{name}.lang
%license COPYING
%doc AUTHORS ChangeLog NEWS README THANKS TODO
%{_bindir}/m4
@ -53,6 +50,59 @@ make %{?_smp_mflags} check
%{_mandir}/man1/m4.1*
%changelog
* Fri Nov 14 2025 Florian Weimer <fweimer@redhat.com> - 1.4.20-3
- Update License tag with build system licenses
* Thu Jul 24 2025 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.20-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
* Mon May 12 2025 Frédéric Bérat <fberat@redhat.com> - 1.4.20-1
- Update to m4-1.4.20 (#2365446)
* Tue Feb 04 2025 Frédéric Bérat <fberat@redhat.com> - 1.4.19-12
- Add -std=gnu17 to CFLAGS to fix FTBFS until new m4 release gets out (#2340807)
* Fri Jan 17 2025 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
* Thu Jul 18 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-10
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Thu Jan 25 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-9
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sun Jan 21 2024 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Tue Aug 08 2023 Frederic Berat <fberat@redhat.com> - 1.4.19-7
- Migrate to SPDX licenses (#2222092).
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.19-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Mon May 31 2021 Vitezslav Crhonek <vcrhonek@redhat.com> - 1.4.19-1
- Update to m4-1.4.19
Resolves: #1965719
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.4.18-17
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Tue Oct 13 2020 Vitezslav Crhonek <vcrhonek@redhat.com> - 1.4.18-16
- Drop workaround introduced in previous release
Resolves: #1864107
* Thu Aug 06 2020 Vitezslav Crhonek <vcrhonek@redhat.com> - 1.4.18-15
- Disable %%check on ppc64le (workaround for FTBFS)
Resolves: #1864107

5
plans/ci.fmf Normal file
View file

@ -0,0 +1,5 @@
summary: CI Gating Plan
discover:
how: fmf
execute:
how: tmt

View file

@ -1,2 +1,2 @@
SHA512 (m4-1.4.18.tar.xz) = 06f583efc3855cd8477d8347544f4ae5153a3e50aea74d21968afa7214784ea3ddfc02d0a2b11324120d76a19f2e804d20de11a456b5da929eb6ae469519b174
SHA512 (m4-1.4.18.tar.xz.sig) = effc857a19f1496d6dde2887c0314b37d4b142a435e77614936c730878c798491ad93b28860dddd2601f99a43fa41923729b961004faafc6f798f7bc1842f980
SHA512 (m4-1.4.20.tar.xz) = dc7b4f61452e564b095010029bf6ce4246e5a03959989cd76b09eb8012db7424c52819143020fab21a3471ff57ab026d3eccbd00dd3969819208980565a9fec0
SHA512 (m4-1.4.20.tar.xz.sig) = bc75a64e47a87fe4073f26850a8344e82d15f156ac5b52cde1af701a0ba4e0d18f414323f86c868f114c4867b00c31ce205a9505343e588ad97825b05136c5eb

View file

@ -1,16 +0,0 @@
---
# Tests for Classic and Container
- hosts: localhost
roles:
- role: standard-test-beakerlib
tags:
- classic
- container
tests:
- testsuite
required_packages:
- autoconf
- automake
- rpm-build
- wget

View file

@ -53,7 +53,7 @@ $(METADATA): Makefile
@echo "Type: Regression" >> $(METADATA)
@echo "TestTime: 3h" >> $(METADATA)
@echo "RunFor: m4" >> $(METADATA)
@echo "Requires: m4" >> $(METADATA)
@echo "Requires: m4 rpm-build autoconf automake gettext gcc" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv2+" >> $(METADATA)
@echo "Confidential: no" >> $(METADATA)

17
tests/testsuite/main.fmf Normal file
View file

@ -0,0 +1,17 @@
summary: testsuite
description: ''
contact: Martin Cermak <mcermak@redhat.com>
component:
- m4
test: ./runtest.sh
framework: beakerlib
require:
- m4
- gcc
- rpm-build
- autoconf
- automake
- gettext
duration: 3h
extra-summary: /tools/m4/Regression/testsuite
extra-task: /tools/m4/Regression/testsuite

7
tests/testsuite/runtest.sh Normal file → Executable file
View file

@ -26,10 +26,10 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Include Beaker environment
. /usr/bin/rhts-environment.sh || exit 1
. /usr/share/beakerlib/beakerlib.sh || exit 1
PACKAGE="m4"
VERSION=$(rpm -q m4 --qf '%{VERSION}')
rlJournalStart
rlPhaseStartSetup
@ -48,7 +48,8 @@ rlJournalStart
rlPhaseEnd
rlPhaseStart FAIL "Run tests"
rlRun "pushd $TMPD/BUILD/m4-*"
rlRun "pushd $TMPD/BUILD/m4-${VERSION}-build/m4-${VERSION}"
rlRun "eval `rpm --eval %___build_pre_env`"
# el7 package creates couple tests/*log files (per testcase)
# el6 package doesn't, so we'll create some explicitly
rlRun "make check > tests/testout.log 2> tests/testerr.log"
@ -61,7 +62,7 @@ rlJournalStart
rlPhaseEnd
rlPhaseStart FAIL "Check for no FAILed test"
rlRun "[[ $(cat tests/*log | grep -i FAIL | grep -P -v '^#' | wc -l) -eq 0 ]]"
rlRun "[[ $(cat tests/*log | grep FAIL | grep -P -v '^#' | wc -l) -eq 0 ]]"
rlPhaseEnd
rlPhaseStart FAIL "Show test results summary"