Index: /trunk/psconfig/psbuild
===================================================================
--- /trunk/psconfig/psbuild	(revision 16127)
+++ /trunk/psconfig/psbuild	(revision 16128)
@@ -13,4 +13,7 @@
 $verbose = 0;
 
+$extlibs = "none";
+$extperl = "none";
+
 @tARGV = ();
 for (; @ARGV > 0; ) {
@@ -23,6 +26,24 @@
         shift; next;
     }
+    if ($ARGV[0] eq "-extlibs") {
+	$extlibs = $ARGV[1];
+        shift; shift; next;
+    }
+    if ($ARGV[0] eq "-extperl") {
+	$extperl = $ARGV[1];
+        shift; shift; next;
+    }
     if ($ARGV[0] eq "-clean") {
 	$clean = 1;
+        shift; next;
+    }
+    if ($ARGV[0] eq "-extcheck") {
+	$extlibs = "check";
+	$extperl = "check";
+        shift; next;
+    }
+    if ($ARGV[0] eq "-extbuild") {
+	$extlibs = "build";
+	$extperl = "build";
         shift; next;
     }
@@ -118,4 +139,22 @@
     # use psconfig.csh to set needed build aliases
 
+    if ($extlibs eq "check") { 
+	$status = vsystem ("pschecklibs");
+	if ($status) { die "failed to find external libraries\n"; }
+    }
+    if ($extlibs eq "build") { 
+	$status = vsystem ("pschecklibs -build");
+	if ($status) { die "failed to build external libraries\n"; }
+    }
+
+    if ($extperl eq "check") { 
+	$status = vsystem ("pschecklperl");
+	if ($status) { die "failed to find external perl modules\n"; }
+    }
+    if ($extperl eq "build") { 
+	$status = vsystem ("pscheckperl -build");
+	if ($status) { die "failed to build external perl modules\n"; }
+    }
+
     # set the psconfig version:
     if ("$version" eq "") {
@@ -221,5 +260,5 @@
 	}
 
-	if (! -e "Makefile") { &failure($cvsname[$i], "missing makefile"); }
+	if (! -e "Makefile") { &failure($cvsname[$i], "missing makefile: do you need to run the -dev developer build?"); }
 
 	if ($clean) { 
