Bug 99100 - rpm macros can be read from comment sections.
Summary: rpm macros can be read from comment sections.
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: rpm-build
Version: 9
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeff Johnson
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-07-14 15:27 UTC by William Hamish Bell
Modified: 2007-04-18 16:55 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2003-07-17 23:32:01 UTC
Embargoed:


Attachments (Terms of Use)

Description William Hamish Bell 2003-07-14 15:27:36 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Description of problem:
If a hapless spec file author has placed something like %prep within a comment
area of the spec file rpmbuild sees this as a second macro and exits with an
error.  Previous versions of rpm did not have this problem.

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

How reproducible:
Always

Steps to Reproduce:
1. Take a working spec file and put %prep within a comment before %prep
2. Try to rebuild the package.
3.
    

Actual Results:  You get an error that there is a second %prep at the line where
the real 
%prep target is given.

Expected Results:  rpmbuild should ignore the commented section and not check
within it for 
%prep or %install etc.

Additional info:

Comment 1 Jeff Johnson 2003-07-17 23:32:01 UTC
Yes. macros are expanded wherever they are found, and the
redhat-rpm-config package is now overloading %prep as a
(multiline) macro.

Either add an escaping '%' before %prep in a comment, or
erase the redhat-rpm-config package.


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