<legend id='fgkUU'><style id='fgkUU'><dir id='fgkUU'><q id='fgkUU'></q></dir></style></legend>
    <i id='fgkUU'><tr id='fgkUU'><dt id='fgkUU'><q id='fgkUU'><span id='fgkUU'><b id='fgkUU'><form id='fgkUU'><ins id='fgkUU'></ins><ul id='fgkUU'></ul><sub id='fgkUU'></sub></form><legend id='fgkUU'></legend><bdo id='fgkUU'><pre id='fgkUU'><center id='fgkUU'></center></pre></bdo></b><th id='fgkUU'></th></span></q></dt></tr></i><div id='fgkUU'><tfoot id='fgkUU'></tfoot><dl id='fgkUU'><fieldset id='fgkUU'></fieldset></dl></div>

      <tfoot id='fgkUU'></tfoot>

      <small id='fgkUU'></small><noframes id='fgkUU'>

      • <bdo id='fgkUU'></bdo><ul id='fgkUU'></ul>

      有没有办法判断 python 是否使用“--with-threads --enable-shared"进行配置

      Is there a way to tell if python was configured and compiled with quot;--with-threads --enable-sharedquot;?(有没有办法判断 python 是否使用“--with-threads --enable-shared进行配置和编译?)
        <tbody id='1JX0V'></tbody>
        <i id='1JX0V'><tr id='1JX0V'><dt id='1JX0V'><q id='1JX0V'><span id='1JX0V'><b id='1JX0V'><form id='1JX0V'><ins id='1JX0V'></ins><ul id='1JX0V'></ul><sub id='1JX0V'></sub></form><legend id='1JX0V'></legend><bdo id='1JX0V'><pre id='1JX0V'><center id='1JX0V'></center></pre></bdo></b><th id='1JX0V'></th></span></q></dt></tr></i><div id='1JX0V'><tfoot id='1JX0V'></tfoot><dl id='1JX0V'><fieldset id='1JX0V'></fieldset></dl></div>

            <legend id='1JX0V'><style id='1JX0V'><dir id='1JX0V'><q id='1JX0V'></q></dir></style></legend>
            <tfoot id='1JX0V'></tfoot>
              <bdo id='1JX0V'></bdo><ul id='1JX0V'></ul>
            • <small id='1JX0V'></small><noframes id='1JX0V'>

              • 本文介绍了有没有办法判断 python 是否使用“--with-threads --enable-shared"进行配置和编译?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                这适用于 Debian Squeeez 上的 Python 2.6.6.我试图找出 debian 附带的二进制文件是否配置了以下标志:

                --with-threads --enable-shared

                好像它们不是我需要自己从源代码编译和安装.

                解决方案

                --with-threads(默认)表示Python支持线程,表示import thread 将工作.一个简单的测试方法是使用 python$version -m threading

                --enable-shared 意味着 Python 带有一个 libpython$version.so 文件,安装在 $prefix/lib 中(与python$version 目录,不在其中.)最简单的方法是查看该文件是否存在——假设您想知道,因为您需要使用这个 libpython 共享库.如果你真的需要知道 python$version binary 是否使用这个共享库,ldd 会告诉你.我做出这样的区分是因为在 Debian 上,即使 /usr/bin/python$version 是静态链接的,/usr/lib/python$version.so 也会存在.p>

                This is for Python 2.6.6 on Debian Squeeez. I'm trying to find out if the binaries shipped with debian were configured with the flags of:

                --with-threads --enable-shared
                

                as if they were not I will need to compile and install from source myself.

                解决方案

                --with-threads (which is the default) will mean Python supports threading, which will mean import thread will work. An easy way to test this is with python$version -m threading

                --enable-shared will mean Python comes with a libpython$version.so file, installed in $prefix/lib (alongside the python$version directory, not inside it.) The easiest thing to do is to look if that file is there -- assuming you want to know because you need to use this libpython shared library. If you actually need to know if the python$version binary uses this shared library, ldd will tell you that. I make that distinction because on Debian, /usr/lib/python$version.so will exist even though /usr/bin/python$version is statically linked.

                这篇关于有没有办法判断 python 是否使用“--with-threads --enable-shared"进行配置和编译?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                What happens when you compare 2 pandas Series(当你比较 2 个 pandas 系列时会发生什么)
                Quickly find differences between two large text files(快速查找两个大文本文件之间的差异)
                Python - Compare 2 files and output differences(Python - 比较 2 个文件和输出差异)
                Why do comparisions between very large float values fail in python?(为什么在 python 中非常大的浮点值之间的比较会失败?)
                Dictionary merge by updating but not overwriting if value exists(字典通过更新合并,但如果值存在则不覆盖)
                Find entries of one text file in another file in python(在python中的另一个文件中查找一个文本文件的条目)

                    <tbody id='40k08'></tbody>

                  <i id='40k08'><tr id='40k08'><dt id='40k08'><q id='40k08'><span id='40k08'><b id='40k08'><form id='40k08'><ins id='40k08'></ins><ul id='40k08'></ul><sub id='40k08'></sub></form><legend id='40k08'></legend><bdo id='40k08'><pre id='40k08'><center id='40k08'></center></pre></bdo></b><th id='40k08'></th></span></q></dt></tr></i><div id='40k08'><tfoot id='40k08'></tfoot><dl id='40k08'><fieldset id='40k08'></fieldset></dl></div>

                    <small id='40k08'></small><noframes id='40k08'>

                      <legend id='40k08'><style id='40k08'><dir id='40k08'><q id='40k08'></q></dir></style></legend>
                      • <tfoot id='40k08'></tfoot>
                          <bdo id='40k08'></bdo><ul id='40k08'></ul>