【问题标题】:Porting Axis2 project to sbt / scala: how to deal with .mar files?将 Axis2 项目移植到 sbt / scala:如何处理 .mar 文件?
【发布时间】:2013-10-10 22:24:38
【问题描述】:

我正在将一个 Java / Maven 应用程序移植到 sbt / scala 上,但我遇到了 Axis2 依赖项的一些问题,即需要将“addressing.mar”工件拉入项目中。 SBT 对此感到窒息,我也想要这个想法插件来创建文件。

目前构建给出并出现错误,但我能够将文件放入本地 lib 文件夹并以这种方式将其拉入项目中。

更多关于 MAR 的信息在这里:http://ssagara.blogspot.com/2009/03/axis2-maven-module-mar-plug-in.html

我想使用:

libraryDependencies += "org.apache.axis2" % "addressing" % "1.5.6"

这不起作用;等效的 mvn dep 将是:

<dependency>
  <groupId>org.apache.axis2</groupId>
  <artifactId>addressing</artifactId>
  <version>1.5.6</version>
  <type>mar</type>
</dependency>

我希望我可以在依赖 ala 的末尾附加一些内容:

libraryDependencies += "org.apache.axis2" % "addressing" % "1.5.6" % withType("mar")

但我还没有找到方法。

SBT:0.12.2

【问题讨论】:

    标签: scala build sbt


    【解决方案1】:

    工件已正确解决,您可以使用show update 或查看target/resolution-cache/reports/ 中的解决报告来查看。但是,默认情况下它不包含在类路径中。 managedClasspath 中包含的工件类型由classpathTypes 控制。要包含mar,请设置:

    classpathTypes += "mar"
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-04-15
      • 1970-01-01
      • 2012-01-12
      • 1970-01-01
      • 2011-02-27
      • 2018-11-16
      相关资源
      最近更新 更多