Enhanced onos-build-selective to react to any src file modifications and to also result in a cascaded build of app modules which require the modified modules.

Change-Id: I1c41ca2d11c936bfeb7307ce0e01b20d0141daa6
diff --git a/tools/dev/bin/onos-build-selective-hook b/tools/dev/bin/onos-build-selective-hook
index c27d747..fbe7752 100755
--- a/tools/dev/bin/onos-build-selective-hook
+++ b/tools/dev/bin/onos-build-selective-hook
@@ -1,16 +1,10 @@
 #!/bin/bash
 # ----------------------------------------------------------------------------
-# Echoes project-level directory if a Java file within is newer than the
+# Echoes project-level directory if a source file within is newer than the
 # target directory.
 # ----------------------------------------------------------------------------
 
-javaFile=${1#*\/src\/*\/java/}
-basename=${1/*\//}
+[ ${1/*\//} = "package-info.java" ] && exit 0
 
-[ $basename = "package-info.java" ] && exit 0
-
-src=${1/$javaFile/}
-project=${src/src*/}
-target=$project/target
-
-[ $target -nt ${src}$javaFile ] || echo ${src/src*/}
+project=${1/src*/}
+[ ${project}target -nt $1 ] || echo ${project}