Skip to content

Commit

Permalink
fix empty bdist_wheel (#1012)
Browse files Browse the repository at this point in the history
  • Loading branch information
yxlao authored Jun 8, 2019
1 parent 27d749a commit 83c55d0
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/Python/package/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,23 @@

from setuptools import setup, find_packages
import glob

# Force platform specific wheel
try:
from wheel.bdist_wheel import bdist_wheel as _bdist_wheel
# https://stackoverflow.com/a/45150383/1255535
class bdist_wheel(_bdist_wheel):
def finalize_options(self):
_bdist_wheel.finalize_options(self)
self.root_is_pure = False
except ImportError:
print('Warning: cannot import "wheel" package to build platform-specific wheel')
print('Install the "wheel" package to fix this warning')
bdist_wheel = None

cmdclass = {'bdist_wheel': bdist_wheel} if bdist_wheel is not None else dict()


# Read requirements.txt
with open('requirements.txt', 'r') as f:
lines = f.readlines()
Expand Down Expand Up @@ -86,7 +94,7 @@ def finalize_options(self):
description=[
"Open3D is an open-source library that supports rapid development of software that deals with 3D data."
],
cmdclass={'bdist_wheel': bdist_wheel},
cmdclass=cmdclass,
install_requires=install_requires,
include_package_data=True,
data_files=data_files,
Expand Down

0 comments on commit 83c55d0

Please sign in to comment.