Robot | Path | Permission |
GoogleBot | / | ✔ |
BingBot | / | ✔ |
BaiduSpider | / | ✔ |
YandexBot | / | ✔ |
Title | 温馨的小窝 |
Description | 记录一些宝宝的碎碎念∎ Toggle navigation 温馨的小窝 Archives Categories Tags About RSS 记录一些宝宝的碎碎念 ∎ 风停了,我没有停,我不会怕,我还有我自己 Python 调用 C 语言动态链接库里的函数 post @ 2021-11-26 源代码在: https://githu |
Keywords | N/A |
WebSite | archibate.top |
Host IP | 185.199.111.153 |
Location | - |
Site | Rank |
US$1,470
Last updated: 2023-05-17 19:14:01
archibate.top has Semrush global rank of 0. archibate.top has an estimated worth of US$ 1,470, based on its estimated Ads revenue. archibate.top receives approximately 169 unique visitors each day. Its web server is located in -, with IP address 185.199.111.153. According to SiteAdvisor, archibate.top is safe to visit. |
Purchase/Sale Value | US$1,470 |
Daily Ads Revenue | US$1 |
Monthly Ads Revenue | US$40 |
Yearly Ads Revenue | US$488 |
Daily Unique Visitors | 11 |
Note: All traffic and earnings values are estimates. |
Host | Type | TTL | Data |
archibate.top. | A | 600 | IP: archibate.github.io. |
archibate.github.io. | A | 3599 | IP: 185.199.111.153 |
archibate.github.io. | A | 3599 | IP: 185.199.110.153 |
archibate.github.io. | A | 3599 | IP: 185.199.109.153 |
archibate.github.io. | A | 3599 | IP: 185.199.108.153 |
archibate.top. | AAAA | 599 | IPV6: archibate.github.io. |
archibate.github.io. | AAAA | 3600 | IPV6: 2606:50c0:8001::153 |
archibate.github.io. | AAAA | 3600 | IPV6: 2606:50c0:8002::153 |
archibate.github.io. | AAAA | 3600 | IPV6: 2606:50c0:8003::153 |
archibate.github.io. | AAAA | 3600 | IPV6: 2606:50c0:8000::153 |
archibate.top. | NS | 21600 | NS Record: dns10.hichina.com. |
archibate.top. | NS | 21600 | NS Record: dns9.hichina.com. |
archibate.top. | TXT | 598 | TXT Record: archibate.github.io. |
Toggle navigation 温馨的小窝 Archives Categories Tags About RSS 记录一些宝宝的碎碎念 ∎ 风停了,我没有停,我不会怕,我还有我自己 Python 调用 C 语言动态链接库里的函数 post @ 2021-11-26 源代码在: https://github.com/archibate/archibate.github.io/tree/master/codes/invoke-c-shared-library-from-python 最近需要在 Blender 里调用 Zeno 的 C++ 部分,本来一直在用 Pybind11,但是他一旦换一个 Python 版本就会加载失败,同时一个个去调用 def 也非常麻烦。 目前主要是传指针字符串之类的,没有对复杂数据结构和类的深度绑定的需求,因此我开始探索另一种兼容性更好的方案——甚至不需要 Python 的头文件。 原来 Python 支持导入任意由 C 语言编写的动态链接库( .so 或者 .dll ),并调用其中的函数。 这其中又有哪些坑呢,今天就让我们一探究竟。 符号导出机制 针对不同的系统,分类讨论: Linux 很简单 首先用 CMake 创建一个 shared library 目标: 1 2 # CMakeLists.txt add_library (mylib SHARED mylib.c) C 语言源代码如下: 1 2 3 4 5 6 // mylib.c # include <stdio.h> void say_hello () { printf ( "Hello, world!\n" ); } 1 2 cmake -B build cmake --build build 编译后会得到 build/libmylib.so 。 然后在 Python 脚本里写: 1 2 3 4 import ctypes mylib = ctypes.cdll.LoadLibrary( ’build/libmylib.so’ ) mylib.say_hello() 成功打印: 1 Hello, world! Windows 不一样 然而我们试着如果用同样的配置在 Windows 上测试: 1 2 3 4 import ctypes mylib = |
HTTP/1.1 200 OK Server: GitHub.com Content-Type: text/html; charset=utf-8 Last-Modified: Mon, 29 Nov 2021 01:04:53 GMT Access-Control-Allow-Origin: * ETag: "61a42735-1c33e" expires: Fri, 15 Apr 2022 08:28:31 GMT Cache-Control: max-age=600 x-proxy-cache: MISS X-GitHub-Request-Id: 188C:11EDC:4C95EE:4EF965:62592A57 Content-Length: 115518 Accept-Ranges: bytes Date: Fri, 15 Apr 2022 08:18:31 GMT Via: 1.1 varnish Age: 0 Connection: keep-alive X-Served-By: cache-hel1410025-HEL X-Cache: MISS X-Cache-Hits: 0 X-Timer: S1650010712.541958,VS0,VE126 Vary: Accept-Encoding X-Fastly-Request-ID: 73befb5ead02df761c1308c12fac55aa5b44f62e |
Domain Name: archibate.top Registry Domain ID: D20200924G10001G_48607528-top Registrar WHOIS Server: whois.hichina.com/ Registrar URL: http://www.net.cn Creation Date: 2020-09-24T07:12:38Z Registry Expiry Date: 2022-09-24T07:12:38Z Registrar: Alibaba Cloud Computing Ltd. d/b/a HiChina (www.net.cn) Registrar IANA ID: 1599 Registrar Abuse Contact Email: DomainAbuse@service.aliyun.com Registrar Abuse Contact Phone: +86.95187 Domain Status: ok https://icann.org/epp#OK Registrant Organization: archibate Registrant Street: REDACTED FOR PRIVACY Registrant State/Province: Beijing Registrant Country: CN Admin Street: REDACTED FOR PRIVACY Tech Street: REDACTED FOR PRIVACY Name Server: dns9.hichina.com Name Server: dns10.hichina.com DNSSEC: unsigned >>> Last update of WHOIS database: 2022-04-17T03:18:43Z <<< |