noel
noel

Reputation: 2339

How to install python3.7-dev on Ubuntu 20.04?

I need to use Python3.7 for a project, but Ubuntu 20.04 doesn't have python3.7-dev in the apt repositories. I've installed Python3.7 from a tarball, but it doesn't install the headers. I noticed in the build directory that libpython3.7m.a exists, but I'm looking for libpython3.7.so. I don't see any options to build shared versus static library, and I don't where that file goes, I was hoping the build script would take care of that.

Does anyone know the recommended way to install python headers from older versions?

Upvotes: 6

Views: 24215

Answers (3)

Shaida Muhammad
Shaida Muhammad

Reputation: 1650

sudo apt-get install python3.7-dev

You can install it for any version of python. by sudo apt-get install python3.x-dev

Upvotes: 6

陶伯承
陶伯承

Reputation: 11

maybe you can use libpython3.7m-pic.a instead, which acts like libpython3.7.so to some extent

Upvotes: -1

Sandeep Panchal
Sandeep Panchal

Reputation: 385

Try this once and let me know if it didn't solve

sudo apt-get install python3-dev

Upvotes: 2

Related Questions