Bug 537316 - 11] Fixing gather parts for patch build

Change-Id: Id673891789c1e6580682d84bc3545e4516d926fb
Signed-off-by: Sravan Kumar Lakkimsetti <sravankumarl@in.ibm.com>
diff --git a/production/build-functions.shsource b/production/build-functions.shsource
index d921bad..78e2120 100755
--- a/production/build-functions.shsource
+++ b/production/build-functions.shsource
@@ -651,8 +651,16 @@
   BUILD_ID="$1"; shift
   REPO_DIR="$1"; shift
   BUILD_DIR="$1"; shift
-  TARGET_PATH=eclipse.platform.releng.tychoeclipsebuilder/eclipse.platform.repository/target/repository
-  REPO_DIR_REPOSITORY=$REPO_DIR/$TAGET_PATH
+  if [[ -n "${PATCH_BUILD}" ]]
+  then
+    PATCH_BUILD_GENERIC=java11patch
+    TARGET_PATH=eclipse.platform.releng.tychoeclipsebuilder/${PATCH_BUILD}/eclipse.releng.repository.${PATCH_BUILD_GENERIC}/target/repository
+    REPO_DIR_REPOSITORY=$REPO_DIR/${TARGET_PATH}
+  else
+    TARGET_PATH=eclipse.platform.releng.tychoeclipsebuilder/eclipse.platform.repository/target/repository
+    REPO_DIR_REPOSITORY=$REPO_DIR/$TAGET_PATH
+  fi
+  
   if [[ -d "$REPO_DIR_REPOSITORY" ]]
   then
     pushd "$REPO_DIR"