Skip to content

Commit 2030b70

Browse files
committed
only include the pycache files for the built module
1 parent 6eb769a commit 2030b70

File tree

5 files changed

+5
-5
lines changed

5 files changed

+5
-5
lines changed

pyp2rpm/templates/epel6.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ popd
119119
{%- for module in data.py_modules -%}
120120
{%- if pv == '3' %}
121121
%dir %{python{{ pv }}_sitelib}/__pycache__/
122-
%{python{{ pv }}_sitelib}/__pycache__/*
122+
%{python{{ pv }}_sitelib}/__pycache__/{{ data.name | module_to_path(module) }}.*
123123
{%- endif %}
124124
%{python{{ pv }}_sitelib}/{{ data.name | module_to_path(module) }}.py{% if pv != '3'%}*{% endif %}
125125
{%- endfor %}

pyp2rpm/templates/epel7.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ rm -rf %{buildroot}%{_bindir}/*
8787
{%- for module in data.py_modules -%}
8888
{%- if pv == '3' %}
8989
%dir %{python{{ pv }}_sitelib}/__pycache__/
90-
%{python{{ pv }}_sitelib}/__pycache__/*
90+
%{python{{ pv }}_sitelib}/__pycache__/{{ data.name | module_to_path(module) }}.*
9191
{%- endif %}
9292
%{python{{ pv }}_sitelib}/{{ data.name | module_to_path(module) }}.py{% if pv != '3'%}*{% endif %}
9393
{%- endfor %}

pyp2rpm/templates/fedora.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ rm -rf %{buildroot}%{_bindir}/*
9090
{%- if data.py_modules %}
9191
{%- for module in data.py_modules -%}
9292
{%- if pv == '3' %}
93-
%{python{{ pv }}_sitelib}/__pycache__/*
93+
%{python{{ pv }}_sitelib}/__pycache__/{{ data.name | module_to_path(module) }}.*
9494
{%- endif %}
9595
%{python{{ pv }}_sitelib}/{{ data.name | module_to_path(module) }}.py{% if pv != '3'%}*{% endif %}
9696
{%- endfor %}

pyp2rpm/templates/mageia.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ rm -rf %{buildroot}%{_bindir}/*
9090
{%- if data.py_modules %}
9191
{%- for module in data.py_modules -%}
9292
{%- if pv == '3' %}
93-
%{python{{ pv }}_sitelib}/__pycache__/*
93+
%{python{{ pv }}_sitelib}/__pycache__/{{ data.name | module_to_path(module) }}.*
9494
{%- endif %}
9595
%{python{{ pv }}_sitelib}/{{ data.name | module_to_path(module) }}.py{% if pv != '3'%}*{% endif %}
9696
{%- endfor %}

pyp2rpm/templates/pld.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ rm -rf $RPM_BUILD_ROOT
141141
{%- endif %}
142142
{%- if pv == '3' -%}
143143
%{py{{ v }}_sitescriptdir}/{{ data.name | module_to_path(module) }}.py
144-
%{py{{ v }}_sitescriptdir}/__pycache__/*
144+
%{py{{ v }}_sitescriptdir}/__pycache__/{{ data.name | module_to_path(module) }}.*
145145
{%- endif %}
146146
{%- endfor %}
147147
{%- endif %}

0 commit comments

Comments
 (0)