How to use the ActiveState Platform to work with Python packages with linked C libraries
To create your own Python environment, featuring up-to-date, secure packages and their fully resolved dependencies you can start by creating a free ActiveState Platform account. When Python packages with linked C libraries are not available as a prebuilt binary for your operating system, you’ll have to build it yourself, which can be a real pain. You can use the ActiveState Platform to create a binary for any package with a linked C or Fortran library without needing a local build environment.
- Create a build environment for each OS
- Populate it with a C compiler native to that OS
- Download the source code for the package and all dependencies
- Create a build script
And so on…
But luckily, all this is taken care of for you by the Platform, which is a cloud-based build farm on AWS.
Follow along with the video to see how the ActiveState Platform automatically builds PyYAML and all of its dependencies. Once complete, all you have to do is copy the install snippet and run it on your command line to install the precompiled runtime environment on your local system.
Note: Creating secure, reproducible environments are functions available to all users of the ActiveState Platform, including free tier users. Just start by creating your account using your email or GitHub credentials. As you work with the ActiveState Platform to create new Python environments, you may need to upgrade to higher tiers to obtain access to features available only to paid tier users. These include role-based access control and project branching. Please get in touch with us to help you find the best tier for your needs.
Watch Next: How to Simplify Working with Reproducible Environments Using the ActiveState Platform
At ActiveState, we use the Platform to build not only our popular open source language distributions, but also custom runtimes for our enterprise clients (i.e. builds containing just the language and packages their project requires). Try it out yourself or get a personalized demo and understand how it can support your enterprise’s open source needs.
To read the blog based on this video ”How to Build and Install C Libraries in Python”, head here.
Use our Platform to build a custom environment for your next project, including just the language and packages your project needs.
- Choose a language (Python, Perl or Tcl right now)
- Select your operating system (Linux or Windows, plus Mac for Python)
- Add the packages your project requires
ActiveState regularly pulls packages from each language’s standard open source repository (CPAN, PyPI, etc) to ensure that your open source language and components are up to date, can be compiled from source, and are then verified to work together in a distribution that is packaged for most major operating systems. Go ahead and try our beta today! We are hanging out at our Community Forum to provide support as you explore.