From ab2647a5cd12c7a8a6fa560eea454c83db42fde3 Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Tue, 11 Sep 2018 08:40:33 +0200 Subject: [PATCH] Bump syn to 0.14 Signed-off-by: Igor Gnatenko --- 0001-Update-to-syn-0.13.patch | 9 +++++---- 0002-Update-to-syn-0.14.patch | 30 ++++++++++++++++++++++++++++ rust-version-sync.spec | 16 ++++++++------- version-sync-0.5.0-fix-metadata.diff | 11 ---------- version-sync-fix-metadata.diff | 11 ++++++++++ 5 files changed, 55 insertions(+), 22 deletions(-) create mode 100644 0002-Update-to-syn-0.14.patch delete mode 100644 version-sync-0.5.0-fix-metadata.diff create mode 100644 version-sync-fix-metadata.diff diff --git a/0001-Update-to-syn-0.13.patch b/0001-Update-to-syn-0.13.patch index 748c910..e07dfd0 100644 --- a/0001-Update-to-syn-0.13.patch +++ b/0001-Update-to-syn-0.13.patch @@ -1,14 +1,15 @@ -From 6c243140aead31bfca3af7bb4af9e5df16fe83f4 Mon Sep 17 00:00:00 2001 +From 559c05428cdb6ff1124e15f5efad34b9e14e1534 Mon Sep 17 00:00:00 2001 From: Josh Stone Date: Tue, 17 Apr 2018 14:52:51 -0700 -Subject: [PATCH] Update to syn 0.13 +Subject: [PATCH 1/2] Update to syn 0.13 +(cherry picked from commit 6c243140aead31bfca3af7bb4af9e5df16fe83f4) --- src/lib.rs | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/src/lib.rs b/src/lib.rs -index 09d41e58eae4..4e98771e8627 100644 +index 09d41e5..4e98771 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -398,17 +398,19 @@ pub fn check_html_root_url(path: &str, pkg_name: &str, pkg_version: &str) -> Res @@ -69,5 +70,5 @@ index 09d41e58eae4..4e98771e8627 100644 } _ => continue, -- -2.17.0 +2.19.0.rc1 diff --git a/0002-Update-to-syn-0.14.patch b/0002-Update-to-syn-0.14.patch new file mode 100644 index 0000000..0e1c6c6 --- /dev/null +++ b/0002-Update-to-syn-0.14.patch @@ -0,0 +1,30 @@ +From 441bd2296af2d5735f413dac0162939d795aa6f1 Mon Sep 17 00:00:00 2001 +From: Jonas Schievink +Date: Sun, 29 Jul 2018 17:31:38 +0200 +Subject: [PATCH 2/2] Update to syn 0.14 + +syn wasn't able to parse my lib.rs, likely because it didn't support +statement attributes. This should fix that, and it even makes a piece of +code slightly simpler. + +(cherry picked from commit d25c08aa8c29cb71b9522c62f2352dbf1f2f5d83) +--- + src/lib.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/lib.rs b/src/lib.rs +index 4e98771..116d558 100644 +--- a/src/lib.rs ++++ b/src/lib.rs +@@ -414,7 +414,7 @@ pub fn check_html_root_url(path: &str, pkg_name: &str, pkg_version: &str) -> Res + _ => continue, + }; + +- if ident.as_ref() != "doc" { ++ if ident != "doc" { + continue; + } + +-- +2.19.0.rc1 + diff --git a/rust-version-sync.spec b/rust-version-sync.spec index 599a496..7334159 100644 --- a/rust-version-sync.spec +++ b/rust-version-sync.spec @@ -6,18 +6,17 @@ Name: rust-%{crate} Version: 0.5.0 -Release: 6%{?dist} +Release: 7%{?dist} Summary: Simple crate for ensuring that version numbers in README files are updated License: MIT URL: https://crates.io/crates/version-sync Source0: https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate # Initial patched metadata -# * Bump syn to 0.13 -Patch0: version-sync-0.5.0-fix-metadata.diff - -# https://github.com/mgeisler/version-sync/pull/36 -Patch1: 0001-Update-to-syn-0.13.patch +# * Bump syn to 0.14 +Patch0: version-sync-fix-metadata.diff +Patch0001: 0001-Update-to-syn-0.13.patch +Patch0002: 0002-Update-to-syn-0.14.patch ExclusiveArch: %{rust_arches} @@ -26,7 +25,7 @@ BuildRequires: rust-packaging BuildRequires: (crate(itertools) >= 0.7.0 with crate(itertools) < 0.8.0) BuildRequires: (crate(pulldown-cmark) >= 0.1.0 with crate(pulldown-cmark) < 0.2.0) BuildRequires: (crate(semver-parser) >= 0.7.0 with crate(semver-parser) < 0.8.0) -BuildRequires: ((crate(syn) >= 0.13.0 with crate(syn) < 0.14.0) with crate(syn/full)) +BuildRequires: ((crate(syn) >= 0.14.0 with crate(syn) < 0.15.0) with crate(syn/full)) BuildRequires: (crate(toml) >= 0.4.0 with crate(toml) < 0.5.0) BuildRequires: (crate(url) >= 1.5.1 with crate(url) < 2.0.0) @@ -65,6 +64,9 @@ which use %{crate} from crates.io. %{cargo_registry}/%{crate}-%{version}/ %changelog +* Tue Sep 11 2018 Igor Gnatenko - 0.5.0-7 +- Bump syn to 0.14 + * Sat Jul 14 2018 Fedora Release Engineering - 0.5.0-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild diff --git a/version-sync-0.5.0-fix-metadata.diff b/version-sync-0.5.0-fix-metadata.diff deleted file mode 100644 index 196264e..0000000 --- a/version-sync-0.5.0-fix-metadata.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- version-sync-0.5.0/Cargo.toml 1969-12-31T16:00:00-08:00 -+++ version-sync-0.5.0/Cargo.toml 2018-04-17T14:57:46.167356-07:00 -@@ -33,7 +33,7 @@ - version = "0.7" - - [dependencies.syn] --version = "0.11" -+version = "0.13" - features = ["full"] - - [dependencies.toml] diff --git a/version-sync-fix-metadata.diff b/version-sync-fix-metadata.diff new file mode 100644 index 0000000..d48388d --- /dev/null +++ b/version-sync-fix-metadata.diff @@ -0,0 +1,11 @@ +--- version-sync-0.5.0/Cargo.toml 1970-01-01T01:00:00+01:00 ++++ version-sync-0.5.0/Cargo.toml 2018-09-11T08:37:10.622525+02:00 +@@ -33,7 +33,7 @@ + version = "0.7" + + [dependencies.syn] +-version = "0.11" ++version = "0.14" + features = ["full"] + + [dependencies.toml]