mac安装thrift0.5.0报错解决

由于工作原因,需要在mac中安装thrift0.5.0,在执行make的时候一直报错:

[ivy:retrieve] :: problems summary ::
[ivy:retrieve] :::: WARNINGS
[ivy:retrieve] 		module not found: org.slf4j#slf4j-api;1.5.8
[ivy:retrieve] 	==== local: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/org.slf4j/slf4j-api/1.5.8/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-api;1.5.8!slf4j-api.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/org.slf4j/slf4j-api/1.5.8/jars/slf4j-api.jar
[ivy:retrieve] 	==== shared: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/org.slf4j/slf4j-api/1.5.8/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-api;1.5.8!slf4j-api.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/org.slf4j/slf4j-api/1.5.8/jars/slf4j-api.jar
[ivy:retrieve] 	==== public: tried
[ivy:retrieve] 	  http://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.5.8/slf4j-api-1.5.8.pom
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-api;1.5.8!slf4j-api.jar:
[ivy:retrieve] 	  http://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.5.8/slf4j-api-1.5.8.jar
[ivy:retrieve] 		module not found: commons-lang#commons-lang;2.5
[ivy:retrieve] 	==== local: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/commons-lang/commons-lang/2.5/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact commons-lang#commons-lang;2.5!commons-lang.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/commons-lang/commons-lang/2.5/jars/commons-lang.jar
[ivy:retrieve] 	==== shared: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/commons-lang/commons-lang/2.5/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact commons-lang#commons-lang;2.5!commons-lang.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/commons-lang/commons-lang/2.5/jars/commons-lang.jar
[ivy:retrieve] 	==== public: tried
[ivy:retrieve] 	  http://repo1.maven.org/maven2/commons-lang/commons-lang/2.5/commons-lang-2.5.pom
[ivy:retrieve] 	  -- artifact commons-lang#commons-lang;2.5!commons-lang.jar:
[ivy:retrieve] 	  http://repo1.maven.org/maven2/commons-lang/commons-lang/2.5/commons-lang-2.5.jar
[ivy:retrieve] 		module not found: javax.servlet#servlet-api;2.5
[ivy:retrieve] 	==== local: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/javax.servlet/servlet-api/2.5/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact javax.servlet#servlet-api;2.5!servlet-api.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/javax.servlet/servlet-api/2.5/jars/servlet-api.jar
[ivy:retrieve] 	==== shared: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/javax.servlet/servlet-api/2.5/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact javax.servlet#servlet-api;2.5!servlet-api.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/javax.servlet/servlet-api/2.5/jars/servlet-api.jar
[ivy:retrieve] 	==== public: tried
[ivy:retrieve] 	  http://repo1.maven.org/maven2/javax/servlet/servlet-api/2.5/servlet-api-2.5.pom
[ivy:retrieve] 	  -- artifact javax.servlet#servlet-api;2.5!servlet-api.jar:
[ivy:retrieve] 	  http://repo1.maven.org/maven2/javax/servlet/servlet-api/2.5/servlet-api-2.5.jar
[ivy:retrieve] 		module not found: org.slf4j#slf4j-log4j12;1.5.8
[ivy:retrieve] 	==== local: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/org.slf4j/slf4j-log4j12/1.5.8/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-log4j12;1.5.8!slf4j-log4j12.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/org.slf4j/slf4j-log4j12/1.5.8/jars/slf4j-log4j12.jar
[ivy:retrieve] 	==== shared: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/org.slf4j/slf4j-log4j12/1.5.8/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-log4j12;1.5.8!slf4j-log4j12.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/org.slf4j/slf4j-log4j12/1.5.8/jars/slf4j-log4j12.jar
[ivy:retrieve] 	==== public: tried
[ivy:retrieve] 	  http://repo1.maven.org/maven2/org/slf4j/slf4j-log4j12/1.5.8/slf4j-log4j12-1.5.8.pom
[ivy:retrieve] 	  -- artifact org.slf4j#slf4j-log4j12;1.5.8!slf4j-log4j12.jar:
[ivy:retrieve] 	  http://repo1.maven.org/maven2/org/slf4j/slf4j-log4j12/1.5.8/slf4j-log4j12-1.5.8.jar
[ivy:retrieve] 		module not found: junit#junit;4.4
[ivy:retrieve] 	==== local: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/junit/junit/4.4/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact junit#junit;4.4!junit.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/local/junit/junit/4.4/jars/junit.jar
[ivy:retrieve] 	==== shared: tried
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/junit/junit/4.4/ivys/ivy.xml
[ivy:retrieve] 	  -- artifact junit#junit;4.4!junit.jar:
[ivy:retrieve] 	  /Users/pilaf/.ivy2/shared/junit/junit/4.4/jars/junit.jar
[ivy:retrieve] 	==== public: tried
[ivy:retrieve] 	  http://repo1.maven.org/maven2/junit/junit/4.4/junit-4.4.pom
[ivy:retrieve] 	  -- artifact junit#junit;4.4!junit.jar:
[ivy:retrieve] 	  http://repo1.maven.org/maven2/junit/junit/4.4/junit-4.4.jar
[ivy:retrieve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:retrieve] 		::          UNRESOLVED DEPENDENCIES         ::
[ivy:retrieve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:retrieve] 		:: org.slf4j#slf4j-api;1.5.8: not found
[ivy:retrieve] 		:: commons-lang#commons-lang;2.5: not found
[ivy:retrieve] 		:: javax.servlet#servlet-api;2.5: not found
[ivy:retrieve] 		:: org.slf4j#slf4j-log4j12;1.5.8: not found
[ivy:retrieve] 		:: junit#junit;4.4: not found
[ivy:retrieve] 		::::::::::::::::::::::::::::::::::::::::::::::
[ivy:retrieve] 
[ivy:retrieve] :: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS

BUILD FAILED
/Users/pilaf/software/thrift-0.5.0/lib/java/build.xml:119: impossible to resolve dependencies:
	resolve failed - see output for details

Total time: 1 second
make[3]: *** [all-local] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

查了好多资料,说可能是ant的代理没设置的,于是在~/.bash_profile中增加了:

export ANT_OPTS="-Dhttp.proxyHost=127.0.0.1 -Dhttp.proxyPort=8087"

然后执行 source ~/.bash_profile
再重新执行make就不报错了,最后成功make install

参考文章:
1.安装步骤:http://blog.leanote.com/post/du00/Mac-OSX- 
2.ant代理:https://liu-hliang.iteye.com/blog/456664
https://www.aliyun.com/zixun/content/6_18_2074881.html

猜你喜欢

转载自blog.csdn.net/lzufeng/article/details/86490209