Maven project with native dependency and copying files

前端 未结 1 1376
栀梦
栀梦 2020-12-01 14:44

I have the following scenario:

mylib is a library (for which I have the sources, so I\'d like to put them into a Maven project mylib:mylib for example). This library

相关标签:
1条回答
  • 2020-12-01 15:03

    The base idea is the following:

    • Maven is good in handling with one result per Maven POM.
    • It is possible to have libraries and dependencies to these libraries in your local repositories only.

    So you have to do the following steps:

    1. Define for the additional library a separate project (or a module in your project) and define the library as the result.
    2. Change your POM so that this POM has now a dependency to the new project.
    3. Do the same steps for your DLL (see the post Managing DLL dependencies with Maven) how to do that).
    4. Deploy your additional library and your DLL to your local repository.

    Now you should be able to use Maven for the build process again, and by using additional plugins like the maven-assembly-plugin, you are able to pack all together.

    0 讨论(0)
提交回复
热议问题