#1 Import upstream fix for build failure from missing docs
Closed 5 years ago by ignatenkobrain. Opened 5 years ago by jstanek.
rpms/ jstanek/rust-cfg-if master  into  master

@@ -0,0 +1,34 @@ 

+ With cargo 1.33+, the crate refuses to compile without documentation

+ for the exported macro. This is upstream fix for that issue.

+ 

+ https://github.com/alexcrichton/cfg-if/commit/5cd2f3066c344415c61e0bd91f23820ec413e49e

+ 

+ From 5cd2f3066c344415c61e0bd91f23820ec413e49e Mon Sep 17 00:00:00 2001

+ From: Alex Crichton <alex@alexcrichton.com>

+ Date: Fri, 11 Jan 2019 09:02:32 -0800

+ Subject: [PATCH] Document macro

+ MIME-Version: 1.0

+ Content-Type: text/plain; charset=UTF-8

+ Content-Transfer-Encoding: 8bit

+ 

+ Signed-off-by: Jan Staněk <jstanek@redhat.com>

+ ---

+  src/lib.rs | 2 ++

+  1 file changed, 2 insertions(+)

+ 

+ diff --git a/src/lib.rs b/src/lib.rs

+ index ff144f6..e867e65 100644

+ --- a/src/lib.rs

+ +++ b/src/lib.rs

+ @@ -32,6 +32,8 @@

+  #![deny(missing_docs)]

+  #![cfg_attr(test, deny(warnings))]

+ 

+ +/// The main macro provided by this crate. See crate documentation for more

+ +/// information.

+  #[macro_export(local_inner_macros)]

+  macro_rules! cfg_if {

+      // match if/else chains with a final `else`

+ --

+ 2.20.1

+ 

file modified
+6 -1
@@ -7,13 +7,15 @@ 

  

  Name:           rust-%{crate}

  Version:        0.1.6

- Release:        4%{?dist}

+ Release:        5%{?dist}

  Summary:        Macro to ergonomically define an item depending on a large number of #[cfg] parameters

  

  # Upstream license specification: MIT/Apache-2.0

  License:        MIT or ASL 2.0

  URL:            https://crates.io/crates/cfg-if

  Source0:        https://crates.io/api/v1/crates/%{crate}/%{version}/download#/%{crate}-%{version}.crate

+ # Patch descriptions are in the respective files

+ Patch0:         0001-Document-macro.patch

  

  ExclusiveArch:  %{rust_arches}

  
@@ -68,6 +70,9 @@ 

  %endif

  

  %changelog

+ * Mon Mar 04 2019 Jan Staněk <jstanek@redhat.com> - 0.1.6-5

+ - Import upstream fix for build failure from missing docs

+ 

  * Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.1.6-4

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild

  

With cargo 1.33+, the #![deny(missing_docs)] apparently applies to macros too, which causes FTBFS for this crate (example build failure).

This PR imports the upstream commit that adds a documentation comment to fix this issue.

it would be great, if description would have link to upstream commit/pr and patch name would be created by git format-patch

1 new commit added

  • Improve patch name and description
5 years ago

@ignatenkobrain Better? I have run the suggested git format-patch on the upstream repo (in place of manual wgeting of said patch). The description is still in the patch file, enhanced with the commit URL.

Pull-Request has been closed by ignatenkobrain

5 years ago