2

I am trying out ZeroMQ to see if it can be used for my application. However, I have problem getting it to work.

OS: Windows 10 Programming Language: C# SDK: VS 2015 Enterprise

From what I read in order to use it in c#, I will need clrmq (which contains clr namspace for .NET) and zmq.

I gotten the "ZeroMQ.Release.zip" from "https://github.com/zeromq/clrzmq4/releases" and within it, it contains libzmq.dll, libsodium.dll (both from i386 folder in bin) and ZeroMQ.dll (from bin).

When I try to add references (of the mentioned 3 dlls) to my testing project, I got an error stating "libsodium.dll and libzmq.dll icould not be added. Please make sure that the file is accessible, and that it is a valid assembly or COM component."

In the end, I only manage to bring in ZeroMQ.dll.

Any help would be appreciated to help me start using zeroMQ in my testing.

Thanks.

user1599647
  • 487
  • 2
  • 7
  • 16
  • 3
    why don't you use the managed library? No need to include native DLLs then. https://github.com/zeromq/netmq – jgauffin Feb 18 '16 at 09:43
  • You just need `ZeroMQ` as `Reference`! You also need the files `libzmq.dll`,`libzmq.so`, `libsodium.dll`, `libsodium.so` in folders `i386` and `amd64`. Set the files also to `copy if newer`. – metadings Feb 18 '16 at 17:54
  • Thanks by added the libzmq as existing items instead of using add ref, I am able to use the it. – user1599647 Feb 19 '16 at 02:44

2 Answers2

3

Try to use NuGet package ZeroMQ. It will add required references properly.

Nikita
  • 6,270
  • 2
  • 24
  • 37
  • Thx, I know NUGet will help me to set up the reference properly. However my VS is on a offline network so it won't be able to get it. – user1599647 Feb 19 '16 at 01:06
  • @user1599647 It's not a problem. You can download NuGet package to your local drive and install it from there. Instruction can be found [here](http://stackoverflow.com/questions/10240029/how-to-install-a-nuget-package-nupkg-file-locally). – Nikita Feb 19 '16 at 06:06
0

Try to use Package Manage Console from Tools in VS. Install clrzmq and zeromq it'll solve all problem. In offline mode download the packages and install them.

user2877969
  • 149
  • 11