diff --git a/0001-Work-around-mtime-being-set-to-0-sometimes.patch b/0001-Work-around-mtime-being-set-to-0-sometimes.patch new file mode 100644 index 0000000..f0a0703 --- /dev/null +++ b/0001-Work-around-mtime-being-set-to-0-sometimes.patch @@ -0,0 +1,28 @@ +From b34f744ac3c8276a854b134d41c28d84664c7e7f Mon Sep 17 00:00:00 2001 +From: Patrick Griffis +Date: Mon, 20 Mar 2017 21:46:42 -0400 +Subject: [PATCH] Work around mtime being set to 0 sometimes + +--- + src/disk_interface.cc | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/src/disk_interface.cc b/src/disk_interface.cc +index b418e04..28530b1 100644 +--- a/src/disk_interface.cc ++++ b/src/disk_interface.cc +@@ -187,6 +187,11 @@ TimeStamp RealDiskInterface::Stat(const string& path, string* err) const { + *err = "stat(" + path + "): " + strerror(errno); + return -1; + } ++ // Some users (Flatpak) set mtime to 0, this should be harmless ++ // and avoids conflicting with our return value of 0 meaning ++ // that it doesn't exist. ++ if (st.st_mtime == 0) ++ return 1; + return st.st_mtime; + #endif + } +-- +2.13.0 + diff --git a/ninja-build.spec b/ninja-build.spec index 68c7583..aae7b9c 100644 --- a/ninja-build.spec +++ b/ninja-build.spec @@ -1,12 +1,13 @@ Name: ninja-build Version: 1.7.2 -Release: 5%{?dist} +Release: 6%{?dist} Summary: A small build system with a focus on speed License: ASL 2.0 URL: http://martine.github.com/ninja/ Source0: https://github.com/martine/ninja/archive/v%{version}.tar.gz#/ninja-%{version}.tar.gz Source1: ninja.vim Source2: macros.ninja +Patch0001: 0001-Work-around-mtime-being-set-to-0-sometimes.patch Patch0002: 0002-Disable-test-which-takes-too-many-resources-for-koji.patch BuildRequires: gcc-c++ %if 0%{?rhel} && 0%{?rhel} <= 7 @@ -69,6 +70,9 @@ ln -s ninja %{buildroot}%{_bindir}/ninja-build %{rpmmacrodir}/macros.ninja %changelog +* Tue Aug 01 2017 Kalev Lember - 1.7.2-6 +- Backport an upstream patch to handle ostree setting 0 mtime + * Wed Jul 26 2017 Fedora Release Engineering - 1.7.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild