canxin121 / app_rhyme

使用Flutter和Rust构建的开源免费音乐软件
MIT License
1.1k stars 48 forks source link

编译和Debug流程文档 #31

Open justdoitgo opened 1 month ago

justdoitgo commented 1 month ago

Try dart pub outdated for more information. Compiling bin/build_tool_runner.dart to kernel file bin/build_tool_runner.dill. SEVERE: ================================================================================ SEVERE: Cargokit BuildTool failed with error: SEVERE: -------------------------------------------------------------------------------- SEVERE:
SEVERE: rustup not found in PATH. SEVERE:
SEVERE: Maybe you need to install Rust? It only takes a minute: SEVERE:
SEVERE: https://www.rust-lang.org/tools/install SEVERE:
SEVERE: ================================================================================ √ Built build\app\outputs\flutter-apk\app-debug.apk Installing build\app\outputs\flutter-apk\app-debug.apk... E/flutter (21406): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Invalid argument(s): Failed to load dynamic library 'librust_lib_app_rhyme.so': dlopen failed: library "librust_lib_app_rhyme.so" not found E/flutter (21406): #0 _open (dart:ffi-patch/ffi_dynamic_library_patch.dart:11:43) E/flutter (21406): #1 new DynamicLibrary.open (dart:ffi-patch/ffi_dynamic_library_patch.dart:22:12) E/flutter (21406): #2 new ExternalLibrary.open (package:flutter_rust_bridge/src/platform_types/_io.dart:42:47) E/flutter (21406): #3 loadExternalLibraryRaw (package:flutter_rust_bridge/src/loader/_io.dart:56:28) E/flutter (21406): #4 loadExternalLibrary (package:flutter_rust_bridge/src/loader/_io.dart:14:10) E/flutter (21406): #5 BaseEntrypoint._loadDefaultExternalLibrary (package:flutter_rust_bridge/src/main_components/entrypoint.dart:129:13) E/flutter (21406): #6 BaseEntrypoint.initImpl (package:flutter_rust_bridge/src/main_components/entrypoint.dart:48:31) E/flutter (21406): #7 RustLib.init (package:app_rhyme/src/rust/frb_generated.dart:36:20) E/flutter (21406): #8 main (package:app_rhyme/main.dart:22:17) E/flutter (21406): #9 _runMain. (dart:ui/hooks.dart:301:23) E/flutter (21406): #10 _delayEntrypointInvocation. (dart:isolate-patch/isolate_patch.dart:297:19) E/flutter (21406): #11 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12) E/flutter (21406): Debug service listening on ws://127.0.0.1:7414/iSc9m_mAIqQ=/ws Syncing files to device POT AL00... D/AwareBitmapCacher(21406): handleInit switch not opened pid=21406 D/ProfileInstaller(21406): Installing profile for canxin.app.rhyme 又遇到这个问题的么?打包后运行白屏

canxin121 commented 1 month ago

本项目为了能分离music_api和ui部分便于后续在其他地方使用,使用了rust来作为music_api的编写语言,因此编译时需要rust工具链,你需要安装rust才可以正常编译和debug。

SEVERE: rustup not found in PATH.
SEVERE:
SEVERE: Maybe you need to install Rust? It only takes a minute:
SEVERE:
SEVERE: https://www.rust-lang.org/tools/install