Bug 28648 - Make %patch use %__patch rather than hard-code 'patch'
Make %patch use %__patch rather than hard-code 'patch'
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Jeff Johnson
David Lawrence
: FutureFeature
Depends On:
  Show dependency treegraph
Reported: 2001-02-21 13:19 EST by Joe Orton
Modified: 2007-04-18 12:31 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-02-21 13:20:20 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Patch for %patch using %__patch (866 bytes, patch)
2001-02-21 13:20 EST, Joe Orton
no flags Details | Diff

  None (edit)
Description Joe Orton 2001-02-21 13:19:17 EST
This patch makes the %patch macro use the patch binary specified by the
%__patch macro, rather than just hard-coding 'patch'.

(maintainer has previously indicated that this patch is unacceptable, but
here it is anyway)
Comment 1 Joe Orton 2001-02-21 13:20:17 EST
Created attachment 10683 [details]
Patch for %patch using %__patch
Comment 2 Jeff Johnson 2001-02-22 13:11:35 EST
I can't change this without the risk (albeit small) of breaking legacy builds.

FWIW, what really needs doing is to rip out the existing %patchN and %setup
in C and use a macro expansion instead, it's just not that hard to write a line
of shell using macros. There would need to be some changes to the existing
macro expansion, specifically
	a) a hack to special case the "N" in %patchN token recognition
	b) a way to parse multiple occurences of -a and -b in %setup
	into a list.

Oh yeah, there's a small memory leak in your patch, rpmGetPath() return's

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