system76 / thelio-io-windows

WIP Windows driver for System76 Thelio Io
GNU General Public License v3.0
16 stars 8 forks source link

failed to run custom build command for `thelio-io v0.1.0 #16

Closed yoann-dufresne closed 1 year ago

yoann-dufresne commented 1 year ago

Hello everyone,

I'm trying to install the windows drivers on my new thelio but the build process in ending on error :

> python .\build.py
 INFO: Building the binary
   Compiling thelio-io v0.1.0 (C:\Users\yoann\thelio-io-windows)
error: failed to run custom build command for `thelio-io v0.1.0 (C:\Users\yoann\thelio-io-windows)`

Caused by:
  process didn't exit successfully: `C:\Users\yoann\thelio-io-windows\target\release\build\thelio-io-5b80d86e6a9a1fa3\build-script-build` (exit code: 101)
  --- stdout
  cargo:rerun-if-changed=build.rs
  cargo:rerun-if-changed=app.manifest
  package.metadata does not exist
  "C:\\Program Files (x86)\\Windows Kits\\10\\bin\\10.0.22000.0\\x64\\rc.exe"
  RC Output:
  Microsoft (R) Windows (R) Resource Compiler Version 10.0.10011.16384
  Copyright (C) Microsoft Corporation.  All rights reserved.

  ------
  RC Error:

  ------
  cargo:rustc-link-search=native=C:\Users\yoann\thelio-io-windows\target\release\build\thelio-io-d37d333640404b6e\out
  cargo:rustc-link-lib=dylib=resource
  cargo:rerun-if-changed=wrapper/Program.cs
  cargo:rerun-if-changed=wrapper/wrapper.csproj

  --- stderr
  The command could not be loaded, possibly because:
    * You intended to execute a .NET application:
        The application 'build' does not exist.
    * You intended to execute a .NET SDK command:
        No .NET SDKs were found.

  Download a .NET SDK:
  https://aka.ms/dotnet-download

  Learn about SDK resolution:
  https://aka.ms/dotnet/sdk-not-found
  thread 'main' panicked at 'failed to build wrapper: exit code: 0x80008091', build.rs:21:9
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Error[1] (Command): The 'cargo' application failed with exit code = 101
Traceback (most recent call last):
  File "C:\Users\yoann\thelio-io-windows\build.py", line 16, in <module>
    subprocess.check_call([
  File "C:\Python310\lib\subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cargo', 'wix', '--nocapture', '--verbose']' returned non-zero exit status 1.
> python .\build.py
 INFO: Building the binary
   Compiling thelio-io v0.1.0 (C:\Users\yoann\thelio-io-windows)
error: failed to run custom build command for `thelio-io v0.1.0 (C:\Users\yoann\thelio-io-windows)`

Caused by:
  process didn't exit successfully: `C:\Users\yoann\thelio-io-windows\target\release\build\thelio-io-5b80d86e6a9a1fa3\build-script-build` (exit code: 101)
  --- stdout
  cargo:rerun-if-changed=build.rs
  cargo:rerun-if-changed=app.manifest
  package.metadata does not exist
  "C:\\Program Files (x86)\\Windows Kits\\10\\bin\\10.0.22000.0\\x64\\rc.exe"
  RC Output:
  Microsoft (R) Windows (R) Resource Compiler Version 10.0.10011.16384
  Copyright (C) Microsoft Corporation.  All rights reserved.

  ------
  RC Error:

  ------
  cargo:rustc-link-search=native=C:\Users\yoann\thelio-io-windows\target\release\build\thelio-io-d37d333640404b6e\out
  cargo:rustc-link-lib=dylib=resource
  cargo:rerun-if-changed=wrapper/Program.cs
  cargo:rerun-if-changed=wrapper/wrapper.csproj

  --- stderr
  The command could not be loaded, possibly because:
    * You intended to execute a .NET application:
        The application 'build' does not exist.
    * You intended to execute a .NET SDK command:
        No .NET SDKs were found.

  Download a .NET SDK:
  https://aka.ms/dotnet-download

  Learn about SDK resolution:
  https://aka.ms/dotnet/sdk-not-found
  thread 'main' panicked at 'failed to build wrapper: exit code: 0x80008091', build.rs:21:9
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Error[1] (Command): The 'cargo' application failed with exit code = 101
Traceback (most recent call last):
  File "C:\Users\yoann\thelio-io-windows\build.py", line 16, in <module>
    subprocess.check_call([
  File "C:\Python310\lib\subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['cargo', 'wix', '--nocapture', '--verbose']' returned non-zero exit status 1.

Do you have any ideas on how to fix that ?

yoann-dufresne commented 1 year ago

Apparently, this is the following subcommand that is not working (from build.rs) :

 dotnet build --configuration Release
yoann-dufresne commented 1 year ago

I installed the wrong .NET sdk.

Problem solved -_-

dsnopek commented 1 year ago

I had this same problem. For if anyone finds this later, I made a PR that attempts to update the README to direct users to install the right SDK:

https://github.com/system76/thelio-io-windows/pull/19