@@ -146,25 +146,20 @@ def _default_to_zip(self):
146
146
]
147
147
148
148
# Define all the different requirements.
149
- dev_requires = get_content ("requirements-dev.txt" , splitlines = True )
150
- doc_requires = get_content ("requirements-doc.txt" , splitlines = True )
151
149
setup_requires = get_content ("requirements-setup.txt" , splitlines = True )
152
150
install_requires = get_content ("requirements.txt" , splitlines = True )
153
151
if sys .version_info [:2 ] == (3 , 2 ):
154
152
# Hack for Python 3.2 because pip < 8 cannot handle version markers.
155
- marker = '; python_version == "3.2"'
156
- dev_requires = [
157
- item .replace (marker , "" ) for item in dev_requires
158
- if item .endswith (marker ) or "python_version" not in item ]
159
- doc_requires = [
160
- item .replace (marker , "" ) for item in doc_requires
161
- if item .endswith (marker ) or "python_version" not in item ]
153
+ marker1 = '; python_version == "3.2"'
154
+ marker2 = '; python_version >= "2.7"'
162
155
setup_requires = [
163
- item .replace (marker , "" ) for item in setup_requires
164
- if item .endswith (marker ) or "python_version" not in item ]
156
+ item .replace (marker1 , "" ).replace (marker2 , "" ) for item in setup_requires
157
+ if item .endswith (marker1 ) or item .endswith (marker2 )
158
+ or "python_version" not in item ]
165
159
install_requires = [
166
- item .replace (marker , "" ) for item in install_requires
167
- if item .endswith (marker ) or "python_version" not in item ]
160
+ item .replace (marker1 , "" ).replace (marker2 , "" ) for item in install_requires
161
+ if item .endswith (marker1 ) or item .endswith (marker2 )
162
+ or "python_version" not in item ]
168
163
169
164
setup (** {
170
165
"name" :
@@ -228,10 +223,12 @@ def _default_to_zip(self):
228
223
"install_requires" :
229
224
install_requires ,
230
225
"extras_require" : {
231
- "dev" :
232
- dev_requires ,
233
226
"doc" :
234
- doc_requires ,
227
+ get_content ("requirements-doc.txt" , splitlines = True ),
228
+ "lint" :
229
+ get_content ("requirements-lint.txt" , splitlines = True ),
230
+ "test" :
231
+ get_content ("requirements-test.txt" , splitlines = True ),
235
232
},
236
233
"cmdclass" : {
237
234
"sdist" : basemap_sdist ,
0 commit comments