aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xTools/portbuild/scripts/buildscript40
1 files changed, 25 insertions, 15 deletions
diff --git a/Tools/portbuild/scripts/buildscript b/Tools/portbuild/scripts/buildscript
index bfe2342c5470..76b14f0a9e84 100755
--- a/Tools/portbuild/scripts/buildscript
+++ b/Tools/portbuild/scripts/buildscript
@@ -112,16 +112,6 @@ if [ $phase = 1 ]; then
else
- xvfb=0
- if which -s Xvfb; then
- xvfb=1
- pid=$(echo $$ % 32768 | bc)
- X11BASE=$(which Xvfb | sed -e 's./bin/Xvfb..')
- Xvfb :${pid} -fp ${X11BASE}/lib/X11/fonts/misc &
- DISPLAY=:${pid}
- export DISPLAY
- fi
-
cd $dir || exit 1
pkgname=$(make package-name)
@@ -144,6 +134,17 @@ else
echo "================================================================"
echo "====================<phase 4: make build>===================="
add_pkg ${BD}
+
+ xvfb=0
+ if which -s Xvfb; then
+ xvfb=1
+ pid=$(echo $$ % 32768 | bc)
+ X11BASE=$(which Xvfb | sed -e 's./bin/Xvfb..')
+ Xvfb :${pid} -fp ${X11BASE}/lib/X11/fonts/misc &
+ DISPLAY=:${pid}
+ export DISPLAY
+ fi
+
cd $dir
/pnohang $TIMEOUT /tmp/make.log4 ${pkgname} make build || cleanup 4
cat /tmp/make.log4
@@ -152,6 +153,7 @@ else
echo "====================<phase 5: make package>===================="
add_pkg ${RD}
cat > /tmp/mtree.exclude <<EOF
+./root/*
./var/*
./tmp/*
EOF
@@ -163,15 +165,17 @@ EOF
prefix=$(make -V PREFIX)
del_pkg ${pkgname}
- mtree -X /tmp/mtree.exclude -x -f /tmp/mtree -p / | egrep -v '^(usr/local/share/nls/POSIX|usr/local/share/nls/en_US.US-ASCII|etc/shells.bak|etc/services|compat |usr/X11R6 |etc/manpath.config|usr/local/info/dir)' > /tmp/list3
+ mtree -X /tmp/mtree.exclude -x -f /tmp/mtree -p / | egrep -v '^(usr/local/var|usr/local/www/|usr/X11R6/lib/X11/xserver/SecurityPolicy|usr/local/share/nls/POSIX|usr/local/share/nls/en_US.US-ASCII|etc/shells.bak|etc/services|compat |usr/X11R6 |etc/manpath.config|usr/local/info/dir)' > /tmp/list3
if [ -s /tmp/list3 ]; then
cd /
- grep ' extra$' /tmp/list3 | awk '{print $1}' | xargs -J % find % -ls > /tmp/list4
- grep ' missing$' /tmp/list3 > /tmp/list5
- grep -vE ' (extra|missing)$' /tmp/list3 > /tmp/list6
+ grep ' extra$' /tmp/list3 | awk '{print $1}' | xargs -J % find % -ls > /tmp/list4
+ grep ' missing$' /tmp/list3 > /tmp/list5
+ grep -vE ' (extra|missing)$' /tmp/list3 > /tmp/list6
if [ "x${PLISTCHECK}" != "x" ]; then
- echo "1" > /tmp/status
+ if grep -qE 'usr/(local|X11R6)/(bin|sbin|share/doc|share/locale/|lib/lib)' /tmp/list4; then
+ echo "1" > /tmp/status
+ fi
fi
echo "================================================================"
fi
@@ -186,6 +190,9 @@ EOF
del_pkg *
fi
+ echo
+ echo "=== Checking filesystem state"
+
if [ -s /tmp/list4 ]; then
echo "list of extra files and directories in / (not present before this port was installed but present after it was deinstalled)"
cat /tmp/list4
@@ -197,6 +204,9 @@ EOF
if [ -s /tmp/list6 ]; then
echo "list of filesystem changes from before and after port installation and deinstallation"
cat /tmp/list6
+ if [ "x${PLISTCHECK}" != "x" ]; then
+ echo "1" > /tmp/status
+ fi
fi
else
cleanup 5