From dda5b4973e6d5ef3569096a97599894ac00ba7c6 Mon Sep 17 00:00:00 2001 From: cnc Date: Tue, 2 Jun 2026 14:02:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8C=89=E6=8F=90=E7=A4=BA=E8=AF=8D=E7=BB=93?= =?UTF-8?q?=E8=AE=BA=E8=A1=A5=20flags=20helper=20=E6=BA=90=E4=BE=9D?= =?UTF-8?q?=E6=8D=AE=E9=94=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- list-linuxcnc-native-linkflags.sh | 3 +++ list-linuxcnc-source-common-cxxflags.sh | 3 +++ list-linuxcnc-wasm-common-cxxflags.sh | 4 ++++ test-linuxcnc-wasm-cmake-safe-probe.sh | 1 + test-native.sh | 3 +++ 5 files changed, 14 insertions(+) diff --git a/list-linuxcnc-native-linkflags.sh b/list-linuxcnc-native-linkflags.sh index c2fde32..784a560 100755 --- a/list-linuxcnc-native-linkflags.sh +++ b/list-linuxcnc-native-linkflags.sh @@ -3,6 +3,9 @@ set -euo pipefail cd "$(dirname "$0")" +# LinuxCNC source basis: native source-link probes link against the built +# LinuxCNC lib directory required by src/emc/rs274ngc/Submakefile, including +# librs274 dependencies on linuxcncini, pyplugin, linuxcnchal, and tooldata. linuxcnc_root=${LINUXCNC_ROOT:-../linuxcnc} preflight_cache_dir=${CNC_SIM_PREFLIGHT_CACHE_DIR:-build/linuxcnc-helper-preflight-cache} diff --git a/list-linuxcnc-source-common-cxxflags.sh b/list-linuxcnc-source-common-cxxflags.sh index 48b0ad7..ade5e99 100755 --- a/list-linuxcnc-source-common-cxxflags.sh +++ b/list-linuxcnc-source-common-cxxflags.sh @@ -3,6 +3,9 @@ set -euo pipefail cd "$(dirname "$0")" +# LinuxCNC source basis: native RS274/source-link builds consume headers from +# src/Makefile SUBDIRS plus src/emc/rs274ngc/Submakefile, pythonplugin, +# nml_intf, motion, and include exports used by librs274 and its bindings. linuxcnc_root=${LINUXCNC_ROOT:-../linuxcnc} preflight_cache_dir=${CNC_SIM_PREFLIGHT_CACHE_DIR:-build/linuxcnc-helper-preflight-cache} include_python=0 diff --git a/list-linuxcnc-wasm-common-cxxflags.sh b/list-linuxcnc-wasm-common-cxxflags.sh index a778caf..f933e5c 100755 --- a/list-linuxcnc-wasm-common-cxxflags.sh +++ b/list-linuxcnc-wasm-common-cxxflags.sh @@ -3,6 +3,10 @@ set -euo pipefail cd "$(dirname "$0")" +# LinuxCNC source basis: wasm-safe probes compile the manifest-selected +# src/emc/rs274ngc, src/emc/ini, and src/emc/tooldata sources against +# browser shims, so include roots mirror LinuxCNC src/Makefile and the rs274, +# ini, and tooldata Submakefiles without linking native LinuxCNC libraries. linuxcnc_root=${LINUXCNC_ROOT:-../linuxcnc} preflight_cache_dir=${CNC_SIM_PREFLIGHT_CACHE_DIR:-build/linuxcnc-helper-preflight-cache} std_flag=-std=c++17 diff --git a/test-linuxcnc-wasm-cmake-safe-probe.sh b/test-linuxcnc-wasm-cmake-safe-probe.sh index 63abb53..dda7f39 100755 --- a/test-linuxcnc-wasm-cmake-safe-probe.sh +++ b/test-linuxcnc-wasm-cmake-safe-probe.sh @@ -629,6 +629,7 @@ if grep -RInF "${forbidden_common_flags_process_substitution}LINUXCNC_ROOT=\"\$l grep -RInF "${forbidden_common_flags_process_substitution}LINUXCNC_ROOT=\"\$linuxcnc_root\" ${forbidden_common_flags_helper}" test-linuxcnc-wasm-*.sh >&2 exit 1 fi +grep -F 'LinuxCNC source basis: wasm-safe probes compile the manifest-selected' list-linuxcnc-wasm-common-cxxflags.sh >/dev/null grep -F 'preflight_cache_dir=${CNC_SIM_PREFLIGHT_CACHE_DIR:-build/linuxcnc-helper-preflight-cache}' list-linuxcnc-wasm-common-cxxflags.sh >/dev/null grep -F 'check-linuxcnc-inputs-cached.sh --cache-dir "$preflight_cache_dir" --root-only' list-linuxcnc-wasm-common-cxxflags.sh >/dev/null grep -F -- '-DCNC_SIM_LINUXCNC_WASM_SOURCE_MANIFEST="$manifest"' build-wasm.sh >/dev/null diff --git a/test-native.sh b/test-native.sh index 8efc7c1..25f899f 100755 --- a/test-native.sh +++ b/test-native.sh @@ -74,6 +74,9 @@ grep -F 'grep -F '\''LinuxCNC source basis: src/emc/rs274ngc/rs274ngc_pre.cc pro grep -F 'core:src/emc/rs274ngc/rs274ngc_pre.cc:Interp implementation covered by rs274ngc_pre link probe' build-linuxcnc-wasm-standalone-probe.sh >/dev/null grep -F 'LinuxCNC source basis: linuxcnc-rs274-source-files.txt enumerates the native' list-linuxcnc-source-manifest-sources.sh >/dev/null grep -F 'LinuxCNC source basis: native source-link support objects come from the' list-linuxcnc-source-support-objects.sh >/dev/null +grep -F 'LinuxCNC source basis: native RS274/source-link builds consume headers from' list-linuxcnc-source-common-cxxflags.sh >/dev/null +grep -F 'LinuxCNC source basis: wasm-safe probes compile the manifest-selected' list-linuxcnc-wasm-common-cxxflags.sh >/dev/null +grep -F 'LinuxCNC source basis: native source-link probes link against the built' list-linuxcnc-native-linkflags.sh >/dev/null grep -F 'LinuxCNC source basis: this probe compiles the core RS274 interpreter sources' test-linuxcnc-source-objects.sh >/dev/null grep -F 'LinuxCNC source basis: this syntax probe checks the native RS274 manifest' test-linuxcnc-source-syntax.sh >/dev/null grep -F 'header:src/emc/ini/inifile.h:LinuxCNC C INI reader declarations exported by ini Submakefile' linuxcnc-rs274-wasm-source-files.txt >/dev/null