Bug 159556

Summary: Parsing code inside comments
Product: [Fedora] Fedora Reporter: Jan Kratochvil <jan>
Component: rpmAssignee: Paul Nasrat <nobody+pnasrat>
Status: CLOSED WONTFIX QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 4CC: n3npq
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2005-08-27 02:22:45 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Kratochvil 2005-06-04 01:55:58 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20050513 Galeon/1.3.21

Description of problem:
The following first lines of the .spec file will create "arm" package.
Despite the line is commented.

# Lace:
# Do not: %define _target_cpu arm
# as rpm assumes 'target_platform' as the '_build'.
%define _prefix /usr/local/XYZZY-%{_vendor}-%{_target_os}


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

How reproducible:
Always

Steps to Reproduce:
1. Prepend the text to the .spec file as above.
2. Type rpmbuild -bb x.spec


Actual Results:  Package gets created in RPMS/arm/... etc.


Expected Results:  Package gets created in RPMS/i386/...


Additional info:

Comment 1 Jeff Johnson 2005-08-27 02:22:45 UTC
Macros are context free, are expanded everwhere they are found, inside strinsg, in comments, everywhere.

Do this instead (note doubled % to escape expansion):

# Do not: %%define _target_cpu arm