Skip to content

Commit 4b41aa4

Browse files
dnicolodirgommers
authored andcommitted
MAINT: tiny simplification for _WheelBuilder._install_path()
This will matter later when intall_path() will get an absolute path into the installation directory rather than a path into the source or build directory.
1 parent 2efa7f1 commit 4b41aa4

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

mesonpy/__init__.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -425,7 +425,6 @@ def _is_native(self, file: Union[str, pathlib.Path]) -> bool:
425425
def _install_path( # noqa: C901
426426
self,
427427
wheel_file: mesonpy._wheelfile.WheelFile,
428-
counter: mesonpy._util.CLICounter,
429428
origin: Path,
430429
destination: pathlib.Path,
431430
) -> None:
@@ -436,7 +435,6 @@ def _install_path( # noqa: C901
436435
library directory on Linux wheels for eg.
437436
"""
438437
location = destination.as_posix()
439-
counter.update(location)
440438

441439
# fix file
442440
if os.path.isdir(origin):
@@ -514,6 +512,7 @@ def build(self, directory: Path) -> pathlib.Path:
514512

515513
for path, entries in self._wheel_files.items():
516514
for dst, src in entries:
515+
counter.update(src)
517516

518517
if path == root:
519518
pass
@@ -523,7 +522,7 @@ def build(self, directory: Path) -> pathlib.Path:
523522
else:
524523
dst = pathlib.Path(self.data_dir, path, dst)
525524

526-
self._install_path(whl, counter, src, dst)
525+
self._install_path(whl, src, dst)
527526

528527
return wheel_file
529528

0 commit comments

Comments
 (0)