Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 8 Sep 2016 14:12:41 +0000 (UTC)
From:      Mathieu Arnold <mat@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r421553 - head/Mk/Scripts
Message-ID:  <201609081412.u88ECfoH067404@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mat
Date: Thu Sep  8 14:12:41 2016
New Revision: 421553
URL: https://svnweb.freebsd.org/changeset/ports/421553

Log:
  Disable some checks for linux ports.
  
  - shebang check: skip scripts in LINUXBASE.  Things like /bin/bash are
    valid in a Linux context.  Also, these scripts usually only work with
    a Linux shell so it doesn't make sense to try to make them work from a
    FreeBSD shell.
  - prefixvar check: allow LINUXBASE/var.
  - proxydeps check: only test FreeBSD ELF files because ldd(1) doesn't
    work with other ELF files.
  
  PR:		212419
  Submitted by:	tijl
  Sponsored by:	Absolight

Modified:
  head/Mk/Scripts/qa.sh   (contents, props changed)

Modified: head/Mk/Scripts/qa.sh
==============================================================================
--- head/Mk/Scripts/qa.sh	Thu Sep  8 14:08:04 2016	(r421552)
+++ head/Mk/Scripts/qa.sh	Thu Sep  8 14:12:41 2016	(r421553)
@@ -26,9 +26,9 @@ shebangonefile() {
 	f="$@"
 	rc=0
 
-	# blacklist of files which are not intended to be runnable
-	case "${f##*/}" in
-	*.pm|*.pod|*.txt)
+	# whitelist some files
+	case "${f}" in
+	*.pm|*.pod|*.txt|${STAGEDIR}${LINUXBASE}/*)
 		return 0
 		;;
 	esac
@@ -306,7 +306,7 @@ libperl() {
 }
 
 prefixvar() {
-	if test -d ${STAGEDIR}${PREFIX}/var; then
+	if [ ${PREFIX} != ${LINUXBASE} -a -d ${STAGEDIR}${PREFIX}/var ]; then
 		warn "port uses ${PREFIX}/var instead of /var"
 	fi
 }
@@ -662,7 +662,7 @@ proxydeps() {
 	done <<-EOT
 	$(cd ${STAGEDIR} && find -s . -type f \( -perm +111 -o -name '*.so*' \) | \
 		file -F $'\1' -f - | \
-		grep -a 'ELF.*dynamically linked' | \
+		grep -a 'ELF.*FreeBSD.*dynamically linked' | \
 		cut -f 1 -d $'\1'| \
 		sed -e 's/^\.//')
 	EOT



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201609081412.u88ECfoH067404>