diff --git a/.fmf/version b/.fmf/version deleted file mode 100644 index d00491f..0000000 --- a/.fmf/version +++ /dev/null @@ -1 +0,0 @@ -1 diff --git a/.gitignore b/.gitignore index b3edfc9..3554a1c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,10 +1 @@ -flex-2.5.35.tar.bz2 -/flex*/ -*.rpm -/flex-2.5.36.tar.bz2 -/flex-2.5.37.tar.bz2 -/flex-2.5.39.tar.bz2 -/flex-2.6.0.tar.bz2 -/flex-2.6.1.tar.xz -/flex-2.6.4.tar.gz -series +flex-2.5.33.tar.bz2 diff --git a/README.quilt b/README.quilt deleted file mode 100644 index e53b9b9..0000000 --- a/README.quilt +++ /dev/null @@ -1,40 +0,0 @@ -This package supports working with patch files using quilt. - -To regenerate the quilt series file run: -./gen-quilt-series.sh - -Setup environment: -export QUILT_PATCHES=$PWD - -Setup the source: -./quilt-patch.sh [-f] - -Use `-f` if you want to have quilt-patch always remove the existing -source directory before starting. Otherwise you'll be patching on top of -an already patched tree generated perhaps by `*pkg prep`. - -To add a new patch: - -Option 1: Create a new patch: - -cd flex-2.6.1/ -quilt new flex-rh1439367.patch -quilt add tests/test-bison-yylloc/parser.y -# edit tests/test-bison-yylloc/parser.y -# you may add and edit several files in the same fashion - -Option 2: Add an already prepared patch (e.g. from an upstream commit): - -cd flex-2.6.1/ -quilt import -P flex-rh1439367.patch ~/backport/obsolete-bison.patch -quilt push # if this fails, manually deal with conflicts (as in Option 1) - -Finally: -quilt refresh -p ab -cd .. -git add flex-rh1439367.patch -# edit flex.spec to build with the new patch -git add flex.spec -git commit - -You're done! diff --git a/flex-2.5.33-includedir.patch b/flex-2.5.33-includedir.patch new file mode 100644 index 0000000..3135be6 --- /dev/null +++ b/flex-2.5.33-includedir.patch @@ -0,0 +1,12 @@ +diff -urp flex-2.5.33/Makefile.in flex-2.5.33-pm/Makefile.in +--- flex-2.5.33/Makefile.in 2007-05-30 10:57:18.000000000 +0200 ++++ flex-2.5.33-pm/Makefile.in 2007-05-30 10:57:11.000000000 +0200 +@@ -291,7 +291,7 @@ SUBDIRS = \ + + + localedir = $(datadir)/locale +-AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I@includedir@ -I$(top_srcdir)/intl ++AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I$(top_srcdir)/intl + AM_CFLAGS = -fPIC + + # Run GNU indent on sources. Don't run this unless all the sources compile cleanly. diff --git a/flex-2.5.33-opts.patch b/flex-2.5.33-opts.patch new file mode 100644 index 0000000..3189fe3 --- /dev/null +++ b/flex-2.5.33-opts.patch @@ -0,0 +1,40 @@ +diff -urp flex-2.5.33/scanopt.c flex-2.5.33-pm/scanopt.c +--- flex-2.5.33/scanopt.c 2002-08-29 22:30:25.000000000 +0200 ++++ flex-2.5.33-pm/scanopt.c 2007-05-11 17:48:29.000000000 +0200 +@@ -789,12 +789,12 @@ int scanopt (svoid, arg, optindex) + } + + optarg = pstart + 1; +- arglen = 0; +- while (optarg[arglen]) +- arglen++; +- +- if (arglen == 0) ++ if (!*optarg) { + optarg = NULL; ++ arglen = 0; ++ } ++ else ++ arglen = strlen (optarg); + } + + /* At this point, we have a long or short option matched at opt_offset into +@@ -812,13 +812,16 @@ int scanopt (svoid, arg, optindex) + + /* case: no args allowed */ + if (auxp->flags & ARG_NONE) { +- if (optarg) { ++ if (optarg && !is_short) { + scanopt_err (s, opt_offset, is_short, errcode = + SCANOPT_ERR_ARG_NOT_ALLOWED); + INC_INDEX (s, 1); + return errcode; + } +- INC_INDEX (s, 1); ++ else if (!optarg) ++ INC_INDEX (s, 1); ++ else ++ s->subscript++; + return optp->r_val; + } + diff --git a/flex-2.5.33-pic.patch b/flex-2.5.33-pic.patch new file mode 100644 index 0000000..7d66683 --- /dev/null +++ b/flex-2.5.33-pic.patch @@ -0,0 +1,13 @@ +Only in flex-2.5.33-pm: flex-2.5.33 +diff -urp flex-2.5.33/Makefile.in flex-2.5.33-pm/Makefile.in +--- flex-2.5.33/Makefile.in 2006-02-21 03:45:12.000000000 +0100 ++++ flex-2.5.33-pm/Makefile.in 2007-01-31 15:06:32.000000000 +0100 +@@ -292,6 +292,7 @@ SUBDIRS = \ + + localedir = $(datadir)/locale + AM_CPPFLAGS = -DLOCALEDIR=\"$(localedir)\" -I@includedir@ -I$(top_srcdir)/intl ++AM_CFLAGS = -fPIC + + # Run GNU indent on sources. Don't run this unless all the sources compile cleanly. + # +Only in flex-2.5.33-pm: Makefile.in~ diff --git a/flex-2.5.33-yy.patch b/flex-2.5.33-yy.patch new file mode 100644 index 0000000..c6bc5fe --- /dev/null +++ b/flex-2.5.33-yy.patch @@ -0,0 +1,76 @@ +diff -urp flex-2.5.33/flex.skl flex-2.5.33-pm/flex.skl +--- flex-2.5.33/flex.skl 2006-02-16 23:20:43.000000000 +0100 ++++ flex-2.5.33-pm/flex.skl 2007-03-30 14:04:42.000000000 +0200 +@@ -54,6 +54,34 @@ m4_changequote([[, ]]) + %# the generated scanner as a C-style comment. This is to aid those who + %# edit the skeleton. + %# ++ ++%not-for-header ++%if-c-only ++%if-not-reentrant ++m4_ifelse(M4_YY_PREFIX,yy,, ++#define yy_create_buffer M4_YY_PREFIX[[_create_buffer]] ++#define yy_delete_buffer M4_YY_PREFIX[[_delete_buffer]] ++#define yy_flex_debug M4_YY_PREFIX[[_flex_debug]] ++#define yy_init_buffer M4_YY_PREFIX[[_init_buffer]] ++#define yy_flush_buffer M4_YY_PREFIX[[_flush_buffer]] ++#define yy_load_buffer_state M4_YY_PREFIX[[_load_buffer_state]] ++#define yy_switch_to_buffer M4_YY_PREFIX[[_switch_to_buffer]] ++#define yyin M4_YY_PREFIX[[in]] ++#define yyleng M4_YY_PREFIX[[leng]] ++#define yylex M4_YY_PREFIX[[lex]] ++#define yylineno M4_YY_PREFIX[[lineno]] ++#define yyout M4_YY_PREFIX[[out]] ++#define yyrestart M4_YY_PREFIX[[restart]] ++#define yytext M4_YY_PREFIX[[text]] ++#define yywrap M4_YY_PREFIX[[wrap]] ++#define yyalloc M4_YY_PREFIX[[alloc]] ++#define yyrealloc M4_YY_PREFIX[[realloc]] ++#define yyfree M4_YY_PREFIX[[free]] ++) ++%endif ++%endif ++%ok-for-header ++ + #define FLEX_SCANNER + #define YY_FLEX_MAJOR_VERSION FLEX_MAJOR_VERSION + #define YY_FLEX_MINOR_VERSION FLEX_MINOR_VERSION +diff -urp flex-2.5.33/skel.c flex-2.5.33-pm/skel.c +--- flex-2.5.33/skel.c 2006-02-21 03:45:41.000000000 +0100 ++++ flex-2.5.33-pm/skel.c 2007-03-30 14:04:43.000000000 +0200 +@@ -59,6 +59,34 @@ const char *skel[] = { + "%# the generated scanner as a C-style comment. This is to aid those who", + "%# edit the skeleton.", + "%#", ++ "", ++ "%not-for-header", ++ "%if-c-only", ++ "%if-not-reentrant", ++ "m4_ifelse(M4_YY_PREFIX,yy,,", ++ "#define yy_create_buffer M4_YY_PREFIX[[_create_buffer]]", ++ "#define yy_delete_buffer M4_YY_PREFIX[[_delete_buffer]]", ++ "#define yy_flex_debug M4_YY_PREFIX[[_flex_debug]]", ++ "#define yy_init_buffer M4_YY_PREFIX[[_init_buffer]]", ++ "#define yy_flush_buffer M4_YY_PREFIX[[_flush_buffer]]", ++ "#define yy_load_buffer_state M4_YY_PREFIX[[_load_buffer_state]]", ++ "#define yy_switch_to_buffer M4_YY_PREFIX[[_switch_to_buffer]]", ++ "#define yyin M4_YY_PREFIX[[in]]", ++ "#define yyleng M4_YY_PREFIX[[leng]]", ++ "#define yylex M4_YY_PREFIX[[lex]]", ++ "#define yylineno M4_YY_PREFIX[[lineno]]", ++ "#define yyout M4_YY_PREFIX[[out]]", ++ "#define yyrestart M4_YY_PREFIX[[restart]]", ++ "#define yytext M4_YY_PREFIX[[text]]", ++ "#define yywrap M4_YY_PREFIX[[wrap]]", ++ "#define yyalloc M4_YY_PREFIX[[alloc]]", ++ "#define yyrealloc M4_YY_PREFIX[[realloc]]", ++ "#define yyfree M4_YY_PREFIX[[free]]", ++ ")", ++ "%endif", ++ "%endif", ++ "%ok-for-header", ++ "", + "#define FLEX_SCANNER", + "#define YY_FLEX_MAJOR_VERSION 2", + "#define YY_FLEX_MINOR_VERSION 5", diff --git a/flex-rh1389575.patch b/flex-rh1389575.patch deleted file mode 100644 index 9095626..0000000 --- a/flex-rh1389575.patch +++ /dev/null @@ -1,39 +0,0 @@ -This patch fixes a flex-2.6.4 build failure on x86_64 and possibly other -architectures where `size_t' is larger than `int'. The failure occurs as -follows: - -A missing `reallocarray' prototype during compilation means that the -compiler assumes an `int' return type. When compiling with `-pie' (standard -for Fedora), addresses on the heap can be larger than `int' can store. Thus, -pointers returned from `reallocarray' are truncated and any read/write to -them leads to a SIGSEGV. - -From 24fd0551333e7eded87b64dd36062da3df2f6380 Mon Sep 17 00:00:00 2001 -From: Explorer09 -Date: Mon, 4 Sep 2017 10:47:33 +0800 -Subject: [PATCH] build: AC_USE_SYSTEM_EXTENSIONS in configure.ac. - -This would, e.g. define _GNU_SOURCE in config.h, enabling the -reallocarray() prototype in glibc 2.26+ on Linux systems with that -version of glibc. - -Fixes #241. ---- - configure.ac | 2 ++ - 1 file changed, 2 insertions(+) - -Index: b/configure.ac -=================================================================== ---- a/configure.ac -+++ b/configure.ac -@@ -25,8 +25,10 @@ - # autoconf requirements and initialization - - AC_INIT([the fast lexical analyser generator],[2.6.4],[flex-help@lists.sourceforge.net],[flex]) -+AC_PREREQ([2.60]) - AC_CONFIG_SRCDIR([src/scan.l]) - AC_CONFIG_AUX_DIR([build-aux]) -+AC_USE_SYSTEM_EXTENSIONS - LT_INIT - AM_INIT_AUTOMAKE([1.11.3 -Wno-portability foreign check-news std-options dist-lzip parallel-tests subdir-objects]) - AC_CONFIG_HEADER([src/config.h]) diff --git a/flex.spec b/flex.spec index 90a52a3..bff8ce7 100644 --- a/flex.spec +++ b/flex.spec @@ -1,26 +1,20 @@ -%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}} - -Summary: A tool for generating scanners (text pattern recognizers) +Summary: A tool for creating scanners (text pattern recognizers) Name: flex -Version: 2.6.4 -Release: 20%{?dist} - -# An SPDX license string check done against flex-2.6.4 using fossology -# found strings corresponding to the licenses noted below across the flex -# source tree. -License: BSD-3-Clause-flex AND GPL-3.0-or-later WITH Autoconf-exception-generic-3.0 AND GPL-3.0-or-later WITH Bison-exception-2.2 AND GPL-3.0-or-later WITH Texinfo-exception AND FSFAP AND FSFUL AND FSFULLR AND FSFULLRWD AND GPL-2.0-or-later AND X11 - -URL: https://github.com/westes/flex -Source: https://github.com/westes/flex/releases/download/v%{version}/flex-%{version}.tar.gz - -Patch0: flex-rh1389575.patch - +Version: 2.5.33 +Release: 9%{?dist} +License: BSD +Group: Development/Tools +URL: http://flex.sourceforge.net/ +Source: flex-%{version}.tar.bz2 +Patch0: flex-2.5.33-pic.patch +Patch1: flex-2.5.33-yy.patch +Patch2: flex-2.5.33-opts.patch +Patch3: flex-2.5.33-includedir.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: m4 -BuildRequires: gettext gettext-devel bison m4 help2man gcc gcc-c++ automake libtool -BuildRequires: make - -Obsoletes: flex-doc < 2.6.4-8 -Provides: flex-doc = %{version}-%{release} +BuildRequires: gettext bison m4 +Requires(post): /sbin/install-info +Requires(preun): /sbin/install-info %description The flex program generates scanners. Scanners are programs which can @@ -36,65 +30,21 @@ build process. You should install flex if you are going to use your system for application development. -# We keep the libraries in separate sub-package to allow for multilib -# installations of flex. - -%define somajor 2 - -%package -n libfl%{somajor} -Summary: Libraries for the flex scanner generator - -%description -n libfl%{somajor} -flex is a tool for generating scanners. - -This package contains the shared library with default implementations of -`main' and `yywrap' functions that binaries using flex can choose to link -against instead of implementing on their own. - -%package -n libfl-devel -Summary: Development files for the flex scanner generator -Requires: libfl%{somajor} = %{version}-%{release} - -%description -n libfl-devel -flex is a tool for generating scanners. - -This package contains files required to build programs that use flex -libraries. - -%package -n libfl-static -Summary: Static libraries for the flex scanner generator -# We renamed flex-static to flex-devel in version 2.5.35-15: -Obsoletes: flex-static < 2.5.35-15 -Provides: flex-static = %{version}-%{release} -# We renamed flex-devel to libfl-static in version 2.6.4-6. This clarifies -# the nature of the package and brings us in line with naming used by SUSE -# and Debian: -Obsoletes: flex-devel < 2.6.4-6 -Provides: flex-devel = %{version}-%{release} - -%description -n libfl-static - -flex is a tool for generating scanners. - -This package contains the static library with default implementations of -`main' and `yywrap' functions that binaries using flex can choose to -statically link against instead of implementing their own. - %prep -%autosetup -p1 +%setup -q +%patch0 -p1 +%patch1 -p1 +%patch2 -p1 +%patch3 -p1 %build -autoreconf -i -%configure --docdir=%{_pkgdocdir} CFLAGS="-fPIC $RPM_OPT_FLAGS" +%configure --disable-dependency-tracking make %{?_smp_mflags} %install rm -rf $RPM_BUILD_ROOT make DESTDIR=$RPM_BUILD_ROOT install rm -f $RPM_BUILD_ROOT/%{_infodir}/dir -rm -f $RPM_BUILD_ROOT/%{_pkgdocdir}/{README.cvs,TODO,AUTHORS,COPYING,ONEWS} -# Exclude libtool archives (.la) as per Fedora packaging guidelines -find %{buildroot} -name '*.la' -delete ( cd ${RPM_BUILD_ROOT} ln -sf flex .%{_bindir}/lex @@ -106,303 +56,41 @@ find %{buildroot} -name '*.la' -delete %find_lang flex +%post +/sbin/install-info %{_infodir}/flex.info.gz --dir-file=%{_infodir}/dir ||: + +%preun +if [ $1 = 0 ]; then + /sbin/install-info --delete %{_infodir}/%{name}.info %{_infodir}/dir ||: +fi + %check echo ============TESTING=============== make check echo ============END TESTING=========== +%clean +rm -rf ${RPM_BUILD_ROOT} + %files -f flex.lang -%dir %{_pkgdocdir} -%license COPYING -%{_pkgdocdir}/NEWS -%{_pkgdocdir}/README.md +%defattr(-,root,root) +%doc COPYING NEWS README %{_bindir}/* %{_mandir}/man1/* +%{_libdir}/*.a %{_includedir}/FlexLexer.h %{_infodir}/flex.info* -%files -n libfl%{somajor} -%{_libdir}/libfl.so.%{somajor}* - -%files -n libfl-devel -%{_includedir}/FlexLexer.h -%{_libdir}/libfl.so - -%files -n libfl-static -%dir %{_pkgdocdir} -%license COPYING -%{_libdir}/*.a - %changelog -* Wed Jul 23 2025 Fedora Release Engineering - 2.6.4-20 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild - -* Thu Jan 16 2025 Fedora Release Engineering - 2.6.4-19 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild - -* Wed Jul 17 2024 Fedora Release Engineering - 2.6.4-18 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild - -* Tue Apr 23 2024 Arjun Shankar - 2.6.4-17 -- Provide flex-doc via the main flex package - -* Wed Jan 24 2024 Fedora Release Engineering - 2.6.4-16 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Fri Jan 19 2024 Fedora Release Engineering - 2.6.4-15 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild - -* Mon Oct 30 2023 Arjun Shankar - 2.6.4-14 -- Analyse flex sources for license information -- Migrate License field to SPDX identifiers for - https://fedoraproject.org/wiki/Changes/SPDX_Licenses_Phase_2 - (#2222083) - -* Wed Jul 19 2023 Fedora Release Engineering - 2.6.4-13 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild - -* Thu Jan 19 2023 Fedora Release Engineering - 2.6.4-12 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild - -* Thu Jul 21 2022 Fedora Release Engineering - 2.6.4-11 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild - -* Thu Jan 20 2022 Fedora Release Engineering - 2.6.4-10 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild - -* Wed Jul 21 2021 Fedora Release Engineering - 2.6.4-9 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild - -* Thu May 06 2021 Arjun Shankar - 2.6.4-8 -- Remove and obsolete the flex-doc subpackage; documention is provided in the - main package itself -- Specify versions in "Provides:" lines for flex-static and flex-devel - -* Tue Jan 26 2021 Fedora Release Engineering - 2.6.4-7 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild - -* Fri Aug 21 2020 Arjun Shankar - 2.6.4-6 -- Re-work flex subpackages and provide shared libraries (#1327851): -- Remove and obsolete the flex-devel subpackage containing static libraries -- Provide shared libraries in a new subpackage named libfl2 -- Provide development files in a new subpackage named libfl-devel -- Provide static libraries in a new subpackage named libfl-static - -* Mon Jul 27 2020 Fedora Release Engineering - 2.6.4-5 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - -* Tue Jan 28 2020 Fedora Release Engineering - 2.6.4-4 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild - -* Thu Jul 25 2019 Fedora Release Engineering - 2.6.4-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild - -* Thu Jan 31 2019 Fedora Release Engineering - 2.6.4-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild - -* Mon Sep 03 2018 Arjun Shankar - 2.6.4-1 -- Rebase to 2.6.4 -- Fix build failure due to missing include and `reallocarray' prototype -- Add gettext-devel, automake and libtool to build dependencies, and - execute `autoreconf -i' to regenerate files after patching configure.ac - -* Mon Jul 23 2018 Arjun Shankar - 2.6.1-10 -- Add gcc-c++ as a build-time requirement - -* Fri Jul 13 2018 Fedora Release Engineering - 2.6.1-9 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild - -* Wed Jun 27 2018 Arjun Shankar - 2.6.1-8 -- Remove g++ signed/unsigned comparison warning in generated scanner - -* Fri Feb 09 2018 Igor Gnatenko - 2.6.1-7 -- Escape macros in %%changelog - -* Wed Feb 07 2018 Fedora Release Engineering - 2.6.1-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild - -* Wed Aug 02 2017 Fedora Release Engineering - 2.6.1-5 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild - -* Wed Jul 26 2017 Fedora Release Engineering - 2.6.1-4 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild - -* Wed Feb 01 2017 Stephen Gallagher - 2.6.1-3 -- Add missing %%license macro - -* Sun Sep 25 2016 Patsy Franklin - 2.6.1-2 -- Fix several type comparison issues including BZ #1373601 - -* Tue Sep 13 2016 Rex Dieter - 2.6.1-1 -- Rebase to 2.6.1 (#1318074,#1364943) -- update URL (github), drop unused patches (#1238860) - -* Wed Jul 27 2016 Patsy Franklin - 2.6.0-2 - Fix wrong type on num_to_read. BZ #1360744 - -* Thu Mar 10 2016 Patsy Franklin - 2.6.0-1 -- Rebase to 2.6.0 -- Pick up an additional patch requested in BZ #1281976 - -* Wed Feb 03 2016 Fedora Release Engineering - 2.5.39-4 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild - -* Thu Oct 29 2015 Patsy Franklin - 2.5.39-3 -- Remove obsolete patches from git repository. (BZ #1238860) - -* Wed Jun 17 2015 Fedora Release Engineering - 2.5.39-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild - -* Mon Apr 13 2015 Patsy Franklin - 2.5.39-1 -- Rebase to 2.5.39 - -* Sat Aug 16 2014 Fedora Release Engineering - 2.5.37-8 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild - -* Sat Jul 19 2014 Ville Skyttä - 2.5.37-7 -- Make docdir unversioned where appropriate (#993754) -- Install docs to one common package doc dir, drop separate one for -doc -- Include COPYING in -devel -- Fix bogus dates in %%changelog - -* Sat Jun 07 2014 Fedora Release Engineering - 2.5.37-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild - -* Wed Apr 16 2014 Patsy Franklin - 2.5.37-5 -- Add a patch to remove obsolete bison constructs YYLEX_PARAM and - YYPARSE_PARAM. Use %%lex-param, %%parse-param, or %%param. - -* Tue Sep 3 2013 Petr Machata - 2.5.37-4 -- Add a patch for "comparison between signed and unsigned" warnings - that GCC produces when compiling flex-generated scanners - (flex-2.5.37-types.patch) - -* Sat Aug 03 2013 Fedora Release Engineering - 2.5.37-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild - -* Thu Apr 4 2013 Petr Machata - 2.5.37-2 -- Update config.sub and config.guess to support aarch64 - -* Wed Mar 20 2013 Petr Machata - 2.5.37-1 -- Rebase to 2.5.37 - -* Wed Feb 13 2013 Fedora Release Engineering - 2.5.36-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild - -* Fri Oct 26 2012 Petr Machata - 2.5.36-2 -- Bump for rebuild - -* Tue Jul 31 2012 Petr Machata - 2.5.36-1 -- Rebase to 2.5.36 - - Drop flex-2.5.35-sign.patch, flex-2.5.35-hardening.patch, - flex-2.5.35-gcc44.patch, flex-2.5.35-missing-prototypes.patch - - Add flex-2.5.36-bison-2.6.1.patch - - Add a subpackage doc -- Resolves #842073 - -* Thu Jul 19 2012 Fedora Release Engineering - 2.5.35-16 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild - -* Mon Mar 12 2012 Petr Machata - 2.5.35-15 -- Rename flex-static to flex-devel so that it gets to repositories of - minor multi-lib arch (i386 on x86_64 etc.) -- Resolves: #674301 - -* Fri Jan 13 2012 Fedora Release Engineering - 2.5.35-14 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild - -* Tue Feb 08 2011 Fedora Release Engineering - 2.5.35-13 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild - -* Tue Aug 17 2010 Petr Machata - 2.5.35-12 -- Drop the dependency of core package on flex-static. -- Resolves: #624549 - -* Wed Jul 14 2010 Petr Machata - 2.5.35-11 -- Forgot that the changes in flex.skl won't propagate to skel.c -- Resolves: #612465 - -* Tue Jul 13 2010 Petr Machata - 2.5.35-10 -- Declare yyget_column and yyset_column in reentrant mode. -- Resolves: #612465 - -* Wed Jan 20 2010 Petr Machata - 2.5.35-9 -- Move libraries into a sub-package of their own. - -* Tue Jan 12 2010 Petr Machata - 2.5.35-8 -- Add source URL - -* Mon Aug 24 2009 Petr Machata - 2.5.35-7 -- Fix installation with --excludedocs -- Resolves: #515928 - -* Fri Jul 24 2009 Fedora Release Engineering - 2.5.35-6 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild - -* Mon Apr 20 2009 Debarshi Ray - 2.5.35-5 -- Resolves: #496548. - -* Mon Apr 20 2009 Petr Machata - 2.5.35-4 -- Get rid of warning caused by ignoring return value of fwrite() in - ECHO macro. Debian patch. -- Resolves: #484961 - -* Tue Feb 24 2009 Fedora Release Engineering - 2.5.35-3 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild - -* Mon May 12 2008 Petr Machata - 2.5.35-2 -- Resolves: #445950 - -* Wed Feb 27 2008 Petr Machata - 2.5.35-1 -- Rebase to 2.5.35. Drop two patches. -- Resolves: #434961 -- Resolves: #435047 - -* Mon Feb 25 2008 Petr Machata - 2.5.34-1 -- Rebase to 2.5.34. Drop five patches. -- Resolves: #434676 - -* Mon Feb 11 2008 Petr Machata - 2.5.33-17 -- Generate prototypes for accessor functions. Upstream patch. -- Related: #432203 - -* Mon Feb 4 2008 Petr Machata - 2.5.33-16 -- Fix comparison between signed and unsigned in generated scanner. - Patch by Roland McGrath. -- Resolves: #431151 - -* Tue Jan 15 2008 Stepan Kasal - 2.5.33-15 -- Do not run autogen.sh, it undoes the effect of includedir patch. -- Adapt test-linedir-r.patch so that it fixes Makefile.in and works - even though autogen.sh is not run. - -* Thu Jan 10 2008 Stepan Kasal - 2.5.33-14 -- Insert the "-fPIC" on configure command-line. -- Drop the -fPIC patch. - -* Tue Jan 8 2008 Petr Machata - 2.5.33-13 -- Patch with -fPIC only after the autogen.sh is run. - -* Thu Jan 3 2008 Petr Machata - 2.5.33-12 -- Run autogen.sh before the rest of the build. -- Add BR autoconf automake gettext-devel. - -* Thu Aug 30 2007 Petr Machata - 2.5.33-11 -- Add BR gawk -- Fix use of awk in one of the tests - -* Wed Aug 29 2007 Fedora Release Engineering - 2.5.33-10 -- Rebuild for selinux ppc32 issue. - * Fri Jun 22 2007 Petr Machata - 2.5.33-9 - Remove wrong use of @includedir@ in Makefile.in. - Spec cleanups. -- Related: #225758 +- Resolves: #225758 * Fri Jun 22 2007 Petr Machata - 2.5.33-8 - Don't emit yy-prefixed variables in C++ mode. Thanks Srinivas Aji. -- Related: #242742 -- Related: #244259 +- Resolves: #242742 +- Resolves: #244259 * Fri May 11 2007 Petr Machata - 2.5.33-7 - Allow joining short options into one commandline argument. @@ -450,7 +138,7 @@ echo ============END TESTING=========== * Wed Mar 8 2006 Petr Machata - 2.5.4a-37.4 - adding test for #183098 into build process -* Thu Mar 2 2006 Petr Machata - 2.5.4a-37.3 +* Fri Mar 2 2006 Petr Machata - 2.5.4a-37.3 - rebuilt, no changes inside. In hunt for #183098 * Fri Feb 10 2006 Jesse Keating - 2.5.4a-37.2 @@ -459,7 +147,7 @@ echo ============END TESTING=========== * Tue Feb 07 2006 Jesse Keating - 2.5.4a-37.1 - rebuilt for new gcc4.1 snapshot and glibc changes -* Thu Feb 02 2006 Petr Machata 2.5.4a-37 +* Wed Feb 02 2006 Petr Machata 2.5.4a-37 - adding `make bigcheck' into build process. Refreshing initscan.c to make this possible. diff --git a/gating.yaml b/gating.yaml deleted file mode 100644 index ce3cdc1..0000000 --- a/gating.yaml +++ /dev/null @@ -1,19 +0,0 @@ ---- !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} ---- !Policy -product_versions: - - rhel-8 -decision_context: osci_compose_gate -rules: - - !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional} ---- !Policy -product_versions: - - rhel-9 -decision_context: osci_compose_gate -rules: - - !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional} diff --git a/gen-quilt-series.sh b/gen-quilt-series.sh deleted file mode 100755 index 6a2fc3a..0000000 --- a/gen-quilt-series.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -# Autogenerates the quilt `series` from the patch order in the spec file. -# We don't use `quilt setup` because it makes a huge mess and doesn't work. -component="flex" -rm -f series.new -extra_args="--fuzz=0" -count=0 -# Filter out the patches, and use `_` as our pseudo-IFS to prevent expansion. -for i in `grep '^%patch' flex.spec | sed -e 's,%patch,,g' -e 's, ,_,g'`; do - # Split the patch into number and arguments. - # 1 - Patch number. - # 2-N - Patch arguments. - # Get back our elements by undoing pseudo-IFS change. - elements=(`echo $i | sed -e 's,_, ,g'`) - num=${elements[0]} - args=${elements[@]:1} - # Find the next patch that applies in order and write it out. - # This way we transform the patch # list into a patch file list in order. - grep "Patch${num}: " flex.spec \ - | sed -e 's,Patch.*: ,,g' -e "s,\$, ${args[@]} ${extra_args},g" \ - | sed -e "s,%{name},${component},g" \ - >> series.new - ((count++)) -done -# Double check we processed the correct number of patches. -fcount=`wc -l series.new | sed -e 's, .*$,,g'` -if [ $fcount -ne $count ]; then - echo "Error! Processed patch count doesn't match spec file count ($fcount != $count)." - exit 1 -fi -echo "Processed $count patches." -mv series.new series -echo "Generated quilt ./series file. Please do not commit." -exit 0 diff --git a/plans/ci.fmf b/plans/ci.fmf deleted file mode 100644 index 3fd3ab7..0000000 --- a/plans/ci.fmf +++ /dev/null @@ -1,5 +0,0 @@ -summary: CI Gating Plan -discover: - how: fmf -execute: - how: tmt diff --git a/quilt-patch.sh b/quilt-patch.sh deleted file mode 100755 index ff55b53..0000000 --- a/quilt-patch.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/bash -# Patches are in the current directory. -export QUILT_PATCHES=$PWD -# Extract source file name from sources file, -# and assume it's the same name as the directory. -source=`awk -F '[() ]+' '/^[A-Z0-9]+ /{print $2}; /^[0-9a-f]+ /{print $2}' sources` -srcdir=${source%.tar.gz} -if [ "$1" == "-f" ] && [ -d "$srcdir" ]; then - echo Cleaning up $srcdir - rm -rf $srcdir -fi -if [ -d "$srcdir" ]; then - # Don't overwrite existing source directory. - echo "ERROR: Source directory $srcdir already exists. Use -f to force cleanup step." - exit 1 -fi -tar xvf $source -echo "Entering $srcdir" -pushd $srcdir -# Apply all patches. -quilt push -a -popd diff --git a/sources b/sources index 67236e5..ca96c58 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (flex-2.6.4.tar.gz) = e9785f3d620a204b7d20222888917dc065c2036cae28667065bf7862dfa1b25235095a12fd04efdbd09bfd17d3452e6b9ef953a8c1137862ff671c97132a082e +343374a00b38d9e39d1158b71af37150 flex-2.5.33.tar.bz2 diff --git a/tests/Sanity/smoke-check-flex-runs/Makefile b/tests/Sanity/smoke-check-flex-runs/Makefile deleted file mode 100644 index 3abe871..0000000 --- a/tests/Sanity/smoke-check-flex-runs/Makefile +++ /dev/null @@ -1,63 +0,0 @@ -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Makefile of /tools/flex/Sanity/smoke-check-flex-runs -# Description: Show your version. Build a one-file project. -# Author: Vaclav Kadlcik -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2015 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -export TEST=/tools/flex/Sanity/smoke-check-flex-runs -export TESTVERSION=1.0 - -BUILT_FILES= - -FILES=$(METADATA) runtest.sh Makefile PURPOSE count_chars_and_lines.l calc-lexer.l calc-grammar.y expected_calc_output.txt - -.PHONY: all install download clean - -run: $(FILES) build - ./runtest.sh - -build: $(BUILT_FILES) - test -x runtest.sh || chmod a+x runtest.sh - -clean: - rm -f *~ $(BUILT_FILES) - - -include /usr/share/rhts/lib/rhts-make.include - -$(METADATA): Makefile - @echo "Owner: Vaclav Kadlcik " > $(METADATA) - @echo "Name: $(TEST)" >> $(METADATA) - @echo "TestVersion: $(TESTVERSION)" >> $(METADATA) - @echo "Path: $(TEST_DIR)" >> $(METADATA) - @echo "Description: Show your version. Build a one-file project." >> $(METADATA) - @echo "Type: Sanity" >> $(METADATA) - @echo "TestTime: 15m" >> $(METADATA) - @echo "RunFor: flex" >> $(METADATA) - @echo "Requires: flex bison gcc" >> $(METADATA) - @echo "Priority: Normal" >> $(METADATA) - @echo "License: GPLv2+" >> $(METADATA) - @echo "Confidential: no" >> $(METADATA) - @echo "Destructive: no" >> $(METADATA) - @echo "Releases: -RHEL4 -RHELClient5 -RHELServer5" >> $(METADATA) - - rhts-lint $(METADATA) diff --git a/tests/Sanity/smoke-check-flex-runs/PURPOSE b/tests/Sanity/smoke-check-flex-runs/PURPOSE deleted file mode 100644 index ed0f21f..0000000 --- a/tests/Sanity/smoke-check-flex-runs/PURPOSE +++ /dev/null @@ -1,3 +0,0 @@ -PURPOSE of /tools/flex/Sanity/smoke-check-flex-runs -Description: Show your version. Build a one-file project. -Author: Vaclav Kadlcik diff --git a/tests/Sanity/smoke-check-flex-runs/calc-grammar.y b/tests/Sanity/smoke-check-flex-runs/calc-grammar.y deleted file mode 100644 index 53d4a85..0000000 --- a/tests/Sanity/smoke-check-flex-runs/calc-grammar.y +++ /dev/null @@ -1,36 +0,0 @@ -%{ -#include -%} - -%token NUMBER -%token ADD SUB MUL DIV -%token EOL - -%% - -input: - | input EOL { } - | input expression EOL { printf("%d\n", $2); } - ; - -expression: - factor - | expression ADD factor { $$ = $1 + $3; } - | expression SUB factor { $$ = $1 - $3; } - ; - -factor: - NUMBER - | factor MUL NUMBER { $$ = $1 * $3; } - | factor DIV NUMBER { $$ = $1 / $3; } - ; - -%% - -int main(int argc, char ** argv) { - yyparse(); -} - -yyerror(char *s) { - fprintf(stderr, "ERROR: %s\n", s); -} diff --git a/tests/Sanity/smoke-check-flex-runs/calc-lexer.l b/tests/Sanity/smoke-check-flex-runs/calc-lexer.l deleted file mode 100644 index fa9ac41..0000000 --- a/tests/Sanity/smoke-check-flex-runs/calc-lexer.l +++ /dev/null @@ -1,15 +0,0 @@ -%option noyywrap -%{ -#include "calc-grammar.tab.h" -%} - -%% -"+" { return ADD; } -"-" { return SUB; } -"*" { return MUL; } -"/" { return DIV; } -[0-9]+ { yylval = atoi(yytext); return NUMBER; } -\n { return EOL; } -[ \t] { /* ignore whitespaces */ } -. { yyerror("unexpected character %c", *yytext); } -%% diff --git a/tests/Sanity/smoke-check-flex-runs/count_chars_and_lines.l b/tests/Sanity/smoke-check-flex-runs/count_chars_and_lines.l deleted file mode 100644 index 7b90045..0000000 --- a/tests/Sanity/smoke-check-flex-runs/count_chars_and_lines.l +++ /dev/null @@ -1,21 +0,0 @@ -%option noyywrap -%{ -#include - -int chars = 0; -int lines = 0; -%} - -%% - -\n { lines++; chars++; } -. { chars++; } - -%% - -int main(int argc, char ** argv) { - yylex(); - printf("chars: %d\n", chars); - printf("lines: %d\n", lines); - return 0; -} diff --git a/tests/Sanity/smoke-check-flex-runs/expected_calc_output.txt b/tests/Sanity/smoke-check-flex-runs/expected_calc_output.txt deleted file mode 100644 index 7baa841..0000000 --- a/tests/Sanity/smoke-check-flex-runs/expected_calc_output.txt +++ /dev/null @@ -1,3 +0,0 @@ -STDOUT: 7 -STDOUT: -221 -STDOUT: 42 diff --git a/tests/Sanity/smoke-check-flex-runs/main.fmf b/tests/Sanity/smoke-check-flex-runs/main.fmf deleted file mode 100644 index 2b25e69..0000000 --- a/tests/Sanity/smoke-check-flex-runs/main.fmf +++ /dev/null @@ -1,15 +0,0 @@ -summary: Show your version. Build a one-file project. -description: '' -contact: -- Vaclav Kadlcik -component: -- flex -test: ./runtest.sh -framework: beakerlib -recommend: -- flex -- bison -- gcc -duration: 15m -extra-summary: /tools/flex/Sanity/smoke-check-flex-runs -extra-task: /tools/flex/Sanity/smoke-check-flex-runs diff --git a/tests/Sanity/smoke-check-flex-runs/runtest.sh b/tests/Sanity/smoke-check-flex-runs/runtest.sh deleted file mode 100755 index 68ee8a3..0000000 --- a/tests/Sanity/smoke-check-flex-runs/runtest.sh +++ /dev/null @@ -1,78 +0,0 @@ -#!/usr/bin/env bash -# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# runtest.sh of /tools/flex/Sanity/smoke-check-flex-runs -# Description: Show your version. Build a one-file project. -# Author: Vaclav Kadlcik -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -# -# Copyright (c) 2015 Red Hat, Inc. -# -# This program is free software: you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation, either version 2 of -# the License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be -# useful, but WITHOUT ANY WARRANTY; without even the implied -# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR -# PURPOSE. See the GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program. If not, see http://www.gnu.org/licenses/. -# -# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - -# Include Beaker environment -. /usr/share/beakerlib/beakerlib.sh || exit 1 - -PACKAGE="flex" - -rlJournalStart - rlPhaseStartSetup - rlAssertRpm $PACKAGE - yum -y install bison gcc - rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory" - rlRun "cp count_chars_and_lines.l calc-lexer.l calc-grammar.y expected_calc_output.txt $TmpDir" - rlRun "pushd $TmpDir" - rlPhaseEnd - - rlPhaseStartTest 'Show version' - - rlRun -t -s 'flex -V' - rlAssertNotGrep '^STDERR:' $rlRun_LOG - rlAssertGrep '^STDOUT: flex [0-9]' $rlRun_LOG - - rlPhaseEnd - - rlPhaseStartTest 'Flex works standalone' - - rlRun 'flex -o count_chars_and_lines.c count_chars_and_lines.l' - rlRun 'gcc -o count_chars_and_lines count_chars_and_lines.c' - rlAssertExists 'count_chars_and_lines' - rlRun -t -s 'echo -e "nazdar\nbazar" | ./count_chars_and_lines' - rlAssertNotGrep '^STDERR:' $rlRun_LOG - rlAssertGrep '^STDOUT: chars: 13$' $rlRun_LOG - rlAssertGrep '^STDOUT: lines: 2$' $rlRun_LOG - - rlPhaseEnd - - rlPhaseStartTest 'Flex works with Bison' - - rlRun 'bison -d calc-grammar.y' - rlRun 'flex calc-lexer.l' - rlRun 'gcc -o calc calc-grammar.tab.c lex.yy.c' - rlAssertExists 'calc' - rlRun -t -s 'echo -e "1 + 2 * 3\n1 - 666 / 3\n42" | ./calc' - rlAssertNotDiffer expected_calc_output.txt $rlRun_LOG - - rlPhaseEnd - - rlPhaseStartCleanup - rlRun "popd" - rlRun "rm -r $TmpDir" 0 "Removing tmp directory" - rlPhaseEnd -rlJournalPrintText -rlJournalEnd