File: meson.build

package info (click to toggle)
pygobject 3.55.3-3
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 6,000 kB
  • sloc: ansic: 39,431; python: 26,883; sh: 114; makefile: 81; xml: 35; cpp: 1
file content (101 lines) | stat: -rw-r--r-- 2,245 bytes parent folder | download | duplicates (3)
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
sources = [
  'pygboxed.c',
  'pygenum.c',
  'pygflags.c',
  'pyginterface.c',
  'pygobject-class.c',
  'pygobject-object.c',
  'pygobject-props.c',
  'pygpointer.c',
  'pygspawn.c',
  'gimodule.c',
  'pygi-capi.c',
  'pygi-repository.c',
  'pygi-info.c',
  'pygi-foreign.c',
  'pygi-struct.c',
  'pygi-source.c',
  'pygi-argument.c',
  'pygi-resulttuple.c',
  'pygi-async.c',
  'pygi-type.c',
  'pygi-boxed.c',
  'pygi-closure.c',
  'pygi-ccallback.c',
  'pygi-util.c',
  'pygi-property.c',
  'pygi-signal-closure.c',
  'pygi-invoke.c',
  'pygi-cache.c',
  'pygi-cache-array.c',
  'pygi-cache-basic.c',
  'pygi-cache-closure.c',
  'pygi-cache-enum.c',
  'pygi-cache-error.c',
  'pygi-cache-hashtable.c',
  'pygi-cache-interface.c',
  'pygi-cache-list.c',
  'pygi-cache-object.c',
  'pygi-cache-struct.c',
  'pygi-marshal-cleanup.c',
  'pygi-basictype.c',
  'pygi-error.c',
  'pygi-fundamental.c',
  'pygi-value.c',
]

headers = [
  'pygobject.h',
  'pygobject-types.h'
]

install_headers(headers, subdir : 'pygobject-@0@'.format(platform_version))

python_sources = [
  'events.py',
  '_constants.py',
  'docstring.py',
  '_enum.py',
  '_error.py',
  '_gtktemplate.py',
  'importer.py',
  '__init__.py',
  'module.py',
  '_ossighelper.py',
  '_propertyhelper.py',
  '_signalhelper.py',
  '_signature.py',
  'types.py',
]

python.install_sources(python_sources,
  pure : false,
  subdir : 'gi'
)

# https://github.com/mesonbuild/meson/issues/4117
if host_machine.system() == 'windows'
  python_ext_dep = python_dep
else
  python_ext_dep = python_dep.partial_dependency(compile_args: true)
endif

configure_file(output : 'config.h', configuration : cdata)

giext = python.extension_module('_gi', sources,
  dependencies : [python_ext_dep, glib_dep, gi_dep, ffi_dep, pythoncapi_compat_dep],
  install: true,
  subdir : 'gi',
  c_args: pyext_c_args + main_c_args + ['-D_INSIDE_PYGOBJECT_']
)

if cairo_dep.found()
  gicairoext = python.extension_module('_gi_cairo', ['pygi-foreign-cairo.c'],
    dependencies : [python_ext_dep, glib_dep, gi_dep, ffi_dep, pycairo_dep, cairo_dep, cairo_gobject_dep, pythoncapi_compat_dep],
    install: true,
    subdir : 'gi',
    c_args: pyext_c_args + main_c_args)
endif

subdir('overrides')
subdir('repository')