meelgroup / approxmc

Approximate Model Counter
Other
70 stars 26 forks source link

main.cpp(265): error C2065: 'solver': undeclared identifier #12

Closed jiayiyang1997 closed 4 years ago

jiayiyang1997 commented 4 years ago

Hello,

I just tried to build ApproxMC on my local machine (Windows OS) and I met this error during the build process. I've checked this line of code in the main.cpp file. It seems that we didn't declare the variable "solver" before we use it (there are one "solver2" and one "appmc->solver"). Is that a typo? I'm just wondering which variable we should use here. Hope I can get some explanation for that. Thank you very much!

P.S. I built it successfully in the Mac OS with the same source code. No idea why there didn't appear any error during the building process.

msoos commented 4 years ago

Hi,

Thanks for your interest. Can you please give me the full output? Also, please make absolutely sure you are using cmake for building on Windows:

SET CMAKE_GENERATOR="Visual Studio 15 2017 Win64"
SET MSBUILD_FLAGS="/maxcpucount /nologo /property:WarningLevel=1"
cmake -G %CMAKE_GENERATOR% -DENABLE_PYTHON_INTERFACE=OFF -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON ..
cmake --build . --config Release

You will have to build CryptoMiniSat similarly, with -DUSE_GAUSS=ON in the cmake command, too. If you encounter this issue again, please give the absolute full log of everything above. Please delete the folder, re-clone, then do the above and send us all of the build logs, including the complete build for CryptoMiniSat.

Let us know how it went and looking forward to helping you out, once you can give us the full and complete build logs,

Mate

kuldeepmeel commented 4 years ago

Closing the issue based on positive reaction from OP.