Bug 810851 - fix broken %if 0%{?fedora} conditionals
fix broken %if 0%{?fedora} conditionals
Product: Fedora
Classification: Fedora
Component: NetworkManager (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Dan Williams
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-04-09 08:02 EDT by Daniel Mach
Modified: 2012-04-10 03:54 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-04-10 03:54:35 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Daniel Mach 2012-04-09 08:02:42 EDT
If the "fedora" macro is not defined, then
0%{?fedora} < 17
is always true.

This leads to broken builds when building the package in different environments.
A good practice is to test if %fedora is set and only then proceed with the version comparison.

Can you apply following change to spec?
(there are 2 occurences of this problem):
-%if 0%{?fedora} < 17
+%if 0%{?fedora} && 0%{?fedora} < 17
Comment 1 Jirka Klimes 2012-04-10 03:54:35 EDT
Fixed both in rawhide and F17.

Note You need to log in before you can comment on or make changes to this bug.