2015-06-17 144 views
1

我試圖從源頭製作賢者,但我失敗了。似乎在優勝美地缺少圖書館_scproxy。我還沒有在網絡上找到一個非常有用的援助。如果有人能幫助我。下面是日誌:ImportError:No module named _scproxy

Found local metadata for setuptools-12.4 
Found local sources at /Users/sam/Downloads/sage-6.7/upstream/setuptools-12.4.tar.gz 
Checksum: 427e916ad99a704af54b7aa3124bd52d4ebf04d3 vs 427e916ad99a704af54b7aa3124bd52d4ebf04d3 
setuptools-12.4 
==================================================== 
Setting up build directory for setuptools-12.4 
Finished set up 
**************************************************** 
Host system: 
Darwin dhcp-147-65-172-203.impa.br 14.3.0 Darwin Kernel Version 14.3.0: Mon Mar 23 11:59:05 PDT 2015; root:xnu-2782.20.48~5/RELEASE_X86_64 x86_64 
**************************************************** 
C compiler: gcc 
C compiler version: 
Using built-in specs. 
COLLECT_GCC=gcc 
COLLECT_LTO_WRAPPER=/Users/sam/Downloads/sage-6.7/local/libexec/gcc/x86_64-apple-darwin14.3.0/4.9.2/lto-wrapper 
Target: x86_64-apple-darwin14.3.0 
Configured with: ../src/configure --prefix=/Users/sam/Downloads/sage-6.7/local --with-local-prefix=/Users/sam/Downloads/sage-6.7/local --with-gmp=/Users/sam/Downloads/sage-6.7/local --with-mpfr=/Users/sam/Downloads/sage-6.7/local --with-mpc=/Users/sam/Downloads/sage-6.7/local --with-system-zlib --disable-multilib --disable-nls --enable-languages=c,c++,fortran --disable-libitm --with-build-config=bootstrap-debug --without-isl --without-cloog 
Thread model: posix 
gcc version 4.9.2 (GCC) 
**************************************************** 
patching file setuptools/command/easy_install.py 
Hunk #1 succeeded at 1491 (offset 45 lines). 
Hunk #2 succeeded at 1529 with fuzz 1 (offset 45 lines). 
Hunk #3 succeeded at 1555 (offset 45 lines). 
patching file pkg_resources/__init__.py 
Traceback (most recent call last): 
    File "setup.py", line 21, in <module> 
    exec(init_file.read(), command_ns) 
    File "<string>", line 11, in <module> 
    File "/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4/src/setuptools/__init__.py", line 11, in <module> 
    from setuptools.extension import Extension 
    File "/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4/src/setuptools/extension.py", line 8, in <module> 
    from .dist import _get_unpatched 
    File "/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4/src/setuptools/dist.py", line 16, in <module> 
    from setuptools.depends import Require 
    File "/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4/src/setuptools/depends.py", line 6, in <module> 
    from setuptools import compat 
    File "/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4/src/setuptools/compat.py", line 19, in <module> 
    from SimpleHTTPServer import SimpleHTTPRequestHandler 
    File "/Users/sam/Downloads/sage-6.7/local/lib/python/SimpleHTTPServer.py", line 16, in <module> 
    import urllib 
    File "/Users/sam/Downloads/sage-6.7/local/lib/python/urllib.py", line 1399, in <module> 
    from _scproxy import _get_proxy_settings, _get_proxies 
ImportError: No module named _scproxy 

real 0m0.113s 
user 0m0.059s 
sys 0m0.037s 
************************************************************************ 
Error installing package setuptools-12.4 
************************************************************************ 
Please email sage-devel (http://groups.google.com/group/sage-devel) 
explaining the problem and including the relevant part of the log file 
    /Users/sam/Downloads/sage-6.7/logs/pkgs/setuptools-12.4.log 
Describe your computer, operating system, etc. 
If you want to try to fix the problem yourself, *don't* just cd to 
/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4 and type 'make' or whatever is appropriate. 
Instead, the following commands setup all environment variables 
correctly and load a subshell for you to debug the error: 
    (cd '/Users/sam/Downloads/sage-6.7/local/var/tmp/sage/build/setuptools-12.4' && '/Users/sam/Downloads/sage-6.7/sage' --sh) 
When you are done debugging, you can type "exit" to leave the subshell. 
************************************************************************ 

編輯:好吧,我不知道發生了什麼事情,但我對重新開始建設,這似乎工作。我沒有任何gcc。當我輸入gcc -v時,有一個答案是我有叮噹而不是它...當我第一次在make時,控制檯要我重命名我的目錄opt/local,因爲它是自制軟件。是不是認爲這是第一次沒有工作。在編譯聖人期間,我將其重命名爲opt/local ...

+0

Sage *應該*建立在約塞米蒂,許多開發者擁有它。我們能否假設您擁有適用於Mac OS的所有開發人員工具? (如果沒有他們,我認爲你不會這麼做。) – kcrisman

回答

1

可能這是由於Python構建(Sage的Python,也就是)未成功構建此模塊;見this sage-release thread。原則上http://trac.sagemath.org/ticket/17174應該已經修復它(請參閱http://trac.sagemath.org/ticket/17169),但也許您正在使用非Sage gcc,如自制軟件?在這種情況下,你需要在某個地方製作that change,或者也許只需要使用Sage的gcc,你可以用SAGE_INSTALL_GCC=yes(儘管這會花費更長的時間)。祝你好運!

+0

是的!我用'brew install gcc47'。它不會改變任何東西。 (我只是複製並粘貼'SAGE_INSTALL_GCC = yes'在運行之前再次make)。也許我應該嘗試從一開始就重新制作它? – Bleuderk

+0

是的,如果發生任何事情,你將不得不重建Sage內部的Python。你可以用'sage -f python'來完成這個工作,但是可能只需要把'make clean && make'和Sage gcc一起使用就可以了。 – kcrisman

+0

PS你會想要確保你沒有Fink或Macport的方式,以防萬一這是問題的一部分。 – kcrisman