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

kivy / python-for-android / 14999495895

13 May 2025 02:38PM UTC coverage: 58.724% (-0.5%) from 59.204%
14999495895

Pull #3136

github

web-flow
Merge 55a9af12f into 40993e323
Pull Request #3136: scipy: update to v1.15.2

1059 of 2408 branches covered (43.98%)

Branch coverage included in aggregate %.

73 of 221 new or added lines in 9 files covered. (33.03%)

4 existing lines in 3 files now uncovered.

4979 of 7874 relevant lines covered (63.23%)

2.52 hits per line

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

0.0
/pythonforandroid/recipes/scipy/wrapper.py
1
#!/usr/bin/python3
2

3
# Taken from https://github.com/termux/termux-packages/blob/master/packages/python-scipy/wrapper.py.in
4

NEW
5
import os
×
NEW
6
import subprocess
×
NEW
7
import sys
×
NEW
8
import typing
×
9

NEW
10
"""
×
11
This wrapper is used to ignore or replace some unsupported flags for flang-new.
12

13
It will operate as follows:
14

15
1. Ignore `-Minform=inform` and `-fdiagnostics-color`.
16
  They are added by meson automatically, but are not supported by flang-new yet.
17
2. Remove `-lflang` and `-lpgmath`.
18
  It exists in classic-flang but doesn't exist in flang-new.
19
3. Replace `-Oz` to `-O2`.
20
  `-Oz` is not supported by flang-new.
21
4. Replace `-module` to `-J`.
22
  See https://github.com/llvm/llvm-project/issues/66969
23
5. Ignore `-MD`, `-MQ file` and `-MF file`.
24
  They generates files used by GNU make but we're using ninja.
25
6. Ignore `-fvisibility=hidden`.
26
  It is not supported by flang-new, and ignoring it will not break the functionality,
27
  as scipy also uses version script for shared libraries.
28
"""
29

NEW
30
COMPLIER_PATH = "@COMPILER@"
×
31

32

NEW
33
def main(argv: typing.List[str]):
×
NEW
34
    cwd = os.getcwd()
×
NEW
35
    argv_new = []
×
NEW
36
    i = 0
×
NEW
37
    while i < len(argv):
×
NEW
38
        arg = argv[i]
×
NEW
39
        if arg in [
×
40
            "-Minform=inform",
41
            "-lflang",
42
            "-lpgmath",
43
            "-MD",
44
            "-fvisibility=hidden",
45
        ] or arg.startswith("-fdiagnostics-color"):
NEW
46
            pass
×
NEW
47
        elif arg == "-Oz":
×
NEW
48
            argv_new.append("-O2")
×
NEW
49
        elif arg == "-module":
×
NEW
50
            argv_new.append("-J")
×
NEW
51
        elif arg in ["-MQ", "-MF"]:
×
NEW
52
            i += 1
×
53
        else:
NEW
54
            argv_new.append(arg)
×
NEW
55
        i += 1
×
56

NEW
57
    args = [COMPLIER_PATH] + argv_new
×
NEW
58
    subprocess.check_call(args, env=os.environ, cwd=cwd, text=True)
×
59

60

61
if __name__ == "__main__":
62
    main(sys.argv[1:])
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

© 2025 Coveralls, Inc