如何在 Mac OS X 上安装 Python 开发头文件?

How to install the Python development headers on Mac OS X?(如何在 Mac OS X 上安装 Python 开发头文件?)
本文介绍了如何在 Mac OS X 上安装 Python 开发头文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

问题描述

对于使用 Boost.Python 的项目(请参阅 其他问题) 我需要包含例如的 Python 开发标头pyconfig.h.

For a project using Boost.Python (see this other question) I need the Python development headers containing e.g. pyconfig.h.

这些显然从我的系统中丢失.我已经通过 Homebrew 安装了 Python 3:

These are apparently missing from my system. I've installed Python 3 via Homebrew:

cls ~ $ brew info python3
python3: stable 3.3.0
http://www.python.org/
Depends on: pkg-config, readline, sqlite, gdbm
/usr/local/Cellar/python3/3.2.3 (4420 files, 78M)
/usr/local/Cellar/python3/3.3.0 (4843 files, 93M) *
https://github.com/mxcl/homebrew/commits/master/Library/Formula/python3.rb

我也希望通过 Homebrew 获取标头,但我找不到它们的包.

I would prefer getting the headers via Homebrew, too, but I cannot find a package for them.

cls ~ $ brew search python-dev
No formula found for "python-dev". Searching open pull requests...

我有哪些安装这些标头的选项?有 Homebrew 包吗?

What are my options for installing these headers? Is there a Homebrew package?

推荐答案

这些是你要找的标题吗:

Are these the headers you are looking for:

Cellar/python3/3.3.0//Frameworks/Python.framework/Versions/3.3/include/python3.3m/

这篇关于如何在 Mac OS X 上安装 Python 开发头文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

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

相关文档推荐

Seasonal Decomposition of Time Series by Loess with Python(Loess 用 Python 对时间序列进行季节性分解)
Resample a time series with the index of another time series(使用另一个时间序列的索引重新采样一个时间序列)
How can I simply calculate the rolling/moving variance of a time series in python?(如何在 python 中简单地计算时间序列的滚动/移动方差?)
How to use Dynamic Time warping with kNN in python(如何在python中使用动态时间扭曲和kNN)
Keras LSTM: a time-series multi-step multi-features forecasting - poor results(Keras LSTM:时间序列多步多特征预测 - 结果不佳)
Python pandas time series interpolation and regularization(Python pandas 时间序列插值和正则化)