question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Windows: "The system cannot find the path specified" when using run-cmake and run-vcpkg

See original GitHub issue

The linux and apple builds works with my configuration, but not the windows one. I’m not sure I understand the error, so I r don’t know if it’s a bug from run-cmake or a problem in my configurations.

Here’ s the error:

► Run lukka/run-cmake@v3
tool: D:\a\_temp\909795809\cmake-3.21.1-windows-x86_64\bin\cmake.exe
tool: D:\a\_temp\909795809\ninja.exe
► Setup environment variables for triplet 'x64-windows' using 'vcpkg env'
⏱ elapsed: 2.161 seconds
Error: get_directories_non_recursive(D:\a\kangaru\kangaru\vcpkg_installed\x64-windows\tools): The system cannot find the path specified.
    
    
    
    at CMakeUtils.<anonymous> (D:\a\_actions\lukka\run-cmake\v3\dist\index.js:4765:27)
    at Generator.next (<anonymous>)
    at fulfilled (D:\a\_actions\lukka\run-cmake\v3\dist\index.js:4717:58)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
Error: run-cmake action execution failed: 'Error: get_directories_non_recursive(D:\a\kangaru\kangaru\vcpkg_installed\x64-windows\tools): The system cannot find the path specified.

Here’s my configuration:



on: [push, pull_request]

jobs:
  build:
    env:
      buildDir: ${{ github.workspace }}/build
    name: ${{ matrix.os }}-hosted-basic
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]
        include:
          - os: windows-latest
            triplet: x64-windows
            build-type: RelWithDebInfo
          - os: ubuntu-latest
            triplet: x64-linux
            build-type: RelWithDebInfo
          - os: macos-latest
            triplet: x64-osx
            build-type: RelWithDebInfo
            
    steps:
      - uses: actions/checkout@v2

      - name: get-cmake
        uses: lukka/get-cmake@v3.21.1

      - name: Run vcpkg
        uses: lukka/run-vcpkg@v6
        with:
          # Just install vcpkg for now, do not install any ports in this step yet.
          setupOnly: true
          # Location of the vcpkg as submodule of the repository.
          vcpkgDirectory: '${{ github.workspace }}/vcpkg'
          vcpkgGitCommitId: '57bd7102d9fd880daa1b0958692294c4a125f6d8'
          # Since the cache must be invalidated when content of the vcpkg.json file changes, let's
          # compute its hash and append this to the computed cache's key.
          appendedCacheKey: ${{ hashFiles( '**/vcpkg.json' ) }}
          vcpkgTriplet: ${{ matrix.triplet }}
          # Ensure the vcpkg artifacts are cached, they are generated in the 'CMAKE_BINARY_DIR/vcpkg_installed'.
          additionalCachedPaths: ${{ env.buildDir }}/vcpkg_installed
      - name: 'Run CMake with Ninja, install dependencies with vcpkg, build with CMake'
        uses: lukka/run-cmake@v3
        with:
          cmakeListsOrSettingsJson: CMakeListsTxtBasic
          cmakeListsTxtPath: '${{ github.workspace }}/CMakeLists.txt'
          useVcpkgToolchainFile: true
          cmakeAppendedArgs: '-GNinja -DKANGARU_TEST=ON'
          buildDirectory: ${{ env.buildDir }}

      - name: Test
        working-directory: ${{github.workspace}}/build
        # Execute tests defined by the CMake configuration.  
        # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
        run: ctest -C ${{env.build-type}}

Here’s the live error. As you can see from that page ubuntu and macos are working correctly.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:12 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
gracicotcommented, Aug 16, 2021

@lukka The workaround worked! I created the directory before running vcpkg and everything is working now. I’m gonna close the issue now, since the problem is actually on the vcpkg side and reported. Thank you very much for your support.

1reaction
gracicotcommented, Aug 12, 2021

Updating it to v7 didn’t helped. I’ll try to use egor-tensin/vs-shell@v2 and see if it helps.

Also, I took the v6 first since that was the version in your examples in your readme, maybe changing it would prevent new users to pick an outdated version?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Vcpkg "The system cannot find the path specified"
The problem was in variable Autorun . I've opened registry.exe and navigated to HKEY_CURRENT_USER\Software\Microsoft\Command ...
Read more >
`vcpkg env --tools` command broken · Issue #19552 - GitHub
Windows : "The system cannot find the path specified" when using run-cmake and run-vcpkg lukka/run-cmake#54.
Read more >
[Solved]-run-vcpkg and run-cmake in github actions
Coding example for the question run-vcpkg and run-cmake in github actions: The system cannot find the path specified on windows only-C++.
Read more >
The system cannot find the path specified. - MSDN - Microsoft
1>Description: The system cannot find the path specified. 1>HelpFile: complib.hlp 1>Build log was saved at "file://c:\dev_proj_old\Visual Studio ...
Read more >
System cannot find path specified - Intel Communities
Hi, I'm currently following the installation steps for the OpenVINO toolkit to work with the NCS2 on my Windows 10 laptop.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found