安裝命令: pip install jsonnet
報錯如下:
lang: warning: libstdc++ is deprecated; move to libc++ with a minimum deployment target of OS X 10.9 [-Wdeprecated] ld: library not found for -lstdc++ clang: error: linker command failed with exit code 1 (use -v to see invocation) error: command 'g++' failed with exit status 1
原因說的比較清楚是 libstdc++已經(jīng)被遺棄了。
解決方案
使用源碼安裝jsonnet
-
https://pypi.org/project/jsonnet/#files
下載源碼 - 解壓縮
- 執(zhí)行下面的安裝命令
CFLAGS=-stdlib=libc++ python3 setup.py install
或者sudo CFLAGS=-stdlib=libc++ python3 setup.py install
這樣就解決了這個jsonnet的安裝問題
其他不work的方案
-
conda install -c conda-forge jsonnet
我這里始終出錯 原因是說 不支持python3.7。我沒有嘗試改成python3.6,但是不想改回python 3.6 - xcode, command line tool 一頓配置等,這些我都嘗試了 也不行。