# Compile python shared object file to be compatible with paraview scripting python implementation

**URL:** https://discourse.paraview.org/t/compile-python-shared-object-file-to-be-compatible-with-paraview-scripting-python-implementation/15412
**Category:** Development
**Tags:** python
**Created:** [September 19, 2024, 6:39pm UTC](https://discourse.paraview.org/t/compile-python-shared-object-file-to-be-compatible-with-paraview-scripting-python-implementation/15412 "2024-09-19T18:39:20Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![lucasmyers97](https://discourse.paraview.org/user_avatar/discourse.paraview.org/lucasmyers97/32/9704_2.png) [@lucasmyers97](https://discourse.paraview.org/u/lucasmyers97)
#### Post date: [September 19, 2024, 6:39pm UTC](https://discourse.paraview.org/t/compile-python-shared-object-file-to-be-compatible-with-paraview-scripting-python-implementation/15412/1 "2024-09-19T18:39:20Z")

</div>

I am trying to compile a shared object file to be used as a python module (this is done using pybind). As I understand it, the only thing necessary is the relevant include files for the Python API. In the [CPython docs](https://docs.python.org/3/extending/extending.html) it says that this will not necessarily work for other Python implementations. Is there some way to make this work for the specific Python implementation included in Paraview?

---

<div class="post-metadata">

### Author: ![ben.boeckel](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/b/ea5d25/32.png) [@ben.boeckel](https://discourse.paraview.org/u/ben.boeckel)
#### Post date: [September 26, 2024, 5:01pm UTC](https://discourse.paraview.org/t/compile-python-shared-object-file-to-be-compatible-with-paraview-scripting-python-implementation/15412/2 "2024-09-26T17:01:06Z")

</div>

You’ll need to compile with a Python that matches the Python version in the ParaView build (major/minor). This is currently 3.10. We use a fairly stock Python build other than that.
