Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 116194 - Prefix directive silently redefines macro "prefix"
Prefix directive silently redefines macro "prefix"
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: rpm (Show other bugs)
i686 Linux
low Severity low
: ---
: ---
Assigned To: Jeff Johnson
Mike McLean
Depends On:
  Show dependency treegraph
Reported: 2004-02-18 16:59 EST by NN Poster
Modified: 2007-11-30 17:07 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2004-02-19 05:19:24 EST
Type: ---
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 NN Poster 2004-02-18 16:59:08 EST
Description of problem:
Use of "Prefix: /foo" will silently redefine macro %{prefix} 
to "/foo". This seems like either a bug or a bad idea because the 
macro is not "_prefix" or "__prefix", just a plain "prefix", hence it 
is not expected that it gets manipulated behind the scenes. (See Red 
Hat RPM Guide, p.305)

Also, this feature is not documented in Red Hat RPM Guide, p.222)

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.  %define prefix /foo
2.  Prefix: %{prefix}
3.  Prefix: /anotherprefix
4.  %{error: value is %{prefix}}

Actual results:
error:  value is /anotherprefix

Expected results:
error:  value is /foo

Additional info:
Comment 1 Jeff Johnson 2004-02-19 05:19:24 EST
rpm has always associated macros with tags like Prefix:, and cannot
be changed without breaking some build somewhere.

Whether this a good/bad/documented behavior is a different question.

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