Skip to content

Commit

Permalink
[build] [bug] Fix a bug of skbuild that loses the root package_dir (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
frostming authored and turbo0628 committed May 17, 2022
1 parent 7ebfeee commit 145be38
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,12 @@ def remove_tmp(taichi_dir):


class EggInfo(egg_info):
def finalize_options(self, *args, **kwargs):
if '' not in self.distribution.package_dir:
# XXX: skbuild loses the root package dir
self.distribution.package_dir[''] = package_dir
return super().finalize_options(*args, **kwargs)

def run(self):
taichi_dir = os.path.join(package_dir, 'taichi')
remove_tmp(taichi_dir)
Expand Down

0 comments on commit 145be38

Please sign in to comment.