HarmonyOS next之鸿蒙Flutter生成hap包编译过程可能遇到的问题
配置别名,简化日常开发的编译命令
在环境变量配置文件中配置别名,简化flutter鸿蒙化日常使用的命令
- windows, 使用
Git Bash
可以执行常见的linux命令。(使用方式:鼠标右键点击文件管理器中的空白处,左键点击 Git Bash Here) - linux, 修改
~/.bash_profile
- mac, 修改
~/.bash_profile
, 并在~/.zshrc
中加上source ~/.bash_profile
# --local-engine 参数可选,指向自行编译的engine产物,建议在 linux/mac 环境使用
export ENGINE_DIR=~/ohos/engine
export ENGINE_DEBUG=$ENGINE_DIR/src/out/ohos_debug_unopt_arm64
export ENGINE_PROFILE=$ENGINE_DIR/src/out/ohos_profile_arm64
export ENGINE_RELEASE=$ENGINE_DIR/src/out/ohos_release_arm64
alias fbuildD="flutter build hap --l