Building on windows (ICU install)


Are there any windows users out there using visual studio? What sorts of steps did you take to get the repository to build?

I’m struggling a bit with how to get ICU on my windows PC. Any suggestions?

I love the idea of a text analytics library for C++.


ICU binaries not found Windows VS 2017 cmake

If you have MSVC 2017 and you use the develop branch, things should compile for you. We run this configuration under CI now.

Have a look here:, which should give you some direction for how to get the dependent libraries set up. (Note that you don’t need to use the Ninja generator; we just do this in CI because it’s faster than MSBuild).

Essentially, you’ll want to download the pre-compiled libraries for ICU from their website and use -DICU_ROOT=WhereverYouExtractedThem in your cmake invocation. You’ll also need to either build zlib from scratch (what we do in CI) or have pre-built binaries for it and use -DZLIB_ROOT=WhereverYouBuiltZlib as well.


Thanks for the quick reply! I used the cmake-gui and added those two options as you suggested.

Everything seems to be working now!

Interestingly, I only needed to add the ZLIB option when compiling in 64 bit. It worked fine without having to explicitly point to the folder when compiling 32.

Thanks again!

Quick notes on how to install for other windows users:

  1. Clone the development branch of the repository to your local drive. (Make sure all the files have cloned.) Github for desktop is pretty helpful for this.
  2. Install zlib at
  3. Download the ICU components and unzip them somewhere or something like that.
  4. Download and install cmake-gui
  5. Make sure you have windows visual studio '17.
  6. Run cmake-gui and open the \meta\ folder you cloned to. Then choose a folder to compile to.
  7. Add two additional arguments (Add Item…) both of which are path arguments.
    7a) ZLIB_ROOT = C:\Program Files (something)\GnuWin32\ or something like that
    7b) ICU_ROOT = the top level of the ICU folder (should have subfolders like lib64)
  8. Hit configure, then generate, then open project.
  9. You should be golden at this point.


I still have build errors.

When I try to build all 91 projects at the same time, I get ~50 errors.

When I build only the pos-tag project, I get a linker error because its looking for lib files that don’t seem to be on my computer.