From ed4f631ae89906e998b1636012e57c8d076c77e2 Mon Sep 17 00:00:00 2001 From: Michal Moskal Date: Fri, 6 Jun 2003 09:50:11 +0000 Subject: [PATCH] - %with, %without, %ifwith %ifwithout macros added Changed files: rpm.macros -> 1.117 --- rpm.macros | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/rpm.macros b/rpm.macros index a247fc6..caa39d8 100644 --- a/rpm.macros +++ b/rpm.macros @@ -105,6 +105,14 @@ %ifdef() %if %{expand:%%{?%{1}:1}%%{!?%{1}:0}} %ifndef() %if %{expand:%%{?%{1}:0}%%{!?%{1}:1}} +# Shorthand for %{defined with_...} +%with() %{expand:%%{?with_%{1}:1}%%{!?with_%{1}:0}} +%without() %{expand:%%{?with_%{1}:0}%%{!?with_%{1}:1}} + +# Shorthand for %if %{with ...} +%ifwith() %if %{expand:%%{?with_%{1}:1}%%{!?with_%{1}:0}} +%ifwithout() %if %{expand:%%{?with_%{1}:0}%%{!?with_%{1}:1}} + # Handle conditional builds. %bcond_with is for case when feature is # default off and needs to be activated with --with ... command line # switch. %bcond_without is for the dual case. -- 2.44.0