From 6266067b47747217519c7c38f4b514a046b51ac2b4c1d54aa3d868c7613f6668 Mon Sep 17 00:00:00 2001 From: Martin Pluskal Date: Tue, 6 Apr 2021 06:06:27 +0000 Subject: [PATCH] Accepting request 883105 from home:elvigia:branches:devel:tools:building - ninja-re2c-g.patch tell re2c to generate gcc specific code using the -g flag, this usually results in lexers that are 20-25% faster. OBS-URL: https://build.opensuse.org/request/show/883105 OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/ninja?expand=0&rev=55 --- ninja-re2c-g.patch | 11 +++++++++++ ninja.changes | 6 ++++++ ninja.spec | 3 ++- 3 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 ninja-re2c-g.patch diff --git a/ninja-re2c-g.patch b/ninja-re2c-g.patch new file mode 100644 index 0000000..7e47e82 --- /dev/null +++ b/ninja-re2c-g.patch @@ -0,0 +1,11 @@ +--- configure.py.orig ++++ configure.py +@@ -479,7 +479,7 @@ + return False + if has_re2c(): + n.rule('re2c', +- command='re2c -b -i --no-generation-date -o $out $in', ++ command='re2c -g -b -i --no-generation-date -o $out $in', + description='RE2C $out') + # Generate the .cc files in the source directory so we can check them in. + n.build(src('depfile_parser.cc'), 're2c', src('depfile_parser.in.cc')) diff --git a/ninja.changes b/ninja.changes index ffc419a..5bfe0fc 100644 --- a/ninja.changes +++ b/ninja.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Apr 5 21:51:58 UTC 2021 - Cristian Rodríguez + +- ninja-re2c-g.patch tell re2c to generate gcc specific code using + the -g flag, this usually results in lexers that are 20-25% faster. + ------------------------------------------------------------------- Tue Dec 29 18:55:10 UTC 2020 - Dirk Müller diff --git a/ninja.spec b/ninja.spec index 5f1d13d..1b5f61a 100644 --- a/ninja.spec +++ b/ninja.spec @@ -1,7 +1,7 @@ # # spec file for package ninja # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2021 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -26,6 +26,7 @@ URL: https://ninja-build.org/ Source0: https://github.com/ninja-build/ninja/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz Source1: macros.ninja Patch1: ninja-disable-maxprocs-test.patch +Patch2: ninja-re2c-g.patch BuildRequires: gcc-c++ BuildRequires: python3-base BuildRequires: re2c