mirror of
https://github.com/boostorg/python.git
synced 2026-01-20 16:52:15 +00:00
156 lines
5.5 KiB
HTML
156 lines
5.5 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
|
|
<!-- Copyright David Abrahams 2006. Distributed under the Boost -->
|
|
<!-- Software License, Version 1.0. (See accompanying -->
|
|
<!-- file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) -->
|
|
<html>
|
|
<head>
|
|
<meta name="generator" content=
|
|
"HTML Tidy for Windows (vers 1st August 2002), see www.w3.org">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
|
|
<link rel="stylesheet" type="text/css" href="../boost.css">
|
|
|
|
<title>Boost.Python - Configuration</title>
|
|
</head>
|
|
|
|
<body link="#0000ff" vlink="#800080">
|
|
<table border="0" cellpadding="7" cellspacing="0" width="100%" summary=
|
|
"header">
|
|
<tr>
|
|
<td valign="top" width="300">
|
|
<h3><a href="../../../../index.htm"><img height="86" width="277"
|
|
alt="C++ Boost" src="../../../../boost.png" border="0"></a></h3>
|
|
</td>
|
|
|
|
<td valign="top">
|
|
<h1 align="center"><a href="../index.html">Boost.Python</a></h1>
|
|
|
|
<h2 align="center">Configuration</h2>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<hr>
|
|
|
|
<dl class="page-index">
|
|
<dt><a href="#introduction">Introduction</a></dt>
|
|
|
|
<dt><a href="#app-defined">Application Defined Macros</a></dt>
|
|
|
|
<dt><a href="#lib-defined-impl">Library Defined Implementation
|
|
Macros</a></dt>
|
|
</dl>
|
|
|
|
<h2><a name="introduction"></a>Introduction</h2>
|
|
|
|
<p><b>Boost.Python</b> uses several configuration macros in <a href=
|
|
"http://www.boost.org/libs/config/config.htm"><boost/config.hpp></a>,
|
|
as well as configuration macros meant to be supplied by the application.
|
|
These macros are documented here.</p>
|
|
|
|
<h2><a name="app-defined"></a>Application Defined Macros</h2>
|
|
|
|
<p>These are the macros that may be defined by an application using
|
|
<b>Boost.Python</b>. Note that if you extend a strict interpretation of
|
|
the C++ standard to cover dynamic libraries, using different values of
|
|
these macros when compiling different libraries (including extension
|
|
modules and the <b>Boost.Python</b> library itself) is a violation of the
|
|
<a href="definitions.html#ODR">ODR</a>. However, we know of no C++
|
|
implementations on which this particular violation is detectable or
|
|
causes any problems.</p>
|
|
|
|
<table summary="application defined macros" width="100%" cellpadding=
|
|
"10">
|
|
<tr>
|
|
<th align="left"><b>Macro</b></th>
|
|
|
|
<th><b>Default</b></th>
|
|
|
|
<th align="left"><b>Meaning</b></th>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top"><code>BOOST_PYTHON_MAX_ARITY</code></td>
|
|
|
|
<td valign="top" align="center">15</td>
|
|
|
|
<td valign="top">The maximum <a href=
|
|
"definitions.html#arity">arity</a> of any function, member function,
|
|
or constructor to be wrapped, invocation of a <b>Boost.Python</b>
|
|
function wich is specified as taking arguments
|
|
<code>x1, x2,</code>...<code>X</code><i>n</i>. This includes, in
|
|
particular, callback mechanisms such as <code><a href=
|
|
"object.html#object-spec">object</a>::operator()(</code>...<code>)</code>
|
|
or <code><a href=
|
|
"call_method.html#call_method-spec">call_method</a><R>(</code>...
|
|
<code>)</code>.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top"><code>BOOST_PYTHON_MAX_BASES</code></td>
|
|
|
|
<td valign="top" align="center">10</td>
|
|
|
|
<td valign="top">The maximum number of template arguments to the
|
|
<code><a href=
|
|
"class.html#bases-spec">bases</a><</code>...<code>></code>
|
|
class template, which is used to specify the bases of a wrapped C++
|
|
class..</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top"><code>BOOST_PYTHON_STATIC_MODULE</code></td>
|
|
|
|
<td valign="top" align="center"><i>not defined</i></td>
|
|
|
|
<td valign="top">If defined, prevents your module initialization
|
|
function from being treated as an exported symbol on platforms which
|
|
support that distinction in-code</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<h2><a name="lib-defined-impl"></a>Library Defined Implementation
|
|
Macros</h2>
|
|
|
|
<p>These macros are defined by <b>Boost.Python</b> and are implementation
|
|
details of interest only to implementors and those porting to new
|
|
platforms.</p>
|
|
|
|
<table summary="library defined implementation macros" width="100%"
|
|
cellpadding="10">
|
|
<tr>
|
|
<th align="left"><b>Macro</b></th>
|
|
|
|
<th><b>Default</b></th>
|
|
|
|
<th align="left"><b>Meaning</b></th>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top"><code>BOOST_PYTHON_TYPE_ID_NAME</code></td>
|
|
|
|
<td valign="top" align="center"><i>not defined</i></td>
|
|
|
|
<td valign="top">If defined, this indicates that the type_info
|
|
comparison across shared library boundaries does not work on this
|
|
platform. In other words, if shared-lib-1 passes
|
|
<code>typeid(T)</code> to a function in shared-lib-2 which compares
|
|
it to <code>typeid(T)</code>, that comparison may return
|
|
<code>false</code>. If this macro is #defined, Boost.Python uses and
|
|
compares <code>typeid(T).name()</code> instead of using and comparing
|
|
the <code>std::type_info</code> objects directly.</td>
|
|
</tr>
|
|
</table>
|
|
<hr>
|
|
|
|
<p>Revised
|
|
<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%d %B, %Y" startspan -->
|
|
7 January, 2003
|
|
<!--webbot bot="Timestamp" endspan i-checksum="39359" -->
|
|
</p>
|
|
|
|
<p><i>© Copyright <a href=
|
|
"../../../../people/dave_abrahams.htm">Dave Abrahams</a> 2002.</i></p>
|
|
</body>
|
|
</html>
|
|
|