Import LinuxCNC source tree

This commit is contained in:
Wang Dequan
2026-08-20 06:17:39 +08:00
commit 2c814634c3
9429 changed files with 10556013 additions and 0 deletions

3
tests/twopass/a.hal Normal file
View File

@@ -0,0 +1,3 @@
loadrt and2 names=andX,andY
net p andX.in0 andX.in1 andY.out

6
tests/twopass/b.hal Normal file
View File

@@ -0,0 +1,6 @@
loadrt and2 names=andZ
net p andZ.in0
list pin
list param
list funct
list sig

11
tests/twopass/expected Normal file
View File

@@ -0,0 +1,11 @@
twopass:invoked with <> options
twopass:found ./a.hal
twopass:found ./b.hal
andX.in0 andX.in1 andX.out andX.time andY.in0 andY.in1 andY.out andY.time andZ.in0 andZ.in1 andZ.out andZ.time
andX.tmax andX.tmax-increased andY.tmax andY.tmax-increased andZ.tmax andZ.tmax-increased
andX andY andZ
p

18
tests/twopass/skip Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/bash
# haltcl needs the Tcl HAL extension (tcl/hal.so), which is only built
# in GUI builds (BUILD_GUI); skip in headless builds. The tcl dir is
# taken from TCLLIBPATH (exported by rip-environment).
set -u
if ! command -v tclsh >/dev/null 2>&1; then
echo "skip: tclsh not installed" >&2
exit 1
fi
read -r tcldir _ <<< "${TCLLIBPATH:-}"
if ! [ -f "${tcldir:-/nonexistent}/hal.so" ]; then
echo "skip: Tcl HAL extension not built (headless build)" >&2
exit 1
fi
exit 0

5
tests/twopass/test.sh Normal file
View File

@@ -0,0 +1,5 @@
#!/bin/sh
INI_FILE_NAME=tp.ini
# Need the export for the parse_ini call to work in haltcl
export INI_FILE_NAME
halrun "$INI_FILE_NAME"

5
tests/twopass/tp.ini Normal file
View File

@@ -0,0 +1,5 @@
[HAL]
TWOPASS=YesPlease
HALFILE=a.hal
HALFILE=b.hal