找不到python.h文件

2024-09-29 21:50:08 发布

您现在位置:Python中文网/ 问答频道 /正文

我试图运行gnumake,但是它说找不到python.h文件,我认为这是python没有正确安装的结果。在

我努力寻找安装Python的最佳方式,最初是在3.6版本中通过macports安装它,然后在使用pycharm时安装anaconda,这使得安装包变得更加容易,尽管我觉得Python的安装可能会引起混乱。在

python --version返回:Python 3.7.3

cat .bash_profile返回:

##
# Your previous /Users/jonathandyke/.bash_profile file was backed up as /Users/jonathandyke/.bash_profile.macports-saved_2019-06-30_at_22:20:05
##

# MacPorts Installer addition on 2019-06-30_at_22:20:05: adding an appropriate PATH variable for use with MacPorts.
export PATH="/opt/local/bin:/opt/local/sbin:$PATH"
# Finished adapting your PATH environment variable for use with MacPorts.


# Setting PATH for Python 3.6
# The original version is saved in .bash_profile.pysave
PATH="/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}"
export PATH
# added by Anaconda3 2019.03 installer
# >>> conda init >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$(CONDA_REPORT_ERRORS=false '/anaconda3/bin/conda' shell.bash hook 2> /dev/null)"
if [ $? -eq 0 ]; then
    \eval "$__conda_setup"
else
    if [ -f "/anaconda3/etc/profile.d/conda.sh" ]; then
        . "/anaconda3/etc/profile.d/conda.sh"
        CONDA_CHANGEPS1=false conda activate base
    else
        \export PATH="/anaconda3/bin:$PATH"
    fi
fi
unset __conda_setup
# <<< conda init <<<````


Tags: pathbashforbininitversionsetupexport

热门问题