projects
/
tools
/
librpm-tizen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9cd34fc
)
Enable built-in %dirname macro
author
Panu Matilainen
<pmatilai@redhat.com>
Thu, 1 Nov 2012 10:09:30 +0000
(12:09 +0200)
committer
Panu Matilainen
<pmatilai@redhat.com>
Thu, 1 Nov 2012 10:12:51 +0000
(12:12 +0200)
- This might've clashed with %dir in spec %files at some point as
indicated by the comments, but that should no longer be the case.
rpmio/macro.c
patch
|
blob
|
history
diff --git
a/rpmio/macro.c
b/rpmio/macro.c
index
e5a3463
..
f7954b3
100644
(file)
--- a/
rpmio/macro.c
+++ b/
rpmio/macro.c
@@
-919,13
+919,10
@@
doFoo(MacroBuf mb, int negate, const char * f, size_t fn,
b = buf;
else
b++;
-#if NOTYET
- /* XXX watchout for conflict with %dir */
} else if (STREQ("dirname", f, fn)) {
if ((b = strrchr(buf, '/')) != NULL)
*b = '\0';
b = buf;
-#endif
} else if (STREQ("suffix", f, fn)) {
if ((b = strrchr(buf, '.')) != NULL)
b++;
@@
-1256,6
+1253,7
@@
expandMacro(MacroBuf mb, const char *src, size_t slen)
/* XXX necessary but clunky */
if (STREQ("basename", f, fn) ||
+ STREQ("dirname", f, fn) ||
STREQ("suffix", f, fn) ||
STREQ("expand", f, fn) ||
STREQ("verbose", f, fn) ||