Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F157563421
D9332.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D9332.diff
View Options
Index: head/Mk/Scripts/qa.sh
===================================================================
--- head/Mk/Scripts/qa.sh
+++ head/Mk/Scripts/qa.sh
@@ -29,7 +29,7 @@
}
shebangonefile() {
- local f interp rc
+ local f interp interparg badinterp rc
f="$@"
rc=0
@@ -42,8 +42,12 @@
esac
interp=$(sed -n -e '1s/^#![[:space:]]*\([^[:space:]]*\).*/\1/p;2q' "${f}")
+ badinterp=""
case "${interp}" in
"") ;;
+ ${LOCALBASE}/bin/python|${PREFIX}/bin/python)
+ badinterp="${interp}"
+ ;;
${LINUXBASE}/*) ;;
${LOCALBASE}/bin/perl5.* | ${PREFIX}/bin/perl5.*)
# lang/perl5* are allowed to have these shebangs.
@@ -59,16 +63,27 @@
/bin/sh) ;;
/bin/tcsh) ;;
/usr/bin/awk) ;;
- /usr/bin/env) ;;
+ /usr/bin/env)
+ interparg=$(sed -n -e '1s/^#![[:space:]]*[^[:space:]]*[[:space:]]*\([^[:space:]]*\).*/\1/p;2q' "${f}")
+ case "${interparg}" in
+ python)
+ badinterp="${interp} ${interparg}"
+ ;;
+ esac
+ ;;
/usr/bin/nawk) ;;
/usr/bin/sed) ;;
/usr/sbin/dtrace) ;;
*)
- err "'${interp}' is an invalid shebang you need USES=shebangfix for '${f#${STAGEDIR}${PREFIX}/}'"
- rc=1
+ badinterp="${interp}"
;;
esac
+ if [ -n "${badinterp}" ]; then
+ err "'${badinterp}' is an invalid shebang you need USES=shebangfix for '${f#${STAGEDIR}${PREFIX}/}'"
+ rc=1
+ fi
+
return ${rc}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, May 23, 9:13 PM (3 h, 53 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33454556
Default Alt Text
D9332.diff (1 KB)
Attached To
Mode
D9332: qa.sh: treat python and python[23] as an invalid shebangs
Attached
Detach File
Event Timeline
Log In to Comment