From 6cc8000e1491ed61cdaedbb9762ba225111c6000 Mon Sep 17 00:00:00 2001 From: Tomas Orsava Date: Fri, 6 Apr 2018 11:48:08 +0200 Subject: [PATCH] Fix the %py_dist_name macro ..to not convert dots (".") into dashes, so that submodules can be addressed as well Resolves: rhbz#1564095 --- macros.python-srpm | 2 +- python-rpm-macros.spec | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/macros.python-srpm b/macros.python-srpm index 38a71dc..397b4fa 100644 --- a/macros.python-srpm +++ b/macros.python-srpm @@ -17,7 +17,7 @@ # Converts Python dist name to a canonical format %py_dist_name() %{lua:\ name = rpm.expand("%{?1:%{1}}");\ - canonical = string.gsub(string.lower(name), "%W+", "-");\ + canonical = string.gsub(string.lower(name), "[^%w%.]+", "-");\ print(canonical);\ } diff --git a/python-rpm-macros.spec b/python-rpm-macros.spec index 8c095d9..b659771 100644 --- a/python-rpm-macros.spec +++ b/python-rpm-macros.spec @@ -1,6 +1,6 @@ Name: python-rpm-macros Version: 3 -Release: 27%{?dist} +Release: 28%{?dist} Summary: The unversioned Python RPM macros License: MIT @@ -69,6 +69,11 @@ install -m 644 %{SOURCE0} %{SOURCE1} %{SOURCE2} %{SOURCE3} \ %changelog +* Fri Apr 06 2018 Tomas Orsava - 3-28 +- Fix the %%py_dist_name macro to not convert dots (".") into dashes, so that + submodules can be addressed as well +Resolves: rhbz#1564095 + * Fri Mar 23 2018 Miro HronĨok - 3-27 - make LDFLAGS propagated whenever CFLAGS are