Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/macos/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python Can';t安装橙色:“;错误:命令';叮当作响';失败,退出状态为“1”;_Python_Macos_Gcc_Orange - Fatal编程技术网

Python Can';t安装橙色:“;错误:命令';叮当作响';失败,退出状态为“1”;

Python Can';t安装橙色:“;错误:命令';叮当作响';失败,退出状态为“1”;,python,macos,gcc,orange,Python,Macos,Gcc,Orange,我正在尝试在我的MacOSX10.7.3(Lion)上安装,但在使用pip或从源代码构建时,我不断遇到错误。首先,我得到一个错误,如下所示: error: command 'gcc-4.0' failed with exit status 1 我有Xcode 4,它与gcc 4.2.1捆绑在一起。所以我安装了GCC4.2,它内置了GCC4.2。我还尝试使用以下命令覆盖编译器选项: export CC=gcc-4.2 但这产生了一个不同的错误: gcc-4.2 not found, using

我正在尝试在我的MacOSX10.7.3(Lion)上安装,但在使用pip或从源代码构建时,我不断遇到错误。首先,我得到一个错误,如下所示:

error: command 'gcc-4.0' failed with exit status 1
我有Xcode 4,它与gcc 4.2.1捆绑在一起。所以我安装了GCC4.2,它内置了GCC4.2。我还尝试使用以下命令覆盖编译器选项:

export CC=gcc-4.2
但这产生了一个不同的错误:

gcc-4.2 not found, using clang instead
...
error: command 'clang' failed with exit status 1
以下是完整日志:

$ python setup.py build
running build
running build_py
copying Orange/version.py -> build/lib.macosx-10.6-intel-2.7/Orange
running build_ext
gcc-4.2 not found, using clang instead
building 'Orange.orange' extension
running pyxtract for Orange.orange
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python ../pyxtract/defvectors.py
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python ../pyxtract/pyprops.py -n orange
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python ../pyxtract/pyxtract.py -m -n orange lib_kernel.cpp lib_components.cpp lib_preprocess.cpp lib_learner.cpp lib_io.cpp lib_vectors.cpp cls_example.cpp cls_value.cpp cls_orange.cpp cls_misc.cpp functions.cpp orange.cpp
Parsing lib_kernel.cpp
Parsing lib_components.cpp
Parsing lib_preprocess.cpp
Parsing lib_learner.cpp
Parsing lib_io.cpp
Parsing lib_vectors.cpp
Parsing cls_example.cpp
Parsing cls_value.cpp
Parsing cls_orange.cpp
Parsing cls_misc.cpp
Parsing functions.cpp
Parsing orange.cpp
Warning: class 'PearsonCorrelation' will not be picklable
Warning: class 'ItemsetNodeProxy' will not be picklable
clang -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -INone -Isource/include -Isource/orange/liblinear -Isource/orange/ppp -Isource/orange/px -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c source/orange/assoc.cpp -o build/temp.macosx-10.6-intel-2.7/source/orange/assoc.o -fPIC -fpermissive -fno-common -w -DDARWIN -DORANGE_EXPORTS
clang: warning: argument unused during compilation: '-fpermissive'
In file included from source/orange/assoc.cpp:25:
In file included from source/orange/random.hpp:26:
In file included from source/orange/root.hpp:25:
source/orange/garbage.hpp:221:9: error: use of undeclared identifier 'raiseError'
        raiseError("bad cast from %s to %s", typeid(U).name(), typeid(T).name());
        ^
source/orange/garbage.hpp:253:7: error: use of undeclared identifier 'raiseError'
      raiseError("Orange internal error: NULL pointer to '%s'", TYPENAME(typeid(T)));
      ^
source/orange/garbage.hpp:261:7: error: use of undeclared identifier 'raiseError'
      raiseError("Orange internal error: NULL pointer to '%s'", TYPENAME(typeid(T)));
      ^
source/orange/garbage.hpp:301:7: error: use of undeclared identifier 'raiseError'
      raiseError("Orange internal error: NULL pointer to '%s'", TYPENAME(typeid(T)));
      ^
source/orange/garbage.hpp:312:7: error: use of undeclared identifier 'raiseError'
      raiseError("Orange internal error: NULL pointer to '%s'", TYPENAME(typeid(T)));
      ^
In file included from source/orange/assoc.cpp:27:
source/orange/examplegen.hpp:143:38: error: expected member name or ';' after declaration specifiers
  TExampleIterator::TExampleIterator(const TExampleIterator &other);
  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
source/orange/examplegen.hpp:143:38: error: expected ')'
source/orange/examplegen.hpp:143:37: note: to match this '('
  TExampleIterator::TExampleIterator(const TExampleIterator &other);
                                    ^
source/orange/assoc.cpp:33:1: error: explicit specialization of 'st_classDescription' after instantiation
DEFINE_TOrangeVector_classDescription(PAssociationRule, "TAssociationRules", true, ORANGE_API)
^
source/orange/orvector.hpp:105:57: note: expanded from macro 'DEFINE_TOrangeVector_classDescription'
    TClassDescription TOrangeVector< _TYPE, _WRAPPED >::st_classDescription = { _NAME, &typeid(TOrangeVector< _TYPE, _WRAPPED >), &TOrange::st_classDescription, TOrange_properties, TOrange_components };
                                                        ^
source/orange/ppp/assoc.ppp:111:72: note: implicit instantiation first required here
  {"rules", "association rules", &typeid(POrange), &TAssociationRules::st_classDescription, offsetof(TAssociationClassifier, rules), false, false, 0},
                                                                       ^
8 errors generated.
error: command 'clang' failed with exit status 1
$python setup.py build
运行构建
运行build\u py
复制Orange/version.py->build/lib.macosx-10.6-intel-2.7/Orange
运行build_ext
未找到gcc-4.2,请改用clang
建筑“橙色。橙色”分机
正在为Orange.Orange运行pyxtract
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python../pyxtract/deffectors.py
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python../pyxtract/pyprops.py-n橙色
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python../pyxtract/pyxtract.py-m-n orange lib_kernel.cpp lib_components.cpp lib_preprocess.cpp lib_learner.cpp lib_.cpp lib_vectors.cpp示例.cpp cls.cpp cls_值.cpp cls_orange.cpp cls misc函数.cpp orange.cpp
解析lib_kernel.cpp
解析lib_components.cpp
解析lib_preprocess.cpp
解析lib_learner.cpp
解析lib_io.cpp
解析lib_vectors.cpp
解析cls_example.cpp
解析cls_value.cpp
解析cls_orange.cpp
解析cls_misc.cpp
解析函数.cpp
解析orange.cpp
警告:“PearsonCorrelation”类将不可拾取
警告:类“ItemsetNodeProxy”将不可拾取
clang-fno严格别名-fno common-dynamic-arch i386-arch x86_64-g-O2-DNDEBUG-g-O3-I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7-INone-isoource/include-isoource/orange/ppp-isoource/orange/px-I/Library/Frameworks/Python.framework/Versions/2.7-include/python2.7-csource/orange/assoc.cpp-o build/temp.macosx-10.6-intel-2.7/source/orange/assoc.o-fPIC-fplication-fno common-w-DDARWIN-DORANGE\u导出
叮当声:警告:编译期间未使用参数:'-fppermissive'
在源代码/orange/assoc.cpp中包含的文件中:25:
在源代码/orange/random包含的文件中。hpp:26:
在源代码/orange/root.hpp中包含的文件中:25:
source/orange/garbage.hpp:221:9:错误:使用未声明的标识符'raiseError'
raiseError(“从%s到%s的错误转换”、typeid(U.name()、typeid(T.name());
^
source/orange/garbage.hpp:253:7:错误:使用未声明的标识符'raiseError'
raiseError(“橙色内部错误:指向“%s”的空指针,TYPENAME(typeid(T)));
^
source/orange/garbage.hpp:261:7:错误:使用未声明的标识符'raiseError'
raiseError(“橙色内部错误:指向“%s”的空指针,TYPENAME(typeid(T)));
^
source/orange/garbage.hpp:301:7:错误:使用未声明的标识符'raiseError'
raiseError(“橙色内部错误:指向“%s”的空指针,TYPENAME(typeid(T)));
^
source/orange/garbage.hpp:312:7:错误:使用未声明的标识符'raiseError'
raiseError(“橙色内部错误:指向“%s”的空指针,TYPENAME(typeid(T)));
^
在源代码/orange/assoc.cpp中包含的文件中:27:
source/orange/examplegen.hpp:143:38:错误:应为成员名或“;”后声明说明符
TExampleIterator::TExampleIterator(常量TExampleIterator&其他);
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^
source/orange/examplegen.hpp:143:38:错误:预期''
source/orange/examplegen.hpp:143:37:注:匹配此“(”
TExampleIterator::TExampleIterator(常量TExampleIterator&其他);
^
source/orange/assoc.cpp:33:1:错误:实例化后“st_classDescription”的显式专门化
定义\u TOrangeVector\u类描述(PAssociationRule,“tasociationRules”,true,ORANGE\u API)
^
source/orange/orvector.hpp:105:57:注意:从宏“DEFINE\u TOrangeVector\u classDescription”展开
TClassDescription TOrangeVector<\u TYPE,\u WRAPPED>::st\u classDescription={\u NAME,&typeid(TOrangeVector<\u TYPE,\u WRAPPED>),&TOrange::st\u classDescription,TOrange\u properties,TOrange\u components};
^
source/orange/ppp/assoc.ppp:111:72:注意:这里首先需要隐式实例化
{“规则”、“关联规则”、&typeid(POrange)、&TAssociationRules::st_classDescription,offsetof(TAssociationClassifier,rules),false,false,0},
^
产生了8个错误。
错误:命令“clang”失败,退出状态为1

问题已解决:Xcode 4实际上并没有随gcc-4.2一起提供;它随新的LLVM编译器一起提供

这只是一个做以下事情的问题:

export CC=llvm-gcc-4.2
export CXX=llvm-g++-4.2
然后构建橙色。

来自

如果你不需要的话,不必了解版本号的细节似乎更可靠,对吗?(我以前没有做过这种事情,所以我不确定。)

更新:当前的
pip安装orange
示例(如上)。要获取开发版本,请使用:

pip install -e hg+https://bitbucket.org/biolab/orange#egg=Orange

我从中获得了上述命令。

我必须执行以下操作来修复Mac OS Catalina上的错误。您可以在命令行中运行它,也可以将其放入您的
bash\u配置文件中

export CC=gcc
export CXX=clang

这里有一条错误消息-问题是什么?问题是我无法安装Orange,因为我不断遇到上述错误我有很多关于Orange的错误安装经验。对我来说从来都不一致。这就是为什么我只使用scikits.learn、scikits.image、scikits.timeseries和scikits.statsmodels。可能值得一看。Solv尝试使用pip安装“matplotlib”时遇到相同问题
export CC=gcc
export CXX=clang