Unverified Commit c483a118 authored by Sébastien Eustace's avatar Sébastien Eustace
Browse files

Fix building wheels with conditional extensions

parent e398b04c
Loading
Loading
Loading
Loading
+1 −0
Changes for CHANGELOG.md: 1 added line, 0 removed lines.
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@
### Fixed

- Fixed built wheels not getting information from the virtualenv.
- Fixed building wheel with conditional extensions.


[0.6.2] - 2018-03-19
+8 −1
Changes for poetry/masonry/builders/wheel.py: 8 added lines, 1 removed line.
Original line number Diff line number Diff line
@@ -109,7 +109,14 @@ class WheelBuilder(Builder):
                os.chdir(current_path)

            build_dir = self._path / 'build'
            lib = list(build_dir.glob('lib.*'))[0]
            lib = list(build_dir.glob('lib.*'))
            if not lib:
                # The result of building the extensions
                # does not exist, this may due to conditional
                # builds, so we assume that it's okay
                return

            lib = lib[0]
            for pkg in lib.glob('*'):
                shutil.rmtree(str(self._path / pkg.name))
                shutil.copytree(str(pkg), str(self._path / pkg.name))