File: configure.py

package info (click to toggle)
pytorch 1.7.1-7
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 80,340 kB
  • sloc: cpp: 670,830; python: 343,991; ansic: 67,845; asm: 5,503; sh: 2,924; java: 2,888; xml: 266; makefile: 244; ruby: 148; yacc: 144; objc: 51; lex: 44
file content (26 lines) | stat: -rwxr-xr-x 670 bytes parent folder | download | duplicates (4)
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
#!/usr/bin/env python


import confu
parser = confu.standard_parser("clog configuration script")


def main(args):
    options = parser.parse_args(args)
    build = confu.Build.from_options(options)

    build.export_cpath("include", ["clog.h"])

    with build.options(source_dir="src", extra_include_dirs="src"):
        build.static_library("clog", build.cc("clog.c"))

    with build.options(source_dir="test", deps={
            (build, build.deps.googletest): all,
            "log": build.target.is_android}):
        build.unittest("clog-test", build.cxx("clog.cc"))

    return build

if __name__ == "__main__":
    import sys
    main(sys.argv[1:]).generate()