From 5aca35b3239ad6738ff25f45423984cc9ef21bc3 Mon Sep 17 00:00:00 2001
From: Zhang Wen <zhw2101024@gmail.com>
Date: Sun, 24 May 2026 14:02:40 +0800
Subject: [PATCH] adjust version-check.sh to accept uutils coreutils

---
 chapter02/hostreqs.xml | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/chapter02/hostreqs.xml b/chapter02/hostreqs.xml
index 65bed3827..8f84e93cd 100644
--- a/chapter02/hostreqs.xml
+++ b/chapter02/hostreqs.xml
@@ -258,7 +258,13 @@ ver_kernel()
 }
 
 # Coreutils first because --version-sort needs Coreutils >= 7.0
-ver_check Coreutils      sort     8.1 || bail "Coreutils too old, stop"
+sort --version 2>&amp;1 | grep -E -q 'uutils'
+if [ $? -eq 0 ]
+then
+    ver_check Coreutils      sort     0.8 || bail "Uutils Coreutils too old, stop"
+else
+    ver_check Coreutils      sort     8.1 || bail "Coreutils too old, stop"
+fi
 ver_check Bash           bash     3.2
 ver_check Binutils       ld       2.13.1
 ver_check Bison          bison    2.7
-- 
2.53.0

