How do I get Eclipse to resolve classes generated with Maven 2?

前端 未结 9 886
日久生厌
日久生厌 2020-12-12 22:11

I\'m using Google Protocol Buffers to generate some Java classes for my project. Using Maven 2 and its \"antrun\" plugin, these classes are freshly generated before compile,

9条回答
  •  暖寄归人
    2020-12-12 22:41

    What you should see in your project explorer is a container named "Maven Dependencies" in place of the usual "Referenced libraries". This means m2eclipse is managing your build path.

    In my case, to achieve this, I checked "Include Modules" and unchecked "Skip Maven compiler plugin when processing resources" on the "Maven" section of Project->Properties.

提交回复
热议问题