Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error - flutter windows x64 arm #29

Open
nowfalsalahudeen opened this issue Oct 8, 2024 · 5 comments
Open

Build error - flutter windows x64 arm #29

nowfalsalahudeen opened this issue Oct 8, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@nowfalsalahudeen
Copy link

Unhandled exception:
C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(254,5): error MSB8066: Custom build for 'C:\Users\nowfal\VaasITS\edr-pos-userapp-flutter\build\windows\x64\CMakeFiles\f1dcc421454c8680511f58c52c0a54fe\rhttp.dll.rule;C:\Users\nowfal\VaasITS\edr-pos-userapp-flutter\build\windows\x64\CMakeFiles\be11f645584e32d7ab5df57c3d550741\rhttp_cargokit.rule;C:\Users\nowfal\VaasITS\edr-pos-userapp-flutter\windows\flutter\ephemeral.plugin_symlinks\rhttp\windows\CMakeLists.txt' exited with code -1. [C:\Users\nowfal\VaasITS\edr-pos-userapp-flutter\build\windows\x64\plugins\rhttp\rhttp_cargokit.vcxproj]
Build process failed.

@Tienisto Tienisto added the bug Something isn't working label Dec 9, 2024
@Minessential
Copy link

Minessential commented Jan 11, 2025

hi, does there have any solution? i meet the same question on arm flutter.

@nowfalsalahudeen
Copy link
Author

no fixes till now

@Tienisto
Copy link
Owner

You need to build with debug logs to get more info

@Minessential
Copy link

Minessential commented Jan 12, 2025

You need to build with debug logs to get more info

here are the detail of build log, it may help to solve the question:

[        ]   Executing Touch task on "ARM64\Debug\rhttp_cargokit\rhttp_cargokit.tlog\unsuccessfulbuild".
[   +7 ms] CustomBuild:
[   +1 ms]
"Generating dependency for 'C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\2cb4590aedfaf45f86ed8c903583a734\rhttp_cargokit.rule' depends on 'C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\682045c109b323bee020e448fd464ba5\rhttp.dll.rule' to generate 'C:\USERS\MINE\CODE\FLUTTER\LOCALSEND\APP\BUILD\WINDOWS\ARM64\PLUGINS\RHTTP\DEBUG\RHTTP.DLL'. The item could not be generated in parallel."
[ +146 ms]   Generating Debug/rhttp.dll, _phony_
[ +363 ms]   SEVERE: ================================================================================
[  +12 ms] SEVERE: Cargokit BuildTool failed with error: [C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj]
[   +1 ms]   SEVERE: --------------------------------------------------------------------------------
[        ]   SEVERE: Exception: Unknown target platform: windows-arm64
[        ]   SEVERE: --------------------------------------------------------------------------------
[        ]   SEVERE: #0      BuildCMake.build (package:build_tool/src/build_cmake.dart:23:7)
[   +1 ms]   SEVERE: #1      BuildCMakeCommand.runBuildCommand (package:build_tool/src/build_tool.dart:79:17)
[   +2 ms]   SEVERE: #2      BuildCommand.run (package:build_tool/src/build_tool.dart:37:11)
[        ]   SEVERE: #3      CommandRunner.runCommand (package:args/command_runner.dart:212:27)
[        ]   SEVERE: #4      CommandRunner.run.<anonymous closure> (package:args/command_runner.dart:122:25)
[        ]   SEVERE: #5      new Future.sync (dart:async/future.dart:313:27)
[        ]   SEVERE: #6      CommandRunner.run (package:args/command_runner.dart:122:14)
[        ]   SEVERE: #7      runMain (package:build_tool/src/build_tool.dart:251:18)
[        ]   SEVERE: #8      runMain (package:build_tool/build_tool.dart:7:21)
[        ]   SEVERE: #9      main (file:///c:/users/mine/code/flutter/localsend/app/build/windows/arm64/plugins/rhttp/cargokit_build/tool/bin/build_tool_runner.dart:3:15)
[        ]   SEVERE: #10     _delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:295:33)
[        ]   SEVERE: #11     _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
[        ]   SEVERE: --------------------------------------------------------------------------------
[   +1 ms]   SEVERE: BuildTool arguments: [build-cmake]
[        ]   SEVERE: ================================================================================
[  +19 ms] C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(254,5): error MSB8066: The custom build for "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\682045c109b323bee020e448fd464ba5\rhttp.dll.rule;C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\2cb4590aedfaf45f86ed8c903583a734\rhttp_cargokit.rule" exited with code -1. [C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj]
[   +6 ms] Completed build for project "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj" (default target) - failed.
[   +2 ms] Completed build for project "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\ALL_BUILD.vcxproj" (default target) - failed.
[   +1 ms] Completed build for project "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\INSTALL.vcxproj" (default target) - failed.
[  +23 ms] Build failed.
[   +6 ms] "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\INSTALL.vcxproj" (default target) (1) ->
[        ] "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\ALL_BUILD.vcxproj" (default target) (3) ->
[        ] "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj" (default target) (4) ->
[        ] (CustomBuild target) ->
[        ]   SEVERE: Cargokit BuildTool failed with error: [C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj]
[        ]   C:\Program Files\Microsoft Visual Studio\2022\Community\MSBuild\Microsoft\VC\v170\Microsoft.CppCommon.targets(254,5): error MSB8066: The custom build for "C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\682045c109b323bee020e448fd464ba5\rhttp.dll.rule;C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\CMakeFiles\2cb4590aedfaf45f86ed8c903583a734\rhttp_cargokit.rule" exited with code -1. [C:\Users\Mine\Code\Flutter\localsend\app\build\windows\arm64\plugins\rhttp\rhttp_cargokit.vcxproj]
[   +1 ms]     0 warnings
[        ]     2 errors
[        ] Time elapsed 00:00:01.99
[ +108 ms] Building Windows application... (completed in 7.2s)
[+7578 ms] Error: Build process failed.
[   +2 ms] "flutter run" took 18,368ms.
[   +3 ms]
           #0      throwToolExit (package:flutter_tools/src/base/common.dart:10:3)
           #1      RunCommand.runCommand (package:flutter_tools/src/commands/run.dart:860:9)
           <asynchronous suspension>
           #2      FlutterCommand.run.<anonymous closure> (package:flutter_tools/src/runner/flutter_command.dart:1450:27)
           <asynchronous suspension>
           #3      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:153:19)
           <asynchronous suspension>
           #4      CommandRunner.runCommand (package:args/command_runner.dart:212:13)
           <asynchronous suspension>
           #5      FlutterCommandRunner.runCommand.<anonymous closure> (package:flutter_tools/src/runner/flutter_command_runner.dart:421:9)
           <asynchronous suspension>
           #6      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:153:19)
           <asynchronous suspension>
           #7      FlutterCommandRunner.runCommand (package:flutter_tools/src/runner/flutter_command_runner.dart:364:5)
           <asynchronous suspension>
           #8      run.<anonymous closure>.<anonymous closure> (package:flutter_tools/runner.dart:131:9)
           <asynchronous suspension>
           #9      AppContext.run.<anonymous closure> (package:flutter_tools/src/base/context.dart:153:19)
           <asynchronous suspension>
           #10     main (package:flutter_tools/executable.dart:94:3)
           <asynchronous suspension>


[   +2 ms] ensureAnalyticsSent: 0ms
[        ] Running 2 shutdown hooks
[  +12 ms] Shutdown hooks complete
[        ] exiting with code 1

@Minessential
Copy link

I found the issue. The cargokit tool used by rhttp does not support the Windows arm64 platform. You can refer to [this pull request] and manually modify the content of the rhttp\cargokit\build_tool\lib\src\target.dart file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants