File: meson.build

package info (click to toggle)
meson-python 0.18.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,264 kB
  • sloc: python: 3,005; ansic: 326; makefile: 8
file content (32 lines) | stat: -rw-r--r-- 791 bytes parent folder | download | duplicates (2)
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
# SPDX-FileCopyrightText: 2022 The meson-python developers
#
# SPDX-License-Identifier: MIT

project('spam', 'c', version: '1.0.0')

py = import('python').find_installation()

# Specify directories to be included - usually this is where your header files live.
# Note that specifying the path to Python.h is not necessary with meson-python.
includes = include_directories('src')

srcs = [
    'src/spammodule.c',
]

# If some files (such as .py files) need to be copied to site-packages,
# this is where they get specified. Files get copied to
# <python directory>/site-packages/<subdir>
py.install_sources(
    'src/__init__.py',
    subdir: 'spam',
    pure: false,
)

py.extension_module(
    '_spam',
    srcs,
    install: true,
    subdir: 'spam',
    include_directories: includes,
)