首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >使用Spring框架的依赖项构建发行版

使用Spring框架的依赖项构建发行版
EN

Stack Overflow用户
提问于 2014-08-02 13:28:11
回答 1查看 282关注 0票数 1

我学习了Spring开发,并按照Github上的一个项目一步一步地尝试配置Spring框架(网站是:https://github.com/spring-projects/spring-framework/wiki/Building-a-distribution-with-dependencies)。在键入命令$ ./gradlew depsZip to Run the depsZip gradle task之后。以下信息显示失败:

代码语言:javascript
复制
:spring-aspects:compileJava
Download http://repo.springsource.org/libs-release/org/aspectj/aspectjrt/1.7.1/a
spectjrt-1.7.1.jar
[ant:iajc] C:\Users\Zihan\Documents\GitHub\spring-framework\spring-aspects\src\m
ain\java\org\springframework\beans\factory\aspectj\AbstractBeanConfigurerAspect.
aj:1 [error] The type java.lang.CharSequence cannot be resolved. It is indirectl
y referenced from required .class files
[ant:iajc] (no source information available)
[ant:iajc] C:\Users\Zihan\Documents\GitHub\spring-framework\spring-aspects\src\m
ain\java\org\springframework\mock\staticmock\AbstractMethodMockingControl.aj:19
[error] The import java.util.Arrays cannot be resolved
[ant:iajc] import java.util.Arrays;
[ant:iajc]        ^^^^^^^^^^^^^^^
[ant:iajc] C:\Users\Zihan\Documents\GitHub\spring-framework\spring-aspects\src\m
ain\java\org\springframework\mock\staticmock\AbstractMethodMockingControl.aj:87
[error] Arrays cannot be resolved
[ant:iajc] if (!Arrays.equals(this.args, args)) {
[ant:iajc]      ^
[ant:iajc]
[ant:iajc] 3 errors
:spring-aspects:compileJava FAILED

FAILURE: Build failed with an exception.

* Where:
Script 'C:\Users\Zihan\Documents\GitHub\spring-framework\spring-aspects\aspects.
gradle' line: 30

* What went wrong:
Execution failed for task ':spring-aspects:compileJava'.
> compile errors: 3

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug
option to get more log output.

BUILD FAILED

Total time: 42.798 secs
C:\Users\Zihan\Documents\GitHub\spring-framework [(abdcefb...)]>

能帮我解决配置问题吗?如果能给我一些指导,我会很感激的。

提前感谢!

EN

回答 1

Stack Overflow用户

发布于 2014-08-02 16:32:16

首先,为什么你不能使用像maven或gradle这样的依赖管理工具?在你的链接上我读到

虽然强烈建议Spring Framework用户利用Gradle、Maven和Ivy等构建系统的可传递依赖项管理功能,但有些团队无法使用这些工具。这通常是由于公司的限制或使用遗留版本造成的

使用上面定义的工具,简单地构建和维护一个spring项目。然后,要开始一个spring项目,您可以遵循下面的Building Spring Project

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/25091978

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档