nmslib / nmslib

Non-Metric Space Library (NMSLIB): An efficient similarity search library and a toolkit for evaluation of k-NN methods for generic non-metric spaces.
Apache License 2.0
3.4k stars 450 forks source link

Update CMakeLists.txt to enable build on Windows #164

Closed searchivarius closed 6 years ago

searchivarius commented 7 years ago

Now it's time to get rid of storing MSVC makefiles. Then could and should be generated by CMake GUI.

You would need to update manual to highlight the couple of nuances, the story would roughly unfold as follows:

In CMake GUI

1) Select the source code folder (root... similarity_search) 2) Select an arbitrary folder to store the MSVC project (screen shot) 3) Open a project in MSVC and modify the code generation option for the Release and/or Debug configurations. The user has to specify multiple sub-projects except a few ones with all-capital ones. Specify: 3.1) Parallel code generation for faster builds 3.1) Enhanced instructions, probably, this should be mostly AVX, b/c AVX is universally supported 3.2) Fast math 4) Run the build! 5) When you run bunit, you run it from the similarity_search subfolder.

The screen shots are attached. cmakedialog settingprojectoptions

searchivarius commented 7 years ago

Actually, this may not be enough, we need to ensure the following options are set in the project file:

     <OpenMPSupport>true</OpenMPSupport>
      <MultiProcessorCompilation>true</MultiProcessorCompilation>
searchivarius commented 6 years ago

This should actually be nearly complete.