• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kivy / python-for-android / 25435676503

06 May 2026 12:37PM UTC coverage: 62.876% (-1.0%) from 63.887%
25435676503

Pull #3278

github

web-flow
Merge 3c07c5446 into 3ab2fd669
Pull Request #3278: Handling system bars and Edge-to-Edge enforcement (android 15+)

1832 of 3180 branches covered (57.61%)

Branch coverage included in aggregate %.

5329 of 8209 relevant lines covered (64.92%)

5.18 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

55.56
/pythonforandroid/recipes/numpy/__init__.py
1
from pythonforandroid.recipe import Recipe, MesonRecipe
8✔
2
from os.path import join
8✔
3
import shutil
8✔
4

5
NUMPY_NDK_MESSAGE = (
8✔
6
    "In order to build numpy, you must set minimum ndk api (minapi) to `24`.\n"
7
)
8

9

10
class NumpyRecipe(MesonRecipe):
8✔
11
    version = "v2.3.0"
8✔
12
    url = "git+https://github.com/numpy/numpy"
8✔
13
    extra_build_args = ["-Csetup-args=-Dblas=none", "-Csetup-args=-Dlapack=none"]
8✔
14
    need_stl_shared = True
8✔
15
    min_ndk_api_support = 24
8✔
16

17
    def get_include(self, arch):
8✔
18
        return join(
×
19
            self.ctx.get_python_install_dir(arch.arch), "numpy/_core/include",
20
        )
21

22
    def get_recipe_meson_options(self, arch):
8✔
23
        options = super().get_recipe_meson_options(arch)
×
24
        options["properties"]["longdouble_format"] = (
×
25
            "IEEE_DOUBLE_LE" if arch.arch in ["armeabi-v7a", "x86"] else "IEEE_QUAD_LE"
26
        )
27
        return options
×
28

29
    def get_recipe_env(self, arch, **kwargs):
8✔
30
        env = super().get_recipe_env(arch, **kwargs)
×
31

32
        # _PYTHON_HOST_PLATFORM declares that we're cross-compiling
33
        # and avoids issues when building on macOS for Android targets.
34
        env["_PYTHON_HOST_PLATFORM"] = arch.command_prefix
×
35

36
        # NPY_DISABLE_SVML=1 allows numpy to build for non-AVX512 CPUs
37
        # See: https://github.com/numpy/numpy/issues/21196
38
        env["NPY_DISABLE_SVML"] = "1"
×
39
        env["TARGET_PYTHON_EXE"] = join(
×
40
            Recipe.get_recipe("python3", self.ctx).get_build_dir(arch.arch),
41
            "android-build",
42
            "python",
43
        )
44
        return env
×
45

46
    def get_hostrecipe_env(self, arch=None):
8✔
47
        env = super().get_hostrecipe_env(arch=arch)
×
48
        env["RANLIB"] = shutil.which("ranlib")
×
49
        return env
×
50

51

52
recipe = NumpyRecipe()
8✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc