diff --git a/buildscripts/target-scripts/run-build b/buildscripts/target-scripts/run-build
index 6fa71db..0baa2ea 100755
--- a/buildscripts/target-scripts/run-build
+++ b/buildscripts/target-scripts/run-build
@@ -4,6 +4,7 @@
 #==============================================================================
 cd $(dirname $0)
 LOG="$(pwd)/build.log"
+KERNEL_DIR="ubuntu-2.6"
 BPID=0
 LPID=0
 # Older build environments check against unset variable.
@@ -49,7 +50,7 @@ if [ $CONCURRENCY_LEVEL -eq 0 ]; then
 	# Detect make parallel ability. I happen to know that this target did not exist until
 	# the make rules were refined to allow parallel builds.
 	#
-	if egrep "install-doc:.*install-headers" debian/rules.d/3-binary-indep.mk > /dev/null
+	if egrep "install-doc:.*install-headers" $KERNEL_DIR/debian/rules.d/3-binary-indep.mk > /dev/null
 	then
 		BLD_CPUS="`expr ${CONCURRENCY_LEVEL} \* 2`"
 		CL="-j${BLD_CPUS}"
@@ -135,7 +136,7 @@ function Cleanup()
 		rm -f $STATUSFILE
 	fi
 	if [ "${BUILDTARGET}" = "kernel" ]; then
-		cd ubuntu-2.6
+		cd $KERNEL_DIR
 		git clean -d -x -f
 	fi
 	wait
@@ -153,7 +154,7 @@ echo "${BUILDTARGET} build started $(date)" >$LOG
 
 case "${BUILDTARGET}" in
 	kernel)
-		cd ubuntu-2.6
+		cd $KERNEL_DIR
 		VER=$(GetVersion)
 		cat <<-EOD >>$STATUSFILE
 		VER=$VER
@@ -162,7 +163,7 @@ case "${BUILDTARGET}" in
 		EOD
 		rm -f ../linux-image-$VER-*
 		fakeroot debian/rules clean >$LOG 2>&1 || Cleanup $?
-		if [ ! -z "${CL}" ] then;
+		if [ ! -z "${CL}" ]; then
 			echo "ACTION=headers" >>$STATUSFILE
 			echo "ACTION=kernel" >>$STATUSFILE
 			dpkg-buildpackage -B ${CL} -us -uc >>$LOG 2>&1
