|
29 | 29 | from setuptools import Extension, find_packages, setup
|
30 | 30 | from setuptools.command.build_ext import build_ext
|
31 | 31 |
|
32 |
| -ISA_L_SOURCE_ARCHIVE = os.path.join("src", "isal", "isa-l", "v2.30.0.tar.gz") |
| 32 | +ISA_L_SOURCE = os.path.join("src", "isal", "isa-l") |
33 | 33 |
|
34 | 34 |
|
35 | 35 | class IsalExtension(Extension):
|
@@ -73,10 +73,9 @@ def build_extension(self, ext):
|
73 | 73 | @functools.lru_cache(maxsize=None)
|
74 | 74 | def build_isa_l():
|
75 | 75 | # Creating temporary directories
|
76 |
| - unpack_dir = tempfile.mktemp() |
| 76 | + build_dir = tempfile.mktemp() |
77 | 77 | temp_prefix = tempfile.mkdtemp()
|
78 |
| - shutil.unpack_archive(ISA_L_SOURCE_ARCHIVE, unpack_dir) |
79 |
| - build_dir = os.path.join(unpack_dir, "isa-l-2.30.0") |
| 78 | + shutil.copytree(ISA_L_SOURCE, build_dir) |
80 | 79 |
|
81 | 80 | # Build environment is a copy of OS environment to allow user to influence
|
82 | 81 | # it.
|
@@ -110,7 +109,9 @@ def build_isa_l():
|
110 | 109 | zip_safe=False,
|
111 | 110 | packages=find_packages('src'),
|
112 | 111 | package_dir={'': 'src'},
|
113 |
| - package_data={'isal': ['*.pxd', '*.pyx', os.path.join('isa-l', '*')]}, |
| 112 | + package_data={'isal': ['*.pxd', '*.pyx', |
| 113 | + 'isa-l/LICENSE', 'isa-l/README.md', |
| 114 | + 'isa-l/Release_notes.txt']}, |
114 | 115 | url="https://github.com/pycompression/python-isal",
|
115 | 116 | classifiers=[
|
116 | 117 | "Programming Language :: Python :: 3 :: Only",
|
|
0 commit comments