0

While building the Windows environment for OsQuery (on my Windows 10 VM) from their website(link: https://osquery.readthedocs.io/en/stable/development/windows-provisioning/), I am getting the msb1009 error during the phase where I have to run the tools\make-win64-binaries.bat command. I get the following result after running that command:

CMake Error at CMakeLists.txt:402 (project): Failed to run MSBuild command:

  C:/Program Files (x86)/Microsoft Visual Studio/2017/Community/MSBuild/15.0/Bin/MSBuild.exe

to get the value of VCTargetsPath:

 Microsoft (R) Build Engine version 15.7.179.6572 for .NET Framework
    Copyright (C) Microsoft Corporation. All rights reserved.

    MSBUILD : error MSB1009: Project file does not exist.
    Switch: VCTargetsPath.vcxproj

Exit code: 1

-- Configuring incomplete, errors occurred! See also "C:/Windows/System32/osquery/build/windows10/CMakeFiles/CMakeOutput.log". Microsoft (R) Build Engine version 15.7.179.6572 for .NET Framework Copyright (C) Microsoft Corporation. All rights reserved.

MSBUILD : error MSB1009: Project file does not exist. Switch: osquery.sln

[-] osquery build failed.

I have been trying to make the osquery.sln file using that command and have looked online for solutions but without any success. Any help would be much appreciated!

Thanks in advance

Edit: Here is the output of running tools\make-win64-dev-env.bat and tools\make-win64-binaries.bat tools\make-win64-dev-env.bat

tools\make-win64-dev-env.bat (contd..)

tools\make-win64-binaries.bat

2 Answers2

1

Could you paste the full output of running the tools\make-win64-dev-env.bat and tools\make-win64-binaries.bat? Also have you tried closing out your shell and re-opening, or even worse -- reboot the system?

I ask because, as you note, it seems like the solution file never gets generated, which usually means there was either a missing dependency during provision, or some other issue when the script first ran. On first provision it's typically the case that a system reboot is needed, as Visual Studio community typically requires one. Further, we set a few shell environment variables that are leveraged during the build process, however those are supposed to be set at the end of the provisioning script.

Also feel free to hit us up in our Slack and check out the #windows channel :)

Muffins
  • 66
  • 4
  • I ran the commands after restarting my VM. Please take a look at the links for the outputs. Thanks for the help! – Bit_by_bit Jun 19 '18 at 17:00
0

After a lot of code reading, researching online and trial and error, I found out that after a clean OS install, one would need to install git and then immediately clone the osquery repository on the user desktop rather than System32. This worked fine, at least for me. Just make sure to switch directories when opening command line with administrator mode.