Make %py3_dist respect %python3_pkgversion
By default, %{py3_dist foo} generates python3dist(foo).
This change makes it respect %python3_pkgversion so when
it is redefined as X.Y, %{py3_dist foo} generates pythonX.Y(foo).
This commit is contained in:
parent
06ee391993
commit
638f809f4c
3 changed files with 10 additions and 2 deletions
|
|
@ -90,6 +90,7 @@
|
|||
# Needs to first put all arguments into a list, because invoking a different
|
||||
# macro (%py_dist_name) overwrites them
|
||||
%py3_dist() %{lua:\
|
||||
python3_pkgversion = rpm.expand("%python3_pkgversion");\
|
||||
args = {}\
|
||||
arg = 1\
|
||||
while (true) do\
|
||||
|
|
@ -102,7 +103,7 @@
|
|||
end\
|
||||
for arg, name in ipairs(args) do\
|
||||
canonical = rpm.expand("%py_dist_name " .. name);\
|
||||
print("python3dist(" .. canonical .. ") ");\
|
||||
print("python" .. python3_pkgversion .. "dist(" .. canonical .. ") ");\
|
||||
end\
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue