Files
MeowOS-SDK/examples/hello/build_hello.sh
T

18 lines
880 B
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/bin/bash
# build_hello.sh — 构建 hello(SDK 示例 App,视图框架批②③目录嵌套+视图深度化):
# 链 meow_ui.a(已内含 meow_font.o)+ 系统 libz.a(meow_font 的 inflate 依赖)+ -lpthread。
# 静态 MIPS32r2 (musl sf)。
#
# 交叉编译器 / sysroot 同 sdk/build_sdk.sh:默认 MeowOS 开发机路径,
# 可用环境变量 MEOW_CC / MEOW_SYSROOT 覆盖。mipsel -Wall -Wextra 0 warning。
set -e
cd "$(dirname "$0")"
CC="${MEOW_CC:-$HOME/Project/R3ProII/.tools/zig-mipsel-cc}"
SYSROOT="${MEOW_SYSROOT:-$HOME/Project/R3ProII/.tools/mipsel-linux-muslsf-cross/mipsel-linux-muslsf}"
"$CC" -Os -static -Wall -Wextra -I../sdk -I. \
app.c ui/home/home.c ui/full.c ui/demo/demo.c ui/demo/list/list.c ui/common/chrome.c \
logic/notify.c logic/state.c \
../sdk/meow_ui.a "$SYSROOT/lib/libz.a" -lpthread -o hello
ls -la hello
file hello