满庭芳·源流归一
结论:LinuxCNC rs274ngc 源码移植边界继续收拢。已将 rs274ngc 头文件纳入 manifest 跟踪,core 编译组仍只包含可编译源文件;启用 CNC_SIM_ENABLE_LINUXCNC_RS274_BACKEND 时 API 默认使用 LinuxCNC rs274 后端;M428/M429/M430 与 5axis/TRT/TDR/RTCP 相关路径继续保持来自 LinuxCNC 源码或 remap 配置的薄桥接。 验证:./test-linuxcnc-source-syntax.sh;./test-linuxcnc-api-native.sh;./test-native.sh;./test-linuxcnc-source-link.sh。
This commit is contained in:
@@ -6,67 +6,11 @@ cd "$(dirname "$0")"
|
||||
manifest=${1:-linuxcnc-rs274-source-files.txt}
|
||||
filter_group=${2:-core}
|
||||
output_mode=${3:-relative}
|
||||
linuxcnc_root=${LINUXCNC_ROOT:-../linuxcnc}
|
||||
|
||||
if [[ ! -f "$manifest" ]]; then
|
||||
echo "missing manifest: $manifest" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ ! -d "$linuxcnc_root" ]]; then
|
||||
echo "missing LinuxCNC root: $linuxcnc_root" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
case "$filter_group" in
|
||||
core|binding|tooldata|all)
|
||||
;;
|
||||
*)
|
||||
echo "unknown manifest source filter: $filter_group" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
case "$output_mode" in
|
||||
relative|full)
|
||||
;;
|
||||
*)
|
||||
echo "unknown manifest source output mode: $output_mode" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
seen_sources=()
|
||||
while IFS=: read -r group path note; do
|
||||
case "$group" in
|
||||
""|\#*)
|
||||
continue
|
||||
;;
|
||||
core|binding|tooldata)
|
||||
;;
|
||||
*)
|
||||
echo "unknown manifest group: $group" >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
|
||||
if [[ ! -f "$linuxcnc_root/$path" ]]; then
|
||||
echo "missing manifest file: $path" >&2
|
||||
exit 1
|
||||
fi
|
||||
if [[ "$group" == "core" ]]; then
|
||||
if printf '%s\n' "${seen_sources[@]}" | grep -Fx -- "$path" >/dev/null; then
|
||||
echo "duplicate manifest source: $path" >&2
|
||||
exit 1
|
||||
fi
|
||||
seen_sources+=("$path")
|
||||
fi
|
||||
|
||||
if [[ "$filter_group" == "all" || "$filter_group" == "$group" ]]; then
|
||||
if [[ "$output_mode" == "full" ]]; then
|
||||
printf '%s\n' "$linuxcnc_root/$path"
|
||||
else
|
||||
printf '%s\n' "$path"
|
||||
fi
|
||||
fi
|
||||
done < "$manifest"
|
||||
./list-linuxcnc-manifest-sources.sh \
|
||||
"$manifest" \
|
||||
"$filter_group" \
|
||||
"$output_mode" \
|
||||
core,header,binding,tooldata \
|
||||
core \
|
||||
"missing manifest file"
|
||||
|
||||
Reference in New Issue
Block a user