File tree Expand file tree Collapse file tree 2 files changed +5
-13
lines changed Expand file tree Collapse file tree 2 files changed +5
-13
lines changed Original file line number Diff line number Diff line change 1+ There are some setuptools specific changes in the
2+ `setuptools.command.bdist_rpm ` module that are no longer needed, because
3+ they are part of the `bdist_rpm ` module in distutils in Python
4+ 3.5.0. Therefore, code was removed from `setuptools.command.bdist_rpm `.
Original file line number Diff line number Diff line change @@ -8,8 +8,6 @@ class bdist_rpm(orig.bdist_rpm):
88 1. Run egg_info to ensure the name and version are properly calculated.
99 2. Always run 'install' using --single-version-externally-managed to
1010 disable eggs in RPM distributions.
11- 3. Replace dash with underscore in the version numbers for better RPM
12- compatibility.
1311 """
1412
1513 def run (self ):
@@ -19,25 +17,15 @@ def run(self):
1917 orig .bdist_rpm .run (self )
2018
2119 def _make_spec_file (self ):
22- version = self .distribution .get_version ()
23- rpmversion = version .replace ('-' , '_' )
2420 spec = orig .bdist_rpm ._make_spec_file (self )
25- line23 = '%define version ' + version
26- line24 = '%define version ' + rpmversion
2721 spec = [
2822 line .replace (
29- "Source0: %{name}-%{version}.tar" ,
30- "Source0: %{name}-%{unmangled_version}.tar"
31- ).replace (
3223 "setup.py install " ,
3324 "setup.py install --single-version-externally-managed "
3425 ).replace (
3526 "%setup" ,
3627 "%setup -n %{name}-%{unmangled_version}"
37- ). replace ( line23 , line24 )
28+ )
3829 for line in spec
3930 ]
40- insert_loc = spec .index (line24 ) + 1
41- unmangled_version = "%define unmangled_version " + version
42- spec .insert (insert_loc , unmangled_version )
4331 return spec
You can’t perform that action at this time.
0 commit comments