mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Also bump apsw
apsw now uses a compiled etension module as its __init__ so support that.
This commit is contained in:
parent
71662297a1
commit
741f195e13
@ -13,13 +13,14 @@ import time
|
||||
from functools import partial
|
||||
|
||||
from bypy.constants import (
|
||||
OUTPUT_DIR, PREFIX, SRC as CALIBRE_DIR, python_major_minor_version
|
||||
OUTPUT_DIR, PREFIX, SRC as CALIBRE_DIR, python_major_minor_version,
|
||||
)
|
||||
from bypy.freeze import (
|
||||
extract_extension_modules, fix_pycryptodome, freeze_python, path_to_freeze_dir
|
||||
extract_extension_modules, fix_pycryptodome, freeze_python, is_package_dir,
|
||||
path_to_freeze_dir,
|
||||
)
|
||||
from bypy.utils import (
|
||||
create_job, get_dll_path, mkdtemp, parallel_build, py_compile, run, walk
|
||||
create_job, get_dll_path, mkdtemp, parallel_build, py_compile, run, walk,
|
||||
)
|
||||
|
||||
j = os.path.join
|
||||
@ -90,8 +91,7 @@ def ignore_in_lib(base, items, ignored_dirs=None):
|
||||
for name in items:
|
||||
path = j(base, name)
|
||||
if os.path.isdir(path):
|
||||
if name in ignored_dirs or not os.path.exists(j(path, '__init__.py')):
|
||||
if name != 'plugins':
|
||||
if name != 'plugins' and (name in ignored_dirs or not is_package_dir(path)):
|
||||
ans.append(name)
|
||||
else:
|
||||
if name.rpartition('.')[-1] not in ('so', 'py'):
|
||||
@ -112,7 +112,7 @@ def import_site_packages(srcdir, dest):
|
||||
src = os.path.abspath(j(srcdir, line))
|
||||
if os.path.exists(src) and os.path.isdir(src):
|
||||
import_site_packages(src, dest)
|
||||
elif os.path.exists(j(f, '__init__.py')):
|
||||
elif is_package_dir(f):
|
||||
shutil.copytree(f, j(dest, x), ignore=ignore_in_lib)
|
||||
|
||||
|
||||
|
@ -20,13 +20,14 @@ from functools import partial, reduce
|
||||
from itertools import repeat
|
||||
|
||||
from bypy.constants import (
|
||||
OUTPUT_DIR, PREFIX, PYTHON, SRC as CALIBRE_DIR, python_major_minor_version
|
||||
OUTPUT_DIR, PREFIX, PYTHON, SRC as CALIBRE_DIR, python_major_minor_version,
|
||||
)
|
||||
from bypy.freeze import (
|
||||
extract_extension_modules, fix_pycryptodome, freeze_python, path_to_freeze_dir
|
||||
extract_extension_modules, fix_pycryptodome, freeze_python, is_package_dir,
|
||||
path_to_freeze_dir,
|
||||
)
|
||||
from bypy.utils import (
|
||||
current_dir, get_arches_in_binary, mkdtemp, py_compile, timeit, walk
|
||||
current_dir, get_arches_in_binary, mkdtemp, py_compile, timeit, walk,
|
||||
)
|
||||
|
||||
abspath, join, basename, dirname = os.path.abspath, os.path.join, os.path.basename, os.path.dirname
|
||||
@ -584,7 +585,7 @@ class Freeze:
|
||||
def add_packages_from_dir(self, src):
|
||||
for x in os.listdir(src):
|
||||
x = join(src, x)
|
||||
if os.path.isdir(x) and os.path.exists(join(x, '__init__.py')):
|
||||
if os.path.isdir(x) and is_package_dir(x):
|
||||
if self.filter_package(basename(x)):
|
||||
continue
|
||||
self.add_package_dir(x)
|
||||
|
@ -767,9 +767,9 @@
|
||||
{
|
||||
"name": "apsw",
|
||||
"unix": {
|
||||
"filename": "apsw-3.36.0-r1.zip",
|
||||
"hash": "sha256:17355c39a8cdb9b9cd75b76d883b624c0dd05f80a6677c693b67c343c2381871",
|
||||
"urls": ["https://github.com/rogerbinns/apsw/releases/download/3.36.0-r1/{filename}"]
|
||||
"filename": "apsw-3.43.0.0.zip",
|
||||
"hash": "sha256:7440d5f976a369ab87477e064545a8a62a93e413ead7bfe0be4efc75b1f30bb0",
|
||||
"urls": ["https://github.com/rogerbinns/apsw/releases/download/3.43.0.0/{filename}"]
|
||||
}
|
||||
},
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user