Bug 116194 - Prefix directive silently redefines macro "prefix"
Summary: Prefix directive silently redefines macro "prefix"
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: rpm
Version: 3.0
Hardware: i686
OS: Linux
low
low
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact: Mike McLean
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-02-18 21:59 UTC by NN Poster
Modified: 2007-11-30 22:07 UTC (History)
1 user (show)

(edit)
Clone Of:
(edit)
Last Closed: 2004-02-19 10:19:24 UTC


Attachments (Terms of Use)

Description NN Poster 2004-02-18 21:59:08 UTC
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):
rpm-4.2.1-4.2

How reproducible:
always

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 10:19:24 UTC
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.