Solves "/bin/sh: line 1: /usr/aarch64-linux-gnu/usr/lib64/qt6/bin/lrelease:
cannot execute binary file: Exec format error" when cross-building

--- a/cMake/FreeCAD_Helpers/SetupQt.cmake
+++ b/cMake/FreeCAD_Helpers/SetupQt.cmake
@@ -43,6 +43,13 @@ foreach(COMPONENT IN LISTS FREECAD_QT_COMPONENTS)
     set(Qt${COMPONENT}_VERSION ${Qt${FREECAD_QT_MAJOR_VERSION}${COMPONENT}_VERSION})
 endforeach()
 
+# when cross-compiling, use host's lrelease instead of cross one
+if(CMAKE_CROSSCOMPILING AND TARGET Qt6::lrelease)
+  set_target_properties(Qt6::lrelease PROPERTIES
+    IMPORTED_LOCATION "/usr/lib64/qt6/bin/lrelease"
+    IMPORTED_LOCATION_NONE "/usr/lib64/qt6/bin/lrelease")
+endif()
+
 set(CMAKE_AUTOMOC TRUE)
 set(CMAKE_AUTOUIC TRUE)
 set(QtCore_MOC_EXECUTABLE ${Qt${FREECAD_QT_MAJOR_VERSION}Core_MOC_EXECUTABLE})
