Should I distribute log4net with my releases?

我的未来我决定 提交于 2019-12-12 12:23:05

问题


I am wondering what is best practice when it comes to dependencies and how releases should be done. In my case I have a library that relies on log4net and I am wondering if I should distribute log4net.dll (set the log4net reference to copy local) along with the release?

Could I simply state that log4net should be installed in the GAC?


回答1:


Relying on libraries in the GAC can cause version conflicts and other problems that are very hard to troubleshoot and debug. I always try to distribute everything with my software.




回答2:


I'm not a big fan of putting log4net (or NUnit) in the GAC. I prefer keeping 3rd party libraries local - it makes it clearer what the dependencies are and what version you're using. It also means that anyone wanting to get started with your project can just download, extract, and build.

So yes, I suggest you distribute log4net.dll, along with its licence agreement.

Have a look at the lib directory for my ProtoBuf port for example.



来源:https://stackoverflow.com/questions/304859/should-i-distribute-log4net-with-my-releases

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!