From b587b5da6bedb94ee46ee03deb6442a8bbe1e072 Mon Sep 17 00:00:00 2001 From: Chris Weyl Date: Wed, 19 Aug 2009 06:08:05 +0000 Subject: [PATCH] - add the filtering framework approved by the FPC/FESCo. (#516240) --- ...at-rpm-config-9.0.3-filtering-macros.patch | 40 +++++++++++++++++++ redhat-rpm-config.spec | 7 +++- 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 redhat-rpm-config-9.0.3-filtering-macros.patch diff --git a/redhat-rpm-config-9.0.3-filtering-macros.patch b/redhat-rpm-config-9.0.3-filtering-macros.patch new file mode 100644 index 0000000..c8102db --- /dev/null +++ b/redhat-rpm-config-9.0.3-filtering-macros.patch @@ -0,0 +1,40 @@ +--- redhat-rpm-config-9.0.3/macros.orig 2009-08-07 08:48:50.925412526 -0700 ++++ redhat-rpm-config-9.0.3/macros 2009-08-07 08:55:16.374536719 -0700 +@@ -224,3 +224,37 @@ + fi \ + kmp_override_filelist="$filelist" kmp_override_preamble="$preamble" kmp_nobuildreqs="$buildreqs" %{kmodtool} rpmtemplate_kmp %{-n*}%{!-n:%name} %{kverrel} $flavors_to_build 2>/dev/null \ + )} ++ ++#============================================================================== ++# ---- Generic auto req/prov filtering macros ++# ++# http://fedoraproject.org/wiki/PackagingDrafts/AutoProvidesAndRequiresFiltering ++ ++# prevent anything matching from being scanned for provides ++%filter_provides_in(P) %{expand: \ ++%global __filter_prov_cmd %{?__filter_prov_cmd} %{__grep} -v %{-P} '%*' | \ ++} ++ ++# prevent anything matching from being scanned for requires ++%filter_requires_in(P) %{expand: \ ++%global __filter_req_cmd %{?__filter_req_cmd} %{__grep} -v %{-P} '%*' | \ ++} ++ ++# filter anything matching out of the provides stream ++%filter_from_provides() %{expand: \ ++%global __filter_from_prov %{?__filter_from_prov} | %{__sed} -e '%*' \ ++} ++ ++# filter anything matching out of the requires stream ++%filter_from_requires() %{expand: \ ++%global __filter_from_req %{?__filter_from_req} | %{__sed} -e '%*' \ ++} ++ ++# actually set up the filtering bits ++%filter_setup %{expand: \ ++%global _use_internal_dependency_generator 0 \ ++%global __deploop() while read FILE; do /usr/lib/rpm/rpmdeps -%{1} ${FILE}; done | /bin/sort -u \ ++%global __find_provides /bin/sh -c "%{?__filter_prov_cmd} %{__deploop P} %{?__filter_from_prov}" \ ++%global __find_requires /bin/sh -c "%{?__filter_req_cmd} %{__deploop R} %{?__filter_from_req}" \ ++} ++ diff --git a/redhat-rpm-config.spec b/redhat-rpm-config.spec index 887c0cf..b2485e4 100644 --- a/redhat-rpm-config.spec +++ b/redhat-rpm-config.spec @@ -1,7 +1,7 @@ Summary: Red Hat specific rpm configuration files. Name: redhat-rpm-config Version: 9.0.3 -Release: 15%{?dist} +Release: 16%{?dist} # No version specified. License: GPL+ Group: Development/System @@ -15,6 +15,7 @@ Patch5: redhat-rpm-config-9.0.3-always_delete_buildroot_at_install.patch Patch6: redhat-rpm-config-9.0.3-xz-payload.patch Patch7: redhat-rpm-config-9.0.3-jars-with-spaces.patch Patch8: redhat-rpm-config-9.0.3-brpssa-speedup.patch +Patch9: redhat-rpm-config-9.0.3-filtering-macros.patch BuildArch: noarch Requires: mktemp BuildRoot: %{_tmppath}/%{name}-root @@ -33,6 +34,7 @@ Red Hat specific rpm configuration files. %patch6 -p1 %patch7 -p5 %patch8 -p1 +%patch9 -p1 %install make DESTDIR=${RPM_BUILD_ROOT} install @@ -45,6 +47,9 @@ rm -rf ${RPM_BUILD_ROOT} %{_prefix}/lib/rpm/redhat %changelog +* Tue Aug 18 2009 Chris Weyl 9.0.3-16 +- add the filtering framework approved by the FPC/FESCo. (#516240) + * Thu Aug 13 2009 Adam Jackson 9.0.3-15 - redhat-rpm-config-9.0.4-brpssa-speedup.patch: When looking for static archives, only run file(1) on files named *.a. (#517101)