iteye_19183 2009-07-16 13:17
浏览 1019
已采纳

mvn install时提示 软件包 org.apache.log4j 不存在

D:\maven\simple-weather>mvn install
[INFO] Scanning for projects...

[INFO] -------------------------------------------------------------------------

[INFO] Building simple-weather
[INFO] task-segment: [install]

[INFO] -------------------------------------------------------------------------

[INFO] [resources:resources]
[INFO] Using default encoding to copy filtered resources.
[INFO] [compiler:compile]
[INFO] Compiling 5 source files to D:\maven\simple-weather\target\classes
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\WeatherForm
atter.java:[7,24] 软件包 org.apache.log4j 不存在

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\WeatherForm
atter.java:[13,23] 找不到符号
符号: 类 Logger
位置: 类 org.sonatype.mavenbook.weather.WeatherFormatter

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooParser
.java:[7,24] 软件包 org.apache.log4j 不存在

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooParser
.java:[14,23] 找不到符号
符号: 类 Logger
位置: 类 org.sonatype.mavenbook.weather.YahooParser

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooRetrie
ver.java:[7,24] 软件包 org.apache.log4j 不存在

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooRetrie
ver.java:[11,23] 找不到符号
符号: 类 Logger
位置: 类 org.sonatype.mavenbook.weather.YahooRetriever

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\Main.java:[
5,24] 软件包 org.apache.log4j 不存在

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\WeatherForm
atter.java:[13,36] 找不到符号
符号: 变量 Logger
位置: 类 org.sonatype.mavenbook.weather.WeatherFormatter

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooParser
.java:[14,36] 找不到符号
符号: 变量 Logger
位置: 类 org.sonatype.mavenbook.weather.YahooParser

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\YahooRetrie
ver.java:[11,36] 找不到符号
符号: 变量 Logger
位置: 类 org.sonatype.mavenbook.weather.YahooRetriever

D:\maven\simple-weather\src\main\java\org\sonatype\mavenbook\weather\Main.java:[
12,16] 找不到符号
符号: 变量 PropertyConfigurator
位置: 类 org.sonatype.mavenbook.weather.Main

[INFO] ------------------------------------------------------------------------
[INFO] For more information, run Maven with the -e switch
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2 seconds
[INFO] Finished at: Thu Jul 16 13:00:39 CST 2009
[INFO] Final Memory: 5M/10M
[INFO] ------------------------------------------------------------------------

D:\maven\simple-weather>

  • 写回答

2条回答 默认 最新

  • wanghaolovezlq 2009-07-16 13:18
    关注

    simple-weather这个工程依赖log4j啊,你没加入吧

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 教务系统账号被盗号如何追溯设备
  • ¥20 delta降尺度方法,未来数据怎么降尺度
  • ¥15 c# 使用NPOI快速将datatable数据导入excel中指定sheet,要求快速高效
  • ¥15 再不同版本的系统上,TCP传输速度不一致
  • ¥15 高德地图点聚合中Marker的位置无法实时更新
  • ¥15 DIFY API Endpoint 问题。
  • ¥20 sub地址DHCP问题
  • ¥15 delta降尺度计算的一些细节,有偿
  • ¥15 Arduino红外遥控代码有问题
  • ¥15 数值计算离散正交多项式