Error installing pip pyicu

后端 未结 8 2010
独厮守ぢ
独厮守ぢ 2020-12-24 13:51

I have been trying to install musicbrainz server on my mac and there is a step where I have to install pip pyicu. I keep getting this error:

Collecting pyicu         


        
8条回答
  •  南方客
    南方客 (楼主)
    2020-12-24 14:28

    On macOS 10.14.2 simply adding the directory containing icu-config to the PATH did the trick for me:

    brew install icu4c
    export PATH="/usr/local/opt/icu4c/bin:$PATH"
    pip install pyicu
    

    In fact, this is suggested by brew info icu4c:

    ==> Caveats
    icu4c is keg-only, which means it was not symlinked into /usr/local,
    because macOS provides libicucore.dylib (but nothing else).
    
    If you need to have icu4c first in your PATH run:
      echo 'export PATH="/usr/local/opt/icu4c/bin:$PATH"' >> ~/.zshrc
      echo 'export PATH="/usr/local/opt/icu4c/sbin:$PATH"' >> ~/.zshrc
    
    For compilers to find icu4c you may need to set:
      export LDFLAGS="-L/usr/local/opt/icu4c/lib"
      export CPPFLAGS="-I/usr/local/opt/icu4c/include"
    
    For pkg-config to find icu4c you may need to set:
      export PKG_CONFIG_PATH="/usr/local/opt/icu4c/lib/pkgconfig"
    

提交回复
热议问题