How to install ZeroMQ for C++ using VS2015 community - c++

I am trying to learn networking in windows in C++ (specifically for making a very simple mmo server).
I was reading about cross-platform-ness and socket complexity and came accross both protobuf and zeroMQ quite a lot.
After reading about zeroMQ I decided it makes sense for an mmo server.
So i went over to the zeroMQ website and downloaded the msi installer. I ran it, and now i'm stuck.
I don't quite understand what the MSI did... Did it plop a zeroMQ.dll in system32? Di I still need to get the C++ binding? Basically, how do you install zeromq for C++?
P.S. extra points if someone shows me how to do it with Nuget. I guess that's why I don't know how to install libraries manually, I always use Nuget...
Thanks.

Nuget does have a package for ZeroMQ, but that seems to be only for C# currently.
The MSI you installed contains Python binding for ZeroMQ, and is installed for the selected python version in the installer.
For C++, they have pre-build binaries on their download page.
However, these libraries are build with an older version of Visual Studio, which are not compatible with Visual Studio 2015. If you want to use ZeroMQ, i'm afraid you are going to have to build the library your self.
When you have successfully build ZeroMQ, you can follow their guide to get a feeling of how to use it. Or you can add the C++ bindings which has a pretty and easy-to-use interface.

Related

How do you install vckpg for Visual Studio Code on Windows?

I am trying to install libcurl for my C++ project on VSCode and I came across a method to install via vckpg from this link: How do you properly install libcurl for use in visual studio 2017?
Hence, I looked for the documentation by Microsoft but only found that you can install vckpg for VSCode for Linux and MacOS but I couldn't find anything on how to install vckpg for VSCode on Windows.
Any idea how do you install vckpg for VSCode on Windows? Or is there an alternative method of installing libcurl on VSCode?
Currently VS Code does not support vcpkg on Windows.
As mentioned here the following issue is directly connected with VS Code support of vcpkg on Windows: https://github.com/microsoft/vcpkg/issues/10217. The issue is currently open and no workaround is provided.
The support may be provided in the future. Here are the comments from the thread:
ghost: "If there are enough requests, a feature request could be initiated to see what would be needed to integrate with CODE RUNNER and/or a plugin for VSCODE."
strega-nil: "Code Runner is not currently a supported way of building with vcpkg; we may add support eventually, but more likely it should be added by the community (or, even better, vcpkg support should be added to Code Runner). However, we do have features hopefully coming down the pipeline which will make life a lot easier for community members adding that support."
Unfortunately i was struggling with the same issue and installing C++ Redistributable which #mutantkeyboard recommended didn't solve the problem.
I installed VS Community Edition with English language pack and now it's OK.

How to install spread library on Windows

Ther are many articles about how to install spread library on Linux(1. download source & unzip it 2.run ./config 3. make 4. make install) but seems no article about how to install spread on Windows......
I had downloaded spread-bin-4.4.0-Windows8_x64 from official site(my environemnt is win10), but there is no .bat or .exe file found under the unzipped folder. Does anyone know how to install spread library on Windows?
In linux, there is a standard way of installing libraries that all the software on your machine is supposed to use. In part this works because all that software is chosen in such a way that the same versions of libraries will satisfy everyone, that's what makes up a linux distribution to some extent.
In windows, the model of development is totally different. Any third party software, not from microsoft, is something the customer paid for and microsoft never signs off on it or anything. Third party stuff generally is supposed to provide its own libraries since you have no idea what other third party stuff is present. There's not much point in globally installing things since most programs won't use what you globally install anyways.
So, if you have a library on windows, you should install in whatever way the program that you intend to use it with will find it. If you are intending to install it for use with a project you are developing, that is a different question, and ultimately one about your build system or IDE.
In modern days there are things like NuGet which allow you to do things in a more linuxy way on windows. But that's quite recent and not that much software from typical user's perspective gets its dependencies that way.
After further study, I found a Visual Studio solution file:spread.sln under \win32 folder! So in conclusion, to install Spread libarary on Windows:
1. get source codes from http://www.spread.org/download.html
2. unzip
3. open solution file under \win32 folder with Visual Studio
(Please note that "do not" use relatively new version of VS since this solution is built with older VS(like VS 2010) otherwise unexpected errors occurred)
4. build solution
There you go! You can build your project with Spread library now!
P.S. This spread.sln is a Win32 solution. I'm just wonder is there a Win64 version solution file......

Compiling cairo (cairomm) on Windows

I'm trying to compile cairo into a lib file using Mingw. I've downloaded the cairo, cairomm, and pixman source packages, but I can't figure out where to go from here. The INSTALL help file talks about a bunch of scripts that I can't seem to run or even find ('./configure', 'make', 'make install'). Googling the issue is bringing up nothing helpful.
I feel like this is a noobish question to ask. I've only recently started getting into the C++ side of programming (coming from Java/C#), and this is the first time I've had to compile an external library before using it. The shocking lack of explanations on the process makes me wonder if there was some chapter of a tutorial somewhere I was supposed to read that makes this whole process a complete no-brainer.
I think this project isn't supporting building with Mingw.
There are build instructions here for building with Visual Studio (which can be downloaded for free as the Visual Studio Express Edition from MS Website: http://www.visualstudio.com/en-US/products/visual-studio-express-vs
Build instructions here:
http://cairographics.org/end_to_end_build_for_win32/
It's probably possible to make this work for MingW, but you will have to make it work yourself, which may be a bit of a long step for someone who is new to compilers and build scripts in general.

installing thrift idl

Basically I have no idea how to create the lib files. The VS solution that come with thrift(0.9.0) say they are created with a newer version and therefore cant' be open with VS 2008. I've also tried installing or running the ./bootstrap.sh but I keep getting an error saying that the file is not an executable.I've been screwing with this for hours and can't figure it out so if someone who knows how to install thrift please guide me.
I haven't been using thrift on windows, but I hope it doesn't matter. First you have to install thrift locally (0.8.0, 0.9.0, whatever). On linux you run ./configure, make, make install. Once you've got your thrift locally installed, you do have the thrift binary and you should make sure it is on the shell path (on linux it's /usr/local/bin/thrift). Then create a thrift definition file with a service, run the thrift binary against that file and thrift will generate code for you (I assume you'll generate C++ code).
Now - for each programming language thrift generates different files, of course. In scripting languages you have to include them manually. In Java you will have a package and you can use it in the rest of the code. And in C++ you'll get .h and .cpp files which you should compile into a library. I strongly encourage you to use cmake, which is a wonderful tool to perform such things automatically.
Anyway, I wouldn't expect that MS Visual Studio will happily cooperate with open source software such as Apache Software Foundation projects ;)
You need use VS2012 and boost_155 like minimum to create the thrift lib files.

Is there a downloadable distribution of Thrift for Windows?

I've been reading quite a bit about Thrift and it looks like a technology I'd really like to use. I'm having all sorts of trouble building the Windows distribution. I know a patch exists to build a Windows version, however I have not had much luck with this either.
Does anyone know of a pre-built distribution for Windows?
Or any suggestions on how to get the latest version of Thrift built (without turning my Windows machine into a pseudo *nix box).
Thanks
Rich
Thrift 0.8 now has VS projects for both the compiler and C++ library. Get the snapshot release or the latest off of SVN
http://thrift.apache.org/download/
Edit: 0.8 has been officially released and the source is available as a tarball on the download page.
Edit2: The SVN trunk now has a cross-platform sample project under thrift/contrib/transport-sample
I ported the client part of Thrift to Windows C++ for my own open-source project. It should be easily usable in other Win32 or WinCE projects.
http://peoplesnote.codeplex.com - src\Evernote API\Thrift
Yes there is, just download the exe from here:
http://thrift.apache.org/download/
exe listed for download there is standalone executable, no installation is needed.
I have used it to generate Smalltalk code, did not test other languages.