summaryrefslogtreecommitdiffstats
path: root/scripts/makepkg.sh.in
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/makepkg.sh.in')
-rw-r--r--scripts/makepkg.sh.in6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index b8896258..179746d2 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -1354,6 +1354,12 @@ if [ ! -f "$BUILDSCRIPT" ]; then
# PKGBUILD passed through a pipe
BUILDSCRIPT=/dev/stdin
fi
+else
+ crlftest=$(file $BUILDSCRIPT | grep -F 'CRLF' || true)
+ if [ "$crlftest" != "" ]; then
+ error "$(gettext "%s contains CRLF characters and cannot be sourced.")" "$BUILDSCRIPT"
+ exit 1
+ fi
fi
source "$BUILDSCRIPT"