GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — python-for-android/pythonforandroid/meson_python.py at develop · kivy/python-for-android Expand file tree/ Copy pathmeson_python.pyMore file actions 76 lines (58 loc) · 2.18 KB / Copy pathmeson_python.pyFile metadata and controls76 lines (58 loc) · 2.18 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 import sys import json import subprocess import importlib.util from os.path import join from glob import glob class C: TARGET_PYTHON_PREFIX = globals().get("TARGET_PYTHON_PREFIX") PYTHON_MAJOR_VERSION = globals().get("PYTHON_MAJOR_VERSION", sys.version_info.major) PYTHON_MINOR_VERSION = globals().get("PYTHON_MINOR_VERSION", sys.version_info.minor) PLATFORM_TAG = globals().get("PLATFORM_TAG", sys.platform) PYTHON_SUFFIX = globals().get("PYTHON_SUFFIX", "") def handle_python_info(): prefix = C.TARGET_PYTHON_PREFIX sysconfig_file = glob(join(prefix, f"lib/python{C.PYTHON_MAJOR_VERSION}.{C.PYTHON_MINOR_VERSION}/_sysconfigdata*.py"))[0] spec = importlib.util.spec_from_file_location("_android_cfg", sysconfig_file) cfg = importlib.util.module_from_spec(spec) spec.loader.exec_module(cfg) ver_python = f"python{C.PYTHON_MAJOR_VERSION}.{C.PYTHON_MINOR_VERSION}" site_path = join(prefix, f"lib/{ver_python}/site-packages") android_paths = { "stdlib": join(prefix, "lib"), "platstdlib": join(prefix, "lib"), "purelib": site_path, "platlib": site_path, "include": join(prefix, f"include/{ver_python}/"), "platinclude": join(prefix, f"include/{ver_python}/"), "scripts": join(prefix, "bin"), "data": prefix, } print( json.dumps( { "variables": cfg.build_time_vars, "paths": android_paths, "sysconfig_paths": android_paths, "install_paths": android_paths, "version": f"{C.PYTHON_MAJOR_VERSION}.{C.PYTHON_MINOR_VERSION}", "platform": C.PLATFORM_TAG, "is_pypy": False, "is_venv": False, "link_libpython": True, "suffix": C.PYTHON_SUFFIX, "limited_api_suffix": ".abi3.so", "is_freethreaded": False, } ) ) WHITELIST = { "python_info.py": handle_python_info, } args = sys.argv[1:] if args: cmd = args[0] name = cmd.split("/")[-1] if name in WHITELIST: sys.exit(WHITELIST[name]()) sys.exit(subprocess.run([sys.executable] + args).returncode) |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |