linuxOS_AP05/debian/test/usr/share/doc/python3/python-policy.html/embed.html
2025-09-26 09:40:02 +08:00

16 lines
3.5 KiB
HTML
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>Chapter 5. Programs Embedding Python</title><meta name="generator" content="DocBook XSL Stylesheets V1.79.1" /><link rel="home" href="index.html" title="Debian Python Policy" /><link rel="up" href="index.html" title="Debian Python Policy" /><link rel="prev" href="programs.html" title="Chapter 4. Python Programs" /><link rel="next" href="other.html" title="Chapter 6. Interaction with Locally Installed Python Versions" /></head><body><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 5. Programs Embedding Python</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="programs.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="other.html">Next</a></td></tr></table><hr /></div><div class="chapter"><div class="titlepage"><div><div><h1 class="title"><a id="embed"></a>Chapter 5. Programs Embedding Python</h1></div></div></div><div class="toc"><p><strong>Table of Contents</strong></p><dl class="toc"><dt><span class="section"><a href="embed.html#build_embedded">5.1. Building Embedded Programs</a></span></dt><dt><span class="section"><a href="embed.html#embedded_deps">5.2. Embedded Python Dependencies</a></span></dt></dl></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="build_embedded"></a>5.1. Building Embedded Programs</h2></div></div></div><p>
Any package that installs a program which embeds a Python
interpreter must declare <code class="literal">Build-Depends</code> on
<code class="literal">python<em class="replaceable"><code>X</code></em>.<em class="replaceable"><code>Y</code></em>-dev</code>, where
<em class="replaceable"><code>X</code></em>.<em class="replaceable"><code>Y</code></em> is the Python version the program
builds against. It should be the current default Python version
unless the program does not work correctly with this version.
</p></div><div class="section"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="embedded_deps"></a>5.2. Embedded Python Dependencies</h2></div></div></div><p>
Dependencies for programs linking against the shared Python
library will be automatically created
by <code class="filename">dpkg-shlibdeps</code>. The
<code class="filename">libpython<em class="replaceable"><code>X</code></em>.<em class="replaceable"><code>Y</code></em>.so.<em class="replaceable"><code>Z</code></em></code>
library the program is built against is provided by the
<code class="literal">python<em class="replaceable"><code>X</code></em>.<em class="replaceable"><code>Y</code></em></code> package.
</p></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="programs.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="other.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 4. Python Programs </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 6. Interaction with Locally Installed Python Versions</td></tr></table></div></body></html>