|
13 | 13 | from pip._internal.operations.build.wheel import build_wheel_pep517
|
14 | 14 | from pip._internal.operations.build.wheel_legacy import build_wheel_legacy
|
15 | 15 | from pip._internal.utils.logging import indent_log
|
16 |
| -from pip._internal.utils.marker_files import has_delete_marker_file |
17 | 16 | from pip._internal.utils.misc import ensure_dir, hash_file
|
18 | 17 | from pip._internal.utils.setuptools_build import make_setuptools_clean_args
|
19 | 18 | from pip._internal.utils.subprocess import call_subprocess
|
20 | 19 | from pip._internal.utils.temp_dir import TempDirectory
|
21 | 20 | from pip._internal.utils.typing import MYPY_CHECK_RUNNING
|
22 |
| -from pip._internal.utils.unpacking import unpack_file |
23 | 21 | from pip._internal.utils.urls import path_to_url
|
24 | 22 | from pip._internal.vcs import vcs
|
25 | 23 |
|
@@ -313,27 +311,6 @@ def build(
|
313 | 311 | req.link = Link(path_to_url(wheel_file))
|
314 | 312 | req.local_file_path = req.link.file_path
|
315 | 313 | assert req.link.is_wheel
|
316 |
| - if should_unpack: |
317 |
| - # XXX: This is mildly duplicative with prepare_files, |
318 |
| - # but not close enough to pull out to a single common |
319 |
| - # method. |
320 |
| - # The code below assumes temporary source dirs - |
321 |
| - # prevent it doing bad things. |
322 |
| - if ( |
323 |
| - req.source_dir and |
324 |
| - not has_delete_marker_file(req.source_dir) |
325 |
| - ): |
326 |
| - raise AssertionError( |
327 |
| - "bad source dir - missing marker") |
328 |
| - # Delete the source we built the wheel from |
329 |
| - req.remove_temporary_source() |
330 |
| - # set the build directory again - name is known from |
331 |
| - # the work prepare_files did. |
332 |
| - req.source_dir = req.ensure_build_location( |
333 |
| - self.preparer.build_dir |
334 |
| - ) |
335 |
| - # extract the wheel into the dir |
336 |
| - unpack_file(req.link.file_path, req.source_dir) |
337 | 314 | build_successes.append(req)
|
338 | 315 | else:
|
339 | 316 | build_failures.append(req)
|
|
0 commit comments