XDCTOOLS-429 - parallel build of app that includes xdc/cfg/global.h may fail
diff --git a/src/packages/xdc/bld/_gen.xs b/src/packages/xdc/bld/_gen.xs
index f130a20..e5100f1 100644
--- a/src/packages/xdc/bld/_gen.xs
+++ b/src/packages/xdc/bld/_gen.xs
@@ -1538,7 +1538,7 @@
  *  compiling objects in the package.  This is ensured by making ".interfaces"
  *  a "order-only" prerequisite of all objects.
  */
-function _mkObjs(objs, target, makeFileName, objListGoal, pkg, srcRels)
+function _mkObjs(objs, target, makeFileName, objListGoal, pkg, srcRels, cfgBase)
 {
     debug("_mkObjs(..., " + makeFileName + ", " + objListGoal + ", ...)");
     
@@ -1668,8 +1668,9 @@
             out.write("-include " + dep + "\n");
             out.write(dep + ": ;\n");
             out.write("endif\n\n");
+            var cfgHeader = cfgBase != null ? (cfgBase + ".h") : "";
             out.write(goalFile + ": | .interfaces\n");
-            out.write(goalFile + ": " + srcFile + " " + makeFileName + "\n");
+            out.write(goalFile + ": " + srcFile + " " + makeFileName + " " + cfgHeader + "\n");
             out.write("\t@$(RM) $@.dep\n");
 
             /*
@@ -2104,7 +2105,7 @@
     /* generate rules to compile the added objects */
     var makeFileName = (pkg.cfgDir + aexe.$private.name + ".mak").replace(/\/\/+/g, '/');
     out.write("-include " + makeFileName + "\n");
-    var objList = _mkObjs(objs, aexe.target, makeFileName, goal, pkg, srcRels);
+    var objList = _mkObjs(objs, aexe.target, makeFileName, goal, pkg, srcRels, cfgBase);
 
     /* create rule to link the program executable */
     if (sharedCfg.pkgName != pkg.name) {