Debian Codegraph @

skmisc/loess/meson.build

raw
1 fs = import('fs')
2
3 __init__py = fs.copyfile('__init__.py')
4
5 #### pyx -> c generator, depending on copied pxd files and init
6 loess_cython_gen = generator(
7 cython,
8 arguments: cython_args,
9 output: '_@[email protected]',
10 depends: [
11 __init__py,
12 fs.copyfile('src/c_loess.pxd'),
13 fs.copyfile('src/loess.h')
14 ]
15 )
16 ###
17
18 #### Fortran Loess into a static library
19 floess_sources = [
20 'src/loessf.f',
21 'src/linpack_lite.f'
22 ]
23
24 floess_lib = static_library(
25 'floess',
26 floess_sources,
27 fortran_args: [fortran_ignore_warnings],
28 dependencies: [blas, lapack]
29 )
30 ###
31
32 #### Loess Extenstion Module
33 py.extension_module(
34 '_loess',
35 sources: [
36 'src/loess.c',
37 'src/loessc.c',
38 'src/misc.c',
39 'src/predict.c',
40 loess_cython_gen.process('src/_loess.pyx')
41 ],
42 c_args: [cython_c_args, numpy_nodepr_api],
43 dependencies: [py_dep, npymath_lib, np_dep],
44 link_with: [floess_lib],
45 link_args: [cython_c_link_args],
46 link_language: 'c',
47 install: true,
48 subdir: 'skmisc/loess'
49 )
50 ###
51
52 #### Include Python Sources in this Directory
53 # Copy the subpackage __init__ to the build dir
54 python_sources = [
55 '__init__.py'
56 ]
57
58 py.install_sources(
59 python_sources,
60 subdir: 'skmisc/loess'
61 )
62 ###
63
64 #### Included sub-packages
65 subdir('tests')
66 ###