• Home
  • Raw
  • Download

Lines Matching +full:build +full:- +full:with +full:- +full:python

13 and must be named after the module name, with an appropriate extension.
21 instance. See :ref:`initializing-modules` for details.
23 .. highlight:: python
25 For modules with ASCII-only names, the function must be named
26 ``PyInit_<modulename>``, with ``<modulename>`` replaced by the name of the
27 module. When using :ref:`multi-phase-initialization`, non-ASCII module names
29 ``PyInitU_<modulename>``, with ``<modulename>`` encoded using Python's
30 *punycode* encoding with hyphens replaced by underscores. In Python::
36 suffix = b'U_' + name.encode('punycode').replace(b'-', b'_')
48 Building C and C++ Extensions with distutils
53 Extension modules can be built using distutils, which is included in Python.
58 Python file, which, in the most simple case, could look like this:
60 .. code-block:: python3
73 With this :file:`setup.py`, and a file :file:`demo.c`, running ::
75 python setup.py build
78 the :file:`build` directory. Depending on the system, the module file will end
79 up in a subdirectory :file:`build/lib.system`, and may have a name like
85 meta-information to build packages, and it specifies the contents of the
86 package. Normally, a package will contain additional modules, like Python
88 documentation in :ref:`distutils-index` to learn more about the features of
91 It is common to pre-compute arguments to :func:`setup`, to better structure the
96 defines an extension named ``demo`` which is build by compiling a single source
103 .. code-block:: python3
120 url = 'https://docs.python.org/extending/building',
127 In this example, :func:`~distutils.core.setup` is called with additional
128 meta-information, which
135-DNDEBUG -g -O3 -Wall -Wstrict-prototypes -fPIC -DMAJOR_VERSION=1 -DMINOR_VERSION=0 -I/usr/local/i…
137 …gcc -shared build/temp.linux-i686-2.2/demo.o -L/usr/local/lib -ltcl83 -o build/lib.linux-i686-2.2/…
150 End-users will typically want to install the module, they do so by running ::
152 python setup.py install
156 python setup.py sdist
165 python setup.py bdist_rpm
166 python setup.py bdist_dumb