diff --git a/scripts/build/ci/determine_git_changes.sh b/scripts/build/ci/determine_git_changes.sh
index 5cfa32880..09f6240d7 100755
--- a/scripts/build/ci/determine_git_changes.sh
+++ b/scripts/build/ci/determine_git_changes.sh
@@ -80,5 +80,19 @@ fi
 
 ## Print names of modified packages.
 for pkg in $PACKAGE_NAMES; do
-	echo "$pkg"
+	case "$pkg" in
+		# Skip packages that known to have long build time.
+		rust|texlive)
+			{
+				echo
+				echo "Package '$pkg' cannot be built via CI because it has"
+				echo "long build time."
+				echo
+			} >&2
+			continue
+			;;
+		*)
+			echo "$pkg"
+			;;
+	esac
 done